Available online at www.scienceirect.com Expert Systems with Applications 3 (009) 454 459 Short communication Feeback linearization control of a two-link robot using a multi-crossover genetic algorithm Jian Liung Chen a, *, Wei-Der Chang b a Department of Electrical Engineering, Kao Yuan University, Kaohsiung 8, Taiwan b Department of Computer an Communication, Shu-Te University, Kaohsiung 84, Taiwan Expert Systems with Applications www.elsevier.com/locate/eswa Abstract In this paper, we propose a novel multi-crossover genetic algorithm (GA) to ientify the system parameters of a two-link robot. The resulte system moel by the propose GA is then applie to the feeback linearization control such that the two-link robot system can be transferre to a linear moel with a nonlinear boune time-varying uncertainty. To eal with the uncertainty, a sliing moe control approach is esigne to achieve the tracking control. Finally, some simulation results are emonstrate to show the utility of our propose metho. Ó 008 Elsevier Lt. All rights reserve. Keywors Multiple-crossovers; Two-link robot; Parameters estimation; Feeback linearization; Sliing moe control. Introuction The mathematical representation of a two-link robot is a highly nonlinear ynamic equation. It is kin of ifficult to esign a controller to achieve the angle setting of a robot. In the literatures, there are many control methos propose for solving such the robot control system, for example, the rate linearize moe (Golla, Garg, & Hughes, 98), moel-base control (Kawaski & Kato, 99), nonlinear robust control (Kuo & Wang, 989), feeback linearization (Khatib & Burick, 98), an Taylor approximation (Seraji, 98). Since the feeback linearization control is to use nonlinear feeback terms to transform the two-link robot system into an equivalent linear system, it has been caught our attentions. A mathematical moel for the two-link robot is neee if this technique is applie. However, uner many physical situations, exact mathematical moels can not be easily obtaine especially for the system parameters of a two-link robot. In the paper, a multi-crossover genetic * Corresponing author. E-mail aresses clchen@cc.kyu.eu.tw (J.L. Chen), wchang@mail.- stu.eu.tw (W.-D. Chang). algorithm (GA) is initially evelope for ientifying system parameters of a two-link robot, an then this estimate moel is applie to the feeback linearization. The GA metho has been proven as a powerful tool for solving optimal or near optimal solution for an given optimization problem (Angelov & Buswell, 003; Carvalho & Freitas, 004; Davis, 99; Golberg, 989; Montiel, Castillo, Melin, & Sepulvea, 003; Montiel, Castillo, Sepulvea, & Melin, 004; Muhlenbein, 994; Muhlenbein & Mahnig, 00; Tang & Xu, 005; Tsutsui & Golberg, 00). It provies better searching capability over the traitional graient metho. Because the graient metho searches for a problem solution only from a single irection, while GA metho is from multiple irections ue to its crossover an mutation operations. This means that it is highly possible to escape from a local minimum (Huang & Huang, 99). In the binary GA (Kristinsson & Dumont, 99; Jiang & Wang, 000), all parameters of interest must be encoe as binary igits (genes) an then collect these binary igits to be a string (chromosome). In contrast to the binary GA, another kin of real-coe GA has been also introuce to a wie variety of applications as in Tang an Xu (005), Huang an Huang (99), Blanco, Delgao, an Pegalajar 095-44/$ - see front matter Ó 008 Elsevier Lt. All rights reserve. oi0.0/j.eswa.008.0.048
J.L. Chen, W.-D. Chang / Expert Systems with Applications 3 (009) 454 459 455 (00), Deb an Gulati (00), Zamparelli (99), Tzeng an Lu (000), Lu an Tzeng (000), Xu an Daley (995). All genes in the chromosome are now encoe as real numbers. For most real optimization problems, this type of real-coe GA has more avantages over the conventional binary GA. For example, the length of a chromosome use in the realcoe GA becomes much shorter than that of the binary GA, an it is easier to implement the real-coe GA into the computer programs. Unlike the general crossover operation by using two chromosomes, a multi-crossover operation will be propose in this paper. We use the improve real-coe GA to ientify the system parameters of a two-link robot. All of unknown parameters are collecte as a chromosome, an a population of these chromosomes will be evolve by using genetic operations of reprouction, multiplecrossover, an mutation. Due to the error cause by parameters estimation, the moel of two-link robot can t be exactly linearize accoring to the estimate moel. Therefore, the inter loop system, i.e. the connection between the estimate moel an actual two-link robot can be viewe as a linear system with nonlinear boune time-varying uncertainty. Furthermore, we will fin out the uncertainty to conform the matching conition. Since the sliing moe control is a popular technique for robust controls uner the matching conition (Khalil, 99), we use it to overcome the rawback an to achieve the tracking control of a two-link robot. In the sliing moe control, state trajectories of system are force to reach a sliing manifol in finite time, an stay on the manifol for all future time. Since the inter loop system is linear, the controller esign can be reuce mostly an be simply well one. Simulation results will be illustrate to show that the angles of a two-link robot can be regulate to the esire output by using our propose metho.. Problem formulation Consier the nonlinear ynamic equation for a two-link robot (Spong & Viyasagar, 989), which is shown in Fig., escribe as follow MðhÞ h þ Nðh; hþþgðhþ _ ¼s ðþ where h ¼ ½h h Š T is the output vector; θ l m θ l m Fig.. A two-link robot system. m p s ¼ ½s s Š T is the two-imensional torque input vector; MðhÞ ¼ M M M T is the symmetric inertia matrix an is M 4 the positive efinition for all h R, M ¼ =3m l þ =m l þ m ðl þ =4l Þ þ m p ðl þ l Þþðm þ m p Þl l cosh M ¼ =m l þ =4m l þ m pl þ =ðm þ m p Þl l cosh M 4 ¼ =m l þ =4m l þ m pl Nðh; hþ¼½n _ N Š T accounts for centrifugal an Coriolis forces; N ¼ðm þ m p Þl l h _ h _ sinh =ðm þ m p Þl l h _ sinh N ¼ð=m þ m p Þl l h _ sin h GðhÞ¼½G G Š T accounts for gravity forces; G ¼ð=m l þ m l þ m p l Þg sinh þð=m l þ m p l Þg sinðh þ h Þ G ¼ð=m þ m p Þl g sinðh þ h Þ For convenience, let ½ x x x 3 x 4 м½h h _ h h _ Š. Since M(h) is the positive efinition for all h R, we set M ðhþ ¼ M M ¼ u u M T M 4 u T u 4 The nonlinear ynamic Eq. () can be represente as the state equation 3 3 3 _x x 0 0 _x 4 _x 3 5 ¼ u ðn þ G Þu ðn þ G Þ 4 x 4 5 þ u u 4 0 0 5 s _x 4 u T ð N þ G Þu 4 ðn þ G Þ u T u 4 ðþ an output equation y ¼ 0 0 0 x x 0 0 0 4 y x 3 x 4 3 5 ð3þ Moreover, let C =[c,c,...,c m ] be an unknown parameter vector in the two-link robot system. From the evolutionary point of view, C is calle a chromosome an all c i, for i m an m = {,,...,m}, are calle genes. 3. A multi-crossover genetic computation To execute the genetic operations, a performance inex or an objective function shoul be efine in the beginning. In GA, it only requires the computation of the objective function to guie its search, an there is no requirement for its ifferentiation, which may be usually neee in the traitional optimal metho. A summation of square error
45 J.L. Chen, W.-D. Chang / Expert Systems with Applications 3 (009) 454 459 (SSE) is chosen as the objective function in this stuy efine by SSE ¼ XT k¼ h i ðy ðþ^y k ðþ k Þ þ ðy ðþ^y k ðþ k Þ ( Γ Γ ) + ( Γ Γ3 ) Γ Γ 3 Γ Γ Γ Γ 3 ¼ XT k¼ e ðþþe k ðþ k ; ð4þ where T is the number of given sampling steps, y an y are the actual outputs in (3), ^y an ^y are the evaluate outputs. Our purpose is to fin the optimal moel parameter vector C by using the propose metho such that the SSE in (4) is minimize. The GA starts with a given ranom initial population that contains many chromosomes. Each chromosome in the population represents a set of possible parameter solution for the two-link robot system. The chromosomes are then evolve within the user-efine interval [c l,c u ] to generate better offspring. When a generate chromosome goes beyon the interval, the original chromosome is retaine. In the following evelopment, let N represent the size of population, parameters p r, p c,anp m are referre to as probabilities of reprouction, crossover, an mutation, respectively. In aition, throughout the paper a uniform probability istribution is assume for all use ranom values. The etaile escriptions of three genetic operators are state as follows. 3.. Reprouction For the reprouction operation there are two well known selection mechanisms the roulette wheel an tournament selections. The roulette wheel selection can be visualize by imagining a wheel where each chromosome occupies an area that is relate to its value of objective function. When a spinning wheel stops, a fixe marker etermines which chromosome will be selecte to reprouce (Blanco et al., 00). This kin of selection mechanism nees more numerical computations. However, the tournament selection is simpler than the roulette wheel selection. In this selection p r N chromosomes with better SSE values are uplicate into the population, an the same amount of chromosomes with worse SSE values are iscare from the population. This keeps the same population size. 3.. Multiple-crossover Unlike the traitional crossover by using only two chromosomes, a novel crossover formula that contains three parent chromosomes is propose in this stuy. We assume that chromosomes C, C, an C 3 are selecte from the population ranomly an SSE (C ) is the smallest among three SSE values. Also, let c be a ranom number selecte from [0, ]. If c P p c, then the following multiple-crossover are performe to generate new chromosomes Fig.. A moifie ajusting vector by using the propose multiplecrossover. C C þ qðc C C 3 Þ; C C þ qðc C C 3 Þ; C 3 C 3 þ qðc C C 3 Þ; where q [0,] is a ranom value etermining the crossover grae of these three. If c < p c, no crossover operation is performe. It is clear from Fig. that the resulting ajuste vector (C C C 3 ) is a combination of vectors C C an C C 3. 3.3. Mutation The mutation operation follows the crossover an provies a possible mutation on some chosen chromosomes C. Only p m N chromosomes in the population will be ranomly selecte to mutate. The formula of mutation operation for the selecte C is given by ð5þ C C þ s U; ðþ where s is a positive constant an U R m is a ranom perturbation vector proucing a small effect on C. Performing the above three evolutionary operations for the whole population one time is calle a generation. The algorithm stops if the pre-specifie number of generations G is achieve. 4. Feeback linearization an controller esign In this stuy, the system parameters l, l, m, an m in () are assume to be unknown an will be estimate by using the propose multi-crossover GA. Hence, let ^l ;^l ; ^m ; an ^m be the estimate system parameters an we have the following nonlinear moel for the two-link robot system bm ðhþv þ bn ðh; hþþ _ bgðhþ ¼s M where bm ðhþ¼ b bm, bn ðh; hþ¼ bm T bm _ N b 4 bn s ¼ s, h ¼ h, s h bm ¼ =3^m ^l þ =^m ^l þ ^m ^l þ =4^l þ m p ^l þ ^l þ ^m þ m p ^l^l cos h ; ðþ, bgðhþ¼ G b, bg Γ
J.L. Chen, W.-D. Chang / Expert Systems with Applications 3 (009) 454 459 45 bm ¼ =^m ^l þ =4^m ^l þ m p^l þ = ^m þ m p ^l^l cos h ; bm 4 ¼ =^m ^l þ =4^m ^l þ m p^l ; bn ¼ ^m þ m p ^l^l h _ h _ sin h = ^m þ m p ^l^l h _ sin h ; bn ¼ = ^m þ m p ^l^l h _ sin h ; bg ¼ =^m ^l þ ^m ^l þ m p^l g sin h þ =^m ^l þ m p^l g sin ðh þ h Þ; bg ¼ =^m þ m p ^l g sin ðh þ h Þ If the errors between M an M _, N an N _, G an G _ are consiere, then the Eq. () can be rewritten as MðhÞv þ Nðh; _ hþþgðhþþe ¼ s where e represents those errors. By using techniques of feeback linearization shown in Fig. 3 an using (), we get the following linear system MðhÞ h þ Nðh; _ hþþgðhþ ¼MðhÞv þ Nðh; _ hþþgðhþþe ) MðhÞ h ¼ MðhÞv þ e ) h ¼ v þ M ðhþe where v is a sliing moe control that will be esigne below. Moreover, let D = M (h)e an the above equation becomes h ¼ v þ D ð8þ Note that the term D can be viewe as the uncertainty of system (8). Since less error can be achieve by using the propose multi-crossover GA, the uncertainty D is boune. Furthermore, the state Eq. (8) is _x ¼ Ax þ Bðv þ DÞ where τ Mˆ v + Nˆ + Gˆ M θ + N + G Fig. 3. Structure of feeback linearization. ( θ,θ ) ð9þ x ¼ ½x x x 3 x 4 Š T ¼ h h _ h h _ T ; 3 3 0 0 0 0 0 0 0 0 0 A ¼ 4 0 0 0 ; B ¼ 0 5 4 0 0 5 0 0 0 0 0 It shoul be pointe out that by means of feeback linearization technique we o not nee to take the internal ynamic of system () into account (Slotine & Li, 99). This inicates that if we can esign a controller to stabilize system (9), it shoul also stabilize the structure of Fig. 3. To overcome the boune uncertainty of system (9), a sliing moe control v is esigne to satisfy the control performance. Reference to the structure of Fig. 4, a esire reference signal y R is generate from _x ¼ A x þ B y y ¼ C x where A, B, an C are constant matrices with appropriate sizes. Furthermore, efine the tracking error as ~x x y an we have the following theorem. Theorem. If we choose a sliing surface r ¼ C~x ¼ ½r r Š T, where C R 4 is a given full row rank constant matrix, an efine P ½p p Š T ¼ CBD, then the sliing control law v ¼ðCBÞ ½CAx CC A x CC B u ŠðCBÞ KsgnðrÞ ð0þ where K =[k ii ] is a iagonal matrix an k ii > j p i j for i =,, will be such that the tracking error approaches zero, i.e., ~x! 0.proof To complete this proof, we nee to show that the controller output v forces r to zero in the finite time an then maintain the conition r = 0 for all further time. Defining V ¼ rt r as a Lyapunov function caniate, then we have _V ¼ r T _r with _r ¼ C _~x ¼ C ð_x _y Þ ¼ CAxþ ½ Bvþ ð DÞŠCC ða x þ B u Þ. Moreover, by using (0), we have _r ¼KsgnðrÞþP ¼ k sgnðr Þþp k sgnðr Þþp Therefore, we get u x y = A x + B u = C x y τ Mˆ v + Nˆ + Gˆ M θ + N + G ( θ,θ ) Fig. 4. Overall control system configuration of a two-link robot.
458 J.L. Chen, W.-D. Chang / Expert Systems with Applications 3 (009) 454 459 _V ¼ r T _r ¼ r ½k sgnðr Þþp Šþr ½k sgnðr Þþp Š< 0; since k ii > jp i j an sgnðr i Þ¼ if r i > 0 ifr i < 0 ðþ for i =,. The inequality _V < 0 ensures that if the trajectory happens to be on the manifol r = 0 at some time, it will be confine to that manifol for all further time because leaving the manifol requires _V > 0, which is impossible in view of the inequality. It also shows that ~x! 0 an, therefore, the angles of a two-link robot will track the reference signal y. Remark. Since the matrix B in Eq. (9) is a full column rank matrix an if we choose the matrix C to be a full row rank matrix, then we can guarantee that the matrix CB is invertible. Therefore, an allowable control law can be obtaine. Fig. 5. Responses of h (the soli line) an y (the otte line); controller v. 5. Simulation results In this section, an illustrative example is given to emonstrate the feasibility of the propose metho. Consier a two-link robot system of () with the actual parameters l = 0.5, l = 0.5, m = 3.4, m =., an m p =. A esire reference output y is given by 3 3 4 40 0 0 0 0 0 0 _x ¼ 4 0 0 4 40 5 x 0 0 þ 4 0 5 u 0 0 0 0 0 3 0 40 0 0 5 0 0 y ¼ 4 0 0 0 405 x ; 0 0 5 with x (0) = 0 an u ¼ ½0uðtÞ 5 uðtþš T, where u(t) is the unit step function. In the beginning, the propose multi-crossover GA is applie to parameter ientification of system () for [l,l,m,m ]. For simulations, the sampling time is set to be 0.005, an both torque inputs s an s in () are generate from the interval (,) at ranom. The relate variables use in GA operations are given as follows ½r l ; r u м½0; 0Š; T ¼ 0; N ¼ 0; G ¼ 3000; p r ¼ 0; p c ¼ 04; p m ¼ 0; s ¼ 005 All of initial chromosomes are ranomly create from the searching interval. Each element of noise vector U in () is ranomly chosen from [0.0, 0.0]. After performing our propose GA metho, we obtain the resulte system parameters ^l ^l ^m ^m ¼ ½05 05 3399 Š. Furthermore, to esign a sliing moel controller, we choose sliing surface as r ¼ C~x with Fig.. Response of h (the soli line) an y 3 (the otte line); controller v. C ¼ 00 0 0 0 0 00 an K in (0) is given by K ¼ 0 0 0 5 Note that it is easy to verify that CB ¼ 00 0 0 0 0 3 0 0 0 00 4 0 05 ¼ 0 0 0 is nonsingular. Therefore, the control law of (0) is wellefine.
J.L. Chen, W.-D. Chang / Expert Systems with Applications 3 (009) 454 459 459 Accoring to Theorem, uner the controller that we have been esigne, output h of a two-link robot will track the esire output y. Figs. 5 an show the output responses an corresponing control laws. It can easily be observe that the reference signal y can be fully tracke.. Conclusions In this paper, we have emonstrate two basic esign steps for a two-link robot control. First, a moifie realcoe GA with a multiple-crossover is propose an uses it to estimate the unknown system parameters. These parameters are viewe as genes an evolve by three genetic operations of reprouction, multiple-crossover, an mutation operations, respectively. Secon, base on this resulte system moel, it is incorporate to the feeback linearization control such that the nonlinear robotic system can be transferre to a linear moel with a nonlinear boune time-varying uncertainty. Furthermore, in orer to overcome the uncertainty term, a sliing moe control is esigne an the stability of the close-loop system is guarantee by the use of the Lyapunov theorem. Finally, a simulation example of two-link robot is given to emonstrate the effectiveness of the propose metho. References Angelov, P. P., & Buswell, R. A. (003). Automatic generation of fuzzy rule-base moels from ata by genetic algorithms. Information Sciences, 50, 3. Blanco, A., Delgao, M., & Pegalajar, M. C. (00). A real-coe genetic algorithm for training recurrent neural networks. Neural Networks, 4, 93 05. Carvalho, D. R., & Freitas, A. A. (004). A hybri ecision tree/genetic algorithm metho for ata mining. Information Sciences, 3, 3 35. Davis, L. (99). Hanbook of genetic algorithms. New York Van Nostran. Deb, K., & Gulati, S. (00). Design of truss-structures for minimum weight using genetic algorithms. Finite Elements in Analysis an Design, 3, 44 45. Golberg, D. E. (989). Genetic algorithms in search. Optimization an machine learning. Reaing, MA Aison Wesley. Golla, D. F., Garg, S. C., & Hughes, P. C. (98). Linear state feeback control of manipulators. Mechanism an Machine Theory, 93 03. Huang, Y. P., & Huang, C. H. (99). Real-value genetic algorithm for fuzzy grey preiction system. Fuzzy Sets an Systems, 8, 5. Jiang, B., & Wang, B. W. (000). Parameter estimation of nonlinear system base on genetic algorithm. Control Theory an Applications,, 50 5. Kawaski, H., & Kato, N. (99). A review of experiments on aaptive control an compute torque control by a robot with nonlinear reuction ratio feature. Journal of Robotics an Mechatronics, 35 359. Khalil, H. K. (99). Nonlinear systems (n e.). New Jersey Prentice- Hall. Khatib, O., & Burick, J. (98). Motion an force control of robot manipulators. In Proceeings of IEEE international conference on robotics an automation (pp. 38 38). Kristinsson, K., & Dumont, G. A. (99). System ientification an control using genetic algorithms. IEEE Transactions on Systems, Man, an Cybernetics,, 033 04. Kuo, C. Y., & Wang, S. T. (989). Nonlinear robust inustrial robot control. ASME Journal of Dynamic Systems, Measurement, an Control, 4 30. Lu, H. C., & Tzeng, S. T. (000). Design of two-imensional FIR igital filters for sampling structure conversion by genetic algorithm approach. Signal Processing, 80, 445 458. Montiel Castillo, O., Melin, P., & Sepulvea, R. (003). The evolutionary learning rule for system ientification. Applie Soft Computing, 3, 343 35. Montiel Castillo, O., Sepulvea, R., & Melin, P. (004). Application of a breeer genetic algorithm for finite impulse filter optimization. Information Sciences,, 39 58. Muhlenbein, H. (994). The breeer genetic algorithm A provable optimal search algorithm an its application. In Proceeings of IEE colloquium on applications of genetic algorithms (pp. 5/ 5/3). Muhlenbein, H., & Mahnig, Th. (00). Evolutionary computation an Wright s equation. Theoretical Computer Science, 8, 45 5. Seraji, H. (98). An approach to multivariable control of manipulators. ASME Journal of Dynamic Systems, Measurement, an Control, 4 54. Slotine, J.-J. E., & Li, W. (99). Applie nonlinear control. New Jersey Prentice Hall. Spong, M. W., & Viyasagar, M. (989). Robot ynamics an control. New York Wiley. Tang, Y. C., & Xu, Y. (005). Application of fuzzy Naive Bayes an a real-value genetic algorithm in ientification of fuzzy moel. Information Sciences, 9, 05. Tsutsui, S., & Golberg, D. E. (00). Search space bounary extension metho in real-coe genetic algorithm. Information Sciences, 33, 9 4. Tzeng, S. T., & Lu, H. C. (000). Complex genetic algorithm approach for esigning equiripple complex FIR igital filters with weighting function. Signal Processing, 80, 9 04. Xu, D. J., & Daley, M. L. (995). Design of optimal filter using a parallel genetic algorithm. IEEE Transactions on Circuits an Systems-II Analog an Digital Signal Processing, 4, 3 5. Zamparelli, M. (99). Genetically traine cellular neural networks. Neural Networks, 0, 43 5.