Upload
duongtuong
View
219
Download
0
Embed Size (px)
Citation preview
Journal of Mechanical Science and Technology 23 (2009) 1354~1364
www.springerlink.com/content/1738-494x DOI 10.1007/s12206-009-0350-3
Journal of
Mechanical Science and Technology
Variable structure fuzzy control using three input variables
for reducing motion tracking errors†
Chul-Goo Kang* Department of Mechanical Engineering, Konkuk University, Seoul, 143-701, Korea
(Manuscript Received February 21, 2007; Revised November 18, 2008; Accepted January 30, 2009)
--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Abstract Conventional fuzzy controllers for motion tracking utilize generally two input variables (position error and velocity
error) to deal with highly nonlinear and time-varying dynamics associated with complex mechanical motion with mul-ti-DOF. This results in some tracking errors at steady state, in general, mainly due to friction existing in mechanical systems. To eliminate the steady-state tracking errors, a variable structure fuzzy control algorithm is proposed using three input variables (position error, velocity error, and integral of position errors) and a switching logic between two inputs and three inputs. Simulation and experimental studies have been conducted to show the validity of the proposed control logic using a direct-drive SCARA manipulator with two degree-of-freedom. It has been shown that the pro-posed fuzzy control logic has significantly improved motion-tracking performance of the mechanical system when it is applied to complex polygon-tracking in Cartesian space with inverse kinematics and path planning.
Keywords: Cartesian space; Fuzzy control; Motion tracking; Steady-state error; Variable structure control
--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
1. Introduction
Since the dynamics of complex mechanical sys-
tems such as robotic manipulators is highly nonlinear
and time-varying, a fast and accurate motion control
is a challenging problem [1]. The control by way of
exact cancellation of all dynamic disturbances such as
varying inertia, Coriolis and centrifugal accelerations,
and gravitational and frictional disturbances, or the
control by way of dealing with all dynamic distur-
bances as uncertainties, could be very complex and
sometimes may not be computationally feasible for
fast operating mechanical systems. In this case, fuzzy
control is a good candidate since it does not depend
on the accurate model of the plant, but is based on
heuristics about plant behaviors. Recently, various
fuzzy control logics have been tried to be applied to
motion control of mechanical systems [2-4].
Fuzzy set theory was first introduced by L. A.
Zadeh [5] to deal with imprecise objects. He sug-
gested various possible application fields of fuzzy set
theory (by relying on the use of linguistic variables
and fuzzy algorithms) where the behaviors of systems
are too complex or too ill-defined to admit of precise
mathematical analysis [6]. Mamdani [7] first success-
fully applied fuzzy logic algorithms for the control of
a small laboratory steam engine. Thereafter, many
applications of fuzzy control were reported in the
various engineering fields including chemical proc-
esses and consumer products [8-10]. A good sum-
mary of the fuzzy logic controls is presented by Lee
[11]. Wang [12] viewed fuzzy control theory as a
subset of nonlinear control theory. He pointed out
better control performance of fuzzy controllers com-
pared to conventional PID controllers is due to the
nonlinear behavior of fuzzy controllers.
Motion control problems require faster and more
accurate response compared with other industrial
†This paper was recommended for publication in revised form by Associate
Editor Kyongsu Yi
*Corresponding author. Tel.: +82 2 447 2142, Fax.: +82 2 447 5886
E-mail address: [email protected]
© KSME & Springer 2009
C.-G. Kang / Journal of Mechanical Science and Technology 23 (2009) 1354~1364 1355
processes. The applications of fuzzy control algo-
rithms to motion control problems are reported exten-
sively in the literature. Among them, Li and Lau [13]
applied fuzzy control to servomotor systems and
showed that the performance of the fuzzy controller is
better than that of PI controllers in terms of steady
state error, settling time and response time through
simulation study using two look-up tables for coarse
and fine controls. Huang and Tomizuka [14] applied
the fuzzy controller to two-dimensional motion track-
ing control and showed tracking precision and travel
time can be improved compared with the system with
conventional PD controller by simulation study.
Scharf and Mandic [15] applied it to motion control
of an indirect drive robot manipulator and showed
that step response and tracking performance are often
superior to those of conventional PID controllers.
However, the effect of time-varying and nonlinear
dynamics in indirect drive is not so severe. Kang et
al.[16] applied fuzzy control to motion tracking con-
trol of direct drive robotic manipulators, and showed
that position tracking performance of fuzzy control is
similar to or often better than the one of PID control
through simulation and experimental studies.
Recently, Kohn-Rich et al.[2], and Ham et al.[3]
designed stable fuzzy controllers for a large class of
mechanical systems in the framework of Lyapunov’s
stability theory. Park et al.[4] proposed a sliding
mode control logic with fuzzy adaptive perturbation
compensator for parallel manipulators. Adams and
Rattan [17] adopted a multi-stage fuzzy PID control
scheme with fuzzy switching to reduce steady-state
errors. Adams and Rattan’s solution shows a nice way
to include fuzzy I action in the controller, in which
fuzzy PD control output is blended with fuzzy I ac-
tion before defuzzifying them when fuzzy PD input is
in the Zero fuzzy set. Sooraksa et al.[18] applied their
fuzzy P2ID scheme to handlebar control of a bicycle
robot.
In this paper, a variable structure fuzzy control
logic, a revised algorithm of Kang et al.’s one [16,19],
is proposed using three input variables of fuzzy con-
troller (position error, velocity error and integral of
position errors) and a switching logic between two
inputs and three inputs in order to eliminate position
errors existing at steady state in motion control, and it
is applied to motion control of a mechanical manipu-
lator.
The present paper has extended the result of the au-
thor’s previous publication [20] to motion control of
Cartesian space additionally using inverse kinematics
and Jacobian of the manipulator. The proposed con-
trol scheme is different from Adams and Rattan’s
solution [17] in the sense that two fuzzy control logics,
fuzzy PD and fuzzy PID control logic, are designed
separately (not multi-stage), and the switching be-
tween fuzzy PD and fuzzy PID control occurs accord-
ing to tracking condition, that is, transient or steady-
state condition. The idea of the proposed control
scheme is relatively simple but the improvement of
actual control performance is significant. This fact has
been shown through simulation and experimental
studies using a direct drive SCARA manipulator with
two degree-of-freedom (DOF) motion.
The paper is organized as follows. Section 2 pre-
sents basic terminologies and the structure of the pro-
posed fuzzy control scheme, and Section 3 describes
application of the proposed fuzzy control scheme to
motion tracking of a mechanical system. In Section 4,
computer simulation and experimental results of the
proposed fuzzy control are discussed, and concluding remarks are given in Section 5.
2. Variable structure fuzzy control
2.1 Definitions and terminology
A fuzzy set A in X is characterized by a membership
function ( )xm which associates with each point x in
X a real number in the interval [0, 1], with the value 0
representing non-membership and the value 1 repre-
senting full membership. The support of a fuzzy set A
is the crisp set of all points x in X such that ( ) 0xm > .
A fuzzy set whose support is a single point in X with
( )xm =1 is referred to as fuzzy singleton. Fuzzy set
operations and fuzzy logic can be defined in many
ways [21]. In the following, we summarize the defini-
tions and terminology used in this paper. The mem-
bership function ( )xm of the union A BÈ of two
fuzzy sets A and B is pointwise defined for all x in X
by ( )A B xm È = max{ ( ), ( )},A Bx x x Xm m Î , and the
membership function ( )xm of the intersection
A BÇ is defined for all x in X by ( )A B xm Ç =
min{ ( ), ( )},A Bx x x Xm m Î , which are originally
proposed by Zadeh [5]. Fuzzy implication adopted
in this paper is Larsen's product rule [12] among
many other choices, which is defined by ( , )A B x ym ®
( ) ( )A Bx ym m= , ,x X y YÎ Î . Fuzzy reasoning is
generally based on a compositional rule of inference
[6], which can be viewed as an extension of the mo-
dus ponens. The following sup-min composition pro-
1356 C.-G. Kang / Journal of Mechanical Science and Technology 23 (2009) 1354~1364
posed by Zadeh is used in this paper.
( )
( ) sup min{ ( ), ( ) ( )}B A A Bx X
B A A B
y x x ym m m m¢ ¢Î
¢ ¢= ®
=
o
A linguistic variable is a variable that can take
words in natural languages (for example, big, small
etc.) as its values. These words are usually labels of
fuzzy sets.
2.2 Proposed variable structure fuzzy controller
Position errors due to Coulomb friction, backlash
etc., generally remain at steady state in position con-
trol of mechanical systems such as robotic manipula-
tors. A conventional fuzzy PD controller using two
input variables (position error and velocity error) [16]
cannot remove such errors existing at steady state,
e.g., at a designation point of the end-effector of a
robotic manipulator.
From the idea that steady state errors can be gener-
ally reduced if we add an integral action to propor-
tional and derivative control, conventional fuzzy PD
controller with two input variables is revised to a
fuzzy controller with variable structure between fuzzy
PD control and fuzzy PID control logic with three
input variables – position error, velocity error, and
integral of position errors – and with a switching logic
to eliminate position errors existing at steady state in
motion control of mechanical systems. Since position
errors at steady state are usually small, we integrate
position errors only during steady state and use inte-
gral values as another input variable of the fuzzy con-
troller to remove small position errors effectively.
The proposed algorithm includes two types of
fuzzy control logic: fuzzy PD control and fuzzy PID
control logic. If motion tracking is in transient mode,
the fuzzy PD control logic is activated, and if it is in a
steady-state mode, the fuzzy PID control logic is acti-
vated. The switching between fuzzy PD control and
fuzzy PID control occurs in a crisp way in this paper
for simplicity, although the decision related to the
steady state detection could be made in a fuzzy way.
That is, if the change of position error during one
sampling period is below a threshold value and the
position error is below the preset maximum steady
state error, then the flag for error integral is turned on
and the fuzzy controller with two input variables is
switched to the one with three input variables.
If the change of position error during one sampling
period becomes again equal to or greater than the
threshold value, or the position error becomes equal
to or greater than the preset maximum steady state
error, then the flag for error integral is turned off and
the fuzzy controller with three input variables is re-
stored to the previous fuzzy controller with two input
variables.
Even though the stability of the fuzzy logic control
system is an important issue, we do not consider the
stability problem here and assume the overall system
is heuristically stable. For stability issues of fuzzy
control systems, refer to the reference papers [2, 3, 18,
22].
A block diagram of the proposed variable structure
fuzzy control system is shown in Fig. 1. The sampler
and zero-order hold (ZOH) are implemented by timer
interrupt and D/A converter (DAC). The position and
velocity signals are digital and the fuzzy control ac-
tion is implemented by using a microprocessor and
random access memory (for a look-up table).
The input variables of the fuzzy controller are an-
gular position error e (rad) and angular velocity error
e& (rad/s), and integral of angular position errors eò
(rad × s). The output variable of the fuzzy controller is
the control input u (N ×m) to the motor driver.
( )
,
( ) ( ( 1) ),
( , ) ( , , )
k
i j
e position command actual position
e kT e k Te
T
e e iT T
u f e e or u f e e e
=
= -
- -=
=
= =
åò
ò
&
& &
where T represents sampling time, and i, j and k are
positive integers such that k represents present time
index and j represents time index at which the steady
state condition is detected. In the fuzzy controller, the
measured e, e& and eò values are scaled to some
real values in the interval [-1, 1] and mapped to lin-
guistic variables E, DE and SE by the fuzzification
operator. The values of linguistic variables are com-
posed of linguistic terms PL, PS, ZO, NS and NL, or
-ZOH Plant
uActual
position
+
dt
d
e
e
Switching
Fuzzy
controller
Positioncommand
òò
e
•
• •
Fig. 1. Block diagram of the proposed fuzzy control system.
C.-G. Kang / Journal of Mechanical Science and Technology 23 (2009) 1354~1364 1357
ZONS PSNL PL
-1.0 0 1.0-0.5 0.5
m
(a)
Z PN
-1.0 0.0 1.0-0.5 0.5
0.5
1.0
(b) Fig. 2. Membership functions of fuzzy sets for (a) position error, velocity error, control input, and (b) integral of position errors.
N, Z and P that are all fuzzy sets.
This linguistic term set forms a fuzzy partition of
input and output spaces. The knowledge base of the
fuzzy controller is composed of a database and a rule
base. The database defines membership functions for
the above linguistic terms, and the rule base repre-
sents fuzzy control rules. Instead of quantizing the
universe of discourse of input and output spaces into a
finite number of segments (quantization levels), we
do a linear scale mapping of position error, velocity
error, integral of position errors and control input with
a value in [-1, 1], and so keep infinite resolutions in
the fuzzification and defuzzification operations (that
is, we do not lose some information from the given
data at these stages).
Membership functions of fuzzy sets (linguistic
terms) and fuzzy control rules have a considerable
effect on control performance. Fig. 2 shows the
membership functions of the fuzzy sets for position
error e, velocity error e& , control input u, and integral
of position errors eò .
We use membership functions with the same trian-
gular shapes and same support sizes, such as Fig. 2.
However, we also can use membership functions with
the same triangular shapes but different support sizes.
With membership functions with different support
sizes, we can emphasize that the control near zero is
more important than that of the other portions.
A fuzzy control rule is a fuzzy conditional statement
(IF-THEN statement) in which the antecedents and
the consequent are associated with fuzzy concepts
(linguistic terms). One example of a fuzzy control
rule is as follows: R1: If E is ZO and DE is ZO and SE is N, then U is NS.
R2: If E is PS and DE is NS and SE is Z, then U is ZO.
m
1
0 0.5DE
m
1
0-1SE
m
1
0-1DE
m
1
0 1
m
1
0 1E
m
1
0 0.5E
m
1
0U
-1
SE-0.25-0.250.3
m
1
0 0.5U
m
1
0 0.5U
-1
0.25
0.5
R1
R2
Fig. 3. Graphical representation of the inference mechanism.
These rules are implemented by fuzzy relation R1 =
{(ZO and ZO and N) ® NS} and R2 = {(PS and NS
and Z) ® ZO} where 'and' and '® ' are processed
by min operation (intersection) and Larsen's product
rule, respectively.
Fuzzy reasoning (or approximate reasoning) is
done by the sup-min composition operator. As an
illustration, consider the above two fuzzy control
rules R1 and R2. Let the inputs be fuzzy singletons,
namely, E’ = 0.3, DE’ = -0.25 and SE’ = -0.25. Then
the inference mechanism adopted here can be repre-
sented graphically as shown in Fig. 3.
Defuzzification is a mapping from fuzzy control ac-
tions into nonfuzzy (crisp) control actions. Among
many defuzzification strategies, we adopt the center
average method [12].
The calculation time consumed for fuzzy inference
and fuzzification is usually considerable (e.g., a few
milliseconds). To save the calculation time in real-
time control, we calculate U for the standard E, DE
and SE values in advance, and form a three-
dimensional look-up table. Since the number of input
variables could be two or three according to tracking
situations (transient or steady state), we need two-
dimensional and three dimensional look-up tables
together. Roughly speaking, a two-dimensional look-
up table is necessary for transient condition, and a
three-dimensional look-up table is for steady state
condition. These two look-up tables are used alter-
nately as time passes.
3. Implementation of the proposed control scheme to motion tracking
The mechanical system with two DOF motion con-
sidered in this paper is shown in Fig. 4. This system is
actually a two axes SCARA manipulator moving in a
horizontal plane. The control system has two inputs
and four outputs. Two inputs are two motor-driving
signals, and four outputs are two position signals and
two velocity signals of two motors coming from re-
solvers. Furthermore, this mechanical system has
highly nonlinear and time-varying dynamics including
1358 C.-G. Kang / Journal of Mechanical Science and Technology 23 (2009) 1354~1364
Fig. 4. Photograph of the 2 DOF mechanical system used in
simulation and experimental studies.
Coriolis acceleration and coupling effects between
axes. This manipulator is driven by two direct drive
motors (Megatorque motors). This system was de-
signed and integrated in our laboratory. The range of
input voltages to driver units is -10 volts to 10 volts.
Torque generated by the Megatorque motor is pro-
portional to input voltage. Maximum torques of the
base motor and the upper motor are 147 N�m and 9.8
N�m, respectively. The resolver is attached to each
Megatorque motor to measure angular position and
velocity. Resolver signals are converted to phase A
and B quadrature signals by RDC (Resolver to Digital
Converter) in the Driver Unit, and these quadrature
signals are counted by each counter board. The reso-
lutions of feedback signals of the base motor and the
upper motor are 38,400 counts/rev and 25,600
counts/rev, respectively. Maximum speeds of the base
motor and the upper motor are 3 rev/sec and 4.5
rev/sec, respectively.
A dynamic model of the robot is not necessary for
designing a fuzzy controller, but we develop one for
simulation purpose. The dynamics of an n-DOF, rigid
link, direct drive manipulator can be generally de-
scribed as follows [23, 24]:
( ( )) ( ) ( ( ), ( )) ( ( )) ( ( ), ( ))
( )
t t t t t t t
t
q w q w q w t
t
+ + +
=
M v g f&
where q is an angular position vector of joints, w
is an angular velocity vector of joints, t is an input
torque vector supplied by actuators, M is a symmet-
ric and positive definite generalized inertia matrix, v
is a vector due to Coriolis and centrifugal forces, f is
viscous and Coulomb friction torque vector, and g
is a gravitational torque vector. For the two-axes di-
rect-drive manipulator considered in this paper, each
term in the above equation is given as follows:
Table 1. Scale mapping of the position error, velocity error,
integral of position errors and control input.
Scaled
values 1e
rad
2e
rad
1eò
rad�s
2eò
rad�s
1 2,e e& &
rad/s
1u
N�m
2u
N�m
-1.0 -0.30 -0.10 -3.0e-4 -8.0e-4 -4.0 -145 -9.8
-0.5 -0.15 -0.05 -1.5e-4 -4.0e-4 -2.0 -72.5 -4.9
0 0 0 0 0 0 0 0
0.5 0.15 0.05 1.5e-4 4.0e-4 2.0 72.5 4.9
1.0 0.30 0.10 3.0e-4 8.0e-4 4.0 145 9.8
1 11
2 2 2
( ) ( )( )( ) , ( ) , ( )
( ) ( ) ( )
t ttt t t
t t t
w tqq w t
q w t
é ù é ùé ù= = =ê ú ê úê úë û ë û ë û
11 3 1 211 12
12 2 1 212 22
22 2
2 cos
( ) , cos
m p pm m
m p pm m
m p
q
q q
= +é ù
= = +ê úë û =
M
2 1 2 1 2
21 1 2
(2 ) sin( , )
sin
p
p
w w w qq w
w q
- +é ù= ê úê úë û
v
1 1
2 2
0.24( , ) ,
0.035
sign if 0
sign if 0 and
if 0 and
i i i
i i i i i i
i i i i
f
f
T
f T T
T
ww t
w
w w
t w t
t w t
´ +é ù= ê ú
´ +ë û
ì >ï
= = >íï = £î
f
1 23.2 , 0.17T N m T N m= × = ×
( ) 0q =g
where
1
2
3
2
0.123 0.08
0.138 0.0625
1.676 0.165
0 3.76
0 0.012
p
p p
p p
p
p
p M
p M I
p M I
M or kg
I or kg m
= +
= + +
= + +
=
= ×
pM is the mass of payload and pI is the mo-
ment of inertia of payload. All the values above are
represented in SI units.
For this mechanical system, the fuzzy controller
proposed in the previous section is applied. First we
define a linear scale mapping for position error, ve-
locity error, integral of position errors and control
input by values in [-1, 1]. Table 1 shows a summary
of the linear scale mapping where subscripts 1 and 2
represent the base motor and the upper motor, respec-
tively.
C.-G. Kang / Journal of Mechanical Science and Technology 23 (2009) 1354~1364 1359
In the table, the maximum value of the control in-
put is the same with the maximum torque that Mega-
torque motor can generate. These maximum values
are the values that we allow at the corresponding
variables. In some sense, these values act like the
inverses of the proportional and derivative gain in PD
control. However, the difference of the fuzzy control-
ler and PD controller is that the fuzzy controller acts
in a nonlinear fashion.
The whole fuzzy control rules of the fuzzy control-
ler for this mechanical system are shown in Table 2.
Linguistic terms in Table 2 are defined in Fig. 2.
In Table 2, the integral term (SE) is activated (i.e.,
summed) only when the steady state condition is de-
tected from the way proposed in Section 2.2 in which
the flag for error integral is used. At the steady state
condition, position error (E) and velocity error (DE)
are both ZO. In this way, the number of fuzzy control
rules is just increased from 25 to 27 even if the num-
ber of input variables is increased from 2 to 3.
After fuzzy inference and defuzzification processes
presented in the previous section, the actual control
input u is obtained by multiplying the scaling factor
145 (for base motor) or 9.8 (for upper motor). Ac-
cording to control input u, actual torque t is gener-
ated by the motor.
For the present mechanical system, one three-
dimensional look-up table instead of two look-up
tables can be generated and used from the given fuzzy
control rules in Table 2. In view of the required
memory size and accuracy of the fuzzy inference,
21x21 U values in the look-up table are generated for
SE = 0, and 11x11x21 U values are generated for the
other SE values. For SE = 0, the values of E and DE
are divided into interval of 0.1 from –1 to 1. For the
other SE values, the values of E and DE are divided
into the same interval from -0.5 to 0.5, and SE into
the same interval from –1 to 1.
In this way, we save the required memory size up
to 70 % compared to the memory size required for
three-dimensional look-up table (21x21x21) with
intervals of 0.1 for three input variables. The 21x21
table for SE = 0 can be considered as the two-
dimensional look-up table that is necessary for a tran-
sient condition of motion tracking. For a specific po-
sition error, velocity error and integral of position
errors, control input is calculated through a linear
interpolation by using look-up tables as shown in Fig.
5. For specific input values, the interpolated fuzzy
controller output U is given as follows (using the
Table 2. Fuzzy control rules for position control of the robotic
manipulator.
If input variables are E and DE (transient condition), or if in-
put variables are E, DE and SE with SE=Z (steady-state condi-
tion), then U are
\E DE NL NS ZO PS PL
NL NL NL NL NS ZO
NS NL NL NS ZO PS
ZO NL NS ZO PS PL
PS NS ZO PS PL PL
PL ZO PS PL PL PL
If E = ZO, DE = ZO and SE = P (steady-state condition),
then U = PS.
If E = ZO, DE = ZO and SE = N (steady-state condition),
then U = NS.
Fig. 5. Interpolation in the three dimensional lookup table.
notations in Fig. 5):
1 2
3 4 5
6 7 8
1 1 1 1 1
1 1 1
1 1 1 1
x y z x y zU U U
x y z x y z
x y z x y z x y zU U U
x yz x y z xyz
x y z x y z x z yU U U
x y z xy z xz y
æ ö æ öD D D D D Dæ ö æ ö æ ö= - - - + - -ç ÷ ç ÷ç ÷ ç ÷ ç ÷è ø è ø è øè ø è ø
D D D D D D D D Dæ ö æ ö æ ö+ - + - - +ç ÷ ç ÷ ç ÷è ø è ø è ø
æ ö æ öD D D D D D D D Dæ ö æ ö+ - - + - + -ç ÷ ç ÷ç ÷ ç ÷
è ø è øè ø è ø
As the tracking condition (transient or steady-state)
of the manipulator is changed, the proposed control
scheme switches the fuzzy PD control logic to the
fuzzy PID control logic and vice versa according to
the switching logic explained in the previous section.
4. Simulation and experimental results
For the 2 DOF mechanical system described in the
previous section, digital simulation and experimental
studies have been conducted to show that the pro-
posed variable structure fuzzy controller reduces
1360 C.-G. Kang / Journal of Mechanical Science and Technology 23 (2009) 1354~1364
steady-state position errors significantly compared to
conventional fuzzy controllers. One simple chosen
task is to drive each axis of the manipulator inde-
pendently in joint space without considering total
end-effector motion, which was shown in the author’s
previous Korean publication [20]. Here the results are
summarized briefly again for comparison purposes.
For this task, the desired trajectory for both axes is
given by the seventh-order polynomial as shown in
Fig. 6. That is, the task is to drive both motors at the
same time with the trajectory given in Fig. 6. The
overlapped curve with the desired trajectory in Fig. 6
is an experimental result for the upper axis when the
proposed fuzzy control is applied for this task.
Since the distinction between the desired trajectory
and the actual trajectory is difficult in Fig. 6, we plot
position errors in a magnified scale to evaluate con-
trol performance clearly. Fig. 7 (a) shows the simula-
tion result, and Fig. 7 (b) shows the experimental
result for position error of the base axis when the
proposed fuzzy controller (denoted by “Proposed
Fuzzy” in the figures) and the conventional fuzzy
controller (denoted by “Old Fuzzy”) are applied with
3.76 kg payload. Here the conventional fuzzy control-
ler implies the fuzzy controller with two input vari-
ables. From Fig. 7 (a) and Fig. 7 (b), we see that the
proposed fuzzy control reduces position errors more
than 80 % (in magnitude) at steady state compared to
those of the conventional fuzzy control, and has simi-
lar position tracking errors to those of the conven-
tional fuzzy control at transient response intervals.
The simulation and experimental results for the
steady state position errors are summarized in Table 3.
Fig. 6. Desired and actual position trajectories of the upper motor when the proposed fuzzy control is applied without pay-
load (experiment).
Table 3. Simulation and experiment results for the steady state
position errors.
Convent.
fuzzy (A)
Proposed
fuzzy (B) B/A
Simul. Base axis
(no payload) -2.5e-3 rad 0.5e-4 rad 2 %
Upper axis
(no payload) -2.0e-3 rad 1.6e-4 rad 8 %
Base axis
(3.76 kg ) 5.4e-3 rad -1.1e-4 rad 2 %
Upper axis
(3.76 kg ) 0.3e-3 rad 0.3e-4 rad 10 %
Exper. Base axis
(no payload) -9.8e-3 rad 6.8e-4 rad 7 %
Upper axis
(no payload) 2.0e-3 rad 3.0e-4 rad 15 %
Base axis (3.76 kg )
-10.8e-3 rad 1.1e-4 rad 1 %
Upper axis
(3.76 kg ) 1.2e-3 rad 2.0e-4 rad 17 %
(a)
(b) Fig. 7. Position tracking errors of the base axis when the pro-
posed and the conventional fuzzy control are applied with 3.76
kg payload. (a) simulation, (b) experiment.
C.-G. Kang / Journal of Mechanical Science and Technology 23 (2009) 1354~1364 1361
However, the motion of the manipulator should be
controlled in Cartesian space in order to be applied to
actual factory operations. Thus, the previous results
are extended to a complex task to drive the manipula-
tor in Cartesian space using inverse kinematics and
path planning. The selected Cartesian space task is to
draw various polygons on the table with the manipu-
lator.
In the simulation, the controller is realized in a dis-
crete time domain, but the manipulator is realized as a
continuous time model (using a 4th-order Runge-
Kutta algorithm). Sampling time T is set to 5 ms in
the simulation and experiment. In the experiment,
elapsed time for executing the interrupt service rou-
tine within one sampling interval was measured to be
about 0.3 ms. To keep sampling intervals exact in the
experiments, we used timer interrupts. Programming
for simulations and experiments was coded with C
language.
To realize tracking control in Cartesian space, we
have to solve the inverse kinematics problem on-line.
The solution of the inverse kinematics problem and
manipulator Jacobian are obtained as closed-forms for
this SCARA manipulator as follows:
2 2 2 2 2 2 21 2 1 21
2 2 2 2 21 2 1 2
1 1 2 21
1 2 2
1 1 2 1 2 2 1 2
1 1 2 1 2 2 1 2
1 ( ) /(4 )tan
( ) /(2 )
sintan tan
cos
sin sin( ), sin( )
cos cos( ), cos( )
x y a a a a
x y a a a a
y a
x a a
a a aJ
a a a
q
q
q q q q q
q q q q q
-
- -
æ ö- + - -ç ÷=ç ÷+ - -è ø
æ öæ ö= - ç ÷ç ÷
+è ø è ø
- - + - +é ù= ê ú+ + +ë û
where x, y are Cartesian coordinates, 1 2,q q are joint
coordinates, 1 2,a a are link lengths, and J is the ma-
nipulator Jacobian.
We have selected polygons (square, triangle and
hexagon) in Fig. 10 in order to see improvement of
tracking performance of the proposed fuzzy controller.
The Cartesian coordinate at every sampling instant is
generated via path planning. Velocity command pro-
files of each side of the polygons are programmed to
be an LSPB (linear segments with parabolic blends)
type as shown in Fig. 8. Specifically, during 1/6 in-
terval of one side of the polygons, motion is con-
stantly accelerated, and during the next 2/3 interval of
the side, motion has constant maximum velocity, and
then during the last 1/6 interval of the side, motion is
constantly decelerated. In other words, the velocity
Fig. 8. Velocity command profile of each side of the polygons;
LSPB type between two points A and B in space. profile forms a trapezoidal shape in Cartesian space,
not in time domain.
Fig. 9 shows the whole block diagram of the con-
trol system in Cartesian space. In the figure, dx
represents the desired position vector in Cartesian
coordinate, and dθ does the desired position vector
in joint space.
Fig. 10 shows results of simulations and experi-
ments for motion tracking of square, triangle and
hexagon when the proposed variable structure fuzzy
control is applied. Tracking control performance is
evaluated by using integral of squared error (ISE) that
is defined as summation of the squared value of posi-
tion error between desired position and actual position
in Cartesian space at every sampling instant. The unit
of ISE in Fig. 10 is 2mm s× .
Fig. 10(a) is an experimental result for square path
tracking with maximum velocity 200 mm/s in the
LSPB, and Fig. 10(b) is an experimental result when
maximum velocity is doubled to be 400 mm/s. In this
case, maximum angular speeds of the motors are
within 20 % of the maximum angular speeds that can
be generated by the motors. From a comparison of (a)
and (b), we see that the ISE value is increased as
tracking speed is increased. Fig. 10(c) is the simula-
tion result at the same operating condition with (b).
Fig. 10(b) and (c) show similar tracking patterns. Fig.
10(d) is the magnified experimental result at the cor-
ner of the square of (a). Fig. 10(d) shows significant
improvement of the proposed fuzzy controller for
corner tracking compared to the conventional fuzzy
controller with two input variables.
Fig. 10(e) and (f) are experimental results to show a
comparison of control performance of the proposed
fuzzy control and classical PID control. We tuned
PID control gains roughly via Ziegler-Nichols tuning-
rules and then finely tuned. However, PID control
gains may possibly be more tuned to have less ISE
value, but it takes time and is a tedious job.
Fig. 10(g) is an experimental result when impact
force is exerted on the side of the upper link during
1362 C.-G. Kang / Journal of Mechanical Science and Technology 23 (2009) 1354~1364
operation, in order to see the response for external
disturbance. We hit the link with a thick book. The
experimental result (g) shows that the stability of the
system with the proposed fuzzy control logic is main-
tained for external disturbances with relatively big
magnitudes. This robust stability comes, we believe,
from the fact that designing the proposed fuzzy con-
troller does not depend on precise knowledge of ac-
tual dynamics and uncertainties of the system.
5. Conclusions
When a conventional fuzzy PD controller with two
input variables (position error and velocity error) is
applied to motion tracking control of mechanical
systems with complex dynamics and nonlinearities,
position errors usually remain at steady state mainly
due to friction. To reduce these errors, we have pro-
posed a revised fuzzy controller with variable struc-
ture between fuzzy PD control and fuzzy PID control
and with a switching logic between two fuzzy con-
trollers according to tracking conditions (transient or
steady state), and applied it to motion control of a
mechanical system in Cartesian space.
When the proposed variable structure fuzzy control
is applied to two DOF mechanical systems with com-
plex dynamics and nonlinearities as shown in Fig. 4,
the position errors at steady state have been decreased
more than 80 % (in magnitude) compared to ones of
the conventional fuzzy control. Moreover, the pro-
posed fuzzy control logic has improved tracking con-
trol performance significantly, especially, at corner
trackings of polygons in Cartesian space.
With the proposed implementation method of the
Fig. 9. The whole block diagram of the control system in Cartesian space.
Proposed fuzzy control
conventional
fuzzy control
(a) ISE=56 (b) ISE=77 (c) ISE=42 (d)
(e) ISE =62 (f) ISE=418 (g) Fig. 10. Position tracking for polygon paths. (a) experiment with maximum velocity = 200 mm/s, (b) experiment with maximum veloc-
ity = 400 mm/s, (c) simulation with maximum velocity = 400 mm/s, (d) comparison of the conventional fuzzy control and the proposed fuzzy control, (e) experiment with the proposed fuzzy controller, (f) experiment with PID controller, (g) experiment with impact dis-
turbances.