Copyright @ IFAC Robot Control, Vienna, Austria, 2000
NEURAL NETWORKS IN THE CONTROL OF A MOBILE PLATFORM Viniicius Menezes de Oliveira' Edson Roberto de Pieri' Waiter Fetter Lages"
• Federal University of Santa Gatarina Gaixa Postal 476 88040-900 Florian6polis, SG - BRAZIL { vinicius, edson} fDlcmi. ufsc. br
•• Federal University of Rio Grande do Sui Electrical Engineering Department Av. Osvaldo Aranha, 103 90035-190 Porto Alegre, RS - BRAZIL w. fetterfDieee. org
Abstract: This paper presents a controller for a nonholonomic mobile robot developed by combining a kinematic controller and a computed torque controller . The computed torque controller is based on a neural network with on-line weight tuning, enabling and it to deal with unmodeled bounded disturbances and unmodeled dynamics . The overall stability is guaranteed by Lyapunov theory. Copyright ©2000 [FAG Keywords: Nonholonomic mobile robots, non linear systems, neural networks
1. INTRODUCTION
expresses that the relative velocity of the two points of contact is zero (Latombe, 1991).
Nowadays a large number of articles about control of nonholonomic systems can be found in the literature. One of the first papers is (Brockett, 1982) , where it is shown that a nonholonomic system cannot be stabilized in a posture by a smooth time-invariant state feedback . Remaining relevant papers are (Bloch et al. , 1992), which proposes an approach based on geometrical control, exploring control properties for nonholonomic systems that have no counterpart in holonomic systems and (Fierro and Lewis, 1998) that applies artificial intelligence techniques (neural networks) to control such systems.
Since this paper is dealing with non linear systems, a interesting approach that has been used in the control of such class of systems is the so called neural networks . The most important here is to point out that neural networks are a complex nonlinear mapping tool. Nevertheless, the analysis of stability and the verification of the internal status of the neural network , concerned with the correct approximation, is difficult to be done (Warwick, 1996), (Renders et al., 1995), (Moreno et al., 1996). This paper is organized as follows: The model of the mobile robot (see figure 1) is presented in section 2. Section 3 reviews some background about artificial neural networks. The block diagram of the control structure adopted is described in section 4. Finally, in section 5 the results obtained
Nonholonomic systems are systems whose kinematic restrictions are non-integrable. A nonholonomic equality constraint is often caused by a rolling contact between two rigid objects (the wheels and the ground in a car-like robot) . It
123
are shown and in section 6 some conclusions are given.
where M(q) E nnxn is the inertia matrix (symmetric and positive definite) , Vm(q , q) E nnxn is the centripetal and coriolis terms matrix, F(q) E nnxl is the friction terms, Td denotes bounded unknown disturbances including unstructured unmodeled dynamics. The matrix B(q) E nnx r is the input transformation matrix, T E nnx! is the input vector, A(q) E nmxn is a matrix related with the constraints and)" E nmx! is the vector of restriction forces . Considering the time-independence of all kinematic equality constraints one can write:
A(q)q
=0
(2)
Let S(q) be a full rank matrix (n - m) belonging to the null space of AT(q) , such that:
(3) Based on 2 and 3 its possible to find out v(t) E
'Rn-m, such that, for all t:
Fig. 1. The mobile robot.
q = S(q)v{t)
2. MOBILE ROBOT MODEL
(4)
The system 1 will be now transformed into a suitable representation to the control perspective. By Differentiating 4 and replacing the result in 1, then pre-multiplying by ST(q) and using 2 and 3 it is possible to eliminate the constraint matrix AT(q),., resulting in:
The mobile robot used in this work (see figure 2) is a circular platform with 4 wheels, with 2 of them mounted on the same axle with a DC motor attached to each one (Lages , 1998). This robot is a differential-driver robot. See (Campion et al. , 1996) for some insights on structural properties of this class of robot.
STMSi> + ST(MS
Yc
+ST F + ST Td
+ +VmS)v +
(5)
= STBT
Y
Which can be rewritten as:
(6)
c
-
Xc
where M(q) E nrxr is the inertia matrix (symmetric and positive definite), Vm(q , q) E nrxris the centripetal and coriolis terms matrix , F(v) E 'Rrx! is the friction terms, T d denotes bounded unknown disturbances including unstructured unmodeled dynamics . T is the input vector (B is a constant nonsingular matrix that depends on geometric parameter of the robot). The matrix M and the norm of the V m are bounded and the matrix 1\1: - 2Vm is skew-symmetric.
TnlCUon wheel
o ~------------------------------X
Fig. 2. Configuration of the wheels of the mobile robot. A mobile robot system having an n-dimensional configuration space C with generalized coordinates q [q! ... qnjT and with m constraints can be described as follows (Fierro and Lewis, 1998) , (Yamamoto and Yun , 1996) :
=
3. ARTIFICIAL ::'>IEURAL NETWORKS In this work a multi-layered perceptron feedforward neural network, as seen in figure 3, using an on-line algorithm of weight tuning is considered.
M(q)q+Vmq+F(q)+Td=B(q)T-AT),. (1)
124
where Y and Ware estimates of the ideal weights of the neural network. The weights are adjusted on-line by the following equations:
~W
= Fu(VTx)e~ -kF
~Y
1
= 1 + e-a
= W T u(VT x)
(7)
11 Y
In the literature, the problem is simplified by neglecting part of the dynamics of the system, considering only part of the dynamics , as described by 4. Thus, assuming that v Vc, 6 is used to calculate T. In practice, such considerations does not hold because the disturbance Td is not considered and a complete knowledge of the dynamics of the system is needed and it can be not so easy to obtain. Let vc(t) to be a solution to the steering system trajectory tracking , one can find T(t) that satisfies 4 and 6 (Fierro and Lewis, 1998). So, the tracking error expressed in the basis of the frame attached to the mobile platform is given by :
(8)
=
One of the most important features of a neural network is its capability to approximate multivariate non linear continuous function (Zbikowski and Dzielinski, 1995) . Considering this fact , let f(x) be a smooth function from Rn M R m , so its possible to show that, as long as x is restricted to a compact set Un E Rn, for some number N of hidden layer neurons, there is a neural network configuration (weights and thresholds) such that:
(13)
ep =T.(qr - q)
ell [e2 e3
= WT u(VT x) + {
(12)
ec
The control structure proposed is shown in figure 4. A trajectory tracking task is supposed. It is possible to observe that no previous knowledge of the dynamics of the robot, 6, is necessary since it is the role of the neural network to learn the dynamics on-the-fly.
where V E R 6x8 is the weight matrix between the input and the hidden layer ; W E R 8X2 is the weight matrix between the hidden layer and the output layer and x E R 6x I is the input vector of the neural network.
f(x)
11
4. THE CONTROL STRUCTURE
The output of the neural net is a vector y E R 2x I , expressed by:
y(x)
(11)
where the design parameters F and G are positive definite matrices and k > O.
This neural network has an input layer wit h 6 neurons, a hidden layer with 8 neurons and , the output layer has 2 neurons. The activation function is t he well-known sigmoid activation function:
u(a)
11e c 11 W
=Gx(u'(yT x)Wec)T -kG
Fig. 3. Neural network structure.
Fu'(VT x)yT xe~
= [cas(o) -sen(O) 0
sen(O) 0] cas(O) 0 0 1
xr - X] [ Yr - y (14) Or - 0
(9)
An auxiliary velocity control input that achieves tracking (Fierro and Lewis , 1998) for 4 is:
The equation 9 denotes that a neural network can approximate any continuous function in a compact set. The error in the neural net approximation is denoted by €. For any specified value to {N > 0, is possible to find { < {N. In the control perspective the meaningful concept is that , specifying {N, there exist some combination of weights such that the maximum desired approximation error can be obtained. Thus, an estimate of f(x) is given by:
vrcas(e3)
Vc
+ Kle!
= [Wr + K 2 vre2 + K 3vrsen(e3)
where K I , K2 and K3 reference velocities .
]
(15)
> 0; Vr and Wr are the
Now , since the desired velocity is supposed to be known , the auxiliary velocity tracking error is defined as:
(16)
(10)
125
Fig. 4. Block diagram of the controller. Thus, taking the time derivative of 16 one can rewrite the dynamics by using the velocity tracking error as:
5. RESULTS In this section the results obtained by a real-time simulation are presented. The controller gains are K [0.5 2.0 5.of and K4 0.5. The neural network sigmoidal activation function is used for the 8 hidden-layer neurons, F = 10- 3 1, G 5 * 10- 3 1 and k 10- 2 . The reference trajectoryisXr =0.2t+2; Yr=0.2t-1; ()r=~. The correspondent linear reference velocity is 0.2V2(m/ s) and the angular reference velocity is null, just as the initial velocity and acceleration .
=
with
f(x)
= Mvc + Vmvc + F(v)
=
(18)
Due to the absence of a complete knowledge of the parameters of 18, the neural network is introduced to perform this nonlinear mapping. The input vector of the neural net is given by:
x
= [vc
Vc v] T
=
=
In figure 5 the complete movement is presented. The initial position is Xo = 5.0m, Yo = -1.5m and () = 0 rad. One can see that the actual trajectory, converges to the reference trajectory and there is not oscillation in steady state.
( 19)
A suitable control input for velocity following is the computed-torque like control:
Figure 6 shows the torques developed by the motors . The range of the torque is within the limits of the real actuator, and those low level values indicate that the robot consumed few energy from batteries, allowing for an extended autonomy of the mobile robot.
(20) where K4 is a positive definite gain matrix and j(x) is an estimate of f(x) obtained from the neural network. The signal I is used to ensure robustness.
The errors in X and Y directions are shown in figure 7. One can observe in figure 8 the error in the orientation of the mobile system. All errors converge to zero and the system has a perfect trajectory tracking (figure 5).
Replacing 15 in 17 the closed-loop dynamic error is determined by :
6.
CO)lCLUSIO~
In this paper a neural networks is used in the control of a nonlinear systems, specifically a mobile robot, in order to cope with the incomplete knowledge of the dynamics and physical parameters (e. g. friction coefficient) of the system.
=
f - j. The overall system stability where j is guaranteed by Lyapunov theory (see Appendix A) and robustness aspects are presented in (Fierro and Lewis , 1998) .
126
J i
.,.
--~-----:---~--,---' ';.. t.
, ' -
Fig. 8. Error in orientation.
Fig. 5. Reference trajectory (solid) and actual trajectory (dashed).
An important point related to a real-time application is the fact that it is not possible to use a neural network with a large number of neurons in the hidden-layer because it must respect the time restrictions of the system. The results presented in this paper are from real-time simulations. The next step is validate the proposed controller under real problems such as error from the sensors , rolling, etc . Another interesting direction to be investigated is the application of others kinematic controllers. In particular , it is important to note that a parking maneuver is not possible with the kinematic controller used here . Current work is the direction of other types of kinematic controller (e. g. time-varying controller or a discontinuous controller) that could avoid the Brockett's theorem restrictions (Brockett , 1982) .
- , ,,", ,
: I)
Fig. 6. Torque on the right motor (solid) and on the left motor (dashed).
7. REFERENCES
"--"'--"---1
~~~ . ' .;
Fig . 7. Error in X (solid) and Y (dashed) directions.
127
Bloch , Anthony M., Mahmut Reyhanoglu and N . Harris McClamroch (1992). Control and stabilization of nonholonomic dynamic systems. IEEE Transactions on Automatic Control37(1l) , 1746-1757 . Brockett , R. W. (1982) . New directions In Applied Mathematics. Chap . Control Theory and Singular Riemannian geometry. Springer-Verlag. Campion, Guy, Georges Bastin and Brigitte D'Andrea-:\lovel (1996). Structural properties and classification of kinematic and dynamic models of wheeled mobile robots . IEEE Transactions on Robotics and AutomatIOn 12(1) , 47-62 . Fierro , R . and Frank L. Lewis (1998) . Control of nonholonomic mobile robot using neural networks . IEEE Transactions on Neural Netuorks 9(4),589-601. Lages, Waiter Fetter (1998) . Controle e Estimar;ao de Posir;ao e Orientar;iio de Robos M6veis . PhD thesis. Instituto Tecnol6gico de
Aeronautica, Sao Jose dos Campos - SP Brasil. Latombe, Jean Claude (1991). Robot Motion Planning. Kluwer Academic. Moreno , L., M. A. Salichs, D. Gachet , J . Pimentel, F . Arroyo and A. Gonzalo (1996). Neuml Networks for Robotic Control. Chap. Neural Networks for Mobile Robot Piloting Control. Ellis Horwood Limited . Renders, Jean-Michel , Marco Saerens and Hugues Bersini (1995) . Neuml Network Engineering in Dynamic Control Systems . Chap . Adaptive Neurocontrol of a Certain Class of MIMO Discrete-Time Processes Based on Stability Theory. Advances in Industrial Control. Springer-Verlag. Warwick, K. (1996). Neuml Networks for Robotic Control. Chap. An Overview of Neural Networks in Control Applications. Ellis Horwood Limited. Yamamoto, Yoshio and Xiaoping Yun (1996). Effect of the dynamic interaction on coordinated control of mobile manipulators. IEEE Tmnsactions on Robotics and Automation 12(5), 816-824 . Zbikowski , R . and A. Dzielinski (1995). Neural Network Engineering in Dynamic Control Systems. Chap. Neural Approximation : A Control Perspective. Advances in Industrial Control. Springer-Verlag .
tr{Z(Z - Z)}
V = -(k l ed 2 - 11 ec 11
-Cl 11
V~ -
c
11 -Co + ( 11
Z II-ZM) ](A.7)
11 ec 11 { K4 11 ec 11 +k 11
Z 11 ( 11 Z 11 -ZM)
Z 11 }
(A .8)
=
Thus,
(A .l)
11 e c 11 +k( 11
Z 11
-C3) 2 - Co - kCj
(A .9)
V is negative as long as 11 ec 11> kCj: Co
(A .IO)
J
(A.ll)
or 11 Z 11>
C3
+ Cl + ~o
which guarantees that 11 ec 11 and 11 Z 11 are locally uniformly bounded.
(A.2)
(A.3)
ec + ec (15 + 'Y) +
+k 11 ec 11 tr{Z(Z - Z)}
[Iy 11e
+
(1/2)[ZM + (CI/k)] and by Let define C3 completing square the term in braces results:
T
4
[k3vrsin(e3)] 2 +
Z 11 +k 11 Z 11
-Co - Cl 11
and differentiating A.2 , then by replacing 21 and using the skew-symmetry property gives:
=-ecT K
(A.6)
In the following , the negative terms of A.7 are neglected , resulting:
v = 2kl (elel + e2e2) +
.
-Co -
-ZM)
-(klel - e4) - (k3vrsin(e3) - es)2
Taking the time-derivative of A.l results:
\/1
11
Z 11 (11 Z 11 Cl 11 Z 11 ]
Taking the velocity tracking error, 16, expression A.6 and the derivative of the position error then by replacing all of them in A.3 leads to :
= ~ [e~Mec + tr{WTF-IW} +
+ VI
11 ec 11 [k 11
+K4 11 ec
where
+2k3Vre3Sin(e3)
~ -e~ ec-
VI
K4
+tr{yT G-Iy}]
W
then expression A.4 can be rewritten as:
In this appendix it is showed that 11 ec 11 and 11 Z IIF are locally uniformly bounded. Consider the following Lyapunov function candidate:
\/1
11 Z
~ 11 Z 1111 Z 11 - 11 Z 11 (A .5)
Appendix A
\/ = kl(ei + e~) + 2k3vr[1- cos(e3) ] + \/1
= < Z, Z > -
(A.4)
where 15 is the disturbance term expressed as : 15 = Wo-'VT X + W T O(VT x) + t + T d Now considering that
128