Adaptive fuzzy observer and robust controller for a -DOF robot arm S. Bindiganavile Nagesh, Zs. Lendek, A.A. Khalate, R. Babuška Delft University of Technology, Mekelweg, 8 CD Delft, The Netherlands (email: s.bindiganavilenagesh@student.tudelft.nl,. sangeetha8@gmail.com) Department of Automation, Technical University of Cluj-Napoca, Memorandumului 8, Cluj-Napoca, Romania, (email: zsofia.lendek@aut.utcluj.ro) Delft Center for Systems and Control, Delft University of Technology, Mekelweg, 8 CD Delft, The Netherlands (email: {a.a.khalate, r.babuska}@tudelft.nl) Abstract Recently, adaptive fuzzy observers have been introduced that are capable of estimating uncertainties along with the states of a nonlinear system represented by an uncertain Takagi-Sugeno (TS) model. In this paper, we use such an adaptive observer to estimate the uncertainties in the state matrices of a two-degrees-of-freedom robot arm model. The TS model of the robot arm is constructed using the sector nonlinearity approach. The estimates are used in updating the model, and the updated model is used to design a controller for the robot arm. We analyze the improvement in the achievable controller performance when using the adaptive observer. I. INTRODUCTION A large class of nonlinear systems can be represented by Takagi-Sugeno (TS) fuzzy models [], [5]. The TS model consists of a rule base, where the consequent of each rule is a linear or affine state-space model. One way to obtain an exact TS representation of a given nonlinear model is the sector nonlinearity approach []. Uncertainty that exists in the parameters of the nonlinear system can be represented in an uncertain TS fuzzy model as unmodelled dynamics. Adaptive observers that are able to estimate the unmodelled dynamics have been developed in []. These observers are designed such that, given an upper bound on the uncertainty norm, the error dynamics are asymptotically stable and the uncertainties are estimated. The observer design is based on a common quadratic Lyapunov function. In this paper, we consider a -DOF robot arm operating in the horizontal plane. A TS model of the robot arm is constructed using the sector nonlinearity approach. The uncertainty in the damping coefficients in the individual joints is represented as uncertainty in the state matrices and we use an adaptive observer to estimate this uncertainty. All the states are measured and hence the adaptive observer estimates only the uncertainties. The design of uncertainty estimation experiments based on the structure of the TS fuzzy model is also investigated. We analyze the influence of the obtained uncertainty estimates on the controller design. The estimates given by the adaptive observer are used to update the TS model of the robot arm. Subsequently, the updated model is used to redesign a stabilizing controller. We analyze the improvements in the controller performance due to the use of an updated model. To use the updated model in controller design, we need a design method which uses the same uncertainty distribution structure as the adaptive observer. Hence, we use a robust controller design approach for the same uncertainty distribution structure. Uncertainty estimation in the presence of a stabilizing controller is also studied. The paper is organized as follows. Section II presents the robot arm model. In Section III, an adaptive observer is designed for the robot arm. In this section we also discuss the use of the structure of the TS model in setting up the uncertainty estimation experiments. Section IV presents the robust controller design for the robot arm. Section V presents the uncertainty estimation in the presence of a controller stabilizing the plant. Finally, Section VI concludes the paper. II. TS MODEL OF THE -DOF ROBOT ARM Robot manipulators are of great importance for automation not only in traditional industries, such as car manufacturing, but more importantly in new upcoming domains, such as agricultural harvesting and product handling, or in household tasks. Rather than big, heavy and therefore dangerous, these new-generation robots need to be human-friendly. This requires light-weight, soft and compliant mechanical design, combined with novel control solutions to achieve the desired precision and repeatability. In this paper we use an adaptive observer to estimate the uncertainties in the state matrices of a -DOF robot arm model. The TS model of the robot arm is constructed using the sector nonlinearity approach. The estimates are used in updating the arm model, and the updated model is used to design a controller for the arm. A schematic representation of a -DOF robot arm is given in Figure. The nonlinear model of the arm operating in the horizontal plane is: M R (θ) θ + C R θ = τ () with M R(θ) = C R(θ, θ) =» P + P + P cos θ P + P cos θ () P + P cos θ P» b P θ sin θ P ( θ + θ ) sin θ P θ () sin θ b
Fig.. A -DOF robot arm. P P + P cos(θ ) B = P cos (θ ) P P P cos (θ ) P P P + P cos(θ ) P P + P + P cos(θ ) cos (θ ) P P P cos (θ ) P P Examining the above nonlinear model reveals the presence of six nonlinear terms: cos(θ ) z = P cos(θ ) z = P P P cos(θ ) P P θ sin(θ ) θ z = P cos(θ ) z = cos(θ ) sin(θ ) P P P cos(θ ) P P θ sin(θ ) θ z 5 = P cos(θ ) z = cos(θ ) sin(θ ) P P P cos(θ ) P P The term A for instance can be written in terms of the above nonlinearities as where M R is the mass matrix, C R is the Coriolis and centrifugal force matrix, θ and θ are the joint angles, θ and θ are the angular velocities, τ and τ are the torque inputs, P = m c + m l + I, P = m c + I, P = m l c, l and l are the lengths, m and m are the masses, I and I are the inertias, c and c are the centers of mass of the first and the second link, respectively, and b and b are the damping coefficients of the first and second joint, respectively. The above model can be written in the state-space form as follows: where x = [ θ [ M ẋ = R C ] R x + I θ θ θ ] T, or as where A A A = A A M R τ () ẋ = A(θ, θ)x + B(θ)τ (5) A = P(b P θ sin(θ ) P cos (θ ) P P P θ sin(θ )(P + P cos(θ )) P cos (θ ) P P b(p + P cos(θ)) A = PP sin(θ)( θ + θ ) P cos (θ ) P P P cos (θ ) P P A = P θ sin(θ )(P + P + P cos(θ )) P cos (θ ) P P (P + P cos(θ))(b P θ sin(θ )) P cos (θ ) P P b(p + P + P cos(θ)) A = P cos (θ ) P P + P sin(θ)(p + P cos(θ))( θ + θ ) P cos (θ ) P P () A = P b z P P z P z Similarly all other elements in A and B can be written in terms of the above six nonlinearities. Using the sector nonlinearity approach [], TS models of the form R i : If z is N i and z is N i,... and z p is N p i, then ẋ = A i x + B i u y = C i x for i =,,...,r can be constructed. The TS model can be written as: ẋ = h i (z)(a i x + B i u) y = i= h i (z)(c i x) (7) i= where r is the number of rules, x is the state vector, u is the input vector, y is the output vector, x R nx, u R nu, and y R ny, z = [z,z...z p ] T is the vector of scheduling variables, A i R nx nx, B i R nx nu, i =,,..., r are known state and input matrices of the individual linear models that are combined to represent the nonlinear system, and h i (z) are normalized membership degrees of the rules. Since we have six nonlinear terms, p =, and the number of rules is r =. However, if we neglect the Coriolis and centrifugal forces in C R, i.e., assuming [ that] θ sin(θ ) and θ sin(θ ), b leading to C R =, we have only the two following b nonlinearities: z = P cos(θ ) (8) P P and z = and we obtain the state-space model cos(θ ) P cos(θ ) P P (9) ẋ = A(z,z )x + B(z,z )u ()
where u is the input voltage [u u ] T and the actual input torque τ is represented in terms of the input voltage,»» km u τ = () k m u P b z P b z P b z P A = b z P b z b z (P + P ) + P b z 7 5 () and P k mz k m(p z + P z ) k B = m(p z + P z ) k m(p z + z (P + P )) 7 5 () where k m and k m are voltage-to-torque motor gains. To obtain the values of the parameters, we first identified the parameters of the DC motors in the individual joints, using SISO identification experiments on a small-scale robot arm, with the bandwidth of operation around 5 Hz. These values were used afterwards to find the values of P, P and P through nonlinear optimization based on input-output data from MIMO experiments on the robot arm. The values obtained through the nonlinear optimization are k m =.59, k m =.5, b =., b =., P =.9, P =.9 and P =.97. The angles are limited to. θ. rad and.7 θ. rad. We have compared the model outputs for the model with a complete C R (Coriolis) matrix and with a simplified C R matrix consisting of only damping coefficients. The comparison between the angular positions of the two links of the robot arm model when excited by a multisine input is presented in Figures and. Normalized input voltage Angular position in degrees.5.5 5 7 8 9 5 7 8 9 θ complete θ simplified Fig.. Comparison between the model outputs link. It can be observed that the outputs are almost the same. This indicates that in the considered setting we can neglect the Coriolis and centrifugal forces in the nonlinear model and in the sequel we use the simplified nonlinear model. With the model parameters as described above, a -rule TS model is Normalized input voltage Angular position in degrees.8...... 5 7 8 9 8 5 7 8 9 θ complete θ simplified Fig.. Comparison between the model outputs link. constructed by using the sector nonlinearity approach []. The rules of the TS model are of the form R i : If z is N i and z is N i then ẋ = A i x + B i u for i =,,, () and membership functions obtained are w (z ) = w (z ) = w (z ) = w (z ) = z max z z max z min z z min z max z min z max z z max z min z z min (5) z max z min Since all the states are measured, the above model can be rewritten as ẋ = h i (z)(a i x + B i u) i= y = Cx with C = I, and the normalized membership values of each rule are given by h i (z) = w i(z) and w (z) = w i (z) i= w (z )w (z ), w (z) = w (z )w (z ), w (z) = w (z )w (z ), and w (z) = w (z )w (z ). The matrices A i and B i, i =,,, are obtained by substituting the minimum and maximum values of the uncertainties, respectively. For instance, the matrices of the first local model are A =.77.89 5.5 9. ()
.9 8. B = 5.8 9. (7) Matrices A i and B i for i =,, can computed in the same way. The output matrix is the identity matrix for all the four rules, i.e., all the states are available as outputs. III. ADAPTIVE OBSERVER DESIGN An adaptive observer that can estimate uncertainties in the state matrices of a TS model has been proposed in []. We use this observer to estimate the uncertainties, and later on, to improve the performance of the controller designed for the robot arm. Since the states are measured and the uncertainties are present only in the state matrices, the uncertain TS model is of the form ẋ = h i (z)(a i x + B i u + M i A δi x) i= y = Cx where C = I and the product M i A δi represents the uncertainty in the state matrices. We assume that this uncertainty is due to the damping coefficients. The adaptive observer that is used to estimate the uncertainties is of the form x = h i (z)(a i x + B i u + L i (y ŷ) + M i (Âδi x)) i= ŷ = C x together with the update law  δi = h i (z)mi T PC e y x T i =,,...,r (8) where L i, i =,,...,r are the observer gain matrices for each rule, P is the Lyapunov matrix, and C is the Moore- Penrose pseudoinverse of the output matrix C. Given that the uncertainty norm satisfies A δi µ max, the update laws are determined so that the estimation errors (x x) and (A δi Âδi) asymptotically converge to zero. Considering the uncertainty in the values of damping coefficients b and b to be.5 and. respectively, we have.. A δi = (9)..5 for i =,,,. The uncertainty distribution matrices are M i = () for i =,,,. The product M i A δi is referred to as the uncertainty distribution structure, with the notation A i = M i A δi. A multi-sine input signal limited in frequency to Hz that activates all rules is used to excite the system. This input is chosen such that the states do not reach their saturation limits. The duration of 5 s for the simulation of the adaptive observer has been experimentally determined as sufficient to obtain a significant reduction in the uncertainty estimation error. With the maximum uncertainty norm A δi being., we can design an adaptive observer with µ max =. However, repeating the experiments for different values of µ max, we observed that as the value of µ max for which the adaptive observer is designed increases, the uncertainty estimation error given by r i= trace(āt δiāδi) decreases at a faster rate. Therefore, we have redesigned the observer for µ max =. For this value, we obtain P = 557.85.... 557.9.... 557.9.... 557.9 and the observer gains L i, i =,,...,r are 8.5 9..9 L = 9..5.5.9 75..5 75. 8.5 7.99.9 L = 7.99 7..5.9 75..5 75. 8.5 9..9 L = 9..5.5.9 75..5 75. 8.5 7.99.9 L = 7.99 7..5.9 75..5 75. After executing the adaptive observer for 5 s, the uncertainty estimates are:..  δ =..55..  δ =..8.9  δ =.5.5.9  δ =.8. The activation of the rules is shown in Figure. The uncertainty estimation error corresponding to each rule is given in Figure 5 for µ max =, µ max = and µ max =. Note that the uncertainty estimation error converges faster for larger values of µ max. The estimation error also converges faster for the rules with higher activation degrees. For instance, the activation degrees of R and R are higher than those of R and R and the uncertainty estimation error is smaller in case of R
h h h h.5 5 5 5 5 5 5.5 5 5 5 5 5 5.5 5 5 5 5 5 5.5 5 5 5 5 5 5 Fig.. Activation of the rules. µ max = are obtained as.. Â δ =..5. Â δ =.8. Â δ =.5 Â δ =. For rules and, the uncertainty estimates are close to the true values. Better estimates for rules and can be obtained if the simulation is run longer. Thus, we can exploit the uncertainty structure in the TS model to design the estimation experiments. IV. ROBUST CONTROLLER DESIGN tr(āt δāδ) tr(āt δāδ) tr(āt δāδ) tr(āt δāδ) µ max = µ max = µ max = 5 5 5 5 5 5 5 5 5 5 5 5 5 5 5 5 5 5 5 5 5 5 5 5 Fig. 5. Uncertainty estimation error with different values of µ max. and R compared to R and R. This is due to the update laws of the uncertainty matrices, which depend on the degree of rule activation. The nonlinearities in the TS model depend only on θ. Moreover, if the uncertainty is only in b, then the uncertainties can be estimated using only u, thus avoiding the need to design the input u. Let us consider this case, i.e., the uncertainty only in b. Then, assuming that the true uncertainties are A δi = [. ].5 the estimates of the uncertainties using input u alone with The estimates obtained in the previous section are now used to update the model of the robot arm. To analyze the achievable improvements in the controller performance, we design a controller with the same uncertainty distribution structure as in the adaptive observer, i.e., A i = M i A δi. Robust control designs similar to those available in [] can be derived for the uncertainty distribution structure M i A δi. Using a common quadratic Lyapunov function V (x) = x T Px, the following theorems present the robust controller design with an associated decay rate of α and the maximum uncertainty norms for which the controller can guarantee stability. The controller is a parallel distributed compensator with each rule of the controller containing a linear feedback law for each corresponding rule of the TS model. Consider the TS fuzzy system, ẋ = h i (z)(a i x + B i u + M i A δi x) () i= and the control law u = h i (z)f i x () i= where h i are the normalized membership functions. Theorem : The uncertain fuzzy system () is stabilized by the controller () and the closed-loop system has a decay rate of at least α if there exist a common positive definite matrix P (X = P ) and N i, i =,,...,r (N i = F i X) that satisfy maximize µ i,x,n,n...n r subject to X >, β i µ i i= Ŝ ii <, T ij <, i,j =,,...,r and i < j s.t h i h j
where r is the number of rules, F i are the controller gains, α is the specified decay rate, β i,i =,,...,r are design parameters and Ŝii and T ij,i,j =,,...,r are given by (Ŝ ) ii + αx M i X Ŝ ii = Mi T I () X I µ i ( ) T ij + αx M i M j X X Mi T I T ij = Mj T I () X I µ i X I µ j with Ŝ ii = A i X + XA T i B i N i N T i BT i, and T ij = A i X + XA T i + A j X + XA T j B in j Nj TBT i B j N i Ni TBT j. The maximum uncertainty bounds µ i on A δi ( A δi µ i ) for which the controller guarantees stability is obtained as part of the control design procedure. Constraints on the control input can also be specified, as follows. Theorem : [] The system () is stabilized by () and given an upper bound φ on the initial state (i.e., x() φ), the constraint on the control input u(t) ζ is satisfied for all t >, if the following LMIs are satisfied X T Ni ζ I N i X φ I for i =,,...,r Using Theorems and, a robust controller is designed for the nominal TS model with α =, φ = and ζ =. The maximum uncertainty norms obtained from the controller design are µ i =., i =,,,. These values guarantee stability of the nominal model since the maximum uncertainty norm of the four rules is.. When the adaptive observer is used to estimate the uncertainties, the norms of the residual uncertainty, i.e., A δi Âδi after 5 s are obtained as.78,.95,. and.77 for the four rules. Consequently, the norm of the uncertainties for which a controller will have to be designed with the updated model, are smaller, and an improvement in the controller performance can be expected. Designing the controller with α =, φ = and ζ = for the updated model, the maximum uncertainty norms guaranteed to be stabilized by the controller are µ i =.7, i =,,,. V. CLOSED-LOOP UNCERTAINTY ESTIMATION IN A CONTROLLED SYSTEM In the case of systems for which open-loop experiments cannot be performed (such as open-loop unstable systems), closed-loop uncertainty estimation must be considered. In this section, we investigate this case. A robust controller that stabilizes the system is designed for the nominal TS model with α =, φ = and ζ =, and an adaptive observer with µ max = is designed to estimate the uncertainties. The h h h h.5 5 5 5 5 5 5.5 5 5 5 5 5 5.5 5 5 5 5 5 5.5 Fig.. tr(āt δāδ) tr(ā T δāδ) tr(āt δāδ) tr(ā T δāδ) 5 5 5 5 5 5 Rule activation when the system is stabilized by a controller. µ max = µ max = µ max = 5 5 5 5 5 5.5.5 5 5 5 5 5 5 5 5 5 5 5 5 5.5.5 5 5 5 5 5 5 Fig. 7. Uncertainty estimation error comparison with and without the controller. activation of the different rules and the individual uncertainty estimation errors are shown in Figures and 7. The uncertainty estimates obtained after 5 s are.8. Â δ =..5.. Â δ =..5. Â δ =.. Â δ =. The uncertainty estimation error obtained in closed loop is higher than then error obtained in open loop. It can be seen from Figure 7 that the estimation error converges faster in the case of rule R. This is due to the fact that the stabilizing action by the controller takes the states of the system towards zero. Since θ is close to zero, the degree of activation of R is high, but the activation of the other rules is lower.
VI. CONCLUSIONS AND DISCUSSIONS In this paper we presented an adaptive observer to estimate uncertainties in the model of a -DOF robot arm. The results show that the value of the upper bound on the uncertainty norm µ max for which the adaptive observer is designed behaves as an uncertainty convergence rate. However, in our model, uncertainty is present only in the state matrices. This behavior has to be verified in situations where uncertainties exist in the input matrices as well. The uncertainty estimates were used to obtain an updated model. Simulation results indicate that with lower uncertainty in the updated model, the controller can guarantee stability with a higher decay rate. It is important to note that in general the value of µ max to be used will depend on the extent to which the initial uncertain model represents the plant, with larger mismatch between the plant and the model requiring higher values of µ max. The possibility to exploit the structure of the uncertainty in the TS model in designing the experiments was also discussed. However, since not all rules are activated with a high degree, in this case, the uncertainty convergence rate becomes very small for those rules that are not activated. Hence, the experiment duration and the type of input signal required to obtain better estimates for these other rules should be further investigated. ACKNOWLEDGMENT This work was supported by a grant of the Romanian National Authority for Scientific Research, CNCS UEFISCDI, project number PN-II-RU-TE---, contract number 7/..5. REFERENCES [] C. Fantuzzi and R. Rovatti, On the approximation capabilities of the homogeneous Takagi-Sugeno model, in Proceedings of the Fifth IEEE International Conference on Fuzzy Systems, New Orleans, Louisiana, September 99, pp. 7 7. [] Zs. Lendek, T. M. Guerra, R. Babuška, and B. De Schutter, Stability Analysis and Nonlinear Observer Design Using Takagi-Sugeno Fuzzy Models, P. J. Kacprzyk, Ed. Springer,. [] Zs. Lendek, J. Lauber, T.-M. Guerra, R. Babuška, and B. De Schutter, Adaptive observers for TS fuzzy systems with unknown polynomial inputs, Fuzzy Sets and Systems, vol., no. 5, pp. 5,. [] H. Ohtake, K. Tanaka, and H. Wang, Fuzzy modeling via sector nonlinearity concept, in Proceedings of the Joint 9th IFSA World Congress and th NAFIPS International Conference, vol., Vancouver, Canada, July, pp. 7. [5] T. Takagi and M. Sugeno, Fuzzy identification of systems and its applications to modeling and control, IEEE Transactions on Systems, Man, and Cybernetics., vol. 5, pp., 985. [] K. Tanaka and H. O. Wang, Fuzzy Control Systems Design and Analysis - A Linear Matrix Inequality Approach. John Wiley & Sons, Inc,.