You are on page 1of 10

Journal of Information, Control and Management Systems, Vol. 5, (2007), No.

101

MODEL PREDICTIVE CONTROL BASED ON THE


TAKAGI-SUGENO FUZZY MODEL
Vesna RANKOVI, Ilija NIKOLI
University of Kragujevac, Faculty of Mechanical Engineering, Serbia
e-mail: vesnar@kg.ac.yu, inkolic@ptt.yu
Abstract
Control of nonlinear objects is considered in this paper. It was supposed that the object
model is not known. Identification of the nonlinear system was realized by application of
the Takagi-Sugeno fuzzy system, based on input-output data. For adapting the premises
parameters, the iterative procedure was applied, which is based on the gradient
decrease method. The consequences functions' parameters were adapted by the least
square method. Control of the identified object is being determined in such a way that
the output from the system is brought to a certain given value by minimizing the cost
function.

Keywords: predictive control, nonlinear system, identification, Takagi-Sugeno


model
1

INTRODUCTION
The predictive controllers are based on the mathematical model of the object,
which is being controlled. Nonlinear system identification and prediction is a complex
task. All the processes in nature are nonlinear. In large number of processes, the
nonlinearities are not prominent, so their behavior can be described by the linear
model. In the linear systems theory there exist a large number of methods that can be
applied for obtaining the linear model of processes. The nonlinear model must be
chosen when the nonlinearity is strongly exhibited. In the identification process, the
parameters of the mathematical model are being determined as such that the difference
between the system response and its mathematical model is as least as possible, both in
the transient regime and in stationary state. The general model of linear processes is
ARX (Auto Regressive eXogenous); while for the nonlinear ones it is NARX
(Nonlinear Auto Regressive eXogenous). The NARX model structure enables
application of the neural networks, the fuzzy systems and the neuro-fuzzy systems for
approximation of the nonlinear function. Identification nonlinear system by TakagiSugeno fuzzy model has been successfully applied in many applications, [1, 2].
Authors in [3] investigated the identification of nonlinear systems by feedforward
neural networks, radial basis function neural networks, Runge-Kutta neural networks

102

Predictive Control Model Based on the Takagi-Sugeno Fuzzy Model

and adaptive neuro-fuzzy inference systems. Result of simulation, reported in this


paper, indicates that adaptive neuro fuzzy inference systems are a good candidate for
identification purposes.
Model predictive control (MPC) is applied to a large number of nonlinear
industrial process, [4-7] has developed a methodology to design and implement neural
predictive controllers for nonlinear system. A numerical algorithm has been designed
to minimize the prediction error. An approach for model-based predictive control of
industrial processes is proposed in [8]. The model for prediction is a recurrent fuzzy
neural network. A generalized predictive control law is derived to minimize a cost
function.
Multiple model predictive control strategy based on Takagi-Sugeno models has
been described and studied for a nonlinear plant in [9].
In this paper is studied the control of the nonlinear object, which is identified by
the Takagi-Sugeno fuzzy system. In the second section is explained the identification
of the nonlinear object by application of the Takagi-Sugeno fuzzy system. In section
three is analyzed the principle of work of the predictive controllers. Results of
simulations are given in section four, while section five presents the concluding
remarks.
2

NEURO-FUZZY MODELING
A wide class of nonlinear dynamic systems with an input u and an output y can
be described by the model:
ym ( k ) = f m ( ( k ) , )
(1)
where:
ym ( k ) is the output of the model,

( k ) = u ( k 1) , u ( k 2 ) ,..., u ( k nu ) , y ( k 1) , y ( k 2 ) ,..., y ( k n y ) is the

regression vector
is the parameter vector
nu denotes the maximum lag of the input and n y denotes the maximum lag of the

output.
The structure scheme of the Takagi-Sugeno fuzzy system identification is shown in
Figure 1.
The input vector to the Takagi-Sugeno fuzzy system is defined as:
I T ( k ) = u ( k 1) , u ( k 2 ) ,... u ( k nu ) , y ( k 1) , y ( k 2 ) ... y ( k n y )

Journal of Information, Control and Management Systems, Vol. 5, (2007), No.1

103

Figure 1 The block scheme of the Takagi-Sugeno fuzzy model


The output is ym ( k ) .
The fuzzy system has n y + nu + 1 linguistic variables, n y + nu inputs ones and one

output variable. Linguistic values of the variable y ( k i ) are A1i , A2i ,..., Ani , i = 1, n y
and u ( k i ) are B1i , B2i , ..., Bni , i = 1, nu . For the system with n y + nu inputs and one
output, set of linguistic rules is defined in the form:

R1 : if y ( k 1) is A11 and y ( k 2 ) is A12 and ... and y ( k n y ) is A1n y and u ( k 1) is


B11 and u ( k 2 ) is B12 ... and u ( k nu ) is B1nu then:

f1 = 11 y ( k 1) + 12 y ( k 2 ) + ... + 1n y y ( k ny ) + 11u ( k 1) + 12 u ( k 2 ) + ...


+ 1nu u ( k nu ) + 1
R2 : if y ( k 1) is A11 and y ( k 2 ) is A12 and ... and y ( k n y ) is A1n y and u ( k 1) is
B11 and u ( k 2 ) is B12 ... and u ( k nu ) is B2 nu then:
f 2 = 21 y ( k 1) + 22 y ( k 2 ) + ... + 2 ny y ( k n y ) + 21u ( k 1) + 22 u ( k 2 ) + ...
+ 2 nu u ( k nu ) + 2
...

104

Predictive Control Model Based on the Takagi-Sugeno Fuzzy Model

Ri : if y ( k 1) is A21 and y ( k 2 ) is A22 and ... and y ( k n y ) is A2 n y and u ( k 1) is


B21 and u ( k 2 ) is B22 ... and u ( k nu ) is B2 nu then:
f i = i1 y ( k 1) + i 2 y ( k 2 ) + ... + in y y ( k n y ) + i1u ( k 1) + i 2 u ( k 2 ) + ...
+ inu u ( k nu ) + i
...
R p : if y ( k 1) is An1 and y ( k 2 ) is An 2 and ... and y ( k n y ) is Ann y and u ( k 1) is
Bn1 and u ( k 2 ) is Bn 2 ... and u ( k nu ) is Bnnu then:
f p = p1 y ( k 1) + p 2 y ( k 2 ) + ... + pn y y ( k n y ) + p1u ( k 1) + p 2 u ( k 2 ) + ...
+ pnu u ( k nu ) + p
n

The number of linguistic rules is: p = ( n y + nu ) .


The output from Takagi-Sugeno fuzzy system is:
p

ym ( k ) = zi f i

(2)

i =1

where:

zi =

zi

(3)

zi
i =1

z1 = A11 ( y ( k 1) ) A12 ( y ( k 2 ) ) ... A1n

( y ( k n )) ( u ( k 1) )
y

B11

B12 ( u ( k 2 ) ) ... B1nu ( u ( k nu ) )


z2 = A11 ( y ( k 1) ) A12 ( y ( k 2 ) ) ... A1n

( y ( k n ) ) ( u ( k 1) )
y

B11

B12 ( u ( k 1) ) ... B2 nu ( u ( k nu ) )
...

zi = A21 ( y ( k 1) ) A22 ( y ( k 2 ) ) ... A2 n

( y ( k n ) ) ( u ( k 1) )
y

B21

B22 ( u ( k 2 ) ) ... B2 nu ( u ( k nu ) )
...

z p = A1n ( y ( k 1) ) An 2 ( y ( k 2 ) ) ... Ann


1

Bn 2 ( u ( k 2 ) ) ... Bnnu ( u ( k nu ) )

( y ( k n ) ) ( u ( k 1) )
y

Bn1

Journal of Information, Control and Management Systems, Vol. 5, (2007), No.1

105

* denotes certain T-norm.

If the membership function are taken in the Gaussian then:

Aij =

1
y ( k j ) a A
ij
1 +

Aij

bAij

, i = 1, n; j = 1, n y

and

Bij =

1
u ( k j ) aB
ij
1 +
cBij

bBij

, i = 1, n; j = 1, nu .

a Aij , bAij , cAij , aBij , bBij , cBij are the parameter of the function Aij and Bij .
Consequences functions of the fuzzy rules are of the form:
ny

nu

j =1

j =1

f i = ij y ( k j ) + ij u ( k j ) + i .

(4)

Substituting (4) and (3) into (2) the system output is obtained as:
ym ( k ) =

1
p

zi

ny

nu

i =1

j =1

j =1

zi ij y ( k j ) + ij u ( k j ) + i .

(5)

i =1

The difference between the output of the plant y ( k ) and the output of the network
ym ( k ) is called the prediction error:
e ( k ) = y ( k ) ym ( k ) .

(6)

This error is used to adjust the parameter in the Takagi-Sugeno fuzzy system via
the minimization of the following function:
2
1
= y ( k ) ym ( k ) .
(7)
2

In [10] is described the procedure used for training.

MODEL PREDICTIVE CONTROL


Here will be briefly presented the principle of operation of the predictive
controllers. Let us suppose that the mathematical model of the process is known. Based
on the model, it is possible to determine the future outputs from the object y ( k + i ) ,
i = 1,2,..., N H , where N H is the prediction horizon. The future outputs depend on the

106

Predictive Control Model Based on the Takagi-Sugeno Fuzzy Model

object current states and future control signals, u ( k + i ) , i = 1,2,..., N c , where N c is the
control horizon and N c N H . The predictive controllers compute potential future
control signals such that the future outputs will be as close as possible to the desired
values r ( k + i ) , i = 1,2,..., N H .
There exist several types of the predictive controllers. In this work is used the
GPC (General Predictive Control) controller, where the cost function is calculated as:
NH

Nc

J ( k ) = r ( k + m ) ym ( k + m ) + u 2 ( k + m 1)
m =1

(8)

m =1

where:
u 2 ( k + m 1) = u ( k + m 1) u ( k + m 2 )
is the weight factor of the control signal.
Model output ym ( k + m ) is calculated based on (5):
ym ( k + m ) =

nu
ny

y
k
+
m

j
+
(
)
i ij
ij u ( k + m j ) + i
p
i =1
j
=
1
j
=
1

zi

(9)

i =1

Nc

Taking into account the term u 2 ( k + m 1) in the cost function (8) prevents
m =1

the control signals to be too big such that the executive organs would not be able to
realize.
T

The control signals in the k-th step u ( k ) , u ( k + 1) ,...u ( k + N c 1) are being


determined such that the function J ( k ) is minimum.
The

optimization

problem,

i.e.,

determination

of

u ( k ) , u ( k + 1) ,...,

u ( k + N c 1) , is possible to solve both numerically and analytically. Analytically it


J
is solved in such a manner that from the system of algebraic equations:
= 0,
u ( k )
T
J
J
= 0 ,
= 0 one obtains u ( k ) , u ( k + 1) ,...u ( k + N c 1) .
u ( k + 1)
u ( k + N c 1)
For analytical solution, it is necessary for the model to be linear. The Takagi - Sugeno
model is nonlinear, its linearization should be performed first, or apply the numerical
methods for solving the optimization problem.
For finding the control signals for which the cost function is minimum was in [11]
applied the genetic algorithm. The genetic algorithms represent the global optimization
technique.

Journal of Information, Control and Management Systems, Vol. 5, (2007), No.1

107

In this work for obtaining the optimum values of the control signals, the function
fminunc of the Matlab's Optimal Toolbox was used. In the k-th step N c 1 control,
signals are obtained. The first calculated signal is being sent to the controller output.

SIMULATION RESULTS
For the simulation example, we consider the nonlinear plant, which is described
by the following nonlinear difference equation:
y ( k 1) y ( k 2 ) y ( k 1) + 2.5

y ( k ) = 0.35
+ u ( k 1) .
(10)
2
2
1 + y ( k 1) + y ( k 2 )

where y is the output of the plant and u is the plant input.


The dynamical system used in the simulation example is given in [12]. We
assume that structure of the model is known, nu = 1 , n y = 2 . The inputs and output of
the Takagi-Sugeno fuzzy system are u ( k 1) , y ( k 1) , y ( k 2 ) and y ( k ) ,
respectively.
Fuzzy partitioning of the input variables of the fuzzy system is realized by
selection of the three primary fuzzy sets. The Takagi-Sugeno fuzzy model in the
considered example has 27 rules. The part of the rule base is:
R1 : if y ( k 1) is A11 and y ( k 2 ) is A12 and u ( k 1) is B11 then:
f1 = 0.4392 y ( k 1) + 0.06631y ( k 2 ) + 0.1857u ( k 1) 0.4976
R2 : if y ( k 1) is A11 and y ( k 2 ) is A22 and u ( k 1) is B11 then:
f 2 = 10.39 y ( k 1) + 3.04 y ( k 2 ) 4.077u ( k 1) 1.435

...
R27 : if y ( k 1) is A31 and y ( k 2 ) is A32 and u ( k 1) is B31 then:
f 27 = 0.6759 y ( k 1) 0.05963 y ( k 2 ) + 0.3103u ( k 1) 0.05284

Since the object model is formed, it is necessary to define the cost function (8)
parameters. These parameters are selected by the trial and error method. By increasing
the variance of the control signal is decreasing, but simultaneously the difference
between the set and real value of the object output is increasing. In the considered
example, the satisfactory results are obtained for the following values of parameters:
N H = 3 , N c = 3 , = 0.05 .
The optimal predictive controller in the k-th step computes the control signals:
T

u ( k ) , u ( k + 1) . In Figure 2 a), the reference signal is shown by the solid line, while

108

Predictive Control Model Based on the Takagi-Sugeno Fuzzy Model

the broken line denotes the object output. In Figure 2 b), difference between the
reference signal and the object output is shown. From the figure, it is obvious that the
tracking error is small. The variation of the control signal is shown in Figure 3. From
the figure, one can notice that the executive organ can track the generated control
signal, since it is not oscillatory. The obtained solution is good for practical realization.
r
y

0.6
0.5
0.4
0.3
0.2
0.1
0
0

10

20

30

40

50

60

70

80

90

60

70

80

90

100
t [s]

a)
0.3
r-y
0.2
0.1
0
-0.1
-0.2
0

10

20

30

40

50

t [s]

100

b)

Figure 2 a) The reference signal-solid line, response of the plant-dashed line


b) The difference between the reference signal and the object output

109

Journal of Information, Control and Management Systems, Vol. 5, (2007), No.1

1.2
u
1
0.8
0.6
0.4
0.2
0
0

10

20

30

40

50

60

70

80

90

t [s]

100

Figure 3 The control signal


5

CONCLUSIONS
In this work is considered the synthesis of the predictive controller for control of
the nonlinear object. The object is modeled by the Takagi-Sugeno fuzzy system. The
cost function is selected so, that by its minimization the difference is decreased
between the future object outputs and the desired values of the outputs, with
simultaneous minimization of the control signal variance. In the paper is the
optimization problem solved by the iterative procedure.
The simulation results, given in Section four, show that the predictive controllers
can successfully be applied for control of the prominently nonlinear object. The given
trajectory tracking error is small. The proposed structure can be applied in control of
the linear objects that are modeled by the Takagi-Sugeno fuzzy system.
Acknowledgement: This research was supported by the Ministry of Science and
Environmental Protection of Republic of Serbia through the Mathematical Institute
SANU Belgrade, Grants No. 144002.
REFERENCES
[1]
[2]

BABUKA, R., VERBRUGGEN, H.: Neuro-fuzzy methods for nonlinear


system identification, Annual Reviews in Control, 2003.h
ABDELAZIM, T., MALIK, O. P.: Identification of nonlinear systems by
Takagi-Sugeno fuzzy logic gray box modeling for real-time control, Control
Engineering Practice, 2005.

110

Predictive Control Model Based on the Takagi-Sugeno Fuzzy Model

[3]

ONDER EFE, M., KAYNAK, O.: A comparative study of neural network


structures in identification of nonlinear systems, Mechatronics, 1999.
DUBLJEVIC, S., et al.,: Predictive control of transport-reaction processes,
Computers and Chemical Engineering, 2005.
MHASKAR, P., EL-FARRA, N. H., CHRISTOFIDES, P. D.: Robust hybrid
predictive control of nonlinear systems, Automatica, 2005.
PENG, H., et al.,: Exponential ARX model-based long-range predictive control
strategy for power plants, Control Engineering Practice, 2001.
LAZAR, M., PASTRAVANU, O.: A neural predictive controller for non-linear
systems, Mathematics and Computers in Simulation, 2002.
LU, C.-H., TSAI, C.-C.: Generalized predictive control using recurrent fuzzy
neural networks for industrial processes, Journal of Process Control, 2007.
LI, N. et al.,: Multi-model predictive control based on the Takagi-Sugeno fuzzy
models: a case study, Information Sciences, 2004.
JANG, J.-S. R.: ANFIS: Adaptive-Network-Based Fuzzy Inference Systems,
IEEE Transactions on Systems, Man, and Cybernetics, 1993.
SARIMVEIS, H., BAFAS, G.: Fuzzy model predictive control of non-linear
processes using genetic algorithms, Fuzzy sets and systems, 2003.
SASTRY, P. S., SANTHARAM G., UNNIKRISHNAN, K. P.: Memory Neuron
Networks for Identification and Control of Dynamical Systems, IEEE
Transactions on Neural Networks, 1994.
MENDONCA, L. F., SOUSA, J. M., SA D COSTA, J. M. G.: Optimization
problems in multivariable fuzzy predictive control, International Journal of
Approximative reasoning, 2004.
TATJEWSKI, P., LAWRYCZUK, M.: Soft computing in model-based
predictive control, Int. J. Appl. Math. Comput. Sci., 2006.

[4]
[5]
[6]
[7]
[8]
[9]
[10]
[11]
[12]
[13]
[14]

You might also like