FLCU – Fuzzy logic controller unit
Block SymbolLicensing group: ADVANCED
Function Description
The FLCU block implements a simple fuzzy logic controller with two inputs and one output.
Introduction to fuzzy logic problems can be found in [4].
The output is defined by trapezoidal membership functions of linguistic terms of the u and v inputs, impulse membership functions of linguistic terms of the y output and inference rules in the form
If (u is ) AND (v is ), then (y is ),
where are the linguistic terms of the u input; are the linguistic terms of the v input and are the linguistic terms of the y output. Trapezoidal (triangular) membership functions of the u and v inputs are defined by four numbers as depicted below.
Not all numbers are mutually different in triangular functions. The matrices of membership functions of the u and v input are composed of rows . The dimensions of matrices mfu and mfv are () and () respectively.
The impulse 1st order membership functions of the y output are defined by the triplet
where is the value assigned to the linguistic term in the case of . If and , then the term is assigned the value of . The output membership function matrix sty has a dimension of () and contains the rows .
The set of inference rules is also a matrix whose rows are , where and defines a particular linguistic term of the and inputs and output respectively. The number defines the weight of the rule in percents . It is possible to suppress or emphasize a particular inference rule if necessary.
Inputs
u | First analog input of the block | double |
v | Second analog input of the block | double |
Outputs
y | Analog output of the block | double |
ir | Dominant rule | long |
wr | Degree of truth of the dominant rule | double |
Parameters
umax | Upper limit of the u input 1.0 | double |
umin | Lower limit of the u input -1.0 | double |
nu | Number of membership functions of the input u 1 25 3 | long |
vmax | Upper limit of the v input 1.0 | double |
vmin | Lower limit of the v input -1.0 | double |
nv | Number of membership functions of the input v 1 25 3 | long |
ny | Number of membership functions of the output y 1 100 3 | long |
nr | Number of inference rules 1 25 3 | long |
mfu | Matrix of membership functions of the input u [-1 -1 -1 0; -1 0 0 1; 0 1 1 1] | double |
mfv | Matrix of membership functions of the input v [-1 -1 -1 0; -1 0 0 1; 0 1 1 1] | double |
sty | Matrix of membership functions of the output y [-1 0 0; 0 0 0; 1 0 0] | double |
rls | Matrix of inference rules [1 2 3 100; 1 1 1 100; 1 0 3 100] | byte |
[Previous] [Back to top] [Up] [Next]