a sliding mode control for robot manipulator
DESCRIPTION
Sliding mode control for 2-link robot manipulator.Simulation was performed using Matlab with Simulink and Simmechanics.This documents contain many images. In order to view them clearly, you may need to download it.TRANSCRIPT
A Sliding Mode Control for Robot Manipulator
Auralius Manurung
RIS-Lab
May, 2010
Introduction
• At certain condition, precise modeling is not possible.
• Unmodeled external forces, frictions, etc may effect the stability.
• Robust and adaptive control can deal with modeling inaccuracies and suitable for nonlinear systems.
• Sliding mode control is a simple approach for robust control technique.
SMC Derivation
• A system with dynamics f and we are giving control input u.
• Considering our system is a 2nd order system:
• For position and velocity control, we define sliding surface s as:
)(),()()( tutxftx n
xxxdt
ds ~~~
ufx
• Setting and substituting :
• Since our dynamic model f is just an approximation, approximated control law that would achieve can be expressed as:
0s
xxfu
xxuf
xxx
s
d
d
d
~
0~
0~
0
ufx
xxfu d ~ˆˆ
0s
• Graphical interpretation where system is pushed to slide in sliding surface with slope .
xx
0s
Slope =
Switching Action
• Introducing switching action that will maintain system work in sliding surface:
• Overall control law can be expressed as:
0,1
0,0
0,1
)(
)(
s
s
s
ssign
ssignKusw
)(~ˆˆ ssignKxxfuuu dsw
Low frequency Control
High frequency Control
• Chattering as a result of control switching
xx
0s
Slope =
Smoothing
• Smoothing out discontinuities by introducing boundary layer thickness:
1,1
1,0
0,1
)(
)(
s
s
s
ssat
ssatKusw
x
x
0s
Slope =
Boundary layer
φ
Simulation Example
• Two-link robot manipulator model:
• Lagrange-Euler dynamic model:
)(),()( GFM rr
• Dynamic equation:
M11 = (m1 + m2) * r1^2 + m2 * r2^2 + 2 * m2 * r1 * r2 * cos(θ2);
M12 = m2 * r2 ^2 + m2 * r1 * r2 * cos(θ2);
M22 = m2 * r2 ^2;
F12 = m2 * r1 * r2 * sin(θ2);
g1 = (m1 + m2) * r1 * cos(theta2) + m2 * r2 * cos(θ1 + θ2);
g2 = m2 * r2 * cos(θ1 + θ2);
2
1
2
1
2
1
112
2112212
2
1
2212
1211
0
)(
u
u
gG
gG
F
FF
MM
MM
Experiment 1: No Boundary Layer
• Input trajectory for each joint (i): θi(t) = -90+52.5(1-cos(1.26t)) • Initial condition: θ1(0) = -80 deg, θ2(0) = -70 deg • m1=0.5kg, m2 = 0.5kg • r1 = 1.0m, r2 = 0.8m • Ts = 1kHz, fixed-step, ode5 • Joint 1: K = 16, λ = 4, ø = 0; • Joint 2: K = 10, λ = 4, ø = 0;
0 0.5 1 1.5 2 2.5 3 3.5 4 4.5 5-0.18
-0.16
-0.14
-0.12
-0.1
-0.08
-0.06
-0.04
-0.02
0
0.02Tracking error of joint-1
Time (Seconds)
Tra
ckin
g e
rror
(rad)
0 0.5 1 1.5 2 2.5 3 3.5 4 4.5 5-0.35
-0.3
-0.25
-0.2
-0.15
-0.1
-0.05
0
0.05Tracking error of joint-2
Time (Seconds)
Tra
ckin
g e
rror
(rad)
0 0.5 1 1.5 2 2.5 3 3.5 4 4.5 5-30
-20
-10
0
10
20
30
40Torque at joint-1
Time (Seconds)
Torq
ue (
Nm
)
Chattering
0 0.5 1 1.5 2 2.5 3 3.5 4 4.5 5-15
-10
-5
0
5
10
15
20Torque at joint-2
Time (Seconds)
Torq
ue (
Nm
)
Switching
-0.18 -0.16 -0.14 -0.12 -0.1 -0.08 -0.06 -0.04 -0.02 0 0.02-0.1
0
0.1
0.2
0.3
0.4
0.5
0.6Phase potrait of joint-1
e(t)
d(e
(t))
/dt
Switching
-0.35 -0.3 -0.25 -0.2 -0.15 -0.1 -0.05 0 0.05-0.2
0
0.2
0.4
0.6
0.8
1
1.2Phase potrait of joint-2
e(t)
d(e
(t))
/dt
Switching
Experiment 2: Introducing Boundary Layer
• Joint 1: K = 16, λ = 4, ø = 0.01;
• Joint 2: K = 10, λ = 4, ø = 0.01;
High frequency switching at joint torque does no longer exist (see next figures).
0 0.5 1 1.5 2 2.5 3 3.5 4 4.5 5-25
-20
-15
-10
-5
0
5
10
15
20Torque at joint-1
Time (Seconds)
Torq
ue (
Nm
)
0 0.5 1 1.5 2 2.5 3 3.5 4 4.5 5-15
-10
-5
0
5
10Torque at joint-2
Time (Seconds)
Torq
ue (
Nm
)
-0.35 -0.3 -0.25 -0.2 -0.15 -0.1 -0.05 0 0.05-0.2
0
0.2
0.4
0.6
0.8
1
1.2Phase potrait of joint-2
e(t)
d(e
(t))
/dt
-0.35 -0.3 -0.25 -0.2 -0.15 -0.1 -0.05 0 0.05-0.2
0
0.2
0.4
0.6
0.8
1
1.2Phase potrait of joint-2
e(t)
d(e
(t))
/dt
Chattering reduced
Chattering reduced
Experiment III: Robustness Test
• Joint 1: K = 8, λ = 5, ø = 0.01;
• Joint 2: K = 8, λ = 5, ø = 0.01;
• m1=0.5kg, m2 = 1.0kg
• We added extra mass 0.5 kg to joint 2.
• Switching re-appears to maintain the trajectory in the sliding surface.
• It is possible to do tracking with more load by reducing the boundary layer to allow more switching to occur.
0 0.5 1 1.5 2 2.5 3 3.5 4 4.5 5-0.35
-0.3
-0.25
-0.2
-0.15
-0.1
-0.05
0
0.05Tracking error of joint-2
Time (Seconds)
Tra
ckin
g e
rror
(rad)
0 0.5 1 1.5 2 2.5 3 3.5 4 4.5 5-0.18
-0.16
-0.14
-0.12
-0.1
-0.08
-0.06
-0.04
-0.02
0
0.02Tracking error of joint-1
Time (Seconds)
Tra
ckin
g e
rror
(rad)
-0.18 -0.16 -0.14 -0.12 -0.1 -0.08 -0.06 -0.04 -0.02 0 0.02-0.1
0
0.1
0.2
0.3
0.4
0.5
0.6Phase potrait of joint-1
e(t)
d(e
(t))
/dt
-0.35 -0.3 -0.25 -0.2 -0.15 -0.1 -0.05 0 0.05-0.2
0
0.2
0.4
0.6
0.8
1
1.2Phase potrait of joint-2
e(t)
d(e
(t))
/dt
Conclusions
• Sliding mode control shows good performances for nonlinear system with parameter uncertainties and unmodeled disturbances.
• SMC is good control method for practical problems.
References
• C. Su, T. Leung, A Sliding Mode Control with Bound Estimation for Robot Manipulators, IEEE Trans. On. Robotics and Automation, vol. 9, pp. 208-213, 1993
• J.E. Slotline, W. Li, Appled Nonlinear Control, Prentice Hall
• S. Tokat, I. Eksin, M. Guzelkaya, M. T. Soylemez, Design of A Sliding Mode Controller with A Nonlinear Time-varying Sliding Surface, SAGE Trans. of The Institute Measurement and Control, vol. 25, pp. 145-162, 2003
• C. Edwards, S. Spurgeon, Sliding Mode Control Theory and Applications, Taylor & Francis
• You can download the Matlab file in: http://sites.google.com/site/auraliusproject/a-sliding-mode-control-for-robot-manipulator