Index
Index
A THESIS SUBMITTED TO
THE GRADUATE SCHOOL OF NATURAL AND APPLIED SCIENCES
OF
MIDDLE EAST TECHNICAL UNIVERSITY
BY
ERHAN POYRAZOĞLU
JANUARY 2017
Approval of the thesis:
Date:
I hereby declare that all information in this document has been obtained and
presented in accordance with academic rules and ethical conduct. I also declare
that, as required by these rules and conduct, I have fully cited and referenced all
material and results that are not original to this work.
Signature :
iv
ABSTRACT
Poyrazoğlu, Erhan
M.S., Department of Electrical and Electronics Engineering
Supervisor : Prof. Dr. Kemal Leblebicioğlu
Gimbal systems are used in various engineering applications such as military sys-
tems. Their configurations are designed according to the types of application and
desired performance requirements. The essential aim of these systems is to compen-
sate the disturbance effects in order to stabilize LOS and positioning to the desired
point.
In this thesis, first, a detailed mathematical model of a 2-DOF gimbal system con-
taining some nonlinear dynamic effects such as friction, static and dynamic mass
unbalance is obtained by Newton-Euler approach. Next, three different controllers
that are cascade proportional-integral (PI), global and local linear quadratic integral
(LQI) have been constructed. The mathematical model and the controllers have been
implemented in MATLAB and their performances have been investigated.
In the final part of this study, in order to visualize and track a target in simulation,
a 3-D virtual environment is constructed within MATLAB/Simulink 3-D Toolbox
v
and a simple target tracking algorithm is designed to detect and track targets. All of
these operations are simulated on MATLAB/Simulink environment.
vi
ÖZ
Poyrazoğlu, Erhan
Yüksek Lisans, Elektrik ve Elektronik Mühendisliği Bölümü
Tez Yöneticisi : Prof. Dr. Kemal Leblebicioğlu
Bu tezde ilk olarak sürtünme, statik ve dinamik kütle dengesizliği gibi doğrusal ol-
mayan dinamikler içeren iki eksen bir gimbal sisteminin detaylı matematiksel modeli
Newton-Euler yaklaşımı ile elde edilmiştir. Ardından üç farklı kontrol yöntemi ku-
rulmuştur. matematiksel model ve kontrolörler MATLAB’da uygulanmış ve perfor-
mansları incelenmiştir.
Son olarak benzetim ortamını görselleştirmek ve hedef takibi yapabilmek için MAT-
vii
LAB/Simulink 3-D Toolbox ile üç boyutlu sanal bir ortam kurulmuş ve basit bir hedef
takip algoritması tasarlanmıştır. Tüm benzetim çalışmaları MATLAB/Simulink orta-
mında yapılmıştır.
viii
To my family
ix
ACKNOWLEDGMENTS
I would like to thank my supervisor Professor Kemal Leblebicioğlu for his guidance
and friendship. It was a great honor to work with him and our cooperation influenced
my academical view highly.
My family also provided invaluable support for this work. I would like to thank es-
pecially to my mother Nezihe Poyrazoğlu and my brother Furkan Poyrazoğlu. They
always make me feel loved and cared.
I would like to thank Mehmet Sami Büyüksarıkulak, Irmak Ece Şener, Kamil Alper
Yalçınkaya and Elif Yavuztürk who supported this work and their contributions were
most valuable. Furthermore I would like to thank my dear friends for their fellowships
and endless supports; Selin Akboğa, Ahmet Furkan Oruç, Onur Aydın, Oğuz Kır-
bıyık, Murat Karabıyık, Deniz Genlik, Dilara Uğurlu, Merve Tiftik, Neslihan Küçük,
Ozan Can Sarıoğlu and Hayrettin Karadağ.
x
TABLE OF CONTENTS
ABSTRACT . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . v
ÖZ . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . vii
ACKNOWLEDGMENTS . . . . . . . . . . . . . . . . . . . . . . . . . . . . . x
TABLE OF CONTENTS . . . . . . . . . . . . . . . . . . . . . . . . . . . . . xi
LIST OF TABLES . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . xv
CHAPTERS
1 INTRODUCTION . . . . . . . . . . . . . . . . . . . . . . . . . . . 1
1.1 Background . . . . . . . . . . . . . . . . . . . . . . . . . . 1
xi
2.2.2 Angular Acceleration . . . . . . . . . . . . . . . . 13
2.8.3 Linearization . . . . . . . . . . . . . . . . . . . . 45
3 CONTROLLER DESIGN . . . . . . . . . . . . . . . . . . . . . . . 55
xii
3.2 Linear Quadratic Integral (LQI) Control . . . . . . . . . . . 62
3.3.3 Conclusion . . . . . . . . . . . . . . . . . . . . . 82
5.1 Summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . 95
REFERENCES . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 99
APPENDICES
xiii
B SIMULINK BLOCKS . . . . . . . . . . . . . . . . . . . . . . . . . 109
xiv
LIST OF TABLES
TABLES
Table 2.1 Parameters of Dahl friction model effect on inner and outer gimbals 17
Table 2.2 Parameters of LuGre friction model effect on inner and outer gimbals 18
Table 2.3 Parameters of the motor models for the inner and outer gimbals . . . 21
Table 2.5 Boundaries of the state variables of the coupled 2-DOF gimbal . . . 34
Table 2.6 Boundaries of the disturbance, sensor noise and control input vari-
ables of the coupled 2-DOF gimbal . . . . . . . . . . . . . . . . . . . . . 35
Table 3.1 Performances of the rate PI controllers of the inner gimbal for dif-
ferent Kp values (Ki = 50) . . . . . . . . . . . . . . . . . . . . . . . . . . 57
Table 3.2 Performances of the rate PI controller of the inner gimbal for differ-
ent Ki values (Kp = 750) . . . . . . . . . . . . . . . . . . . . . . . . . . 58
Table 3.3 Performances of the position PI controller of the inner gimbal for
different Kp values (Ki = 0.1) . . . . . . . . . . . . . . . . . . . . . . . . 58
Table 3.4 Performances of the position PI controller of the inner gimbal for
different Ki values (Kp = 8) . . . . . . . . . . . . . . . . . . . . . . . . . 58
Table 3.5 Position performances of the inner gimbal with cascade PI control
for different position commands . . . . . . . . . . . . . . . . . . . . . . . 59
xv
Table 3.6 Performances of the rate PI controller of the outer gimbal for differ-
ent Kp values (Ki = 150) . . . . . . . . . . . . . . . . . . . . . . . . . . 60
Table 3.7 Performances of the rate PI controller of the outer gimbal for differ-
ent Ki values (Kp = 300) . . . . . . . . . . . . . . . . . . . . . . . . . . 60
Table 3.8 Performances of the position PI controller of the outer gimbal for
different Kp values (Ki = 0.05) . . . . . . . . . . . . . . . . . . . . . . . 60
Table 3.9 Performances of the position PI controller of the outer gimbal for
different Ki values (Kp = 5) . . . . . . . . . . . . . . . . . . . . . . . . . 60
Table 3.10 Position performances of the outer gimbal with cascade PI control
for different position commands . . . . . . . . . . . . . . . . . . . . . . . 61
Table 3.11 Position performances of the gimbals with global LQI control for
different position commands . . . . . . . . . . . . . . . . . . . . . . . . . 70
Table 3.12 Position performances of the coupled nonlinear inner gimbal with
local LQI control for different position commands . . . . . . . . . . . . . 73
Table 3.13 Position performances of the coupled nonlinear outer gimbal with
local LQI control for different position commands . . . . . . . . . . . . . 75
Table 3.14 Performance comparison of global and local LQI control with re-
spect to ISE, IAE and ITAE measures . . . . . . . . . . . . . . . . . . . . 79
Table 3.15 Performance comparison of global LQI and cascade PI control with
respect to ISE, IAE and ITAE measures . . . . . . . . . . . . . . . . . . . 81
xvi
LIST OF FIGURES
FIGURES
Figure 2.4 Combination of Coulomb, viscous, static friction and Stribeck ef-
fect [2] . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 16
Figure 2.7 Chirp responses of the Dahl and LuGre friction models . . . . . . . 19
xvii
Figure 2.15 Elements of 3rd row of SG matrix . . . . . . . . . . . . . . . . . . 40
Figure 2.18 Clustering evaluation for decoupled inner gimbal equilibrium points 49
Figure 2.19 Clustering evaluation for decoupled outer gimbal equilibrium points 49
Figure 3.2 System responses and motor torque of the inner gimbal with cas-
cade PI control . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 59
Figure 3.3 System responses and motor torque of the outer gimbal with cas-
cade PI control . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 61
Figure 3.5 Block diagram of LQI control system with merged gain matrix K̂ . 63
Figure 3.6 Block diagram of the LQI control system with separated gain ma-
trix K̂ . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 64
Figure 3.8 System responses and motor torque of the outer gimbal with global
LQI control . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 69
Figure 3.9 System responses and motor torque of the inner gimbal with global
LQI control . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 69
Figure 3.10 Block diagram of a decoupled inner gimbal control subsystem model 71
Figure 3.11 System responses and motor torque of the coupled nonlinear inner
gimbal with local LQI control . . . . . . . . . . . . . . . . . . . . . . . . 73
xviii
Figure 3.12 Block diagram of a decoupled outer gimbal control subsystem model 74
Figure 3.13 System responses and motor torque of the coupled nonlinear outer
gimbal with local LQI control . . . . . . . . . . . . . . . . . . . . . . . . 76
Figure 3.14 System responses and motor torques of inner gimbal with global
and local LQI control methods . . . . . . . . . . . . . . . . . . . . . . . 78
Figure 3.15 System responses and motor torques of outer gimbal with global
and local LQI control methods . . . . . . . . . . . . . . . . . . . . . . . 79
Figure 3.16 System responses and motor torques of inner gimbal with global
LQI and cascade PI control methods . . . . . . . . . . . . . . . . . . . . 80
Figure 3.17 System responses and motor torques of the outer gimbal with global
LQI and cascade PI control methods . . . . . . . . . . . . . . . . . . . . 81
Figure 4.6 Position of the moving plane and estimation of the target tracking
algorithm . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 89
Figure 4.8 System responses and motor torque of outer gimbal when the sys-
tem tracks a target in a virtual world . . . . . . . . . . . . . . . . . . . . . 91
Figure 4.9 System responses and motor torque of inner gimbal when the sys-
tem tracks a target in a virtual world . . . . . . . . . . . . . . . . . . . . . 91
Figure 4.10 Virtual camera view of a 2-DOF gimbal system tracking a plane . . 92
xix
Figure B.1 Simulink block of LuGre friction model . . . . . . . . . . . . . . . 109
Figure B.5 Simulink block of outer gimbal cascade PI control rate loop . . . . 110
xx
LIST OF ABBREVIATIONS AND SYMBOLS
xxi
η Angular position of the outer gimbal
ηref Angular position reference of the outer gimbal
Angular position of the inner gimbal
ref Angular position reference of the inner gimbal
Ωab Angular velocity vector of the reference frame (a) relative to
the reference frame (b) in the reference frame (a)
Ωabx , Ωaby , Ωabz Components of the angular velocity vector Ωab on x, y and z
axes of the reference frame (a)
αab Angular acceleration vector of the reference frame (a) relative
to the reference frame (b) in the reference frame (a)
αabx , αaby , αabz Components of the angular acceleration vector αab on x, y and
z axes of the reference frame (a)
TC Coulomb friction torque
TS Static friction torque
vs Stribeck velocity
δ Stribeck shape factor
Tf r ab Friction torque between the reference frame (a) and reference
frame (b)
σ0 , σ1 , σ2 Stiffness, damping and viscous damping coefficients of friction
models
Rm Resistance of motor
Lm Inductance of motor
ImI , ImO Inner and outer gimbal rotor moment of inertia
Km Torque constant
Ke Back EMF constant
Tp Peak torque of motor
Tf rm Friction motor torque
Tr Torque ripple
TmI , TmO Motor torques transmitted to the inner and outer gimbal
mI , mO Inner and outer gimbal masses
AGI , AGO Linear acceleration vector of the the inner and outer gimbal CG
Fab Linear force vector applied from the reference frame (a) to ref-
erence frame (b)
g Gravity vector
HI,P Angular momentum vector of the inner gimbal about pivot
point P relative to the inner gimbal reference frame (I)
xxii
HO,P Angular momentum vector of the outer gimbal about pivot
point P relative to the outer gimbal reference frame (I)
IIP , IO
P Inertia tensors of the decoupled inner and outer gimbal calcu-
lated about pivot point P relative to the earth frame (e)
Mab Moment vector applied from reference frame (a) to the refer-
ence frame (b)
I
DstaticU nb Disturbance moment vector caused by static mass unbalance
on the inner gimbal
O
DstaticU nb Disturbance moment vector caused by static mass unbalance
on the outer gimbal
I
DdynamicU nb disturbance moment vector caused by dynamic mass unbalance
on the inner gimbal
O
DdynamicU nb disturbance moment vector caused by dynamic mass unbalance
on the outer gimbal
rP GI , rP GO Position vectors from pivot point to the CG of inner and outer
gimbal
xa State vector of gimbal model (a)
ua Control input vector of gimbal model (a)
wa Disturbance vector of gimbal model (a)
na Gyroscope noise vector of gimbal model (a)
ya Output vector of gimbal model (a)
Aa State matrix of gimbal model (a)
Ba Control input matrix of gimbal model (a)
Ca Output matrix of gimbal model (a)
Ga Disturbance state matrix of gimbal model (a)
Pa Disturbance output matrix of gimbal model (a)
Ŝa Matrix used to collect all the first order derivative terms of
states on the left of state equation of gimbal model (a)
Γa Equilibrium points of gimbal model (a)
CHk The Calinski-Harabasz index
SSB Overall between-cluster variance
SSW Overall within-cluster variance
δx Deviation of state variables
Kp Proportional gain of PID controller
Ki Integral gain of PID controller
Kd Derivative gain of PID controller
xxiii
K State feedback gain matrix of linear quadratic control problem
ξ Integral of error signal vector of linear quadratic control prob-
lem
Q̂, R̂ LQI controller matrices
wu Scalar weight constant of control signal of a LTI subsystem
d Euclidean distance
qi ith pixel of the image
Ix (qi ) Partial derivative of qi on x axis
Iy (qi ) Partial derivative of qi on y axis
It (qi ) Partial derivative of qi with respect to time
v Optical flow vector
Vx Optical flow in horizontal direction
Vy Optical flow in vertical direction
xEst.P laneLoc Estimated translational position of the plane on the x axis of
virtual world
yEst.P laneLoc Estimated translational position of the plane on the y axis of
virtual world
zEst.P laneLoc Estimated translational position of the plane on the z axis of
virtual world
xLOS , yLOS , zLOS Projection of LOS onto the x,y and z axes of virtual world
xxiv
CHAPTER 1
INTRODUCTION
1.1 Background
Inertial stabilization platforms (ISPs) are used in lots of various engineering appli-
cations such as weapon systems, telescopes and cameras. Their configurations are
designed according to the types of application and desired performance requirements
[20]. The essential aim of these systems is to compensate the maneuvers, platform
motions, vibrations and nonlinearity based disturbances such as friction, static mass
unbalance, dynamic mass unbalance and torque ripple in order to stabilize, or hold
steady, a pointing vector, namely line-of-sight (LOS), in an inertial space by means of
electro-optic sensors such as inertial measurement units (IMUs), encoders and cam-
eras [25]. All of these disturbances cause decreasing the pointing accuracy of the
ISPs [27].
This thesis consists of three main parts which are modeling, control and animation of
an inertially stabilized 2-DOF gimbal system being developed by ASELSAN. Con-
figuration of this system has two gimbals which are mounted on each other with
orthogonal pivot axes: The inner gimbal contains two cameras, one laser designator,
one IMU, one brushed DC motor to drive the inner gimbal and one encoder mounted
on motor. The outer gimbal has only one brushed DC motor and one encoder.
When the gimbal is yet to be constructed, simulation studies gain more importance
for control system designers. There are lots of applications and softwares to simulate
the dynamic characteristics of control systems [15], [40], [44]. Mathematical mod-
1
eling of the gimbal takes the most importance for this study because this system is
still in preliminary design phase. If we construct a detailed system model, designers
can observe the performances of control algorithms even if the physical system is not
present. Moreover, simulation studies are faster, desired data can be acquired easily
and system scenarios can be simulated any number of times. Mathematical modeling
study of our gimbal has been started with the geometrical model shown in Figure 1.1,
which is a detailed CAD drawing of the physical model to be constructed.
Figure 1.1: CAD drawing of a stabilized 2-DOF gimbal system developing by ASEL-
SAN
During the modeling study of the gimbal system, gimbal frame transformations, kine-
matics and dynamics of a gimbal system have been investigated, [4], [39] and [16].
When we examine [39] and [10] which focus on modeling of a gimbal system, it has
been observed that static and dynamic mass unbalance effects are neglected in their
gimbal models and all gimbals are decoupled, which results in unsatisfactory gimbal
2
models, which are used for many purposes. [1] explains static and dynamic mass un-
balance dynamics of a 2-DOF gimbal system in detail. On the purpose of observing
mass unbalance effects on a gimbal, they are included in the dynamic equations in this
thesis. Furthermore, static friction models in these studies are unable to capture most
of the friction phenomena and their success in simulation can not be guaranteed in
practice. To construct a realistic friction model for friction compensation study, [42]
compares lots of static and dynamic friction models. According to the result of this
comparison, we decided to use Dahl friction model due to a number of advantages it
provides, instead of the other static and dynamic friction models. Generally, simple
DC motor models are combined by linear electrical and mechanical components [17].
It has been decided that two nonlinear terms are to be incorporated with the motor
models; motor friction and torque ripple effects, based on the formulation provided
in [35]. A nonlinear 2-DOF gimbal is described as a multiple-input, multiple-output
(MIMO) system. In order to the resultant MIMO system via a linear compensator, a
state space representation of the gimbal is obtained, equilibrium points are computed
and these system models which are represented in state space are linearized about
equilibrium points. There are two different approaches for the state space representa-
tion of the gimbal model in this study: In the first approach, inner and outer gimbals
are coupled with each other and one gimbal model is obtained in state space. In the
second approach, inner and outer gimbals are decoupled and their state space repre-
sentations are expressed separately. These three nonlinear state space models contain
lots of equilibrium points; these points are partitioned into clusters according to their
similarities by means of K-means algorithm [33] and Calinski-Harabasz criterion [7]
to reduce the number of linear models. [36] helps formulation of the gimbal models
in state space, calculation of equilibrium points and linearization of nonlinear system
models about clustered equilibrium points.
After mathematical models are constructed, two main control methods are examined.
Firstly, [29] introduces PID control method, discusses whether the controller param-
eters in performance and some handicaps when integral and derivative terms are not
fine-tuned. In this thesis, we have constructed a cascade PI control structure whose
design procedure has been explained in detail for both inner and outer gimbals, cou-
pled with each other. Secondly, the linear quadratic regular problem is formulated
3
in [36] and its benefits are discussed in [41]. However, linear tracking problem, pro-
posed in [28], is more convenient than a regulator problem. In addition, none of our
linearized subsystems have integrators present and integrator inclusions in controllers
have been investigated. In literature, [36] presents and integrator-inserted LQI con-
troller between error signals and the plant, which satisfies all the design requirements.
In order to determine LQI controller parameters, [5] offers a very successful method
to obtain the best performance control system. It is observed in this study that linear
gimbal models represented in state space have more than one LTI subsystem. Thus,
control inputs of subsystems are weighted by a gain scheduling algorithm for each
subsystem and the sum of their outputs gives the overall system response.
After modeling and designing controller of the system is completed, Virtual Reality
Modeling Language (VRML) technology [8] is used to generate a 3-D virtual world
and capture video frames in camera frame frequency (rate) on MATLAB/Simulink
environment [22]. The main aim of building a virtual reality world is to realize sys-
tem scenarios for tracking a plane by looking from a distance when platform motion
is carried out at the gimbal. To understand how to build a virtual world by using
VRML and utilize Simulink blocks for target tracking in video frame sequence, es-
pecially [32], published by MATLAB, is a very helpful document which explains all
examples and key parts of the utilization in detail. In [22], a virtual car, a static video
camera and a virtual world having obstacles are built and Horn-Schunck optical flow
method [21] is used for image processing and target tracking. In this thesis, discrete
Kalman filter [9] is used to be able to track a target in the virtual world, based on
motion estimation. [11] explains and formulates this algorithm in detail. To run the
target tracking algorithm, blob analysis has been utilized in Simulink environment,
[31].
Chapter 2 presents detailed mathematical modeling of the 2-DOF gimbal system for
4
the purpose of constructing a model as realistic as possible. In the modeling process
of the gimbal system, first, reference frames are described, transformation matrices
and their first order derivatives are computed. Second, kinematic equations are incor-
porated. Third, the most realistic friction and actuator models are provided. Then,
dynamic equations with friction models and mass unbalance effects are formulated.
Lastly, both coupled and decoupled 2-DOF gimbal models are represented in a state
space and their LTI models are obtained by Jacobian linearization technique.
Chapter 3 focuses on the two main control strategies implemented in nonlinear gim-
bal models on MATLAB/Simulink environment and their performances are compared
in consideration of desired criteria. One of them is cascade PI control which is com-
posed of rate and position controllers utilizing stabilization and pointing of the sys-
tem, respectively. The other is linear quadratic integral control which is designed
with LTI subsystems of both coupled 2-DOF gimbal and decoupled gimbals. Also
gain scheduling is implemented into LQI control to weight the control signal of each
LTI subsystems of coupled and decoupled gimbals.
Finally in Chapter 5, the summary of the thesis and some suggestions for future stud-
ies have been presented.
5
6
CHAPTER 2
In the modeling study of the gimbal system, first, reference frames and transformation
matrices are described. Second, kinematic equations are formulated. Then, friction
effects between the gimbals, brushed DC actuators and sensor noises of the gyro-
scopes are modeled. After that, dynamic equations containing the friction and mass
unbalance effects are formulated for the inner and outer gimbals. In addition, two
decoupling methods for the gimbal platform are proposed and outputs of the coupled
2-DOF and decoupled gimbals are compared.
7
2.1 Reference Frames and Transformations
The mathematical model of the 2-DOF gimbal platform includes the outer gimbal,
inner gimbal and gimbal base. Angular motions of the outer and inner gimbals are
yaw (η) and pitch () directions on their own reference frames, respectively. More-
over the gimbal base motion referring to the disturbances, caused by the sea waves,
is a yaw-pitch-roll sequence. Angular displacements of the base motions in yaw (ψ),
pitch (θ) and roll (φ) directions are called Euler angles. It is assumed that all refer-
ence frames are orthogonal and their origins are overlapped (in Figure 2.1). Frame
transformations used to analyze the motion are summed up below:
and the unit direction vectors about the x, y and z axes are:
1 0 0
ux = 0 , uy = 1 , uz = 0
(2.1)
0 0 1
Moreover, rotational relations of the reference frames between the earth and inner
gimbal are given in Figure 2.2. These transformations are highly important for com-
puting kinematic and dynamic equations of the system.
8
Figure 2.1: Rotational directions of a 2-DOF gimbal
In [4], theory of the transformation matrices between reference frames and compu-
tation of their first order derivatives with respect to time are examined in detail. A
transformation matrix is expressed by Tab which is used to project a vector from the
reference frame (a) to the reference frame (b). Transformation matrices between ref-
erence frames in a sequence are expressed as follows:
cos (ψ) − sin (ψ) 0
Tem (ψ) = TTme (ψ) =
sin (ψ) cos (ψ) 0
(2.2)
0 0 1
9
cos (θ) 0 sin (θ)
Tmn (θ) = TTnm (θ) =
0 1 0
(2.3)
− sin (θ) 0 cos (θ)
1 0 0
TnB (φ) = TTBn (φ) =
0 cos (φ) − sin (φ)
(2.4)
0 sin (φ) cos (φ)
cos (η) − sin (η) 0
TBO (η) = TTOB (η) =
sin (η) cos (η) 0
(2.5)
0 0 1
cos () 0 sin ()
TOI () = TTIO () =
0 1
0 (2.6)
− sin () 0 cos ()
dTT dT
T + TT =0
dt dt
and TT dT
dt
term is a skew-symmetric matrix expressed by MΩ .
0 −Ωz Ωy
MΩ =
Ωz 0 −Ωx
(2.7)
−Ωy Ωx 0
h iT
The matrix MΩ is related with the angular velocity vector Ω = Ωx Ωy Ωz .
Hence the derivative of a transformation matrix is represented as:
dT
= MΩ · T (2.8)
dt
Consequently, the first order derivatives of all transformation matrices are written
10
(based on Eqs. 2.7 and 2.8) as:
0 −ΩIOz ΩIOy cos () 0 − sin ()
ṪIO = MΩIO TIO = ΩIOz 0 −ΩIOx
0 1 0
−ΩIOy ΩIOx 0 sin () 0 cos ()
ΩIOy sin () −ΩIOz ΩIOy cos ()
= Ω
IOz cos () − ΩIOx sin () 0 −Ω IOz sin () − ΩIOx cos ()
ΩIOy cos () ΩIOx ΩIOy sin ()
(2.9)
0 −ΩOBz ΩOBy cos (η)
sin (η) 0
ṪOB = MΩOB TOB = ΩOBz 0 − sin (η) cos (η) 0
−ΩOBx
−ΩOBy ΩOBx 0 0 0 1
ΩOBz sin (η) −ΩOBz cos (η) ΩOBy
= ΩOBz cos (η) ΩOBz sin (η) −ΩOBx
−ΩOBy cos (η) − ΩOBx sin (η) −ΩOBy sin (η) + ΩOBx cos (η) 0
(2.10)
0 −ΩBnz ΩBny 1 0 0
ṪBn = MΩBn TBn =
ΩBnz 0 −ΩBnx
0 cos (φ) sin (φ)
−ΩBny ΩBnx 0 0 − sin (φ) cos (φ)
0 −ΩBnz cos (φ) − ΩBny sin (φ) −ΩBnz sin (φ) + ΩBny cos (φ)
= ΩBn z Ω Bn x sin (φ) −Ω Bn x cos (φ)
−ΩBny ΩBnx cos (φ) ΩBnx sin (φ)
(2.11)
0 −Ωnmz Ωnmy cos (θ) 0 − sin (θ)
Ṫnm = MΩnm Tnm = Ωnmz 0 −Ωnmx
0 1 0
−Ωnmy Ωnmx 0 sin (θ) 0 cos (θ)
Ωnmy sin (θ) −Ωnmz Ωnmy cos (θ)
= Ω
nmz cos (θ) − Ωnmx sin (θ) 0 −Ω nmz sin (θ) − Ωnmx cos (θ)
Ωnmy cos (θ) Ωnmx Ωnmy sin (θ)
(2.12)
11
2.2 Kinematic Equations of Gimbal
Kinematics of the gimbal represent the angular velocity and acceleration terms. There
are twelve kinematics of the 2-DOF gimbal relative to the earth frame. Transforma-
tions between the reference frames are related in kinematics. In order to project the
inner and outer gimbal kinematics into the earth frame, first, they are transformed to
the reference frame of the gimbal base. Then these are rotated by an amount of φ, θ
and ψ Euler angles about the x, y and z axes, respectively [6].
h iT
Firstly, angular velocity vector of the outer gimbal ΩOe = ΩOex ΩOey ΩOez
relative to the earth frame (e) and represented in the outer gimbal frame (O) is:
and
ΩOe = η̇uz + φ̇TOB ux + θ̇TOB TBn uy + ψ̇TOB TBn Tnm uz
0 φ̇ 0 0
=0 + TOB 0 + TOB TBn θ̇ + TOB TBn Tnm 0
η̇ 0 0 ψ̇
where η is the angular position of the outer gimbal about the z axis. By substituting
transformation matrices into ΩOe , components of this velocity expression about the
x, y and z axes are:
ΩOex = φ̇ cos φ + θ̇ cos φ sin η + ψ̇(cos θ sin η sin φ − cos η sin θ) (2.13)
ΩOey = −φ̇ sin φ + θ̇ cos φ cos η + ψ̇(sin η sin θ + cos η cos θ sin φ) (2.14)
where ΩdistOz is disturbance velocity effect about the z axis of the outer gimbal.
12
h iT
Secondly, angular velocity of the inner gimbal ΩIe = ΩIex ΩIey ΩIez relative
to the earth frame and represented in the inner gimbal frame (I) is:
ΩIe = u
˙ y + TIO ΩOe
0 0 φ̇ 0 0
= ˙ + TIO 0 + TIO TOB 0 + TIO TOB TBn θ̇ + TIO TOB TBn Tnm 0
0 η̇ 0 0 ψ̇
(2.16)
where is the angular position of the inner gimbal. When transformation matrices
substituted into Eq. 2.16, components of ΩIe about the x, y and z axes are written as
follows:
ΩIex = φ̇ cos cos η − ψ̇(sin cos φ − cos sin η sin φ) + θ̇(sin sin φ + cos sin η cos φ)
− η̇ sin
(2.17)
where ΩdistIy is the disturbance velocity about the y axis of the inner gimbal.
ΩIez = φ̇ sin cos η + ψ̇(cos cos φ + sin sin η sin φ) − θ̇(cos sin φ − sin sin η cos φ)
+ η̇ cos
(2.19)
Angular acceleration of the 2-DOF gimbal is obtained by the first order derivative of
angular velocity of the same gimbal reference frame with respect to time. Angular
acceleration of the outer gimbal relative to the earth frame (e) described by αOe =
13
h iT
αOex αOey αOez can be calculated by:
αOe = η̈uz
+ φ̈TOB ux
+ θ̈(TOB TBn )uy
+ ψ̈(TOB TBn Tnm )uz (2.20)
+ φ̇ṪOB ux
+ θ̇(ṪOB TBn + TOB ṪBn )uy
+ ψ̇(ṪOB TBn Tnm + TOB ṪBn Tnm + TOB TBn Ṫnm )uz
sin η − cos η 0
ṪOB = MΩOB TOB = η̇
cos η sin η 0
0 0 0
0 sin2 φ −cosφ sin φ
ṪBn = MΩBn TBn = φ̇
0 cos φ sin φ − cos2 φ
sin φ cos2 φ cos φ sin φ
h iT
and angular acceleration of the inner gimbal αIe = αIex αIey αIez relative to
14
the earth frame (e) and represented in the inner gimbal reference frame (I) is:
αIe = ¨uy
+ η̈TIO uz
+ η̇ ṪIO uz
+ φ̈(TIO TOB )ux
+ θ̈(TIO TOB TBn )uy
+ ψ̈(TIO TOB TBn Tnm )uz
+ φ̇(ṪIO TOB + TIO ṪOB )ux
+ θ̇(ṪIO TOB TBn + TIO ṪOB TBn + TIO TOB ṪBn )uy
+ ψ̇(ṪIO TOB TBn Tnm + TIO ṪOB TBn Tnm + TIO TOB ṪBn Tnm + TIO TOB TBn Ṫnm )uz
(2.21)
where
sin 0 cos
ṪIO = MΩIO TIO = ˙
0 0 0
− cos 0 sin
By substituting transformation matrices into Eq. 2.20 and Eq. 2.21, components of
αOe and αIe about the x, y and z axes are given in Eqs. A.1 - A.6.
Friction term can be described as the resistance to the motion between two surfaces
sliding against each other. It is a natural phenomenon which is quite hard to model
and it is not yet completely understood [14]. The main goal of modeling of the fric-
tion is to observe uncertainty of the mechanical systems. There are two main types of
friction models which are static and dynamic in simulation studies.
The classic friction models can be accepted the most basic friction models, includ-
ing Coulomb, viscous, stiction, Stribeck effect and their all possible combinations.
These types of frictions depend statically on the applied load and relative velocity
[42]. Hence classical models are described by static maps between velocity and fric-
tion torque [14].
15
Figure 2.3: Combination of Coulomb, viscous and static friction [2]
The Stribeck effect [2] is expressed as nonlinear continuous transition from the static
friction to the dynamic friction for lubricated and dry surfaces. The Stribeck veloc-
ity vs can be defined as the velocity where dip point of the Stribeck curve, shown in
Figure 2.4. Stribeck effect is formulated by:
δ
s(v) = (TC + (TS − TC )e−(v/vs ) )sgn(v) (2.22)
Figure 2.4: Combination of Coulomb, viscous, static friction and Stribeck effect [2]
The main limitations of the classical friction models are zero crossing of velocity and
non-uniqueness of the solution between −TS and +TS at zero velocity [3]. To solve
these problems, Karnopp friction model which is capable of detecting zero velocity
with high accuracy is proposed in [24]. Although Karnopp model is efficient in simu-
16
lation studies, it is strongly coupled with the rest of system and external torque which
is one of the friction input terms which can not be described explicitly. Therefore, the
success in simulation may fail in practical applications [42]. When all problems and
limited capabilities of static models are taken into account, these models are not able
to satisfy the friction phenomenon accurately. On the other hand, dynamic models
can solve all problems of static models and capture some friction phenomena. Con-
sequently, the dynamic models are preferred instead of static models.
The Dahl friction model [12], which is the simplest dynamic model, is used to sim-
ulate servo systems with ball bearing friction [37]. This model depends on Coulomb
friction, sign of velocity and angular displacement. It captures hysteresis effects and
solves all problems of static friction models. In addition, the Dahl model is very suc-
cessful in both simulation and practical applications [14]. On the other hand, the Dahl
neither captures the Stribeck effect, depending on angular velocity, nor the stick-slip
motion. Description of the Dahl model in time domain is formulated by:
Tf r = σ0 z (2.23)
dz σ0 |v|
=v− z (2.24)
dt TC
where Tf r is friction torque, TC is Coulomb friction, v is relative angular velocity and
σ0 is stiffness.
Table2.1: Parameters of Dahl friction model effect on inner and outer gimbals
The LuGre friction model includes all advantages of the Dahl model. In addition, this
model can capture the Stribeck effect, stick-slip motion, friction lag in sliding regime,
hysteresis curve in pre-sliding and it can estimate the break-away force at transition
from pre-sliding to sliding regime [42]. The LuGre friction model is based on repre-
sentation of the elastic bristles visualized between two rigid bodies [18]. Modeling
of LuGre is built on the average deflection of the bristles. When a tangential force
is applied, the bristles will deflect like springs. If deflection is sufficiently large the
17
bristles start to slip [14], [37].
where TC is the Coulomb friction torque, TS is the stiction torque, vs is the Stribeck
velocity and δ is the Stribeck shape factor. Values of parameters of LuGre friction
models on inner and outer gimbals are given in Table 2.2. With these values of pa-
rameters, hysteresis curves of frictions between gimbals are shown below.
Table2.2: Parameters of LuGre friction model effect on inner and outer gimbals
18
Figure 2.6: Hysteresis curves of the LuGre friction models
In order to decide the most convenient dynamic friction model for simulation studies,
outputs of Dahl and LuGre are examined for different angular velocity inputs.
Figure 2.7: Chirp responses of the Dahl and LuGre friction models
In [42], LuGre friction model is chosen for friction compensation instead of the other
static and dynamic models. It can capture many friction phenomena and the number
19
of LuGre parameters is less than Leuven and GMS models for identification. In me-
chanical design of our system, ball bearings are used on the purpose of decreasing
friction effects between weighty gimbals. Although LuGre has many advantages on
obtaining a realistic friction model, Dahl model is more suitable to use in this study.
Actuators of the inner and outer gimbals are chosen as brushed DC motors from
KOLLMORGEN Company. Mathematical model of the DC motor, constructed by
electrical and mechanical parts, is strengthened in a lot of scientific paper [17]. Elec-
trical part parameters are inductance Lm , motor resistance Rm and back EMF con-
stant Ke . On the other hand, mechanical part parameters of the brushed DC motor are
rotor moment of inertia Im , motor friction torque Tf rm , torque ripple Tr and torque
constant Km .
Mathematical model of the DC actuator contains both linear and nonlinear effects.
In [1], simplest linear DC motor model is used for the mathematical model of the
gimbal. In this study, Coulomb motor friction torque and torque ripple effect, caused
by lots of reasons such as coupling of magnetic field, cogging torque and mechanical
unbalances of motor, are implemented into the linear motor model. Torque ripple
causes acoustic noise, mechanical vibrations and inaccuracy for position and speed
control [43]. As shown in Figure 2.8, characteristic of the torque ripple is a sine wave
function of the ripple frequency and angular displacement. Value of the torque ripple
can be described as the percent change from the peak value to the average value of
motor torque. Besides, ripple frequency refers to the number of ripple cycles in one
revolution of the motor. Indeed, number of ripple cycles in one revolution is equal to
the number of commutator bars [35].
20
Figure 2.8: Torque ripple effect [35]
In Simulink model of the actuator, given in Figure B.3, relative angular velocity
comes from the first order derivative of angular displacement measured by encoder.
In addition, torque ripple depend on angular displacement. Last, saturation block en-
sures the operation of the motor in torque limits.
Table2.3: Parameters of the motor models for the inner and outer gimbals
21
have main role in stabilization. However, there are some problems of gyroscopes
which can be handled by means of sensor fusion algorithms such as bias, angular
random walk, scale factor and misalignment. In this study, angular random walk of
√
used gyroscope is lower than 0.013◦ / hr and its bandwidth frequency at higher that
440 Hz. White noise characteristic of the gyroscopes is shown in Figure 2.9.
Frictions and mass unbalances of the inner and outer gimbals are the essential dis-
22
turbance sources on the system. Especially, it can be said that friction is the more
dominant effect against mass unbalance. There are two types of mass unbalances of
the gimbals. One of them is the dynamic mass unbalance caused by the asymmet-
ric mass distribution, called product of inertia (POI) [38]. Inertia matrices (tensors)
demonstrate the dynamic unbalance states of the gimbals. If the gimbal has symmet-
rical mass distribution with respect to the its frame axis, dynamic mass unbalance
will be nonexistent and inertia tensor of the gimbal becomes a diagonal matrix. The
other disturbance source is the static mass unbalance caused by the offset between
the intersection (pivot) point of the rotation axes and the center of gravity (CG) of
gimbals. The gravitational and base motion acceleration act on the CG of gimbals
and disturbance torques about the pivot point occur [1].
In this thesis, values of parameters of the system are obtained by CAD drawings. It
is an important point about the determination of values of these parameters that both
gimbals have to be decoupled in CAD drawings.
23
2.6.1 Inner Gimbal
Newton’s equation which yields translational motion for the inner gimbal is:
where mI is the inner gimbal mass, ACGI is the linear acceleration of the CG of the
inner gimbal, FOI is the linear force applied from the outer gimbal to the CG of the
inner gimbal and g is the gravity vector.
Angular momentum of the inner gimbal about the pivot point P relative to the in-
ner gimbal frame HI,P is:
HI,P = IIP · ΩIe (2.29)
where IIP and ΩIe express the inertia tensor of the decoupled inner gimbal calculated
about the pivot point and angular velocity vector of the inner gimbal relative to the
earth frame, respectively. Total moment applied to the inner gimbal is formulated
by the first order derivative of inner gimbal angular momentum with respect to time.
With some calculations in [4], Euler’s equation of the inner gimbal about the pivot
point is formulated by:
where
IIP : Inertia tensor of the decoupled inner gimbal about the pivot point
αIe : Angular acceleration of the inner gimbal frame relative to the earth
frame
ΩIe : Angular velocity of the inner gimbal frame relative to the earth
frame
MOI : Moment applied from the outer gimbal on the inner gimbal
I
DstaticU nb : Disturbance moment caused by static mass unbalance on the inner
gimbal
24
To calculate disturbance torque caused by static mass unbalance on gimbals, the grav-
itational effect and the gimbal base motion acceleration should be transformed into
the reference frames of the gimbals. However, the base motion acceleration is ne-
glected in these equations. The gravity vector relative to the earth reference frame is
g e = −guz which is projected into the inner gimbal reference frame.
Thus
− cos η sin θ cos + sin ηz sin φ cos θ cos − cos φ cos θ sin
g I = −g
sin η sin θ + cos η sin φ cos θ
(2.31)
− cos η sin θ sin + sin η sin φ cos θ sin + cos φ cos θ cos
Equation of the static mass unbalance torque of the inner gimbal is:
I I
DstaticU nb = rP GI × (mI {g} ) (2.32)
where mI is the mass of inner gimbal. Position vector from the pivot point to the CG
of the inner gimbal is:
h iT
rP GI = rP GIx rP GIy rP GIz (2.33)
Besides, the moment term transfered into the inner gimbal can be expressed by:
MOI x
MOI =
TmI + Tf rOI
(2.34)
MOI z
where TmI is the motor torque transmitted into the inner gimbal and Tf rOI is the
friction torque between the inner and outer gimbals. TmI + Tf rOI is transfered into
the inner gimbal along the y axis so that components of the moment, which is applied
from the outer gimbal on the inner gimbal, about the x and z axes are neglected.
Inertia tensor of the inner gimbal is:
I I I
Ixx Ixy Ixz
IIP = I I I
Iyx Iyy Iyz (2.35)
I I I
Izx Izy Izz
25
If Euler’s equation of the inner gimbal is rewritten with above terms
I I I I I I
Ixx Ixy Ixz αIex ΩIex Ixx Ixy Ixz ΩIex
I I I I I I αIe + ΩIe × I I I I I I ΩIe
yx yy yz y y yx yy yz y
I I I I I I
Izx Izy Izz αIez ΩIez Izx Izy Izz ΩIez
(2.36)
0 rP GIx cos() sin(θ) + cos(θ) sin()
= T
mI + T
f rOI + r
P GIy
× −(mI g)
0
0 rP GIz sin() sin(θ) − cos() cos(θ)
This equation can be expanded into three equations of the inner gimbal with respect to
the angular accelerations αIex , αIey , αIez and the angular velocities ΩIex , ΩIey , ΩIez .
These scalar equations are given in Eq. A.7 - A.9, explicitly. If dynamic equation of
the inner gimbal about the y axis, given by Eq. A.8, is rewritten:
I I I
Iyy αIey + DdynamicU nby = TmI + Tf rOI + DstaticU nby (2.37)
where disturbance torques caused by the dynamic and static mass unbalance are:
I I I I I I
DdynamicU nby = Ixy αIex + Iyz αIez + ΩIez (Ixx ΩIex + Ixy ΩIey + Ixz ΩIez )
I I I
− ΩIex (Ixz ΩIex + Iyz ΩIey + Izz ΩIez )
I
DstaticU nby = gmI (rP GIx (cos cos θ − sin sin θ) + rP GIz (cos sin θ + cos θ sin ))
Angular velocity ΩIey and angular position are measured by the gyroscope and
26
encoder sensors, respectively. Moreover, angular velocity term ΩdistIey represents the
platform motion affect on the inner gimbal. Relative velocity ˙ can be defined as
changing rate of the angular displacement [39]. Total inertia of the inner gimbal is
I
computed by the sum of motor inertia ImI and inner gimbal inertia Iyy along the y
axis. Then, only the friction model is required to determine the relative velocity of the
inner gimbal ˙ whereas mass unbalance block gets platform motion, angular positions
of the inner and outer η gimbals. Last, motor model requires angular position and
relative velocity of the inner gimbal.
where mO is the outer gimbal mass, AGO is linear acceleration of the CG of the outer
gimbal, FBO is linear force applied from the gimbal base to the CG of the outer gim-
bal, FIO is linear force applied from the inner gimbal to the CG of the outer gimbal.
The angular momentum of the outer gimbal about the pivot point P relative to the
outer gimbal frame HO,P is formulated by:
HO,P = IO I
P · ΩOe + TIO · IP · ΩIe (2.40)
where IO
P is the inertia tensor of the decoupled outer gimbal and ΩOe is angular ve-
locity vector of the outer gimbal relative to the earth frame. Euler’s equation of the
outer gimbal about the pivot point is:
IO I I O I
P · αOe + ṪIO · IP · ΩIe + TIO · IP · αIe + ΩOe × (IP · ΩOe + TIO · IP · ΩIe )
O
= MBO + MIO + DstaticU nb
(2.41)
where
IIP : Inertia tensor of the decoupled inner gimbal about pivot point
27
IO
P: Inertia tensor of the decoupled outer gimbal about pivot point
αIe : Angular acceleration of the inner gimbal frame relative to the earth
frame
αOe : Angular acceleration of the outer gimbal frame relative to the earth
frame
ΩIe : Angular velocity of the inner gimbal frame relative to the earth frame
ΩOe : Angular velocity of the outer gimbal frame relative to the earth frame
MBO : Moment applied from the gimbal base to the outer gimbal
MIO : Moment applied from the inner gimbal to the outer gimbal
O
DstaticU nb : Disturbance torque caused by static mass unbalance on the outer gim-
bal
Equation of the static mass unbalance torque on the outer gimbal is:
O O
DstaticU nb = rP GO × ((mO + mI ){g} ) (2.42)
where mI and mO are the mass of inner and outer gimbals, respectively. Position
vector from the pivot point to the CG of the outer gimbal is expressed by rP GO :
h iT
rP GO = rP GOx rP GOy rP GOz (2.43)
and the gravity vector {g}O projected into the outer gimbal is:
Furthermore
− cos η sin θ + sin η sin φ cos θ
g O = −g
sin η sin θ + cos η sin φ cos θ
(2.44)
cos φ cos θ
The moment terms transfered into the outer gimbal can be written as:
MIOx MBOx
MIO = MIOy ,
MBO = MBOy
(2.45)
Tf rIO TmO + Tf rBO
28
where Tf rBO is the friction torque between the gimbal base and the outer gimbal,
Tf rIO is friction torque between the inner and outer gimbals and TmO is motor torque
applied to the outer gimbal. Rotations of the joints between the gimbal base and outer
gimbal are overlapped along the same z axis. Thus TmO + Tf rBO is transfered into the
outer gimbal directly whereas Tf rIO is the friction torque transfered indirectly.
When we rewrite Euler’s equation of outer gimbal and substitute above terms into this
equation with assuming MIOx = MIOy = 0 and MBOx = MBOy = 0,
O O O I I I
Ixx Ixy Ixz αOex sin 0 cos Ixx Ixy Ixz ΩIex
I O I O I O αOe + 0 0 0 I I I I I I ΩIe
yx yy yz y yx yy yz y
O O O I I I
Izx Izy Izz αOez − cos 0 sin Izx Izy Izz ΩIez
I I I
cos 0 sin Ixx Ixy Ixz αIex
+ 0 1 0 I I I I I I αIe
yx yy yz y
I I I
− sin 0 cos Izx Izy Izz αIez
O O O I I I
ΩOex Ixx Ixy Ixz ΩOex cos 0 sin Ixx Ixy Ixz ΩIex
ΩOey × Iyx Iyy Iyz ΩOey + 0
+ O O O
1 0 I I I
Iyx Iyy Iyz ΩIey
O O O I I I
ΩOez Izx Izy Izz ΩOez − sin 0 cos Izx Izy Izz ΩIez
0 0
= 0 + 0
TmO + Tf rBO Tf rIO
rP GOx − cos η sin θ + sin η sin φ cos θ
+ rP G
× −g(mO + mI ) sin η sin θ + cos η sin φ cos θ
Oy
rP GOz cos φ cos θ
(2.47)
This matrix is decomposed into three scalar equations of outer gimbal with respect
to angular accelerations αOex , αOey , αOez and angular velocities ΩOex , ΩOey , ΩOez .
These equations are written in Eq. A.10 - A.12, explicitly. The equation of motion
29
for the outer gimbal on the z axis is given in Eq. A.12. If we write again this equation
O O O
Izz αOez + DdynamicU nbz = TmO + Tf rBO + Tf rIO + DstaticU nbz (2.48)
O O O
DdynamicU nbz = Ixz αOex + Iyz αOey
I I I I
+ αIex (Ixz cos + Ixx sin ) + αIey (Iyz cos + Ixz sin )
I I
+ αIez (Izz cos + Ixz sin )
I O I O I O
+ ΩOex (ΩOex (Ixy + Ixy ) + ΩOey (Iyy + Iyy ) + ΩOez (Iyz + Iyz ))
O I I O I I
− ΩOey (ΩOex (Ixx + Ixx cos − Ixz sin ) + ΩOey (Ixy + Ixy cos − Iyz sin )
O I I
+ ΩOez (Ixz + Ixz cos − Izz sin ))
I I I I
− ΩIex (I
˙ xx cos − Ixz sin ) − ΩIey (I
˙ xy cos − Iyz sin )
I I
− ΩIez (I
˙ xz cos − Izz sin )
O
DstaticU nbz = g(mO + mI )((− cos η sin θ + sin η sin φ cos θ)rP GOy
Block diagram of outer gimbal is shown in Figure 2.11. The angular velocity ΩOez
and η are measured by gyroscope and encoder sensors, respectively.
Angular velocity ΩdistOez expresses platform motion disturbance on the outer gimbal
and η̇ is relative velocity of outer gimbal. Total inertia of the outer gimbal is computed
O
by the sum of motor inertia ImO and outer gimbal inertia Izz along the z axis. Fur-
ther, motor model requires angular position and relative velocity of the outer gimbal.
Moreover, inputs of the friction models are relative velocities of the gimbals whereas
30
inputs of the mass unbalance block are platform motion and angular positions of both
inner and outer gimbals.
The stabilized gimbal system has the inner and outer gimbals controlled separately.
However, if two separate controllers are implemented to control the two gimbals,
these one has to verify that decoupling is realistic [39].
There are two methods in order to decouple mechanically coupled two gimbals. In
the first proposed method, if dynamic equations of the gimbal includes the inertia and
mass terms of the other gimbal, these expressions have to be neglected. In addition
to the ignored terms of the first method, each gimbal is fixed to the other and angular
position of the other gimbal is set to zero in the second method. When motor torques
as chirp signals are applied to inner and outer gimbals, angular position and velocity
outputs of the systems are shown below.
These figures shows that decoupling approaches are unable to respond with the same
31
Figure 2.13: Velocity outputs of coupled and decoupled gimbals
coupled 2-DOF gimbal. Even though outputs of the coupled and decoupled inner
gimbal with the first decoupling approach are about same, they are much different in
all the other cases. In this study, the first approach is used to obtain state space mod-
els of the decoupled gimbals. After that local LQI controllers, discussed in the next
chapter, are designed for these decoupled models and linear quadratic controllers for
models of the coupled and decoupled gimbals are compared.
32
also defined in state space. None of system model represented in state space contains
mathematical model of the motors.
State variables describe the behavior of the system. Friction state z which is used
in the Dahl model, relative angular position and relative angular velocity terms of the
inner and outer gimbals are chosen as state variables. Output variables have to be
selected as measurable quantities whereas state variables do not have any necessity
on being measurable [36]. Hence angular position and velocity responses, measured
by encoders and gyroscopes of IMU, for inner and outer gimbals are chosen as the
output variables. Motor torques refers to the control input variables, platform motion
kinematics and sensor noise are used to define external effects carried out to the sys-
tem.
The nonlinear state space representation of the system is in the following form:
ẋ = f (x, u, w) (2.49)
y = h(x, w, n) (2.50)
where x is the state vector, u is the control input vector, w is the disturbance vector
referring to platform motion which is carried out to the gimbal base, f (x, u, w) is the
state equation consisting of dynamic and kinematic equations of the system, ẋ is the
first order derivative of the state vector, y is the output vector, n is the gyroscope noise
vector and h(x, w, n) is the output equation which defines the system responses.
The nonlinear state space representation of the coupled 2-DOF gimbal is:
yG = hG (xG , wG , nG ) (2.52)
There are six states, two control inputs, eight disturbances, two gyroscope noises and
four outputs for the coupled gimbal. State vector consists of two angular positions (η,
), two friction states (zOB , zIO ), relative angular velocity between the outer gimbal
33
and the platform base about the z axis ΩOBz and relative angular velocity between
inner and outer gimbals about the y axis ΩIOy . Nonetheless control input vector
contains two motor torques (TmO , TmI ) and disturbance vector involves two Euler
angles (θ, φ), the first order derivatives (ψ̇, θ̇, φ̇) and the second order derivatives
(ψ̈, θ̈, φ̈) of the Euler angles. Noise vector has only gyroscope noise states affecting
on angular velocity responses. Output vector has two measurable relative angular
positions (η, ) for tracking and two measurable angular velocities relative to the
earth reference frame (ΩOez + nz , ΩIey + ny ) for stabilization.
h iT
xG = η ΩOBz ΩIOy zOB zIO
h iT
uG = TmO TmI
h iT
wG = θ φ ψ̇ θ̇ φ̇ ψ̈ θ̈ φ̈
h iT
yG = η (ΩOez + nz ) (ΩIey + ny )
h iT
nG = 0 0 nz ny
The limits of the state, control input, disturbance and sensor noise variable of the
coupled 2-DOF gimbal are given in Table 2.5 and Table 2.6. Boundaries of η and
angular position come from the mechanical limits of the outer and inner gimbal,
respectively. Angular velocity limits are determined from the maximum acceleration
in a second in the case of disturbances are neglected. Further, boundaries of TmO and
TmI inputs refers to the peak torque values of the outer and inner gimbal motors. On
the other hand, limiting ranges of disturbance and friction state variables are chosen
arbitrarily.
34
Table2.6: Boundaries of the disturbance, sensor noise and control input variables of
the coupled 2-DOF gimbal
Inputs Units Lower Upper
uG1 N.m −203 203
uG2 N.m −35.3 35.3
π π
w G1 rad − 20 20
w G2 rad − π8 π
8
π π
w G3 rad/sec − 180 180
π π
w G4 rad/sec − 60 60
π π
w G5 rad/sec − 18 18
π π
w G6 rad/sec2 − 180 180
π π
w G7 rad/sec2 − 60 60
π π
w G8 rad/sec2 − 18 18
nG3 rad/sec -0.000001 0.000001
nG4 rad/sec -0.000001 0.000001
In order to obtain state equations, first, we rewrite the first order derivatives of relative
angular positions for both gimbals.
η̇ = ΩOBz
˙ = ΩIOy
Ω̇OBz = η̈
Ω̇IOy = ¨
where αOez is the angular acceleration of outer gimbal relative to the earth reference
frame about the z axis and αdistOz is disturbance angular acceleration. By using Euler
35
equation of the outer gimbal about the z axis, given in Eq. 2.48, and friction torque
equation, given in Eq. 2.23, Ω̇OBz can be written as follows:
1 O 1 1 1 1 O
Ω̇OBz = − O
DdynamicU nbz + O TmO + O Tf rBO + O Tf rIO + O DstaticU nbz −αdistOz
Izz Izz Izz Izz Izz
This equation is written in terms of state and input variables with values of system
parameters, given in Table 2.4, and friction parameters, given in Table 2.2, as follows:
O O
ẋG3 = −0.1DdynamicU nbz + 0.1uG1 + 0.1Tf rBO + 0.1Tf rIO + 0.1DstaticU nbz − αdistOz
(2.55)
where the dynamic mass unbalance is:
O 2 2
DdynamicU nbz = + ẋG3 (14.41 cos xG2 − 14.51 sin xG2 )
with
O
D̂dynamicU nbz = − 4.76αOex + 0.0006αOey
+ 164.8(sin xG1 sin wG1 + cos xG1 sin wG2 cos wG1 ),
the friction torque between the outer gimbal and gimbal base is:
Tf rBO = 80xG5
36
and the friction torque between the inner and outer gimbals is:
Tf rIO = 90xG6
where αIey is the angular acceleration of inner gimbal about the y axis relative to the
earth frame and αdistIy is the disturbance angular acceleration about the y axis. Ω̇IOy
is written from Euler equation for the inner gimbal, given in Eq. 2.37, and the friction
torque equation, given in Eq. 2.23.
1 I 1 1 1 I
Ω̇IOy = − I
D dynamicU nb y
+ I
Tf r OI
+ I
TmI
+ I
DstaticU nby − αdistIy
Iyy Iyy Iyy Iyy
This equation is rewritten in terms of state and input variables with values of inner
gimbal parameters in Table 2.4 and friction parameters in Table 2.1.
I I
ẋG4 = −0.35DdynamicU nby + 0.35Tf rOI + 0.35uG2 + 0.35DstaticU nby − αdistIy (2.56)
with
I
D̂dynamicU nby = + 0.067αdistIx + 0.364αdistIz
Tf rOI = 90xG6
Lastly, the first order derivatives of friction states from Eq. 2.24 are:
|ΩBOz |
żBO = ΩBOz − σ0BO zBO
TC BO
37
|ΩIOy |
żIO = ΩIOy − σ0IO zIO
TC IO
With values of friction parameters in Table 2.1, these equations can be described in
terms of state variables:
The first order derivatives of all states have to be on the left side of the state equations.
Eq. 2.55 and Eq. 2.56 contain both ẋG3 and ẋG4 terms on the right side of the state
equation. Thus Eq. 2.55 and Eq. 2.56 are rewritten after ẋG3 and ẋG4 are substituted
on the left side.
ẋG3 (1 + 1.441 cos2 xG2 − 1.451 sin2 xG2 ) + ẋG4 (0.0364 cos xG2 + 0.0052 sin xG2 )
O O
= −0.1D̂dynamicU nbz + 0.1uG1 + 0.1Tf rBO + 0.1Tf rIO + 0.1DstaticU nbz − αdistOz
(2.59)
ẋG4 + ẋG3 (−0.02345 sin xG2 + 0.1274 cos xG2 )
I I
= −0.35D̂dynamicU nby + 0.35Tf rOI + 0.35uG2 + 0.35DstaticU nby − αdistIy
(2.60)
with
sg1 = 1 + 1.441 cos2 xG2 − 1.451 sin2 xG2
sg2 = 0.0364 cos xG2 + 0.0052 sin xG2
sg3 = −0.02345 sin xG2 + 0.1274 cos xG2
38
and fˆG (xG , uG , wG ) vector contains kinematic and dynamic equations without the
first order derivatives of state variables.
xG 3
xG 4
−0.1D̂O + 0.1u + 0.1T + 0.1T + 0.1D O
− α
dynamicU nbz G1 f rBO f rIO staticU nbz distOz
−0.35D̂I I
dynamicU nby + 0.35uG2 + 0.35Tf rOI + 0.35DstaticU nby − αdistIy
x G 3 − 4.42 · |x G3 | · x G 5
xG4 − 33.3 · |xG4 | · xG6
Some elements of SG matrix depend on the inner gimbal position. It can be said
that SG matrix has to be invertible in mechanical limits of inner gimbal. As shown
in Figure 2.14, all determinants of SG matrix are nonzero except xG2 ≈ 66.5 de-
gree. Besides diagonal terms of SG matrix are dominant in comparison with the other
elements except diagonal term of 3rd row of SG if xG2 > 66.5 degree.
39
Figure 2.15: Elements of 3rd row of SG matrix
To be able to definite this system model for all inner gimbal positions, we describe a
new matrix ŜG :
SG S
: xG2 ε [−20.0, 66.0) (67.0, 80.0]
ŜG =
SG + τG · I1
: xG2 ε [66.0, 67.0]
40
Figure 2.16: Determinants of ŜG matrix
The nonlinear state space representation of the decoupled inner gimbal is:
yI = hI (xI , wI , nI ) (2.63)
There are three state, one control input, eight disturbance, two outputs and one gyro-
scope noise variables for decoupled inner gimbal. State variables are angular position
41
, angular velocity ΩIOy and friction state zIO . Control input reflects the inner mo-
tor torque TmI and disturbance vectors of the coupled 2-DOF and decoupled inner
gimbals are the same. Measurable output variables are angular position and angular
velocity which is the sum of ΩIey and sensor noise ny .
h iT
xI = ΩIOy zIO
uI = TmI
h iT
wI = wG = θ φ ψ̇ θ̇ φ̇ ψ̈ θ̈ φ̈
h iT
yI = (ΩIey + ny )
h iT
nI = 0 ny
State equation of the decoupled inner gimbal may be written from Eq. 2.54, 2.56
and 2.58. Inner gimbal state variables xI1 , xI2 , xI3 and control input variable uI are
substituted into xG2 , xG4 , xG6 and uG2 , respectively. Disturbance vectors of the de-
coupled inner and coupled 2-DOF gimbals are the same. In order to decouple inner
gimbal from outer gimbal, the mass and inertial terms of the outer gimbal have to be
neglected.
The first order derivative of state variables are given below. Firstly, ẋI1 is:
I I
ẋI2 = −0.35DdynamicU nby + 0.35Tf rOI + 0.35uI + 0.35DstaticU nby − αdistIy (2.65)
I
DdynamicU nby = + 0.067αdistIx + 0.364αdistIz
42
the static mass unbalance is:
I
DstaticU nby = − 2.66(cos xI1 cos wI1 − sin xI1 sin wI1 )
Tf rOI = 90xI3
The nonlinear state space representation of the decoupled outer gimbal is:
yO = hO (xO , wO , nO ) (2.69)
There are three state, one control input, eight disturbance, two output and one gyro-
scope noise variables for outer gimbal. State variables are angular position η, angular
velocity ΩOBz and friction state zOB . Control input is the outer motor torque TmO and
disturbance vectors of coupled 2-DOF and decoupled outer gimbals are the same..
43
Measurable output variables are angular position η and angular velocity which is the
sum of ΩOez and sensor noise nz .
h iT
xO = η ΩOBz zOB
uO = TmO
h iT
wO = wG = θ φ ψ̇ θ̇ φ̇ ψ̈ θ̈ φ̈
h iT
yO = η (ΩOez + nz )
h iT
nO = 0 nz
State equation of decoupled outer gimbal may be written from Eq. 2.53, 2.55 and
2.57. Outer gimbal state variables xO1 , xO2 , xO3 and control input variable uO are
substituted into xG1 , xG3 , xG5 and uG1 , respectively. Disturbance vectors of decou-
pled outer and coupled 2-DOF gimbals are the same.
The first order derivative of state variables are given below. Firstly, ẋO1 is:
O O
ẋO2 = −0.1DdynamicU nbz + 0.1uO + 0.1Tf rBO + 0.1Tf rIO + 0.1DstaticU nbz − αdistOz
(2.71)
where dynamic mass unbalance is:
O
DdynamicU nbz = − 4.76αOex + 0.0006αOey
+ 87.8(sin xO1 sin wO1 + cos xO1 sin wO2 cos wO1 ),
The friction torque between outer gimbal and gimbal base is:
Tf rBO = 80xO3
44
and friction torque between inner and outer gimbals is:
Tf rIO = 90zIO
In Eq. 2.71, the mass of inner gimbal mI in static mass unbalance expression and
all elements of inertia tensor for inner gimbal in dynamic unbalance expression are
chosen as zero in order to decouple outer gimbal from inner gimbal. Consequently,
state equation of the decoupled outer gimbal fO (xO , uO , wO ) is:
xO2
−0.1DO O
dynamicU nbz + 0.1uO + 0.1Tf rBO + 0.1Tf rIO + 0.1DstaticU nbz − αdistOz
xO2 − 4.42 · |xO2 | · xO3
and output equation of the decoupled outer gimbal hO (xO , wO , nO ) is:
xO 1
(2.73)
xO2 − wG4 sin wG2 + wG3 cos wG2 cos wG1 + nz
2.8.3 Linearization
Equilibrium points of the nonlinear system which are the real roots of Eq. 2.49 can
be computed by:
ẋ = f (xe , ue , we ) = 0 (2.74)
45
decoupled inner gimbal contains three state equations, three unknown states of inner
gimbal, two unknown states of outer gimbal and eight unknown inputs. Lastly, de-
coupled outer gimbal has three state equations, three unknown states of outer gimbal,
three unknown states of inner gimbal and eight unknown inputs. Trimmed condition
of coupled 2-DOF gimbal ΓG , trimmed condition of decoupled inner gimbal ΓI and
trimmed condition of decoupled outer gimbal ΓO can be described as follows:
The number of state equations has to be greater than or equal to the number of un-
known variables to be capable of computing equilibrium points. Hence equilibrium
states of the gimbals are determined as unknowns and they are calculated for different
values of the equilibrium inputs in boundaries. In this computation, each disturbance
variable only get its lower boundary, zero and upper boundary. In finding equilibrium
points of the coupled system, angular position of the inner gimbal xG2e and angular
position of the outer gimbal xG1e are split into 11 different values within mechanical
limits.
π
xG1e = −π : :π
11
π 5π/18 4π
xG2e =− : :
9 11 9
After we computed equilibrium points of the coupled gimbal, these points were as-
signed to the equilibrium points of decoupled gimbals. Equilibrium points of the
decoupled inner gimbal can be described by:
Dynamic and kinematic equations of the decoupled gimbals still include unknown
46
state variables. Dynamic equation of the decoupled inner gimbal, given in Eq. 2.65,
contains angular position η, relative angular velocity η̇ of the outer gimbal. Values
of these two unknown variables are chosen the equilibrium points xG1e and xG3e ,
respectively. Similar to the inner gimbal, Eq. 2.71 includes , ˙ and zIO which come
from equilibrium points xG2e , xG4e and xG6e , respectively. In conclusion, the numbers
of trimmed conditions of coupled 2-DOF gimbal, decoupled inner and decoupled
outer gimbal are 38 × 11 × 11 = 793881, 38 × 11 = 72171 and 38 × 11 = 72171,
respectively.
Linearization of the system and designing linear controller are computationally ex-
pensive for entire trimmed conditions. Hence equilibrium points are partitioned into
clusters to reduce the number of linear models. The purpose of cluster analysis is to
collect similar observations, equilibrium point sets, into the clusters and isolate from
dissimilar ones in some sense. Clustering analysis can be separated into two parts,
one of which is the clustering evaluation to determine the optimal number of clusters
by means of different criteria such as Davies-Bouldin [13] and Calinski-Harabasz [7],
and the other is clustering observations with respect to the optimal number of cluster
result of evaluation analysis. In this thesis, K-means clustering algorithm [34] [30],
with squared Euclidean distances, along with Calinski-Harabasz clustering evaluation
criterion is used in order to find the sufficient number of linearized models.
The Calinski-Harabasz criterion, also named as the variance ratio criterion (VRC),
calculates an index value for each number of cluster. The Calinski-Harabasz index
value CHk can be formulated by:
n − k SSB (k)
CHk = · (2.75)
k − 1 SSW (k)
where n is the number of trimmed conditions, k is the number of clusters, SSB (k)
term is the overall between-cluster variance and SSW (k) term is the overall within-
cluster variance. SSB (k) and SSW (k) variance terms are:
k
X
SSB (k) = ni ||mi − m||2 (2.76)
i=1
47
k X
X
SSW (k) = ||x − mi ||2 (2.77)
i=1 x∈ci
It can be said that clusters are partitioned successfully if V RCB (k) variance value
is large and V RCW (k) is small so that success of partition of trimmed conditions
depends on how large the Calinski-Harabasz index value is. The optimal number of
clusters is determined by the highest Calinski-Harabasz value. Clustering evaluation
analysis for equilibrium points of all gimbal models indicates that the optimal num-
ber of clusters is two for coupled 2-DOF and decoupled inner gimbal. On the other
hand, the optimal number of clusters is three for decoupled outer gimbal, as shown in
Figures 2.17 - 2.19.
48
Figure 2.18: Clustering evaluation for decoupled inner gimbal equilibrium points
Figure 2.19: Clustering evaluation for decoupled outer gimbal equilibrium points
The K-means clustering is an iterative algorithm that partitions all observations into
exactly one of the K groups, or clusters, which is determined by centroids [33]. Ob-
servations are assigned into clusters by minimizing of a cost function given by Eq.
2.78.
n X
X k
J= uij d(xj , ci ) (2.78)
j=1 i=1
49
In this equation, n is the number of observations, K is the number of clusters, uij ,
giving the membership of xj observation to ith cluster, is an element of K × n par-
tition matrix, xj is the observation, ci is the centroid of ith cluster and d(xj , ci ) =
(xj − ci )(xj − ci )T is squared Euclidean distance between the observation xj and the
centroid ci .
In clustering analysis of the equilibrium points of the system models, algorithm gives
cluster centroid points and assigns all equilibrium points into a cluster. After that, dis-
tances of each equilibrium point to the centroid in the cluster are calculated and the
one equilibrium point set which is closest to centroid is selected in order to linearize
the system.
ẋ = Ax + Bu + Gw (2.79)
y = Cx + P w + n (2.80)
50
State equation (Eq. 2.49) may be written as a Taylor series about equilibrium points.
ẋ = f (x, u, w) = + f (xe , ue , we )
∂f ∂f ∂f
+ δx + δu + δw
∂x ∂u ∂w
1 ∂ 2f 2 1 ∂ 2f 2 1 ∂ 2f 2
+ δ + δ + δ + ...
2! ∂x2 x 2! ∂u2 u 2! ∂w2 w
where deviation variables are
δx = x − xe
δu = u − ue
δw = w − we
In this equation, ẋe = f (xe , ue , we ) = 0 and the higher-order derivative terms are
neglected because these derivatives are multiplied by very small variations raised to,
at least second power. State equation of the LTI system can be written by Jacobian
linearization method as follows:
where state matrix A, control input matrix B and disturbance state matrix G are:
∂f1 ∂f1
∂x1
... ∂xn
∂f
A= =
... ... ...
∂x xe ,ue ,we
∂fn ∂fn
∂x1
... ∂xn xe ,ue ,we
∂f1 ∂f1
∂u1
... ∂um
∂f
B= =
... ... ...
∂u xe ,ue ,we
∂fn ∂fn
∂u1
... ∂um xe ,ue ,we
∂f1 ∂f1
∂w1
... ∂wk
∂f
G= =
... ... ...
∂w xe ,ue ,we
∂fn ∂fn
∂w1
... ∂wk xe ,ue ,we
where n is the number of state variables, m is the number of control input variables
and k is the number of disturbance input variables.
51
Taylor series expression of the output equation, given in Eq. 2.50, about the equi-
librium points is:
y = h(x, w, n) = + h(xe , we , ne )
∂h ∂h ∂h
+ δx + δw + δn
∂x ∂w ∂n
1 ∂ 2h 2 1 ∂ 2h 2 1 ∂ 2h 2
+ δ + δ + δ + ...
2! ∂x2 x 2! ∂w2 w 2! ∂n2 n
∂h1 ∂h1
∂w1
... ∂wk
∂h
P = =
... ... ...
∂w xe ,we ,ne
∂hp ∂hp
∂w1
... ∂wk xe ,we ,ne
where n is the number of state variables, p is the number of output variables and k is
the number of disturbance input variables.
According to the clustering analysis explained in previous section, both coupled and
decoupled inner gimbals have two LTI subsystems, on the other hand, decoupled
outer gimbal has three LTI subsystems. Firstly, state space representation of a linear
time invariant subsystem of the coupled gimbal is:
ẋG = AG xG + BG uG + GG wG (2.81)
yG = CG xG + PG wG + nG (2.82)
where xG is 6×1 state vector, uG is 2×1 control input vector, wG is 8×1 disturbance
vector, yG is 4 × 1 measured output vector, nG is 4 × 1 sensor noise vector, AG is
52
6 × 6 constant state matrix, BG is 6 × 2 constant input matrix, GG is 6 × 8 constant
disturbance state matrix, CG is 4 × 6 constant output matrix and PG is 4 × 8 constant
disturbance output matrix.
Secondly, state space representation of a linear time invariant subsystem of the de-
coupled inner gimbal is:
ẋI = AI xI + BI uI + GI wI (2.83)
yI = CI xI + PI wI + nI (2.84)
Lastly, state space representation of a linear time invariant subsystem of the decoupled
outer gimbal is:
ẋO = AO xO + BO uO + GO wO (2.85)
yO = CO xO + PO wO + nO (2.86)
Controllability has a great importance for the control systems in state space. Con-
h i
trollability matrix of the LTI system is defined as B AB A2 B ... An−1 B .
The LTI system, given by Eq. 2.79, may be called completely state controllable if and
only if rank of the controllability matrix is equal to n which is the number of state
variables. Analysis of controllability of LTI subsystems of the coupled and decoupled
gimbals results that all linear subsystems of the gimbals are full state controllable.
53
Even though all LTI subsystems of the gimbals are controllable, it does not guarantee
the controllability of gimbal models. A partially controllable linear system can be
called a stabilizable if its all uncontrollable subsystems are stable or its all unstable
subsystems are controllable [36]. Thus, first, we analyzed the controllability and sta-
bility of all LTI subsystems of the coupled and decoupled gimbals. Result of the these
analyses is that all subsystems of the gimbals are controllable and unstable. Further-
more, it is verified that linear state space models of all gimbals are stabilizable.
54
CHAPTER 3
CONTROLLER DESIGN
The design procedures of the two control methods, cascade PI and linear quadratic in-
tegral (LQI), of the 2-DOF gimbal system are introduced in this chapter. After that, all
controllers are compared between each other and the best performed control method
will be used for target tracking and stabilization. All of these studies are made on the
MATLAB/Simulink platform.
During controller design study, parameters of the cascade PI controller are tuned with
the nonlinear system, which includes friction, static and dynamic mass unbalance,
directly. In contrast, the linear quadratic controllers are designed for the linearized
state space models of both coupled and decoupled gimbals and these controllers are
implemented in the nonlinear system model.
Global linear quadratic integral (LQI) control is used to yield the stabilization and
tracking control problems of the coupled 2-DOF gimbal. Diversely, decoupled inner
and outer gimbals have two separate linear quadratic controllers, called local LQI.
Structure of the LQI controllers for the decoupled gimbals has some difference from
the global LQI controller. Global LQI controller produces two control signals (mo-
tor torques). On the other hand, decoupled gimbals are controlled by own local LQI
compensators.
Angular position references of the inner and outer gimbals are applied as step func-
tions within the first order pre-filters for tracking with less control effort and lower
position overshoot. On the other hand, when we implemented pre-filters of rate com-
55
mands, it has been observed that pre-filters of rate loops have no contribution to the
performance. Controller parameters and cut-off frequency of the pre-filters are tuned
with respect to the aim of achieving the desired conditions which are less than or
equal to 2 seconds settling time, 10% maximum overshoot and 2% settling limit for
position step responses.
It can be said that the most used control strategy in the industrial applications is
proportional integral derivative (PID) control. In many implementations of PID con-
trollers, derivative term is generally set to zero due to raise of the high frequency
sensor noise. In this study, we use only the proportional and integral terms of this
controller. Integral term of the controller overcomes the steady state error for step
responses. In addition, proportional term is used to adjust the system response time
[29].
Cascade PI control consists of one PI controller for position loop to track the tar-
get and one PI controller for rate loop to eliminate disturbances. Block diagram of
56
cascade PI control for the coupled 2-DOF gimbal is given in Figure 3.1. In this sec-
tion, the continuous time position and rate PI controllers are tuned for both gimbals.
Transfer function of the continuous time PI controller is:
Ki
CP I (s) = Kp + (3.1)
s
where Kp and Ki express the proportional and integral gain of controller, respectively.
First step of design procedure is that only PI controllers of the rate loops are tuned
for different Kp and Ki values and the best performed controllers are chosen. After
we designed the rate controllers of the system, position controllers are tuned with
respect to the desired conditions. Lastly, pre-filters are designed for different cut-off
frequency values to decrease overshoot and control effort for tracking.
In cascade PI control design of the inner gimbal for different Kp and Ki values, per-
formances of the rate controllers (Table 3.1, 3.2) and performances of position con-
trollers (Table 3.3, 3.4) are given below. According to these results, when parameters
of rate controller are selected as Kp = 750 and Ki = 50 and parameters of position
controller are chosen Kp = 8 and Ki = 0.1, position step response has 1.7% over-
shoot, 1.0 seconds settling time and less than 1% steady state error.
Table3.1: Performances of the rate PI controllers of the inner gimbal for different Kp
values (Ki = 50)
Kp Values Overshoot(%) Settling Time(sec) Steady State Error(%)
375 1.7 0.24 <1
500 1.3 0.23 <1
625 1.1 0.23 <1
750 1.0 0.23 <1
1000 1.6 0.23 <1
57
Table3.2: Performances of the rate PI controller of the inner gimbal for different Ki
values (Kp = 750)
Ki Values Overshoot(%) Settling Time(sec) Steady State Error(%)
50 1.0 0.23 <1
100 1.4 0.23 <1
150 1.7 0.23 <1
200 2.1 0.23 <1
250 2.5 0.23 <1
Table3.3: Performances of the position PI controller of the inner gimbal for different
Kp values (Ki = 0.1)
Kp Values Overshoot(%) Settling Time(sec) Steady State Error(%)
7 1.9 1.2 <1
8 1.7 1.0 <1
9 8.2 1.0 <1
10 15.4 1.1 <1
Table3.4: Performances of the position PI controller of the inner gimbal for different
Ki values (Kp = 8)
Ki Values Overshoot(%) Settling Time(sec) Steady State Error(%)
0.1 1.7 1.0 <1
1 3.0 2.1 <1
3 7.7 2.5 <1
5 13.2 2.4 <1
Position performances of the inner gimbal with cascade PI control for different po-
sition references and cutoff frequency values of the pre-filters are given below. It is
clearly seen that, this control method only satisfies all desired conditions if cut-off
frequency of pre-filter is selected 1 Hz. As a result, when we implement the best per-
formed controllers and pre-filter into the inner gimbal model, system responses and
motor torque of the inner gimbal with cascade PI control is shown in Figure 3.2.
58
Table3.5: Position performances of the inner gimbal with cascade PI control for dif-
ferent position commands
Figure 3.2: System responses and motor torque of the inner gimbal with cascade PI
control
In cascade PI control design of the outer gimbal for different Kp and Ki values, per-
formances of the rate controllers (Table 3.6, 3.7) and performances of position con-
trollers (Table 3.8, 3.9) are given below. If parameters of rate controller are selected
as Kp = 300 and Ki = 150 and parameters of position controller are chosen Kp = 5
and Ki = 0.05, position step response has 1.8% overshoot, 1.1 seconds settling time
and less than 1% steady state error.
59
Table3.6: Performances of the rate PI controller of the outer gimbal for different Kp
values (Ki = 150)
Kp Values Overshoot(%) Settling Time(sec) Steady State Error(%)
75 4.4 1.36 <1
150 1.1 0.38 <1
225 0.6 0.33 <1
300 0.5 0.32 <1
375 22.4 3.8 <1
450 26.6 >4 <1
Table3.7: Performances of the rate PI controller of the outer gimbal for different Ki
values (Kp = 300)
Ki Values Overshoot(%) Settling Time(sec) Steady State Error(%)
30 1.9 >4 <1
75 0.7 0.35 <1
150 0.5 0.32 <1
225 1.3 0.31 <1
300 2.8 0.57 <1
Table3.8: Performances of the position PI controller of the outer gimbal for different
Kp values (Ki = 0.05)
Kp Values Overshoot(%) Settling Time(sec) Steady State Error(%)
2 1.9 2.0 <1
3 2.0 1.5 <1
4 1.9 1.2 <1
5 1.8 1.1 <1
Table3.9: Performances of the position PI controller of the outer gimbal for different
Ki values (Kp = 5)
Ki Values Overshoot(%) Settling Time(sec) Steady State Error(%)
0.05 1.8 1.1 <1
0.1 2.5 1.2 <1
0.5 4.8 >4 <1
1.0 8.3 >4 <1
Position performances of the outer gimbal with cascade PI control for different posi-
tion commands are given Table 3.10. Thus, all desired conditions are satisfied with
the pre-filters whose cut-off frequency is 1 Hz for lower than 1.5 rad position ref-
erence. When we implement the best performed controllers and the pre-filter in the
outer gimbal, system responses and motor torque of the outer gimbal with cascade PI
control is shown in Figure 3.3.
60
Table3.10: Position performances of the outer gimbal with cascade PI control for
different position commands
Reference Pre-filter cutoff frequency Overshoot(%) Settling time(sec)
0.5 rad 1.3 1.6
1.0 rad 1.8 1.1
1.5 rad 11.6 2.4
1 Hz
2.0 rad 16.8 2.9
2.5 rad 22.6 >3.0
3.0 rad 30.3 2.6
0.5 rad 2.1 1.0
1.0 rad 18.6 2.9
1.5 rad 24.3 >3
2 Hz
2.0 rad 28.7 >3
2.5 rad 35.0 >3
3.0 rad 41.7 >3
0.5 rad 4.2 >3
1.0 rad 21.4 >3
1.5 rad 28.4 >3
10 Hz
2.0 rad 32.6 >3
2.5 rad 38.2 >3
3.0 rad 46.1 >3
Figure 3.3: System responses and motor torque of the outer gimbal with cascade PI
control
61
3.2 Linear Quadratic Integral (LQI) Control
The main benefits of the LQ controllers are that stability and robustness of system
are guaranteed [41]. Aim of this problem is computing the state feedback gain matrix
K of the optimal control vector u assumed as unconstrained in order to minimize
the quadratic cost function J. In the design procedure of the LQ, it is required that
system model has to be completely state controllable for the existence of u [36].
Block diagram of a linear quadratic (LQ) system is given below.
u = −K(x − xr ) (3.2)
is the energy of states. During the LQ controller design, there is a trade-off between
minimization of these energy terms. If we would like to decrease the energy of control
signal, the energy of states will be increased, or, conversely, large states are obtained
62
by small control signals [19].
AT N + N A − N BR− B T N + Q = 0.
K = R− B T N (3.4)
It is examined that integrator effect exists in none of the linearized subsystems of the
gimbals represented in state space. Hence integrators are inserted in the feed-forward
path between the error signal (ξ̇), which is difference between reference and mea-
sured output signals, and the plant [36]. This configuration is called linear quadratic
integrator (LQI) control which calculates the gain matrix K̂ for the tracking [28].
Figure 3.5: Block diagram of LQI control system with merged gain matrix K̂
In this problem, a new state vector arises by combining of state variables of the system
x and integrator output of the error signal ξ. As seen in Figure 3.6, K̂ gain matrix is
obtained by merging of state feedback gain matrix K and error gain matrix Kξ .
h i
K̂ = K −Kξ
k×(n+m)
In the design procedure, references are chosen as step functions. Hence r(t) =
r(∞) = r for t > 0 and the system is assumed asymptotically stable. As shown
in Figure 3.6, error vector between references and outputs is:
ξ̇ = r − y = r − Cx − P w − n (3.5)
63
Figure 3.6: Block diagram of the LQI control system with separated gain matrix K̂
where ẋe (t) and ξ̇e (t) are state error vectors, ue (t) is control input error vector, we (t)
is disturbance error vector, ne (t) is noise error vector and I1 is the identity matrix.
ẋe (t) and ξ̇e (t) vectors are combined into ze (t) vector. New definition of state equa-
tions with respect to state and input error vectors is:
że (t) = Âze (t) + B̂ue (t) + V̂ we (t) + Êne (t) (3.6)
G 0
V̂ = , Ê =
−P −I1
(n+m)×j (n+m)×l
where n is the number of state variables of system and m is the number of error signal,
k is the number of control input variables, j is the number of disturbance variables, l
is the number of noise variables. From Eq. 3.4, optimal feedback gain matrix K̂ is:
K̂ = R̂− B̂ T N̂ (3.7)
ÂT N̂ + N̂ Â − N̂ B̂ R̂− B̂ T N̂ + Q̂ = 0.
64
Consequently, the optimal control law of LQ tracking problem can be formulated by:
h i x
e
ue = − K̂ze (t) = − K −Kξ
ξe (3.8)
− Kxe (t) + Kξ ξe
where diagonal terms Q̂ii = (zei )max , R̂jj = (uej )max and ρ express the maximum
value of the state signal, input signal and a positive constant, respectively. The desired
maximum values of position and velocity error states are determined in consideration
of the system performance criteria. During controller design of the gimbal system, ρ
is chosen very small in order to obtain large control inputs.
After we computed the feedback gain matrices for each linearized subsystems of the
coupled and decoupled gimbals, gain scheduling method is used for nonlinear system
model in order to weight control signals of LQI controllers. Total control input of the
nonlinear gimbal system is:
k
X
u(t) = wui (t)ui (t) (3.11)
i=1
where k is the number of subsystems, ui is the control signal of the subsystem i and
wui is the weight constant of the control signal of the subsystem i. Weight constant
65
of the subsystem may be computed by:
1 : di < ε
1
wui (t) = di (t)
: di ≥ ε (3.12)
k
P 1
dj (t)
j=1
where di is the Euclidean distance between the instant values of state variables and
equilibrium points of the subsystem i and ε is a very small positive number. It can be
seen that the sum of all weight constants are equal to 1. In case of di < ε, wui = 1
and weight constants of the other subsystems reach zero.
Mathematical model of the coupled 2-DOF gimbal contains kinematics and dynam-
ics of both inner and outer gimbals. Coupled gimbal model has four inputs and four
outputs: two input-outputs of them are related to the angular positions of each gim-
bal, and the other two input-outputs represents the angular velocity. In this way, to
yield tracking and stabilization control problem of this MIMO system model, a lin-
ear quadratic controller, called global LQI, is designed. In global LQI control, two
control signals (motor torques) are applied to coupled inner and outer gimbal. Block
diagram of coupled 2-DOF gimbal with global LQI controller is shown in Figure 3.7.
Figure 3.7: Linear quadratic integral control structure of a LTI subsystem of the cou-
pled 2-DOF gimbal
66
2.81 and 2.82, is:
ẋG = AG xG + BG uG + GG wG
yG = CG xG + PG wG + nG
and according to the control structure, shown in Figure 3.7, error vector between
references and outputs ξ̇G is:
ξ̇G = rG − yG = rG − CG xG − PG wG − nG (3.13)
Optimal control gain matrix of a LTI subsystem of the coupled gimbal K̂G can be
described by:
h i
K̂G = KG −Kξ G
2×10
Consequently, control input vector of the coupled gimbal can be written as:
uG = − K̂G zG
(3.15)
− KG xG + kG1 ξG1 + kG2 ξG2 + kG3 ξG3 + kG4 ξG4
67
Controller design matrices Q̂G and R̂G are defined by Eq. 3.9 and Eq. 3.10, respec-
tively. The maximum values of the system state and control input variables are given
in Tables 2.5, 2.6.
1
(zGe )2max
1
1
Q̂G =
(zGe2 )2max
..
.
1
(zGe10 )2max 10×10
1
(uGe )2max
R̂G = ρG
1
1
2
(uGe2 )max 2×2
Maximum values of the position error states zGe7 max and zGe8 max are selected 10%
of zGe1 max and zGe2 max . In addition, maximum values of the velocity error states
zGe9 max and zGe10 max are the same with zGe3 max and zGe4 max . Lastly, ρG is tuned
manually in order to get the best performance.
From Eq. 3.11, the sum of the control inputs of all subsystems is:
Angular position commands are applied as step function references within the pre-
filters which are at first order low-pass filters. On the other hand, angular velocity
commands are zero to stabilize the system. When we implemented global LQI con-
trol in the nonlinear gimbal system, performances of the global LQI controller for
different position commands are given in Table 3.11. It can be seen that global LQI
controller satisfies the desired tracking performances for the outer gimbal when cut-
off frequency of the pre-filter is 1 Hz. Likewise if the cut-off frequency of the pre-
filter is increased for the outer gimbal, global LQI controller is unable to control the
system for position commands higher than 2.0 rad. Moreover, inner gimbal has the
best system performances by means of 10 Hz cut-off frequency of the pre-filter. Sys-
tem responses and motor torques of the nonlinear coupled 2-DOF gimbal with global
LQI control are shown in Figure 3.8 and 3.9.
68
Figure 3.8: System responses and motor torque of the outer gimbal with global LQI
control
Figure 3.9: System responses and motor torque of the inner gimbal with global LQI
control
69
Table3.11: Position performances of the gimbals with global LQI control for different
position commands
In control of the decoupled inner and outer gimbals, local linear quadratic integral
(LQI) method is implemented. Different from global LQI control, there are two sep-
arate compensators to control decoupled inner and outer gimbal models having two
inputs and two outputs. Control structures of the decoupled gimbals with local LQI
controllers, gain-scheduling algorithm and LTI subsystems of the gimbals are exam-
ined in this section. Then quadratic controller matrices and cut-off frequencies of
the pre-filters are tuned to satisfy system performance requirements. Similar to the
global LQI control method, angular position commands are applied as step function
references within the pre-filters and angular velocity commands are zero.
70
3.2.2.1 Inner Gimbal
Linear quadratic integral control structure of a LTI subsystem of the decoupled inner
gimbal is given in Figure 3.10.
Figure 3.10: Block diagram of a decoupled inner gimbal control subsystem model
State space representation of linearized decoupled inner gimbal, given by Eq 2.83 and
2.84, is:
ẋI = AI xI + BI uI + GI wI
yI = CI xI + PI wI + nI
ξ̇I = rI − yI = rI − CI xI − PI wI − nI (3.16)
where ξI is integral of error vector and rI is reference vector. Output vector of in-
h iT
tegrator can be separated into two scalar variables ξI = ξI1 ξI2 and new state
xI
vector is: zI = . Hence new state equation of inner gimbal is:
ξI
5×1
71
Optimal control gain matrix of decoupled LTI inner gimbal system K̂I is:
h i
K̂I = KI −Kξ I
1×5
h i
where state feedback gain matrix is KI = kI1 kI2 kI3 and error gain matrix is
h i
Kξ I = kI1 kI2 . Thus control input scalar of inner gimbal is:
uI = − K̂I zI
(3.18)
− KI xI + kI1 ξI1 + kI2 ξI2
Terms of inner gimbal local LQI controller, Q̂I and R̂I , are:
1
(zIe )2max
1
1
Q̂I =
(zIe2 )2max
...
1
(zIe5 )2max 5×5
1
R̂I = ρI
(uI )2max
where parameter values of decoupled inner gimbal and coupled gimbal are the same.
By means of gain scheduling, sum of control inputs of all inner subsystems is:
System performances of the coupled inner gimbal with local LQI controller for dif-
ferent position commands are given in Table 3.12. Results of this analysis show that
coupled inner gimbal has the best performance with local LQI control if cut-off fre-
quency of the pre-filter is chosen as 2 Hz. Motor torque, angular position and velocity
responses of the coupled nonlinear inner gimbal with local LQI control is shown in
Figure 3.11.
72
Table3.12: Position performances of the coupled nonlinear inner gimbal with local
LQI control for different position commands
Figure 3.11: System responses and motor torque of the coupled nonlinear inner gim-
bal with local LQI control
Linear quadratic integral control structure of a LTI subsystem of the decoupled outer
gimbal is given in Figure 3.12. State space representation of linearized outer gimbal,
given by Eq 2.85 and 2.86, is:
ẋO = AO xO + BO uO + GO wO
yO = CO xO + PO wO + nO
73
Figure 3.12: Block diagram of a decoupled outer gimbal control subsystem model
ξ̇O = rO − yO = rO − CO xO − PO wO − nO (3.19)
and optimal control gain matrix of a LTI subsystems of the decoupled outer gimbal
is:
h i
K̂O = kO1 kO2 kO3 −kO1 −kO2
1×5
uO = − K̂O zO
(3.21)
− KO xO + kO1 ξO1 + kO2 ξO2
Controller matrices of the local LQI controller for the decoupled outer gimbal, Q̂O
74
and R̂O , are given below. Values of parameters of the decoupled outer and coupled
gimbals are the same.
1
(zOe )2max
1
1
Q̂O =
(zOe2 )2max
..
.
1
(zOe5 )2max 5×5
1
R̂O = ρO
(uO )2max
Decoupled outer gimbal model consists of three subsystems. By means of gain
scheduling, sum of control inputs of all outer subsystems is:
System performances of the coupled nonlinear outer gimbal with local LQI controller
for different position commands are given in Table 3.13.
Table3.13: Position performances of the coupled nonlinear outer gimbal with local
LQI control for different position commands
75
We can say that the coupled outer gimbal goes to instability when position command
is higher than 2.0 rad for all pre-filters. This controller satisfies the most desired
performance conditions for the coupled outer gimbal if cut-off frequency of the pre-
filter is 1 Hz. Motor torque and system responses of the coupled nonlinear outer
gimbal with local LQI control are shown in Figure 3.13.
Figure 3.13: System responses and motor torque of the coupled nonlinear outer gim-
bal with local LQI control
Before construction study of the virtual world, we have to choose the best performed
control method for nonlinear 2-DOF gimbal in order to stabilize the system and track
the target. During controller design study, parameters of the cascade PI controller
are tuned with the nonlinear system directly. On the other hand, LQI controllers are
implemented in the nonlinear system after their gain matrices are computed for the
linear gimbal models. In this section, we have examined performances of all control
methods for nonlinear 2-DOF gimbal model.
76
First performance comparison of the controllers is about their tracking and stabi-
lization performances when different position commands are applied to the nonlinear
2-DOF gimbal model. Second comparison is about some performance measures re-
lated to the position and rate error signals such as the integrated square error (ISE), the
integrated absolute value of the error (IAE) and the integrated time-weighted absolute
error (ITAE). These performance measures are formulated by:
Z ∞
ISE = e(t)2 dt (3.22)
0
Z ∞
IAE = |e(t)|dt (3.23)
0
Z ∞
IT AE = t|e(t)|dt (3.24)
0
where e(t) represents error signal. In this analysis, a controller having the lowest
measure value of a criterion has the best performance in regard to the criterion.
As it is explained in the previous sections, both global and local LQI controllers are
designed for the linear subsystems of coupled and decoupled gimbals. Although local
LQI controllers are designed for decoupled linear inner and outer gimbal subsystems,
these models are actually coupled in the linearization procedure.
Position performances of inner gimbal with global and local LQI control methods
are given in Table 3.11, 3.12. Analysis of results show that both controllers guaran-
tee the stability of the system and satisfy the desired conditions. In addition, we can
say that global LQI controller with 10 Hz cut-off frequency of the pre-filter has the
best performance. On the purpose of examining the system behaviors in more detail,
system responses and motor torque of the system are simulated for both controllers
in Figure 3.14. As a result, target tracking and elimination of disturbances abilities
of the global LQI position response is better than local LQI controller. Moreover,
although continuous motor torques of both controllers are about the same, local LQI
frequently reaches the peak motor torque values.
77
Figure 3.14: System responses and motor torques of inner gimbal with global and
local LQI control methods
For the outer gimbal control, performance results of global and local LQI controllers
are given in Table 3.11, 3.13, respectively. These tables shows that global LQI con-
troller with 1 Hz cut-off frequency of the pre-filter is only successful method in all
desired conditions. Likewise the best performed local LQI controller with 1 Hz cut-
off frequency of the pre-filter is unstable when position command higher than 2.0
radians is applied to the outer gimbal. Figure 3.15 shows that global LQI has no
overshoot and less settling time than local LQI controller. Further, global LQI elim-
inates disturbances faster than local LQI. Lastly, continuous motor torque values of
both controllers are about the same even though local LQI frequently reaches the peak
motor torques.
78
Figure 3.15: System responses and motor torques of outer gimbal with global and
local LQI control methods
Table3.14: Performance comparison of global and local LQI control with respect to
ISE, IAE and ITAE measures
According to the performance results of the inner gimbal with cascade PI, given in
Table 3.5, and global LQI, given in Table 3.11, global LQI control has no overshoot
and its settling time is less than 1.8 seconds whereas cascade PI satisfies the desired
conditions only if cut-off frequency of the pre-filter is 1 Hz. In Figure 3.16, sys-
tem responses and motor torques of the inner gimbal with both controllers are shown.
When global LQI controller with 10 Hz cut-off frequency of the pre-filter and cascade
79
PI controller with 1 Hz cut-off frequency of the pre-filter are compared, cascade PI
has overshoot for position commands higher than 0.5 rad although settling time and
rise time of the cascade PI are lower than global LQI. Furthermore angular velocities
of these methods reach to the zero velocity about the same time.
Figure 3.16: System responses and motor torques of inner gimbal with global LQI
and cascade PI control methods
Position performances of outer gimbal with cascade PI and global LQI control meth-
ods are given in Table 3.10, 3.11, respectively. It is clearly seen that, global LQI
controller with 1 Hz cut-ff frequency of the pre-filter is only compensator satisfying
the desired conditions for all position commands. When we applied position com-
mands higher than 1.0 rad to the outer gimbal with cascade PI, position outputs of
gimbal have overshoot higher than %10 and their settling times rise. Position out-
puts, velocity outputs and motor torques of the outer gimbal with both controllers are
shown in Figure 3.14.
80
Figure 3.17: System responses and motor torques of the outer gimbal with global LQI
and cascade PI control methods
Table3.15: Performance comparison of global LQI and cascade PI control with re-
spect to ISE, IAE and ITAE measures
Comparison of the global LQI and cascade PI controllers with respect to the perfor-
mance criteria is given in Table 3.15. Outer gimbal position, outer gimbal velocity
and inner gimbal velocity performances of the global LQI controller is better than
cascade PI controller. In spite of that cascade PI is seen more successful than global
LQI for the inner gimbal.
81
3.3.3 Conclusion
In this chapter, cascade PI and linear quadratic integral control methods are compared
between each other. Decoupling of the inner and outer gimbals is examined in Sec-
tion 2.7. Result of this examination shows that our decoupling approaches are unable
to respond with the same coupled 2-DOF gimbal. Although we can not obtain real-
istic decoupled models via these approaches, designed local LQI controllers satisfies
the desired conditions for some position commands. When we compared global and
local LQI controllers, it is clearly seen that stabilization and tracking performances
of the global LQI is more successful than local LQI’s. If global LQI control method
is implemented in the nonlinear system model the 2-DOF gimbal with 10 Hz cut-off
frequency of the prefilter for inner gimbal and 1 Hz cut-off frequency of the pre-filter
for outer gimbal, outputs of both gimbals satisfy the desired conditions for all posi-
tion commands.
When we compare cascade PI and global LQI control methods, both approaches are
very successful and compatible in order to use in system simulator. Global LQI con-
trol has the lowest overshoot and settling time for step position commands and it
reaches to zero velocity in a short time. Further, global LQI is the most successful
controller with respect to the performance measures except position response of the
inner gimbal. Even though global LQI controller overcomes target tracking and sta-
bilization requirements, it has slow rise time so this control method is unable to give
quick responses against instant changes of the position commands. Unlike global
LQI, cascade PI controllers have the fastest position responses and their rise times
are rather short. In addition, cascade PI controllers can handle disturbances in a short
time and position performance of them are in desired conditions for lower position
commands. In flight scenarios of the target for this study, position commands are
lower than 0.5 rad and rise time, settling time and elimination of disturbances contain
more importance. As a result, cascade PI control with pre-filters providing the best
performance is preferred to be implemented in control system for system simulator
although the other controllers are very successful.
82
CHAPTER 4
The main aim of building a virtual reality world is realization of the system scenarios
when a plane is tracked by the gimbal looking from a distance and platform motion is
carried out in the gimbal base. Structure of simulation framework is shown in Figure
4.1.
Video output of the VRML sink produces images in sequence and each image is used
by target tracking algorithm with the discrete Kalman filter [9]. Tracking algorithm
computes angular position commands for the gimbal and later position responses of
the system is converted to the orientation of camera view in the VRML coordinate
system. Simulink blocks of control system, tracker algorithm, VRML sinks and the
other functions are shown in Figure B.6.
83
4.1 Construction of the Virtual World
Virtual Reality Modeling Language (VRML) is a file format, which is saved with .wrl
file extension, for visualizing interactive 3-D virtual worlds. On the purpose of creat-
ing and modifying the virtual worlds, VREALM Builder [32] produced by MATLAB
is used in this study. The objects in a virtual world can be created by MPEG im-
ages, MIDI data, 3-D aggregates and their interactions [45]. Libraries of VREALM
Builder give lots of options for inserting navigation screens, backgrounds and various
objects. In order to simulate the sky and ground in the virtual worlds, at background
objects defining a color backdrop can be implemented. In addition, some features
of the objects such as scale, translational position and orientation can be modified
both statically and dynamically. In this study, scale and orientation of all objects are
described as static. On the other hand, translational position of the plane is changed
dynamically in order to move the target.
VRML coordinate system on MATLAB/Simulink (Figure 4.3) and the earth coordi-
nate system are identical. Objects are placed farther or nearer from the point of view
on the z axis and altitude of objects are pointed on the y axis. In addition, rotation
angles are described by the right hand rule. Units of all translation distances and an-
84
gular measurements are in meters and radians, respectively [32].
Viewpoints are used to display the objects from different position and orientation.
There are two types of viewpoint options: Static viewpoint is independent from the
objects and its position and orientation remains the same during simulation whereas
dynamic viewpoint can move at both, tranlationally and rotationally [32]. In this
study, camera view must be the dynamic viewpoint on the purpose of orienting the
gimbal to the target.
Initial distance between the virtual world and the camera view, camera orientation
and field of view (FOV) can be determined by viewpoints. The gimbal is located
away at constant 5000 meters from the plane along the +z axis and initial position of
the center of the camera view is (0, 0) on the horizontal and vertical axes. The plane
flies along the horizontal and vertical axes of the virtual world and initial position of
the plane is (x, y, z) = (-2000, 1500, 0) in meters. The other objects such as apart-
ments, houses, markets etc. are located arbitrarily. Appearance of the virtual world
from the camera is shown in Figure 4.4.
85
Figure 4.4: Appearance of the virtual world from the camera
The Kalman filter which looks for the target in a search window, centered in the
predicted value of the filter, is a very efficient method for tracking [11]. In this study,
it uses the measurement which is the real position of the target and estimates the ve-
locity and position of the target. Besides, the constant velocity model is used for the
86
motion model of the Kalman filter. The state and the output equations are formulated
by:
xk+1 = Axk + wk (4.1)
yk = Cxk + vk (4.2)
where xk is the state vector, A is the state matrix, wk ∼ N (0, Q) is the process noise,
yk is the measurement vector, C is the measurement matrix and vk ∼ N (0, R) is the
measurement noise. When a constant velocity model is implemented, the system
matrices given in Eq. 4.1 and Eq. 4.2 are:
1 0 0.02 0
0 1 0 0.02 1 0 0 0
A= , C= (4.3)
0 0 1 0 0 1 0 0
0 0 0 1
Kalman filter starts with initial covariance and state values. It predicts the state and
covariance based on the equations given in 4.4 and 4.5.
In our cases, the initial state estimation error covariance matrix is:
100 0 0 0
0 100 0 0
0 0 10000 0
0 0 0 10000
87
Then, Kalman filter uses the measurement to update the filter based on the equations
given in 4.6 and 4.7 [9].
There are two VR sink blocks using the same .wrl file in simulation: One of them is
used to produce the images in sequence on the purpose of detection and estimation of
the moving target via target tracking algorithm. Besides the camera can be oriented
to the target by means of the other VR sink block. As explained in Section 4.1,
location of the camera is (0, 0, 5000) and initial location of plane is (-2000, 1500, 0)
in the direction of x, y and z axes, respectively. When we implemented the tracking
algorithm in the system simulator, the flight of the target and trajectory of the outputs
of the algorithm are shown in the Figure 4.5. Position of the plane and estimation of
the tracker algorithm are simulated in Figure 4.6. It is clearly seen that the tracking
algorithm captures the object in the image and estimates position and velocity of the
target successfully.
88
Figure 4.5: Trajectories of the outputs of the tracker algorithm
Figure 4.6: Position of the moving plane and estimation of the target tracking algo-
rithm
Output of the tracker algorithm expresses the estimated translational position of the
plane. In order to compute angular position references of the gimbal, these locational
89
data must be projected onto the angular displacements. Projection of LOS onto the
virtual world is shown in figure 4.7.
From Figure 4.7, angular position references of outer and inner gimbals, expressed
by ηref and ref , respectively, can be formulated by:
xEst.P laneLoc x
Est.P laneLoc
ηref = tan = tan
zEst.P laneLoc 5000
yEst.P laneLoc y
Est.P laneLoc
ref = tan = tan
zEst.P laneLoc 5000
According to the performance comparison of cascade PI, global and local linear
quadratic control methods in Section 3.3, cascade PI control has the best stabiliza-
tion and positioning performance for the flight scenario of the target. Hence cascade
PI is implemented in the visual tracking simulator. When angular tracker position
commands are applied to the nonlinear gimbal model containing platform motions
and sensor noise, system responses and motor torques of both outer and inner gim-
bals are shown in Figure 4.8 and 4.9, respectively.
90
Figure 4.8: System responses and motor torque of outer gimbal when the system
tracks a target in a virtual world
Figure 4.9: System responses and motor torque of inner gimbal when the system
tracks a target in a virtual world
91
After tracker commands ηref and ref are computed and applied to the coupled 2-
DOF gimbal model, angular position responses of outer (η) and inner () gimbals are
converted to the translational positions in the virtual world in order to view the target
in the center of camera screen. Conversion of angular position responses of gimbals
to the translational positions are computed by:
It must be stated that the center of the camera view is oriented by the translational
projection of the outputs of the gimbal system onto the virtual world, or namely LOS,
if the positions of the LOS is applied to the VR sink block. Virtual camera view of a
2-DOF gimbal tracking a plane is shown in Figure 4.10.
Figure 4.10: Virtual camera view of a 2-DOF gimbal system tracking a plane
In this figure, red point with a 80-by-80 pixel black square expresses the center of the
92
camera view and 60-by-60 pixel green square refers to the track gate. As a conclusion,
we have constructed a realistic system simulator having a detailed system model,
control method rejecting disturbances and pointing to the target, tracker algorithm
detecting and estimating position and velocity of the target and a virtual reality world
to observe flight scenarios.
93
94
CHAPTER 5
This chapter is organized in a summary of the main results of this thesis and some
recommendations for future studies have been suggested.
5.1 Summary
Simulation environment gives lots of opportunities for control system designers. For
instance, system scenarios can be replicated multiple times, since computational times
of simulations are very short and obtaining desired data using encoders and gyro-
scopes is very easy. This study focuses mainly on the detailed mathematical modeling
of a 2-DOF gimbal on the purpose of obtaining a mathematical model as realistic as
possible. The other purpose is to design different controllers and compare their per-
formances. Finally, the best controller have been tested for its tracking performance
in a virtual world. Parameters of the system model are obtained by a CAD analysis,
because the physical system is yet to be constructed. It is to be noted that certain
assumptions have been made in modeling, controller design and visualization of the
virtual world.
Chapter 2 focuses on the detailed mathematical model of the gimbal system on the
purpose of observing disturbance effects and obtaining a realistic system model by
using Newton-Euler approach. Nonlinear effects of this system are friction between
inner and outer gimbals, friction between outer gimbal and gimbal base, static and dy-
namic mass unbalances of inner and outer gimbals, motor friction and torque ripple.
95
Before dynamic equations and nonlinearities are formulated, first, reference frames
and transformation matrices of this system are described. By means of transformation
matrices between each reference frame, angular velocity and acceleration variables of
frames are expressed. Then Dahl friction model is determined to be the most conve-
nient model. In modeling of a DC brushed actuator, ripple torque and Coulomb fric-
tion torque are added to the basic motor model having electrical and mechanical parts.
After kinematic equations are obtained, motor and friction models are expressed, dy-
namic equations of gimbal are written and system model is constructed. Apart from
this conventional approach, modern control theory allows to construct a MIMO sys-
tem model in state space. Therefore coupled 2-DOF gimbal, decoupled inner and
decoupled outer gimbals are represented in state space to determine which approach
is more convenient in control studies. Platform motions, sensor noise, kinematic and
dynamic equations are defined in state space except motor models. After nonlinear
models of gimbal are written in state space, linearization has been performed around
too-many equilibrium points, which are clustered according to their similarities by
means of the K-means algorithm and Calinski-Harabatz criterion. As a result, there
are two LTI subsystems of both coupled 2-DOF and decoupled inner gimbal and three
LTI subsystems of the decoupled outer gimbal.
96
ing Bryson’s rule allowing to weight state variables and optimal gain matrices K̂ are
computed for all LTI subsystems of the coupled and decoupled gimbals. Next, control
signals are weighted by a gain scheduling algorithm for each subsystem and sum of
their outputs gives the overall system controller outputs. Last step of LQI design is
determining the cut-off frequency of the pre-filter to satisfy the desired performance.
In system simulator study, position commands are lower than 0.5 rad and rise time,
settling time and elimination of disturbances contain more importance. For these
position commands, all control methods have success in stabilization and tracking
problems. Global LQI controller is the most successful controller for higher position
commands. However, cascade PI control has the fast positioning and elimination per-
formances for disturbances for lower position commands. Even though all control
strategies are very successful for lower position commands, cascade PI control with
pre-filters providing the best performance is preferred to implement in control system
for system simulator.
97
5.2 Future Works
This thesis study provides the requirements of system simulation; however there are
still many theoretical and practical matters have been left untouched or not sufficiently
discussed yet. In this section, some recommendations are given so as to obtain more
realistic system simulator and compare their performances with control and tracker
methods mentioned in previous sections.
In the simulation study, there are some assumptions for system model parameters
so controllers are designed for this system models. All of system parameters may be
identified via some optimization algorithms when physical system is completed. Af-
ter system parameters are identified, they are implemented to the system model and
controller can be designed again, theoretical and physical system performances can
be compared between each other to check how realistic system simulator is. If there
are differences between behaviors of physical and modeled systems, modeling study
can be improved to implement the other unknown dynamics on the purpose of taking
advantages of simulation studies.
98
REFERENCES
[3] P. Bliman and M. Sorine. Easy-to-use Realistic Dry Friction Models for Au-
tomatic Control. In Proceedings of 3rd European Control Conference, volume
113, pages 267–272, 1995.
[4] J.-L. Boiffier. The Dynamics of Flight: The Equations, Volume 1. John Wiley
& Sons, 1998.
[7] T. Caliński and J. Harabasz. A Dendrite Method for Cluster Analysis. Commu-
nications in Statistics-theory and Methods, 3(1):1–27, 1974.
[8] R. Carrey and G. Bell. The Annotated VRML97 Reference Manual, 1997.
[11] E. V. Cuevas, D. Zaldivar, and R. Rojas. Kalman Filter For Vision Tracking.
2005.
[12] P. Dahl. A Solid Friction Model. Technical Report, DTIC Document, 1968.
99
[14] C. C. De Wit, H. Olsson, K. J. Astrom, and P. Lischinsky. A New Model for
Control of Systems with Friction. Automatic Control, IEEE Transactions on,
40(3):419–425, 1995.
[15] D. Domínguez. VRML and Simulink Interface for the Development of 3-D
Simulator for Mobile Robots. In Proceedings of World Academy of Science,
Engineering and Technology, volume 25. Citeseer, 2007.
[16] B. Ekstrand. Equations of Motion for A Two Axes Gimbal System. Aerospace
and Electronic Systems, IEEE Transactions on, 37(3):1083–1091, 2001.
[23] X. Jianbo and L. Jingwei. Moving Target Tracking Algorithm Based on Scale
Invariant Optical Flow Method. Information Science and Control Engineering
(ICISCE), 2016 3rd International Conference on, pages 468–472, 2016.
[25] P. J. Kennedy and R. L. Kennedy. Direct Versus Indirect Line of Sight (LoS)
Stabilization. Control Systems Technology, IEEE Transactions on, 11(1):3–15,
2003.
100
[27] H. Khodadadi, M. R. J. Motlagh, and M. Gorji. Robust Control and Modeling
a 2-DOF Inertial Stabilized Platform. In Electrical, Control and Computer En-
gineering (INECCE), 2011 International Conference on, pages 223–228. IEEE,
2011.
[29] C. Knospe. PID Control. IEEE Control Systems Magazine, 26(1):30–31, 2006.
[31] Mathworks. Computer Vision System Toolbox User’s Guide. Accessed: 2016-
11-05.
[33] Mathworks. Statistics and Machine Learning Toolbox User’s Guide. Accessed:
2016-11-03.
[35] K. I. Motor. Direct Drive DC Motors Catalogue. Radford, VA, USA: Kollmor-
gen Corporation.
101
[42] E. Sincar. Friction Identification and Compensation in Stabilized Platforms.
Master’s Thesis, METU, 2013.
[43] K. Xia, J. Lu, C. Bi, Y. Tan, and B. Dong. Dynamic Commutation Torque-ripple
Reduction for Brushless DC Motor Based on Quasi-z-source Net. IET Electric
Power Applications, 2016.
102
APPENDIX A
103
αdistOz = − θ̈ sin φ + ψ̈ cos φ cos θ
+ ψ̇ θ̇(cos φ cos θ sin η sin φ − sin2 φ sin θ + cos η cos2 φ sin θ)
+ φ̇(ψ̇(cos φ cos θ sin φ − sin φ sin θ) + θ̇ cos2 φ)
where αdistIx representing the disturbance acceleration effect on the x axis of inner
gimbal is:
where αdistIy representing the disturbance acceleration effect on the y axis of inner
gimbal is:
104
αdistIy = − φ̈ sin η + ψ̈(cos η cos θ sin φ + sin η sin θ) + θ̈ cos η cos φ
− φ̇θ̇ sin η + η̇ φ̇ cos η + φ̇θ̇ cos2 φ sin η + ψ̇ θ̇ cos2 η cos φ sin φ sin θ
+ η̇ θ̇ cos φ sin η − η̇ ψ̇ cos η sin θ + φ̇θ̇ cos η cos φ sin φ
+ η̇ ψ̇ cos θ sin η sin φ − φ̇ψ̇ cos η cos2 φ cos θ − ψ̇ θ̇ cos η cos φ cos θ sin η
+ φ̇ψ̇ cos φ cos θ sin η sin φ + ψ̇ θ̇ cos η cos φ sin φ sin θ
− ψ̇ θ̇ cos η cos2 φ cos θ sin η
where αdistIz representing the disturbance acceleration effect on the z axis of inner
gimbal is:
105
A.2 Dynamic Equations
Firstly, dynamic equations of outer gimbal can be written as three scalar equations
by Eq. 2.36. Dynamic equations of inner gimbal on x, y and z axes with respect to
angular velocity and acceleration terms are given below, respectively.
I I I I I I
Ixx αIex + Ixy αIey + Ixz αIez − ΩIez (Ixy ΩIex + Iyy ΩIey + Iyz ΩIez )
I I I (A.7)
+ ΩIey (Ixz ΩIex + Iyz ΩIey + Izz ΩIez )
= −gmI rP GIy (cos() cos(θ) − sin() sin(θ))
I I I I I I
Ixy αIex + Iyy αIey + Iyz αIez + ΩIez (Ixx ΩIex + Ixy ΩIey + Ixz ΩIez )
I I I
− ΩIex (Ixz ΩIex + Iyz ΩIey + Izz ΩIez )
(A.8)
= TmI + Tf rOI + gmI rP GIx (cos() cos(θ) − sin() sin(θ))
+ gmI rP GIz (cos() sin(θ) + cos(θ) sin())
I I I I I I
Ixz αIex + Iyz αIey + Izz αIez − ΩIey (Ixx ΩIex + Ixy ΩIey + Ixz ΩIez )
I I I (A.9)
+ ΩIex (Ixy ΩIex + Iyy ΩIey + Iyz ΩIez )
= −gmI rP GIy (cos() sin(θ) + sin() cos(θ))
Secondly, in order to obtain dynamic equations of the outer gimbal, Eq. 2.47 is de-
scribed as three scalar equations. Dynamic equations of the outer gimbal on x, y and
z axes with respect to angular velocity and acceleration terms are given below, re-
spectively.
O O O
Ixx αOex + Ixy αOey + Ixz αOez
I I I I I I
+ αIex (Ixx cos − Ixz sin ) + αIey (Ixy cos − Iyz sin ) + αIez (Ixz cos − Izz sin )
I O I O I O
− ΩOez (Ixy ΩOex + Ixy ΩOex + Iyy ΩOey + Iyy ΩOey + Iyz ΩOez + Iyz ΩOez )
O O O I I
+ ΩOey (Ixz ΩOex + Iyz ΩOey + Izz ΩOez + ΩOex (Ixz cos + Ixx sin )
I I I I
+ ΩOey (Iyz cos + Ixy sin ) + ΩOez (Izz cos + Ixz sin ))
I I I I
+ ΩIex (I
˙ xz cos + Ixx sin ) + ΩIey (I
˙ yz cos + Ixy sin )
I I
+ ΩIez (I
˙ zz cos + Ixz sin )
= g(m0 + m1)((sin η sin θ + cos η sin φ cos θ)rP GOz − (cos φ cos θ)rP GOy )
(A.10)
106
I O I O I O
Ixy αIex + Ixy αOex + Iyy αIey + Iyy αOey + Iyz αIez + Iyz αOez
O O O I I
+ ΩOez (Ixx ΩOex + Ixy ΩOey + Ixz ΩOez + ΩOex (Ixx cos − Ixz sin )
I I I I
+ ΩOey (Ixy cos − Iyz sin ) + ΩOez (Ixz cos − Izz sin ))
O O O I I
− ΩOex (Ixz ΩOex + Iyz ΩOey + Izz ΩOez + ΩOex (Ixz cos + Ixx sin )
I I I I
+ ΩOey (Iyz cos + Ixy sin ) + ΩOez (Izz cos + Ixz sin ))
= g(mO + mI )(cos φ cos θrP GOx − (− cos η sin θ + sin η sin φ cos θ)rP GOz )
(A.11)
O O O I I I I
Ixz αOex + Iyz αOey + Izz αOez + αIex (Ixz cos + Ixx sin ) + αIey (Iyz cos + Ixz sin )
I I
+ αIez (Izz cos + Ixz sin )
I O I O I O
+ ΩOex (Ixy ΩOex + Ixy ΩOex + Iyy ΩOey + Iyy ΩOey + Iyz ΩOez + Iyz ΩOez )
O O O I I
− ΩOey (Ixx ΩOex + Ixy ΩOey + Ixz ΩOez + ΩOex (Ixx cos − Ixz sin )
I I I I I I
+ ΩOey (Ixy cos − Iyz sin ) + ΩOez (Ixz cos − Izz sin )) − ΩIex (I
˙ xx cos − Ixz sin )
I I I I
− ΩIey (I
˙ xy cos − Iyz sin ) − ΩIez (I
˙ xz cos − Izz sin )
= TmO + Tf rBO + Tf rIO + g(mO + mI )((− cos η sin θ + sin η sin φ cos θ)rP GOy
− (sin η sin θ + cos η sin φ cos θ)rP GOx )
(A.12)
107
108
APPENDIX B
SIMULINK BLOCKS
109
Figure B.3: Simulink block of a brushed DC motor model
Figure B.5: Simulink block of outer gimbal cascade PI control rate loop
110
B.3 System Simulator
111