Back Up Next

Introduction

The fuzzy logic theory overcomes the difficulty of defining an explicit relationship between the current system states and the actions required to achieve a certain system performance by using linguistic rules. These rules could be determined with an experts knowledge or simply by stating the required cause effect relation in common language, which has the form of if-then statements. Furthermore, the rules could be learned during some kind of training algorithm [4].

This chapter uses a simple fuzzy controller to introduce the fuzzy elements interactions before exploring a more sophisticated representation of the fuzzy algorithm. The rule base of the proposed fuzzy filter is determined by an analogy to the optimal solution of the rest-to-rest maneuver of a second order system [3], where we propose a relationship between the damping and stiffness determined by the rest-to-rest maneuver to the smoothing parameter tex2html_wrap_inline1001 and tex2html_wrap_inline1003 .

Principles of the Fuzzy Algorithm

Fuzzy Logic on an Example

The interaction between the fuzzy elements is first shown on an single-input-single-output example, followed by description of a general fuzzy logic algorithm. Suppose one is interested in keeping a constant flow out of a valve, one would open the valve if the flow slows down and vice versa. The appropriate rules may formulated as:
bullet tex2html_wrap_inline1009 : IF flow is zero THEN valve opening is large
bullet tex2html_wrap_inline1011 : IF flow is small THEN valve opening is medium
bullet tex2html_wrap_inline1013 : IF flow is medium THEN valve opening is small
bullet tex2html_wrap_inline1015 : IF flow is large THEN valve opening is zero
A human operator might use these rules since he is capable of distinguishing between the linguistic terms small, medium etc. Since the flow rate and the valve position are quantified using crisp values, these rules cannot be applied directly to the system. However, what one human operator determines the flow to be small, in contrast, others state that the flow exhibits medium behavior. The resulting valve opening depends on characterizing the current flow. The above two operators might negotiate between the valve positions medium and small, which again are uncertainties of the operator. Certain human operators also have different belief about the linguistic terms small, medium, etc. These vague information are modeled in the fuzzy theory by assigning the input variables (here the flow) to memberships of linguistic terms as opposed to declaring the input to a fixed value in the input space on which a mathematical model calculates the required control. The membership functions, tex2html_wrap_inline1017 , are defined over the entire universe of discourse such that every input has a specific membership of a fuzzy set like large, medium, etc. The membership functions of the above example are defined as triangular shapes over the universe of discourse [0,3] as shown in Figure 1. The shape of the membership functions is arbitrary and changes are reflected in different behavior of the fuzzy system. The membership functions and the applied fuzzy algorithm may be represented in the continuous or discrete space depending on the computational cost. Throughout this work only the discrete representation is considered, whereas the continuous representation could be applied in similar formulations.

   figure38
Figure 1: Input and Output Membership function of the Example

For reasons of generality and brevity it is convenient to introduce a label for each rule. Since each input could possible be related to every output, a matrix of rules with the size of [number of input membership functions tex2html_wrap_inline1021 number of output membership functions] is constructed. Thus, the four given example rules are labeled as shown above. The first rule, tex2html_wrap_inline1009 , for instance, shows that the first input membership function is combined with the fourth output membership function. This labeling scheme is also convenient with the use of confidences of each rule. A confidence of a rule expresses the belief in this rule, and is a gain between zero and one. If more than one rule is applied to one input membership function, the confidences should be normalized such that the sum equals one. This is not necessarily required, but its use permits scaling the output. The general form of the fuzzy rule can now be written as:

  equation44

where tex2html_wrap_inline1025 and tex2html_wrap_inline1027 are the input and output variables of dimension m and n. Each input and output set contains tex2html_wrap_inline1033 and tex2html_wrap_inline1035 membership functions. For a single input-single output fuzzy system the rule and confidence matrixes are of size [ tex2html_wrap_inline1037 ], whereas for multi-input-output fuzzy systems the rule and confidence matrixes are of size [ tex2html_wrap_inline1039 ] thus avoiding higher order matrixes.

Since the input and often the output are crisp values, processing the crisp values using linguistic rule bases requires the input to be fuzzyfied and the output to be defuzzyfied. This procedure assigns a certain numerical value refered to as degrees of membership functions ( tex2html_wrap_inline1041 ) and vice versa for degrees on output memberships ( tex2html_wrap_inline1043 ) a crisp output value. Since both schemes differ from each other, they are discussed separately. The input fuzzyfication assigns degrees of active membership functions to a crisp value. As shown as in Figure 2, Part A the example input, x, has non-zero membership in the input set zero and small with the degree of tex2html_wrap_inline1047 and tex2html_wrap_inline1049 . To explain the output defuzzyfication we need to construct first the fuzzy output according to the fuzzy inference. Since this example input activates the membership functions of zero (i=1) and small (i=2), which means that all rules tex2html_wrap_inline1055 and tex2html_wrap_inline1057 , where tex2html_wrap_inline1059 , need to be evaluated. According to the example rules there are two rules tex2html_wrap_inline1009 and tex2html_wrap_inline1011 . The first rule suggests: If the input is zero then the output should be large, which means that the output membership function large is activated. Since the input has a fractional membership of the input set zero, the corresponding membership of the output set large needs also be adjusted. For purpose of demonstration the simple truncation algorithm is applied, where the output set large is truncated to the membership of the input set tex2html_wrap_inline1047 . Similarly the second fuzzy influence can be constructed. Part C in Figure 2 visualizes this algorithm. Note, that a multivariable input space is mapped in a hyper membership set, where the inputs are combined with respect to each rule. Furthermore, since rule tex2html_wrap_inline1009 and rule tex2html_wrap_inline1011 are firing, a compromise between these two suggested outputs needs to be achieved. During this step, the and operation is carried out which is either the algebraic (Addition) or logic (Maximum) operator. Combining the two fuzzy influences with the addition operator yields the fuzzy output shown in Figure 2, Part D. This linguistic (fuzzy) output is quite certain that the output should be somewhat medium and also somewhat large, let us say somewhat between medium and large. The human operator might be able to interpret this linguistic terms as opposed to most technical applications requiring a crisp value. This final step of defuzzyfication loses all the important information about the fuzzy output by reducing it to one crisp value, the defuzzyfied output.

  figure92
Figure 2: Fuzzy Example Algorithm  

A General Fuzzy Logic Approach

The above example of a fuzzy algorithm contains a lot of motivation for use of fuzzy systems instead of equations describing the same process. However, implementing the fuzzy algorithm in a lot more complex requiring a more sophisticated process. Figure 3 recalls the steps taken by the fuzzy decision process.

  figure98
Figure 3: Fuzzy Flow Chart  

The fuzzyfication maps the crisp value tex2html_wrap_inline1075 into the fuzzy set tex2html_wrap_inline1077 . A common approach is the singleton fuzzyfication where a binary membership is used. eq:single represents the singleton method.

  equation108

The fuzzy influence combines the input sets with the output sets based on the fuzzy rules, which results in the fuzzy set with the membership tex2html_wrap_inline1083 for each rule and the fuzzy rule base tex2html_wrap_inline1085 combining the separate rules. The individual membership functions are calculated as:

equation123

where tex2html_wrap_inline1087 is the AND-operator. If tex2html_wrap_inline1025 is multivariate, each input set needs to be related to the other according to:

equation136

Combining the individual sets with the OR-operator ( tex2html_wrap_inline1093 ) yields the input-output-relation:

  equation149

where the indices i and j are within the range 1 to tex2html_wrap_inline1103 and 1 to tex2html_wrap_inline1107 . The fuzzy intersection AND may be a algebraic product operator or a the logic minimum operator. Whereas, the OR intersection can be derived using the addition or maximum operator. These are the most popular fuzzy intersection, where the logic operators in the literature referred to as Mamdani intersection. Table 1 summarizes the most popular fuzzy intersections.

   table154
Table 1: Common Fuzzy Intersections 

The fuzzy rule base eq:rulebase can now be used to generate the fuzzy output distribution for a given input set tex2html_wrap_inline1109 obtained by the fuzzyfication process. This procedure is known as the compositional rule of inference, which may be written as:

equation184

where `` tex2html_wrap_inline1111 '' is the composition operator and tex2html_wrap_inline1113 is the degree of output membership functions. The composition procedure is similar to the example in Figure 2 where the suggested output by each rule is truncated and than added to get the final output distribution. Therefore, the composition operator performs a comparison of the two membership functions and summarizes over all possible values of tex2html_wrap_inline1075 . The composition operator for fuzzy sets defined on a continuous domain in a more general expression may be written as:

equation194

and similarly in the discrete domain as:

  equation203

For a singleton fuzzyfication Equation 8 reduces to:

  equation213

where tex2html_wrap_inline1117 is the discrete value closest to the input tex2html_wrap_inline1075 .

Figure 4 illustrates the rule base given in Equation 5 for the fuzzy example introduced above. The universe is discrete, and the AND and OR operators are represented with the algebraic operations.

  figure209
Figure 4: Relational Matrix of the above Example 

The relational matrix represents the shape of the fuzzy input and output sets and shows the underlying fuzzy algorithm. Observing the relational matrix in Figure 4, illustrates the mapping of the input space to the output space with respect to the four example rules (four spikes). The influence of the rule confidences on the relational matrix is also shown in Figure 4, where the confidence of the rule tex2html_wrap_inline1009 is reduced to tex2html_wrap_inline1123 . Thus, the weight of the output according to this rule reduces and the spike of the relational matrix is therefore scaled down. If the input is singleton fuzzyfied, eq:mubs can be applied, which means that the fuzzy output is given by the appropriate column of the discrete relational matrix. Figure 5 shows such a slice through the relational matrix at the crisp input value of 1.25.

  figure219
Figure 5: Discrete Fuzzy Output Membership 

As mentioned before, the fuzzy, imprecise output, tex2html_wrap_inline1127 needs to be transformed to a crisp value using a defuzzyfication scheme. The most popular defuzzyfication is the center of gravity defuzzyfication, which is defined for the continuous and discrete domain as follows:

  eqnarray242

Exploiting the eq:cogd and applying algebraic operators, reduces the calculation of the output to [1]:

  equation255

where tex2html_wrap_inline1129 are the weights similar to the joints of an Associative Memory Network (AMN). The relationship between the confidences and the weights can be shown to be:

equation267

where tex2html_wrap_inline1131 is the center of the tex2html_wrap_inline1133 output membership function. For a singleton input fuzzyfication eq:cogd2 reduces to:

equation272

This representation is less computational expensive as opposed to storing the relational matrix and carrying out the matrix operations.

The Fuzzy Algorithm in Target Tracking

Unlike the fixed gain tex2html_wrap_inline1001 - tex2html_wrap_inline1003 filter the fuzzy logic based tex2html_wrap_inline1001 - tex2html_wrap_inline1003 filter changes the smoothing parameter, tex2html_wrap_inline1001 and tex2html_wrap_inline1003 , as a function of the maneuver error and error rate with the tracking performance comparable to a Kalman filter, but without modeling a target system and a sensor noise model. Furthermore, the computational cost is less than that of the Kalman filter. Moreover, the fuzzy algorithm reaches a decision by considering several different situations at the same time resulting in a more human like decision.

The Fuzzy Logic Inputs

The maneuver error is now defined as the difference between the observed position and the predicted position of the target. Since, the filter estimates the targets future position, the maneuver error at the current time influences the choise of the appropriate smoothing parameter tex2html_wrap_inline1001 and tex2html_wrap_inline1003 . The maneuver error at the current time may be written as:

  equation282

Besides the information ``How close the prediction is to the true target position'', the change of the maneuver error is also an important fact since different action must be taken whether the maneuver error is about to increase or decrease. The error rate is defined as follows:

  equation285

For purpose of generality of the target tracker, normalization of the maneuver error and error rate are desired. Chan [2] introduced an effective normalization scheme, where the normalization denominator is variable and depends on the magnitude of the error. The following three situations may occur:

  1. The magnitude of the error is less than the difference between the current and previous observed position.

      equation290

  2. The magnitude of the error is greater than the difference between the current and previous observed position.

      equation295

  3. The predicted position equals the current observed position and the current and previous observations are the same.

      equation300

Plotting the Equations (16) to (18), yields the normalized error shown in Figure 6, which is a saturation function with changing slope and symmetric about the origin.

  figure271
Figure 6: Error Normalization Scheme 

Since the normalized maneuver error lies within the interval [-1,1], the maximum absolute maneuver error rate is 2. Similar to the above normalization scheme the error rate is also transformed into the interval [-1,1] according to the following equations:

  equation311

This normalization scheme might be applied for each dimension separately, where every normalized error and error rate contains the information about the relative position of prediction and observation (sign of the error). In a multivariable dimensional space one could calculate the magnitude of the error and the error rate, and use those to determine the appropriate tex2html_wrap_inline1001 and tex2html_wrap_inline1003 . This is proposed by Chan [2] and the corresponding error magnitude are defined as:

eqnarray325

where the summations are carried out over the number of dimensions. These error and error rate magnitude lie within the interval [0,1]. On the contrary, the relative position of the prediction to the observation and the direction of changing the error are important to choose an appropriate control. Figure 7 illustrates the four situations.

  figure334
Figure 7: Development of Maneuver Error 

The predicted position ``A'' in Figure 7 exhibits a positive maneuver error and a positive error rate increases the error of the next time step, whereas a negative error rate decreases the next error. On the other hand, a positive error rate for the predicted position ``B'' in Figure 7 decreases the maneuver error of the next time step. Likewise, a negative error rate induces the opposite effect.

Hence, a normalized representation of the error and error rate is given in Equations (16)-(18) and eq:ner, a general set of input membership functions can be defined. With regard to the normalization scheme, the input membership functions are generated as shown as in Figure 8. The fact that large errors are mirrored into the normalized bounds -1 and +1 leads to a larger region of support (ROS) of the negative-large (nl) and positive-large (pl) membership functions. Furthermore, the other membership functions shrink around zero together.

  figure306
Figure 8: Membership Functions 

The Fuzzy Logic Rule Base

The fuzzy logic rule base is built by combining the input membership sets via the linguistic rules with the output membership sets. The linguistic rules are of the form of eq:rules, where every possible input combination should be covered. In case of the seven error and seven error rate input sets shown in Figure 8, a minimum of 49 rules is required. To increase the modeling capability a input combination of the maneuver error and error rate may call different output membership functions at the same time with the use of continuous confidences [1]. Determining the rules is difficult and might be done with the help of experts knowledge about the system [2]. In Chans work this expert's knowledge is used to determine the specific amount of the smoothing parameter tex2html_wrap_inline1001 and tex2html_wrap_inline1003 . The proposed fuzzy filter exploits an analogy from system control theory, the rest-to-rest maneuver of a second order system [3], to define appropriate rules.

The rest-to-rest maneuver requires a mass at rest to move as quickly as possible to another desired position of rest. The control law is modeled in the form of a non-linear spring-damper system shown in Figure 9. The coordinate system is fixed at the desired final position of rest, so that the first rest is expressed as an initial condition, and the controller of the rest-to-rest maneuver is designed to exhibit Lyupanov stability. The results of this work [3] are used to determine the 49 rules as explained in the following section.

  figure358
Figure 9: Rest-to-Rest Maneuver 

The transfer function of a spring-mass-dashpot system shown in Figure 9 can be represented in continuous time domain as:

  equation363

where tex2html_wrap_inline1183 and tex2html_wrap_inline1185 are the undamped eigenfrequency and the damping ratio. The transfer function of eq:r2rtf is later used to define a relation between the smoothing parameter tex2html_wrap_inline1001 and tex2html_wrap_inline1003 , and the undamped eigenfrequency and the damping ratio. The non-linear control law is defined in [3] as follows:

equation372

where the constants tex2html_wrap_inline1191 are determined to satisfy the above mentioned performance. The solution of the original problem, the rest-to-rest maneuver, with an initial position error and zero initial velocity is shown in Figure 10.

  figure333
Figure 10: States and Control of the Rest-to-Rest Maneuver 

We can infer from Figure 10 that the stiffness increases from a non-zero value and the damping starts at zero. The closer the mass to the final position, the higher the stiffness and damping. This knowledge may now be used to determine the rules according to which the control action is taken. A convinient structure of writing these rules is shown in Table (2). Within this table all possible input combinations are captured, since the normalized error, Equations (16)-(18), is entered in the first row and the normalized error rate, eq:ner, is entered in the first column. The original rest-to-rest maneuver, explained above, is represented in Table 2 at the row tex2html_wrap_inline1193 equals zero, where large errors require small stiffness and damping and zero error requires large stiffness and damping. For similar reasons, the column with zero error rate requires large stiffness and damping, trying to keep the error and error rate small. As shown as in Figure 7 positive error and negative error rate exhibits the same situation as negative error and positive error rate. Thus, the Table 2 is mirrored symmetrical about the two main-diagonals, which is emphasized by the light and dark gray table entries. The gray table entries are determined by the use of the modified rest-to-rest maneuver, where the initial rest position is changed to different values of initial position and velocity. For instance, the rule of positive medium normalized error and positive medium normalized error rate are obtained by setting the initial velocity and the initial position to 0.5 as shown in Figure 11. The rule table entry in the upper right and lower left rectangulars are obtained with the same method.

  figure355
Figure 11: States and Control of the Rest-to-Rest Maneuver for non-zero initial position and velocity 

Underlying to this method is the following rule observed by Figure 7:
bullet If the error decreases by itself (positive error and negative error rate and vise versa), do not apply a large control (small stiffness and damping), only if the error is small and the error rate is large increase the damping of the system to prevent overshoot!
bullet If the error increases by itself, increase the damping moderate to counteract this situation

  table408
Table: Fuzzy Rule Base (Compare the linguistic Terms with Figure 8) 

With the knowledge of the fuzzy rule base, Table 2, and the membership sets defined in Figure 8 the fuzzy relational matrix can now be derived according to eq:rulebase. Using the singleton input-fuzzyfication and the Center of Gravity Method to defuzzyfy the controllers output, the control surfaces shown in Figure 12 can be calculated.

  figure489
Figure 12: Stiffness and Damping Control Surface 

Since the fuzzy controller is defined in terms of stiffness and damping, it is required to express those terms as smoothing parameter tex2html_wrap_inline1001 and tex2html_wrap_inline1003 . For this purpose we recall the transfer function of the tex2html_wrap_inline1001 - tex2html_wrap_inline1003 filter derived in Chapter gif. The discrete transfer function, eq:G_zdomain, shall be mapped into another discrete domain where the terms stiffness and damping are defined. Thus, the area of the unit circle of the z-domain is transformed into the left half plane, often referred to as the w-domain. This mapping is described by the following equation:

  equation498

Applying this transformation to the transfer function of eq:G_zdomain, yields the transfer function of tex2html_wrap_inline1001 - tex2html_wrap_inline1003 filter with respect to the w-domain.

  equation504

The w-domain exhibits similar behavior to the continuous s-domain since their stability regions are both defined in the left half plane. This similarity is used to relate the stiffness and damping to the smoothing parameter tex2html_wrap_inline1001 and tex2html_wrap_inline1003 . Comparing the characteristic polynomial of eq:r2rtf with this of eq:G_wdomain leads to the following relationship:

  eqnarray511

Applying the transformation eq:albezo to the control surface shown in Figure 12 yields finally to the input-output-relationship between maneuver error and error rate and the smoothing parameter tex2html_wrap_inline1001 and tex2html_wrap_inline1003 , which is shown in Figure 13. During this mapping we assumed the direct relationship between stiffness and eigenfrequency.

  figure521
Figure 13: Smoothing Parameter tex2html_wrap_inline1001 and tex2html_wrap_inline1003 Control Surface 

Summary

This chapter proposed a Fuzzy Logic Algorithm applied to the standard tex2html_wrap_inline1001 - tex2html_wrap_inline1003 filter developed in Chapter gif. Unlike the fixed gain tex2html_wrap_inline1001 - tex2html_wrap_inline1003 filter, the fuzzy logic approach adapts the smoothing parameter tex2html_wrap_inline1001 and tex2html_wrap_inline1003 as a function of the maneuver error and error rate. Thus, the adaptive tex2html_wrap_inline1001 - tex2html_wrap_inline1003 filter is capable of tracking various types of maneuvers whereas the fixed tex2html_wrap_inline1001 - tex2html_wrap_inline1003 filter can only be optimized for one trajectory and certain sensor noise.

The fuzzy logic algorithm is first illustrated via single-input-single-output example and is discussed in detail in section 2.2 following the scheme illustrated in Figure 3. It is shown how the fuzzy relational matrix can be created using the input and output membership sets and the fuzzy rules. Finally, the relational matrix is used to calculate the output fuzzy set ( tex2html_wrap_inline1271 ) which is defuzzyfied for further usage.

The final section discusses the implementation of the fuzzy logic algorithm into the target tracking process. The linguistic rule base is determined by an analogy to the rest-to-rest maneuver, where the system variables, stiffness and damping, are derived. A relationship between those system variables and the smoothing parameters tex2html_wrap_inline1001 and tex2html_wrap_inline1003 is proposed to conclude with the control surfaces shown in Figure 13.

References

1
Martin Brown and Chris Harris. Neurofuzzy Adaptive Modeling and Control. Prentice Hall International (UK), 1994.

2
Keith C.C. Chan, Vika Lee, and Henry Leung. Robust target tracking using a fuzzy filter. In International Conference on Systems, Man and Cybernetics, volume 5. IEEE, October 1995.

3
L. Ducourau, T. Singh, and R. W. Mayne. Automated parameter optimization for structural and controller design. Proceedings of the CSME Mechanics in Design Conference, May 6-9 1996.

4
Li-Xin Wang. Adaptive Fuzzy Systems and Control : Design and Stability analysis. Prentice Hall, 1994.