Starting from a nonlinear model for a pendulum-cart system, on which viscous friction is considered, a Takagi-Sugeno (T-S) fuzzy augmented model (TSFAM) as well as a TSFAM with uncertainty (TSFAMwU) is proposed. Since the design of a T-S fuzzy controller is based on the T-S fuzzy model of the nonlinear system, then, to address the trajectory tracking problem of the pendulum-cart system, three T-S fuzzy controllers are proposed via parallel distributed compensation: (1) a T-S fuzzy servo controller (TSFSC) designed from the TSFAM; (2) a robust TSFSC (RTSFSC) designed from the TSFAMwU; and (3) a robust T-S fuzzy dynamic regulator (RTSFDR) designed from the RTSFSC with the addition of a T-S fuzzy observer, which estimates cart and pendulum velocities. Both TSFAM and TSFAMwU are comprised of two fuzzy rules and designed via local approximation in fuzzy partition spaces technique. Feedback gains for the three fuzzy controllers are obtained via linear matrix inequalities approach. A swing-up controller is developed to swing the pendulum up from its pendant position to its upright position. Real-time experiments validate the effectiveness of the proposed schemes, keeping the pendulum in its upright position while the cart follows a reference signal, standing out the RTSFDR.
1. Introduction
A great number of nonlinear systems can be represented by Takagi-Sugeno (T-S) fuzzy models. They are considered universal approximators [1]. In [2–4], the T-S fuzzy control system stability has been verified considering a common Lyapunov function determined using linear matrix inequalities (LMIs) and optimization algorithms. New relaxed stability conditions and designs based on LMI for fuzzy control systems in continuous and discrete time have been presented in [5] and its utility is demonstrated with a fuzzy regulator and a fuzzy observer design.
The pendulum-cart system is a perfect test bed for demonstrating the theoretical and practical aspects of the control theory because of its inherently unstable open-loop with highly nonlinear dynamics. Two different dynamics of the pendulum and the cart are coupled together. There are several limitations in controlling the system, such as the limited length of the rail, and the restriction on the maximum control action.
There are many works about the swing-up and stabilization of the pendulum-cart system using several methods, for instance, [6–12]. In [6] the energy control method is used to swing the pendulum up from its pendant position to around the upright position, and a linear servo state feedback controller design by coefficient diagram method is used to stabilize the pendulum. In [7], a hybrid fuzzy controller with fuzzy swing-up and parallel distributed pole assignment schemes is adopted to position the pendulum and the cart at the desired states. The T-S fuzzy model proposed is obtained via linearization with respect to different operating points; it consists of seven fuzzy rules and friction is considered. The effectiveness of the proposed controller is validated via numerical simulations. In [8] a hybrid fuzzy controller is proposed to swing and stabilize the pendulum-cart system. The controller is designed to have a robust performance using the LMIs technique for T-S fuzzy systems. The T-S fuzzy model proposed consists of three fuzzy rules obtained through linearization via Taylor’s series where friction has not been considered. The effectiveness of this method is validated via simulation and real-time experiment. In [9] a swing-up and tracking controller design for a pendulum-cart system using hybrid fuzzy control has been proposed. A fuzzy tracking controller is designed based on a synthesis of the tracking control theory of linear multivariable control and the T-S fuzzy model. A stabilizing compensator based on observer is chosen. The Takagi-Sugeno fuzzy model is obtained via Taylor’s series linearization and consists of three fuzzy rules where friction has not been considered and both controller and observer gains are obtained via poles placement method. In [10] the robust fuzzy control problem for uncertain continuous-time nonlinear systems is considered. The T-S fuzzy model with norm-bounded parameter uncertainties is adopted. Parallel distributed compensation (PDC) scheme is employed to design, independently, the robust fuzzy controller and the robust fuzzy observer from the T-S fuzzy models. The number of rules is only two. Simulation on an inverted pendulum system demonstrates the effectiveness and the applicability of the proposed approach. On the other hand, in [11] robust H∞ controller design methodologies for T-S descriptors are considered. Two different approaches, based on LMIs, are proposed. The first one involves classical closed-loop dynamics formulation and the second one redundancy closed-loop dynamics approach. The provided conditions are obtained through a fuzzy Lyapunov function candidate and a non-PDC control law. Both the classical and redundancy approaches are compared. It is shown that the latter leads to less conservative stability conditions. To show the applicability of the proposed approaches, the benchmark stabilization of an inverted pendulum on a cart is considered. Finally, in [12] a T-S fuzzy dynamic regulator for a pendulum-cart system is proposed using local approximation in fuzzy partition spaces to derive the T-S fuzzy model of the nonlinear system. Both a fuzzy controller and a fuzzy observer are designed via PDC scheme for which feedback gains are obtained via LMIs technique. Real-time experiments validate the effectiveness of this approach for the regulation case only.
In this paper, unlike [12], the focus is placed on the trajectory tracking problem, that is, stabilizing the pendulum in its upright position while the cart follows a reference signal. Starting from a nonlinear model for a pendulum-cart system, on which viscous friction is considered, a Takagi-Sugeno fuzzy augmented model (TSFAM) as well as a TSFAM with uncertainty (TSFAMwU) is proposed. Since the design of a T-S fuzzy controller is based on the T-S fuzzy model of the nonlinear system, then, to address the trajectory tracking problem of the pendulum-cart system, three T-S fuzzy controllers are proposed: (1) a T-S fuzzy servo controller (TSFSC) designed from the TSFAM; (2) a robust TSFSC (RTSFSC) designed from the TSFAMwU; and (3) a robust T-S fuzzy dynamic regulator (RTSFDR) designed from the RTSFSC with the addition of a T-S fuzzy observer, designed also via PDC using the separation principle, which estimates cart and pendulum velocities. Both TSFAM and TSFAMwU are comprised of only two fuzzy rules and designed via local approximation in fuzzy partition spaces technique. The three T-S fuzzy controllers are designed via PDC scheme for which the state feedback gains of the local linear controllers are obtained via LMIs technique for Takagi-Sugeno fuzzy systems. A nonfuzzy swing-up controller is developed to swing the pendulum up from its pendant position to its upright position, where any of the three T-S fuzzy controllers takes action. Real-time experiments validate the effectiveness of the three proposed schemes, keeping the pendulum in its upright position while the cart follows a reference signal. The performance of the three proposed controllers is evaluated using the norm of the stable state errors of the cart and pendulum, based on the norm L2, standing out between the three controllers the RTSFDR, which presents the smaller errors.
This paper is organized as follows. Section 2 describes the state-space model of the pendulum-cart system. In Section 3 the framework of the T-S fuzzy modeling is described and also shows how the servo compensator model is introduced into a Takagi-Sugeno fuzzy model. The design of the three proposed fuzzy controllers is developed in Section 4. Real-time experimentation results are shown in Section 5. Finally, in Section 6 the conclusions are given.
2. State-Space Model of the Pendulum-Cart System
The state-space representation of the pendulum-cart system is given as in [12] (see Figure 1):
(1)x˙1=x3,x˙2=x4,x˙3=Δγβx42sinx2-βfvxx3+γδsinx2cosx2+γfvθx4cosx2+βutx42,x˙4=Δ-γ2x42sinx2cosx2-αδsinx2+γfvxx3cosx2-αfvθx4-γcosx2utx42,
where x1 denotes the position of the cart from the center of the rail [m], x2 denotes the angle of the pendulum from the upright position [rad], x3 is the velocity of the cart [m/s], x4 is the angular velocity of the pendulum [rad/s], g is the gravity constant [m/s2], m is the mass of the pendulum [kg], M is the mass of the cart [kg], l is the distance from the axis of rotation to the center of mass of the pendulum-cart system [m], I is the moment of inertia of the pendulum-cart system with respect to the center of mass [kg·m^{2}], u(t) is the force applied to the cart [N], and fvx and fvθ represent the viscous friction of the cart and the pendulum [N·m·s/rad], respectively; α=m+M, β=ml2+I, γ=ml, δ=-mgl, and Δ=1/(αβ-γ2cos2x2).
Pendulum-cart system.
3. Takagi-Sugeno Fuzzy Modeling and Control
The Takagi-Sugeno fuzzy model [13] is described by a set of fuzzy IF-THEN rules, which represent input-output local linear approximations of a nonlinear system. The main feature of a Takagi-Sugeno fuzzy model is its ability to express the local dynamics of each rule through a linear subsystem. The overall fuzzy model of the system is achieved by fuzzy blending of the linear system models.
The structure of a T-S fuzzy model for a continuous system is described as follows.
Model Rule i(2)IFz1(t)isMi1and…andzp(t)isMipTHENx˙(t)=Aix(t)+Biu(t),y(t)=Cix(t),i=1,2,…,r,
where z1(t),…,zp(t) are known premise variables that may depend on the states variables, external disturbances, and/or time, Mij are fuzzy sets, r is the number of model rules, x(t)∈Rn is the state vector, u(t)∈Rm is the input vector, y(t)∈Rq is the output vector, and Ai∈Rn×n, Bi∈Rn×m, and Ci∈Rq×n. In this work it is assumed that the premise variables are not functions of the input variables u(t).
Given a pair of (x(t),u(t)), the final output of the T-S fuzzy system 2 is inferred using a singleton fuzzifier, a product inference engine, and a center average defuzzifier as follows [14]:
(3)x˙(t)=∑i=1rhi(z(t)){Aix(t)+Biu(t)},(4)y(t)=∑i=1rhi(z(t))Cix(t),
where z(t)=(z1(t)z2(t)⋯zp(t)), hi(z(t))=wi(z(t))/∑i=1rwi(z(t)) is regarded as the normalized weight of each IF-THEN rule with wi(z(t))=∏j=1pMij(zj(t)) and Mij(zj(t)) is the degree of membership of zj(t) in Mij.
The fuzzy controller is designed via PDC technique, where each control rule is designed from the corresponding rule of the Takagi-Sugeno fuzzy model. The PDC offers a procedure to design a fuzzy controller from a given Takagi-Sugeno fuzzy model. The designed fuzzy controller shares the same fuzzy sets with the fuzzy model in the premise parts [2]. The following fuzzy controller via PDC is suggested.
Control Rule i(5)IFz1tisMi1and…andzp(t)isMipTHENu(t)=-Kix(t)
for i=1,2,…,r, where r is the number of rules and Ki is the local feedback gain. The overall nonlinear fuzzy controller is given by
(6)u(t)=-∑i=1rhi(z(t))Kix(t).
3.1. T-S Fuzzy Modeling with Uncertainty
To address the robustness of fuzzy control systems, a first and necessary step is to introduce a class of fuzzy systems with uncertainty. For this, uncertainty blocks are introduced into the Takagi-Sugeno fuzzy model to arrive at the following fuzzy model with uncertainty [1].
Fuzzy Model Rule i(7)IFz1tisMi1and…andzp(t)isMipTHENx˙(t)=(Ai+DaiΔai(t)Eai)x(t)+(Bi+DbiΔbi(t)Ebi)u(t)
for i=1,2,…,r, where the uncertain blocks satisfy that
(8)Δai≤1γai,Δbi≤1γbi
with Δai=ΔaiT(t), Δbi=ΔbiT(t), and the matrices Dai, Eai, Dbi, and Ebi, for all i, are constants associated with parameter uncertainties of the linearized model [15]. Then, the overall Takagi-Sugeno fuzzy model with uncertainties is represented as
(9)x˙t=∑i=1rhi(z(t))(Ai+DaiΔai(t)Eai)x(t)+(Bi+DbiΔbi(t)Ebi)u(t).
The next theorem provides a solution to the robust stabilization problem, which consists in selecting a PDC fuzzy controller 6 to maximize the norm of the uncertainty blocks, or equivalently, to minimize γai and γbi.
Theorem 1 (see [<xref ref-type="bibr" rid="B1">1</xref>]).
The feedback gains Ki that stabilize the fuzzy model 7 and maximize the norms of the uncertain blocks (i.e., minimize γai and γbi) can be obtained by solving the following LMIs, where αi,βi>0 are design parameters:
(10)minimizeγai2,γbi2,X,M1,…,Mr,Y0∑i=1r{αiγai2+βiγbi2}
subject to
(11)X>0,Y0≥0,S^ii+(s-1)Y1<0,T^ij-2Y2<0,i<jsuchthathi∩hj≠∅,
where s>1, Y0=XQ0X, with Q0 being a common positive semidefinite matrix, Y1=
block-diag
(Y00000), Y2=
block-diag
(Y000000000), (12)S^ii=XAiT+AiX-BiMi-MiTBiTDaiDbiXTEaiT-MiTEbiTDaiT-I000DbiT0-I00EaiX00-γai2I0-EbiMi000-γbi2I,T^ij=XAiT+AiX-BiMj-MjTBiT+XAjT+AjX-BjMi-MiTBjDaiDbiDajDbjXEaiT-MjTEbiTXEajT-MiTEbjTDaiT-I0000000DbiT0-I000000DajT00-I00000DbjT000-I0000EaiX0000-γai2I000-EbiMj00000-γbi2I00EajX000000-γaj2I0-EbjMi0000000-γbj2I,where X=P-1 and Mi=KiP-1 for all i, with P being a common positive definite matrix. The feedback gains can be obtained as Ki=MiX-1 from the solutions X and Mi of the above LMIs.
3.2. T-S Fuzzy Observer
In practical applications it is common to find that the state vector is not measurable at all. Under such circumstances, the question arises whether it is possible to determine the state from the system response to some input over some period of time. For linear systems, a linear observer provides an affirmative response if the system is observable. In linear systems theory, one of the most important results about observer design is the so-called separation principle.
As in any observer design, fuzzy observers are required to satisfy that x(t)-x^(t)→0 as t→∞, where x^(t) denotes the state vector estimated by a fuzzy observer [1]. As in the case of the controller design, the fuzzy observer is also designed via the PDC scheme. The following fuzzy observer via PDC is proposed [1].
Observer Rule i(13)IFz1tisMi1and…andzptisMipTHENx^˙(t)=Aix^(t)+Biu(t)+Liyt-y^t,y^t=Cix^t,i=1,2,…,r,
where Li∈Rn×q are the observer gains and y(t) and y^(t) are the final output of the fuzzy system and fuzzy observer, respectively. The fuzzy observer has the laws of the linear observer in its consequent parts.
The final estimated state of the fuzzy observer is given as
(14)x^˙t=∑i=1rhiztAix^t+Biut+Liyt-y^t
and the final output given by
(15)y^(t)=∑i=1rhi(z(t))Cix^(t).
The fuzzy observer design problem is to determine the local gains Li in the consequent parts. By substituting 4 and 15 into 14, then
(16)x^˙t=∑i=1rhiztAix^t+∑i=1rhiztBiut+∑i=1r∑j=1rhi(z(t))hj(z(t))LiCj(x(t)-x^(t)).
Using the final estimated states x^(t) and 6, the following T-S fuzzy dynamic regulator [12] is obtained.
Hence, the overall T-S fuzzy dynamic regulator is given by
(18)u(t)=-∑i=1rhi(z(t))Kix^(t).
Combining 18 and 14-15, as well as 3-4, and denoting x~(t)=x(t)-x^(t), the following representation is obtained:
(19)x˙t=∑i=1r∑j=1rhizthjzt·Ai-BiKjxt+BiKjx~t,(20)x~˙(t)=∑i=1r∑j=1rhi(z(t))hj(z(t))(Ai-LiCj)x~(t).
It must be noticed that the system 19-20 is an augmented system in x~(t).
3.3. Takagi-Sugeno Fuzzy Augmented Model
Let us consider the servo compensator model [16] given as follows:
(21)x˙ct=Acxct+Bcet,
where xc(t)∈Rnc are the servo compensator states and e(t)∈Rq is the tracking error, given by e(t)=yr(t)-y(t), where y(t) is the output of the plant and yr(t) is the reference signal, and
(22)Ac=block-diagAc1Ac2⋯Acn,Bc=block-diagBc1Bc2⋯Bcn,
where Aci is the companion matrix of the characteristic polynomial of the reference signal, that is, ϕ(s)=sl+αl-1sl-1+⋯+α1s+α0, such that
(23)Aci=0⋮Il-10-α0-α1⋯-αl-1,Bci=0⋮01.
Moreover, combining 2 and 21 the following T-S fuzzy augmented model (TSFAM) is obtained [9].
Augmented Model Rule i(24)IFz1(t)isMi1and…andzp(t)isMipTHENx˙tx˙ct=Ai0-BcCiAcxtxct+Bi0u(t)+0Bcyr(t)
for i=1,2,…,r.
Besides, the overall TSFAM can be described as
(25)x˙tx˙ct=∑i=1rhiztAi0-BcCiAcxtxct+∑i=1rhi(z(t))Bi0u(t)+0Bcyr(t),y(t)=∑i=1rhi(z(t))Cix(t).
For easiness of notation, 25 can be rewritten as
(26)x˙a(t)=Aaxa(t)+Bau(t)+0Bcyr(t)yat=Caxat,
where xa(t)=[x(t)xc(t)]T, Aa=∑i=1rhi(z(t))Aai, Ba=∑i=1rhi(z(t))Bai, and Ca=∑i=1rhi(z(t))Cai, with Aai=Ai0-BcCiAc,Bai=Bi0,Cai=[Ci0].
Then, for 24 the following T-S fuzzy servo controller (TSFSC) via PDC approach is suggested [9].
Servo Controller Rule i(27)IFz1tisMi1and…andzptisMipTHENu(t)=-KiKcixa(t)
for i=1,2,…,r.
Thus, the overall TSFSC is represented by
(28)ut=-∑i=1rhiztKaixat,
where Kai=[KiKci] is the augmented feedback gain matrix and hi(z(t)) is the same as the weight of the ith rule of the fuzzy system 3-4.
Substituting 28 into 25, the closed-loop behavior of the fuzzy control system is given by
(29)x˙at=A~axat+0Bcyrt,
where
(30)A~aij=Aai-BaiKaj=Ai0-BcCiAc-Bi0KjKcj=Ai-BiKj-BiKcj-BcCiAc.
The stability theorem for 29 has been derived by means of the Lyapunov direct method in [9].
4. Design of the Proposed T-S Fuzzy Controllers
In this section, based on the servo compensator approach, the design of the three proposed T-S fuzzy controllers is derived in order to meet the trajectory tracking objective for the pendulum-cart system. In [9], a fuzzy tracking controller uses the observer-based stabilizing compensator structure of the robust servo mechanism problem since there are two states of the pendulum-cart system immeasurable. In [17] it has been shown how to design a fuzzy output tracking controller based on the theory of multivariable control and Takagi-Sugeno fuzzy model.
The goal of the tracking fuzzy controller is that the cart position x1(t) asymptotically tracks the reference signal yr(t)=0.1sin(0.2πt). The Laplace transformation for the sinusoidal signal is Yr(s)=0.0628/(s2+0.3948) with characteristic polynomial ϕ(s)=s2+0.3948. Thus, the servo compensator model 21 for y(t) has the following parameters:
(31)Ac=01-0.39480,Bc=01.
4.1. Design of the TSFAM for the Pendulum-Cart System
In order to meet with the design of the TSFSC for the pendulum-cart system, a TSFAM from 1 must be constructed. Considering the pendulum deviation from the upright position, that is, x2(t), as premise variable and using the local approximation in fuzzy partition spaces technique [1], the following two-rule TSFAM for the nonlinear system is proposed.
Augmented Model Rule 1(32)IFx2t≈0THENx˙tx˙ct=A10-BcC1Acxtxct+B10ut+0Bcyrt.
Augmented Model Rule 2(33)IFx2t≈π8THENx˙tx˙ct=A20-BcC2Acxtxct+B20ut+0Bcyrt,
where
(34)A1=001000010Δ1γδ-Δ1βfvxΔ1γfvt0-Δ1αδΔ1γfvx-Δ1αfvt,A2=001000010Δ2γδξ1-Δ2βfvxΔ2γΓfvt0-Δ2αδξ2Δ2γΓfvx-Δ2αfvt,B1=00Δ1β-Δ1γ,B2=00Δ2β-Δ2γΓ,C1=C2=10000100,
with ξ1=ξ2=sin(π/4)/(π/4), Δ1=1/(αβ-γ2), Δ2=1/(αβ-γ2Γ2), Γ=cos(π/8), and membership functions μ1(x2(t))=(π/8-x2(t))/(π/8) and μ2(x2(t))=1-μ1(x2(t)) for the fuzzy rules 1 and 2, respectively.
4.2. Design of the TSFSC
Assessing the matrices for each linear local subsystem of the TSFAM 32-33 and considering the nonlinear system parameters given by Table 1, as well as verifying beforehand that the pair (Ai,Bi) is controllable, it is possible to proceed with the design of the Takagi-Sugeno fuzzy servo controller (TSFSC). The TSFSC design problem is to determine the feedback gains Kai that satisfy the stability conditions of the following theorem.
Experimental pendulum-cart system parameters.
Mass of the cart
M
2.278 [kg]
Mass of the pendulum
m
0.266 [kg]
Length to the center of mass of the pendulum
l
0.2958 [m]
Moment of inertia
I
0.00532 [kg·m^{2}]
Viscous friction of the cart
fvx
6.33 [Nms/rad]
Viscous friction of the pendulum
fvθ
0.003 [Nms/rad]
Total length of the rail
Lr
1.43 [m]
Total length of the pendulum
Lp
0.428 [m]
Theorem 2 (see [<xref ref-type="bibr" rid="B9">9</xref>]).
The equilibrium of the continuous fuzzy control system described by 27, 32, and 33 is globally asymptotically stable if there exists a common positive definite matrix PC such that
(35)A~aiiTPC+PCA~aiiT<0,A~aij+A~aji2TPC+PCA~aij+A~aji2≤0,
for i<j≤r such that hi∩hj≠∅.
The conditions 35 are not jointly convex in Kai and PC. Multiplying the inequality on the left- and right-hand sides by PC-1 and defining X=PC-1 and Mi=KaiX such that Kai=MiX-1 for X>0 exists, the next LMI conditions define the design problem of the stable fuzzy controller [1]:
(36)-XAaiT-AaiX+MiTBaiT+BaiMi>0,-XAaiT-AaiX-XAajT-AajX+MjTBaiT+BaiMj+MiTBajT+BajMi≥0.
The feedback gains Kai and a common PC can be obtained as
(37)PC=X-1,Kai=MiX-1
from the solutions X and Mi.
Then, solving the design problem of the stable fuzzy controller using the LMI control toolbox of MATLAB, we have determined the existence of a common positive definite matrix PC obtained as follows: (38)PC=0.02300.06030.01610.01280.0010-0.01250.06030.22050.04740.04140.0050-0.03220.01610.04740.01620.01230.0012-0.01100.01280.04140.01230.01130.0010-0.00800.00100.00500.00120.00100.0016-0.0004-0.0125-0.0322-0.0110-0.0080-0.00040.0110with augmented feedback gain matrices Kai for the TSFSC 28 given as follows:
(39)K1=-19.4855-108.5209-21.2657-14.1041,K2=-20.8014-115.8115-22.1939-15.0287,Kc1=-1.87529.6473,Kc2=-2.008510.2388.
4.3. Design of the TSFAMwU for the Nonlinear System
Taking into account the same considerations from the TSFAM design proposed previously, the following TSFAM with uncertainty (TSFAMwU) for the pendulum-cart system is suggested.
Augmented Model w/Uncertainty Rule 1(40)IFx2t≈0THENx˙tx˙ct=Ar10-BcC1Acxtxct+Br10ut+0Bcyrt.
Augmented Model w/Uncertainty Rule 2.(41)IFx2t≈π8THENx˙tx˙ct=Ar20-BcC2Acxtxct+Br20u(t)+0Bcyr(t)
with Ar1=Aa1+Da1Δa1(t)Ea1, Br1=Ba1+Db1Δb1(t)Eb1, Ar2=Aa2+Da2Δa2(t)Ea2, and Br2=Ba2+Db2Δb2(t)Eb2, where the uncertainty matrices are given as
(42)Da1=00-Δ1βfvxΔ1γfvx00,Da2=00-Δ2βfvxΔ2γΓfvx00,Db1=Db2=000010010000,Ea1=Ea2=001000,Eb1=Δ1β-Δ1γ,Eb2=Δ2β-Δ2γΓ,
with Δa1(t)=Δa2(t)=Δb1(t)=Δb2(t)=sin(t)/γr and γa1=γa2=γb1=γb2=γr=10.
4.4. Design of the RTSFSC
Evaluating the matrices for the TSFAMwU 40-41 and, as before, verifying previously that the corresponding pair (Ari,Bri) is controllable, one can proceed with the design of the robust T-S fuzzy servo controller (RTSFSC).
Then, according to Theorem 2 and solving the stable fuzzy controller design problem 36–37, a common positive definite matrix PR can be obtained as follows:
(43)PR=X-1,Fai=MiX-1,
where (44)PR=0.0000502500.000440.0000950.0000840.0000074670.0000000000.00044854078.0592213.16087514.5472980.0000623840.0000376960.00009525313.160872.2236742.4524300.0000133210.0000074860.00008419914.547292.4524302.7112130.0000117100.0000070760.0000074670.000060.0000130.0000110.0000029480.0000000000.0000000000.0000376960.0000074860.0000070760.0000000000.000007467with feedback gains Fai=[FiFci] given as (45)F1=-0.00367321-725.02502-122.09471-135.13451,F2=-0.00370942-739.54154-124.52753-137.84322,Fc1=-0.000508881-0.000322926,Fc2=-0.000513693-0.000327362.
4.5. Design of the T-S Fuzzy Observer
The real system has two states that are not measurable at all: the cart and pendulum velocities, namely, x3(t) and x4(t), respectively. Consequently, it is necessary to design a fuzzy observer to estimate them. Using the separation principle from the linear systems theory, the fuzzy observer design problem can be solved satisfying stability conditions of the next theorem.
Theorem 3 (see [<xref ref-type="bibr" rid="B9">9</xref>]).
The system 20 is globally asymptotically stable if there exists a common positive definite matrix PO such that the following Lyapunov inequalities are satisfied:
(46)HiiTPO+POHii<0,i=1,2,…,r,Hij+Hji2TPO+POHij+Hji2≤0
for i<j≤r, such that hi∩hj≠∅, with Hij=Ai-LiCj.
These inequalities can also be solved numerically through a LMI’s framework. Considering the same premise variable of the TSFAM 32-33, namely, x2(t), the fuzzy rules are then established as follows.
In addition, verifying beforehand that the pair (Ai,Ci) is observable and placing the closed-loop poles in [-25+10i-25-10i-27+10i-27-10i], the observer gains result as
(49)L1=47.9553-0.34486.363853.2103607.36594.8545314.3413835.2024,L2=48.0082-0.41055.693453.1955609.75033.1926283.0115833.1834,
and for which, attending Theorem 3 and solving via LMI approach, a common positive definite matrix PO has been determined as follows:
(50)PO=2.17780.1923-0.1677-0.01020.19230.6646-0.0012-0.0431-0.1677-0.00120.0175-0.0002-0.0102-0.0431-0.00020.0037.
4.6. Design of the RTSFDR
Adding the servo compensator model 21 to the RTSFSC system, the robust T-S fuzzy dynamic regulator (RTSFDR) is finally obtained as
(51)u(t)=-∑i=1rhi(z(t))Faix^i(t)xci(t).
The RTSFDR (see Figure 2) can be rewritten as
(52)u(t)=uTSR=-∑i=1rhi(z(t))Faixo(t)
with xo=[x^i(t)xci(t)].
Control scheme proposed for the inverted pendulum-cart system.
5. Real-Time Results
The experimental inverted pendulum on a cart system used to evaluate the proposed schemes consists of a cart with horizontal movement mounted on a rail with physical limits. The cart has mounted a pendulum, which rotates freely (see Figure 3 and Table 1). The rail is too short (1.43 [m]) to let the tested fuzzy controllers drive the pendulum to its upright position by themselves (this only happens on simulation conditions); for this reason, a nonfuzzy swing-up controller is used. A positive force usu(+)(t)=23.5 N and a negative force usu(-)(t)=-21 N are used to swing the pendulum up, with short movements, from its pendant position to its upright position. The switching condition between the swing-up and any of the three T-S fuzzy controllers is set for a pendulum deviation of ±π/8 with respect to the upright position. Due to the fact that the pendulum-cart system shows a large Coulomb friction in the rail, and the original nonlinear model does not consider this issue, a friction compensation was added in real-time experiments as mentioned in [12].
Experimental inverted pendulum-cart system.
The performance of the TSFSC, RTSFSC, and RTSFDR schemes applied on the pendulum-cart system is verified and exhibited in Figures 4–6. In Figure 4(a) the responses of the position of the pendulum caused by the TSFSC (blue line), the RTSFSC (red line), and the RTSFDR (black line) can be appreciated. In Figure 4(b) the reference signal yr(t) (dashed line) and the responses of the dynamics of the cart due to the TSFSC (blue line), RTSFSC (red line), and RTSFDR (black line) are exhibited. Position errors are presented in Figure 5; (a) presents the pendulum error and (b) the cart error by the TSFSC (blue line), RTSFSC (red line), and RTSFDR (black line). Figure 6 exhibits real-time control action applied to the cart by the (a) TSFSC, (b) RTSFSC, and (c) RTSFDR.
(a) Pendulum and (b) cart responses.
(a) Pendulum and (b) cart errors.
Control force applied to the cart.
To have a better control performance appreciation, we proceed to calculate the average of the root mean square (RMS), which is based on the norm L2, of the stable state error through the equations
(53)L2ex1=1T-t0∫t0Tex12dt,L2ex2=1T-t0∫t0Tex22dt,
where T is the total time of the experiment (60 sec), t0 is the initial time of interest (15 sec in this case), and
(54)L2u=1T-t0∫t0Tu2dt
is the average control action (control effort).
Table 2 presents the norms for each controller. It is clear that the RTSFDR has the smaller values for the three norms, showing hence not only the better performance, but also the less control effort.
Performance indices for the three fuzzy controllers.
Controller
L2[ex1] m
L2[ex2] deg
L2[u] N
TSFSC
0.0366
4.5893
27.0061
RTSFSC
0.0355
2.5650
20.7189
RTSFDR
0.0167
0.8608
16.4481
6. Conclusions
In this paper, in order to meet the requirement of trajectory tracking, using the local approximation in fuzzy partition spaces technique, a TSFAM and a TSFAMwU for the pendulum-cart system have been proposed. Each T-S fuzzy model is comprised of two rules on which viscous friction has been considered and, for the robust case, uncertainties have been added. Then, from the proposed TSFAM or TSFAMwU, a TSFSC, a RTSFSC, and a RTSFDR are designed via PDC scheme, which are the contribution of this paper. To make the pendulum reach its upright position, a nonfuzzy swing-up controller was developed. The switching condition between the swing-up and any of the three T-S fuzzy controllers is set for a pendulum deviation of ±π/8 with respect to the upright position. It has been demonstrated that in spite of the fact that our three T-S fuzzy controllers are comprised of only two rules, and in presence of viscous friction, a good real-time performance on the pendulum-cart system has been achieved, standing out the RTSFDR due to smaller errors and less control effort.
Conflict of Interests
The authors declare that there is no conflict of interests regarding the publication of this paper.
Acknowledgments
This work has been realized through the support of DGEST (Tecnológico Nacional de México) and CONACYT. The fourth author thanks Universidad Autónoma del Carmen (UNACAR) and Instituto Tecnológico de Sonora (ITSON) for supporting his research stage. The authors dedicate this work to the memory of Desiderio Woo Rodríguez, who built this pendulum-cart system and died young. Five master theses have been developed on it.
TanakaK.WangH. O.WangH. O.TanakaK.GriffinM.Parallel distributed compensation of nonlinear systems by Takagi-Sugeno fuzzy model2Proceedings of the IEEE International Joint Conference of the 4th IEEE International Conference on Fuzzy Systems and the 2nd International Fuzzy Engineering Symposium (FUZZ-IEEE/IFES’ 95)March 199553153810.1109/FUZZY.1995.409737WangH. O.TanakaK.GriffinM.An analytical framework of fuzzy modeling and control of nonlinear systems: stability and design issues3Proceedings of the American Control ConferenceJune 1995Seattle, Wash, USA2272227610.1109/ACC.1995.531376WangH. O.TanakaK.GriffinM. F.An approach to fuzzy control of nonlinear systems: stability and design issuesTanakaK.IkedaT.WangH. O.Fuzzy regulators and fuzzy observers: relaxed stability conditions and LMI-based designsAsaE.BenjanarasuthT.NgamwiwitJ.KomineN.Hybrid controller for swinging up and stabilizing the inverted pendulum on cartProceedings of the International Conference on Control, Automation and Systems (ICCAS '08)October 20082504250710.1109/ICCAS.2008.46942762-s2.0-58149097960TaoC. W.TaurJ. S.HsiehT. W.TsaiC. L.Design of a fuzzy controller with fuzzy swing-up and parallel distributed pole assignment schemes for an inverted pendulum and cart systemAgustinahT.JazidieA.NuhM.Hybrid fuzzy control for swinging up and stabilizing of the pendulum-cart systemProceedings of the IEEE International Conference on Computer Science and Automation Engineering (CSAE '11)June 201110911310.1109/CSAE.2011.59528132-s2.0-80051900807AgustinahT.JazidieA.NuhM.Swinging up and tracking controller design for a pendulum-cart system using hybrid fuzzy controlZhangJ.FeiM.Analysis and design of robust fuzzy controllers and robust fuzzy observers of nonlinear systemsProceedings of the 6th World Congress on Intelligent Control and Automation (WCICA '06)June 2006Dalian, China3767377110.1109/WCICA.2006.17130752-s2.0-34047217370BouararT.GueltonK.ManamanniN.Robust fuzzy Lyapunov stabilization for uncertain and disturbed Takagi-Sugeno descriptorsde la TorreW.JuradoF.LlamaM. A.Garcia-HernandezR.Takagi-Sugeno fuzzy dynamic regulator for a pendulum on a cart systemProceedings of the 10th International Conference on Electrical Engineering, Computing Science and Automatic Control (CCE '13)October 2013Mexico City, Mexico525710.1109/ICEEE.2013.66760102-s2.0-84899125663TakagiT.SugenoM.Fuzzy identification of systems and its applications to modeling and controlWangL. X.LendekZ.GuerraT. M.BabuskaR.de SchutterB.DavisonE. J.MastenM. K.Linear systemsMaX.-J.SunZ.-Q.Output tracking and regulation of nonlinear system based on Takagi-Sugeno fuzzy model