[ieee 2007 ieee international fuzzy systems conference - london, uk (2007.07.23-2007.07.26)] 2007...
TRANSCRIPT
Interpretable Fuzzy Models from Data and Adaptive Fuzzy Control:A New Approach
Juan Contreras Montes, Member, IEEE, Roger Misa Llorca, Luis Murillo Fernandez, Member IEEE
Abstract A novel approach for the development oflinguistically interpretable fuzzy models from data is proposed.Based on this approach a methodology for inverse and indirectadaptive fuzzy control is presented. The proposed methodologyincludes clustering techniques to determine rules, the minimumsquares method to adjust consequents and, for a sharp tuning,the descendant gradient to adjust the modal values of sets thatconfirm the antecedent. The antecedent partition usestriangular sets with 0.5 interpolations. The most promissoryaspect in our proposal consists in achieving a great precisionwithout sacrificing the fuzzy system interpretability. The real-world applicability of the proposed approach is demonstratedby application to a classic benchmark in system modeling andidentification (Box-Jenkins gas furnace) and to a temperaturecontrol of a food process.
Keywords: Fuzzy identification, least squares method,clustering interpretability, adaptive fuzzy control.
I INTRODUCTION
T he construction of fuzzy models involves the selectionand tuning of many parameters as the shape anddistribution of ownership functions of input variables,
rule base, logic operators used, shape and distribution ofconsequents, etc. The great number of parameters needed toobtain a fuzzy model has obstructed the development of aunique technique for modeling, especially in the case offuzzy identification from experimental input and output data.One of the first proposals to automatically design a fuzzy
system from data was the table look-up echeme [1]. ThenSugeno and Yasukawa [2] proposed a methodology toidentify fuzzy model parameters using singleton consequents,but it required many rules and presents a poor descriptioncapacity.
Fuzzy clustering algorithms perform as the most adequatetechnique to obtain fuzzy models, being fuzzy C-Means [3]and Gustafson-Kessel [4] the most used methods. Manyvariations to these clustering algorithms have been proposed[5]-[8], and another methods [9]-[13] witch obtain goodprecision but sacrifying interpretability, because they present
Juan Contreras Montes is working for Department of Naval Engineer atNavy School and for the Corporacion Universitaria Rafael Nuinez. inCartagena, Colombia (epcontreras ( ieee orgA
Roger Misa Llorca is working for the Instituto Superior Polit6cnico Jos6Antonio Echeverrma, La Habana, Cuba (rmisate1ectricacujae.edu.cu)
Luis F Murillo Femrnndez is working for the Corporacion UniversitariaRafael Nfinez ( f1Urillof 1iee.(rg)
interpolation between more than two membership functionsand, generally, the sum of the membership values for aninput data is upper than 1. Other methods generate fuzzymodel but a great number of rules are created [14]-[16].
The methodology used in this paper to get the fuzzymodel from input and output data [17] is based on theinference error method from Sala [8] and is presented inthree phases: At the first, the inference error method is usedto generate an interpretable fuzzy model and also, to detectpossible classes or clusters in data; at the second phase, theconsequent parameters are adjusted by means of least squaremethod; at the third phase, the method is used to buildadaptive fuzzy controllers.
II INFERENCE ERROR
A fuzzy rule: "if u is A, then y is B ", where u and yrepresent two numeric variables, and A c U and B c Y, aretwo fuzzy input and output sets respectively, defined at theuniverses U and Y, is equivalent to the equation:
UA (U) < UB (Y) (1)
The inference error £, is given by
0 ... UA (U) < UB ( Y)GE 'z A
{UA (U)-UB (y) ... UA (U) > UB (y) (2)
A fuzzy rule of the kind "If u is A, then y is B" with a nullinference error, must fulfill the condition
UA (U) = UB (Y) (3)
If the system has n inputs, it must be represented by rulesof the kind "If ul is A1 and U2 is A2 and ...and urn is Am, theny is B", and the generated system must fulfill the condition
((UAl (Xk)A (UA2 (Xk)A.*. (UAm(Xk)) = UB (Yk) (4)
where A represents a t-norm, or an aggregation operator, offuzzy logic
1-4244-1210-2/07/$25.00 C 2007 IEEE.
III FuzzY IDENTIFICATION BY INFERENCE ERROR
A) Fuzzy model structure
1) Membership functionsThe universe partitioning of the input variables in the
learning process will be done with normalized triangular setswith specific overlapping of 0.5. The triangular membershipfunctions allow the reconstruction of the linguistic value atthe same numeric value after a defuzzyfication method hasbeen applied [16]; also, the overlapping in 0.5 assures thatthe supports of the fuzzy sets are different. The fuzzy setsgenerated by the output variable will be a singleton.
2) Distribution of the membership functionsThe triangular fuzzy sets of input variables will be
distributed symmetrically at each respective universe.
3) OperatorsFor combining the antecedents OWA operators will be
used.
4) Inference method
yy mj(X)f (x() = j=I (5)
kmj(X())j=l
where
mj (x(i))= u (xi) ( ).u (x( )) (6)A1 A2 An
is the output grade of the j-est rule of a Sugeno fuzzy system,y J is the singleton value corresponding to rulej.
B) Fuzzy Identification AlgorithmGiven a collection of experimental input and output data
{Xk, Yk}, k =1, ..., N, where Xk is the n-dimensional inputarray xI, x2 . n, and y Yk is the one-dimensional outputXk Xk Yiotuarray, the algorithm is defined by the following steps:
1 Organization of the N pair set of input outputdata{(xi,yi) i=1,2,...,N}, where xi E= n are
input arrays and y, are output scalars.2 Determination of universe ranges of each variable,
according to maximum and minimum values ofassociated data [xi., xi+ , Ly-, y]+
3 Distribution of triangular membership functions overeach universe. As a general condition the vortexwith ownership value one (modal value) falls at themiddle of the region covered by the membership
function while the other two vortexes, withmembership values equal to zero, fall in the middleof the two neighboring regions
4 Calculate the position of the modal values from theinput variable(s), according toif u (n) (Xk
(n)Ysk ) y[i]
endwhere YS(n) corresponds to the projection over the
output space of data X(i) evaluation of the k-thinput variable at the n-th set of the correspondingpartition. The output value corresponding to thisprojection is given by the value of the i-th positionof output array y.
5 Rule determination. Initially, the number of rules areequal to the number of sets of each input variablemultiplied by the number of variables; in otherwords, n x k . The membership function associatedto a consequent will be the antecedent of this rule.Antecedents of rules with the same consequent aremerged by using OWA operator, reducing thus thenumber of rules. Additional method to reduce thenumber of rules is presented in [17].
6 Model validation using the inference methoddescribed by (5)
7 Parameters adjust, relocating the output singletonsusing the least squares method. Equation (5) can beexpressed in the form:
(8)( L i (
j=l
where
wj ~~~=W.WL =
j=l
(9)
Output values can be represented as Y = WO + E,that, in matrix form is given by
Iyl 1y W
2 2y - Wl
L n
y wy
w22w2
nW2W
1 -1WL Y el
2 -2. WL Y [+
n L
o E
(10)
where E is the approximation error, which should beminimized. Using the quadratic error norm, we have:
TWY= =(T iwT0 =(W W) WY (11)
If (WTW) is no singular, the least square estimationcan be done recursively
8 Finish if the square error measure MES is notgreater than a measure previously established. In anyother way, Increment in 1 the number n of sets in theinput variable (the number of partition member) andturn back to step 3.
system, fromL
Euy(k + 1) = '' L
1=1
that can be simplified
cxl (x(k)) UB, (u(k)) Si
',u xl (x(k )) U B, (u (k ))(16)
The fuzzy model obtained is interpretable, with goodprecision and only requires the adjustment of consequentparameters, which are singletons. It is possible to get a betterapproximation ("fine tuning") if at the end of the mentionedprocess the descendent gradient method is applied to adjustthe location of the modal values of the antecedent triangularsets, keeping the sum-i partitioning and, therefore, systeminterpretability.
IV ADAPTIVE FuzzY CONTROL
The output of a single input- single output (SISO) systemwithout delay can be written as a general nonlinear model
Yr (k + 1) = g (x(k), u(k)) (12)
L
y(k + 1) = E Al (x(k)) UB1 (u(k)) -
I1=1L L
- Z UBI(u(k))Z Al (x(k)) -
1=1 1=1
(17)
where Al (x(k)) is the normalized degree of fulfillment ofthe antecedent that corresponds to the state of the system. Asstate x(k) is known the last sum of (17) can be solved
L
y(k +1) = ,UB, (u(k)).3,1=1
(18)
where x4k) = Iyr(k),...,yr(k+I-ny),u(k-l),....4(k+l-nu)] is
the current state, u(k) is the current input and y(k + 1) is
the system's output at the next sample time. The objective ofinverse control is compute the input u(k) for the current statex(k) such as the output system's at the next sample time isequal to the desires output yr(k+l) [19], [20].
u(k) = g-' (x(k), yr(k + 1)) (13)
The use of partition sum 1 with triangular membershipfunctions and singleton consequents facilitates the inversionof the model. The multivariate mapping in (12) is reduced toa univariate mapping
Interchanging the antecedent and the consequent we can
obtain the rules of the inverse model
(21)IF y(k + 1) isd,THEN u(k) is B
The output of the inverse model will be given by
where
L
t51 = E A, (x(k)) t1=1
(19)
Therefore, the rule (15) can be summarized
(20)
Yr(k + 1) = g, (u(k)) (14)
where the subscript x indicates that gx is calculated for a
particular state of x.
Consider the following fuzzy system that uses three inputvariables: the current output y(k), the past output y(k - 1)and the current input u(k), to predict the output y(k + 1). Theinput U and the output variable Y have N and M membershipfunctions respectively. The state of the system is given
by x(k) = LYr (k), Yr (k -1)]. The rules are given by
IF y(k)is Al, y(k -1)is Al, u(k)is B,
THEN y(k +1)is d1 (15)
Considering that y(k) and y(k-1) form the vector of statex(k), the output y(k+1) is calculated, for a general fuzzy
L
u(k) = , u 8 (y(k + 1)) b11=1 I
(22)
where b1 corresponds to the modal values of B1 . In order to
calculate u * (y(k + 1)) we must interpolate betweens1
singletons of the consequent, thus:
u*(Yr)=maxr0miniYrl 81±YjK91i :1 1+
(23)
1<I<L
When the set of the left end, either the right end, takespart in the interpolation, the first term, or the second term,affected by the operator min will be equal to zero.
IF u(k) is B1,THEN y(k + 1) is31
From the equation (8), and knowing output values
f (X' ) , we can obtain the input model form
=
I
I
I
0-
1-
(24) 1
0-
I
0-
(i)Xk k =IZ..
(25)
When more than one antecedent is presented in a rule we
can have a problem because the base rule should have only
bijective assignments of antecedents and consequents. This
constraint will not be a problem if the consequent and the
antecedents (except the one we are calculating) are known.
Figure shows the structure of an adaptive fuzzy
controller where the parameters of the fuzzy model of the
process are updated on line, using recursive least square
method. A reference model is used.
Fig. 2. Membership functions for Box-Jenkins gas furnace
Fig. 3. Box-Jenkins gas furnace: Fuzzy identification
Fig. 1. Adaptive model-based control scheme
V RESULTS
A) The Box-Jenkins Gas Furnace
The Box-Jenkis gas furnace is a classic benchmark in
system modeling and identification [18]. The data set is
composed of 296 input-output pairs. The input corresponds
to the gas flow to be burned and the output is the carbon
dioxide concentration in the exhaustion gases. The objective
is to predict the output of using past values of both the input
and the output
Many authors have worked out this problem with different
number of past values. Gaweda and Zurada [19] used the
variables u(k-1), u(k-2), u(k-3), y(k-1), y(k-2) y y(k-3), while
Pavia and Dourado [II] used only two variables y(k- 1) and
u(k-4), reached a root mean square error (RMS) of 0.390.
Using the same variables used by Pavia and Dourado we
applied the proposed method and we obtained the partition
showed in figure 2 and the result shows in figure 3. The
singletons consequent were adjusted using least square
method during the learning process and, after that, modal
values of the membership functions were adjusted using
descendent gradient. Table I presents the rule base of the
fuzzy model and table shows a comparison with the results
TABLE I
RULE BASE: BOX-JENKINS GAS FURNACE
Rules u(k-4) A y(k-1) => y(k)1 A B 44.78
1 2 B A 653
The fuzzy model obtained has a good performance with a
low number of parameters and a suitable interpretability in
the sense that a human operator has a clearly mean of the
rules.
TABLE
BOX-JENKINS GAS FURNACE: COMPARISON WITH OTHER METHODS
B) Adaptive Fuzzy Control
An adaptive fuzzy control was applied to regulate the
Cl - --- - --
--------------------
--------------------- ----------------------
--- - --
I- ---
-
-10 -0 -S -4 -.2 0 .2 4 s a I c
Model MSE Rules ParametersKim etal (1998) [20] 0.048 2 110Gaweda y Zurada 0.055 2 38(2003)[1 8]This model 0.066 2 6Sugeno. Wang y 0.066 2 N/ALangari (1995) [21]ARMA. Box-Jenkins 0.202 N/A N/A1(1976) [17]
- ----
-- -- -
--
---------------
---------------
--
-- ---------------- -----------------
obtained by other authors.
temperature into a blancher. Pieces of banana (or broccoli)are introduced into the blancher for pre-fried process. Due tocommitments of production of the food company, it was notallowed to apply to the system input signals that excited it inthe rank of frequencies that requires an identificationprocess. Therefore, we were limited to use data of theprocess in a normal operation, which was regulated by meansof a PID control.
Figure 4 shows the control of temperature into theblancher while pieces of banana are been pre-fried. Abruptvariations of the valve of steam injection and gradualchanges of the set-point are observed. These changes of theset-point are made so that the PID controller does not apply avery high steam injection in order to diminish the thermalshock and the high level of noise that would be caused andthat affects the well-being of the workers.
100
90
60
70
60
50
40
30
water temperature IO (--), open valve % ('), set point F)
o0 5o 1 ooo 1500seconds
Fig. 4. Banana fried process: identification data
U2(k) Ay1(k - 7) -* 1
y1(k-1) > 2
ul (k) - 33Y2(k-7)AY2(k-1) -*34
where the vector of singletonsadjusted, is given by:
(consequent), after
d= [84.69 -31.31 81.20 97.62]
Figure 6 shows a comparison between the real output andthe output of the fuzzy model (MSE = 0.1006).
70 [
so
0 o00 1000 1q00 2000 200 30oorSeconds
Fig. 6. Temperature into the blancher.
From de Fuzzy model obtained we proceeded to obtainthe inverse model. A reference model was defined as:
The opening of the valve u(k) (output of the controller)and the past values of the temperature into the blancher, y(k-1) and y(k-7), were used as input in order to build the fuzzymodel. The current value of temperature y(k) was consideredas the output of the system. The results obtained were:
0
a) u(k)
45 SU 55 60 65 76 75 HU 85 96b)y(k- 1)
0n -- -r --L-
45 51 55 60 65 760 75 80 90 1
c) y(k)Fig. 5. Fuzzy partition
Yr = 90 - 55e- 002kT; k = 0121 ..., n
considering an initial temperature into the blancher of35°C and a setting time closed to 2500 seconds in order toreduce the noise caused for the thermal shock. A sample timeof 30 seconds was selected.
From the rule base
W=[(u(k)+)(k-74 yj(k-1)0 =181 S2
83(k) 84](k-7+YA-I)gi3 gi4 I
Yr is the reference model and can be expressed as
Yr = WlOl + W202 + W303where
WI =[Yl(k _1)T Y2(k-1)T ]; ol =J g4]TThe rule base is given by:
lu
An1
-----------
-----------
W = I(k-7)T2 Y2 (k 7)T; 02 g, IT
W3=LIl(k)T U2(k)T]
The vectors y, (k -1I)T,
, 451 ~~~~~The real-world applicability of the proposed approach isdemonstrated by application to a classic benchmark (Box-
Y2(k _f)T, yl(k -7)T, Jenkins gas furnace) and to the temperature control of a foodprocess using adaptive fuzzy control.
Y2 (k -7)T ,ul (k)T Y U2(k)T contain the membershipdegree of the partitions of each variable: y(k-1), y(k-7) y u(k)respectively. The first four vectors and Y, are known. Theobjective is to find the input signal that produce Yr, It isobtained from
W363 = -r-W16 +W262
Figure 7 shows the input signal calculated to produce thereference model and the real input, which wxline.
lEJE
90
60
70
60
50
40
30
20
1
0 500 1000 1500
Timne (seconds)
Fig. 7. Signal control
The input generated by the inverse modeli
that does not produce abrupt opening of the
shows that the real process output is much
reference model.
90
-~60
RefeIeilce imiotoReal otitputit
0 500 1000 1500 20CTime (seodds)
Fig. 8. Process output
VI CONCLUSIONS
A method based on inference error mir
presented to identify systems with inter]
models, generating partitions sum-i of the an
a triangular partition sum-i initially assumec
presence of complex overlapping that happi
methods.
AcKNOWLEDGMENT
The authors would like to thank the reviewers for theirvaluable comments and constructive suggestions. This workwas supported in part by Colciencias (Colombia) under thegrant no. 14191417481.
REFE-RENCES
/as adjusted on [1] Wang, L-X, Mendel, J.M., "Generating fuzzy rules by learning formexamples", IEEE Transactions, Nov. 1992.
[2] Sugeno, M., Yasukawa, T., "A fuzzy logic based approach toqualitative modeling". Transactions on Fuzzy Systems, vol. 1, No. 1,pp. 7-31. 1993
[3] Bezdek J. C. (1987). Pattern recognition with Fuzzy ObjectiveFunction Algorithms. Ed. Plenum Press.
[4] Guztafson E. E., Kessel W. C. Fuzzy Clustering with a Fuzzy-------------Covariance Matrix. IEEE CDC, San Diego, California, pp. 503-
516.1979.paraiuieteis: [5] Nauck, D., Kruse, R., "Nefclass- a neuro-fuzzy approach for the
----------------classification of data", In Proceedings of the Symposium on AppliedComputing, 1995.
[6] Nauck, D., Kruse, R., "Neuro-fuzzy systems for function-approximation". Fuzzy Sets and System. 101(2), pp. 261 271. Jan.1999.
[7] Espinosa, J., Vandewalle, J., "Constructing fuzzy models with2000 2500 ~~linguistic integrity form numerical data-afreli algorithm", IEEE Trans.
Fuzzy Systems, vol. 8, pp. 591 -600, Oct. 2000.[8] Sala, A. (1998). Validacion y Aproximacion Funcional en Sistemas de
Control Basados en Logica Borrosa. Universidad Polit6cnica de
sa"soft"input Valencia. Tesis Doctoral.Isasoft"input [9] Sala, A., Albertos, P., Inference error minimisation: fuzzy modellingvalve. Figure 8 of ambiguous functions. Fuzzy Sets and Systems, 121 (2001) pp. 95-iclosed to the 111. 2001
[10] Diez J. L., Navarro J. L., Sala A. (2004). Algoritmos de Agrupamientoen la Identificacion de Modelos Borrosos. RIAI: Revistalberoamericana de Automditica e Informditica Industrial.
[11] Paiva, R. P., Dourado, A., "Interpretability and learning in neuro-
fuzzy systems", Fuzzy Sets and System. 147(2004), pp. 17 38. 2004.[12] Guillaume, S., Carnomordic, B., "Generating an interpretable Family
of Fuzzy Partitions Form Data", IEEE Trans. Fuzzy Systems, vol. 12,No. 3, pp. 324 -335, Jun. 2004.
[13] Joo M.G., and Lee, J.S. "Universal Approximation by HierarchicalFuzzy Systems With Constraints on the Fuzzy Rules", Fuzzy Sets andSystems, 130(2002), pp 175 188, 2002
[14] Joo M.G., and Lee, J.S. "A Class of Hierarchical Fuzzy Systems Withlei: Constraints on the Fuzzy Rules", IEEE Trans. Fuzzy Systems, vol. 13,
--------------No. 2, pp.194 203, 2005.[15] Chen, W.,, and Saif, M. "A Novel Fuzzy System With Dynamic Rule
Base", IEEE Trans. Fuzzy Systems, vol. 13, No. 5, pp.569-582, 2005.DO 2500 [16] Pedriycz. W. Why Triangular Membership Functions?". IEEE Trans.
Fuzzy Sets and System, vol. 64, pp.21 30, 1994[17] Contreras, J., Misa, R., Paz, J., Building Interpretable Fuzzy Systems:
A New Methodology. In proceedings of Electronics, Robotics andAutomotive Mechanics Conference CERMA 2006. IEEE Computer
riimization was [8 Society. Pp.: 172 178. Nov. 2006[1]Box, G., Jenkins, G., Times Seiries Analysis, Forescasting and
pretable fuzzy Control, 2nd ed. Holden Day, San Francisco, 1976.itecedents from [19] Babuska, R. Fuzzy and Neural Control. Disc Course Lecture Notes.
1,avoiding the Delft University of Technology. Delft, the Netherlands. 2001..J,avidin the [20] Passino, K, y Yurkovich, S. Fuzzy Control. Addison-Wesley.iens in another California. (pp. 301 390). 1998
-------------- ------------- ------------
---------------I------------- ------------
------------- ------------
----------
coiltrol sigiial Wil'it a(laptatioil of 1:coiltrol sigiial whitotit a(laptatioil:
-------------- ------------
---------------------------- ------------
01
.L 1-1 .L