Академический Документы
Профессиональный Документы
Культура Документы
Page 1 of 35
Abstract
Page 2 of 35
Table of Contents
Acknowledgment........................................................................................................ 1
Abstract...................................................................................................................... 2
List of Figure............................................................................................................... 4
List of Tables............................................................................................................... 5
Introduction................................................................................................................ 6
Open loop................................................................................................................ 6
Closed loop.............................................................................................................. 7
Objective.................................................................................................................... 8
Research and control design:..................................................................................... 9
System modeling:.................................................................................................... 9
Mathematical modelling........................................................................................ 10
Open Loop Transfer Function.............................................................................. 12
Closed loop transfer function............................................................................. 12
Design simulation and analysis................................................................................ 14
Original system analysis........................................................................................... 15
Open loop response........................................................................................ 15
Close loop response........................................................................................ 15
Stability.................................................................................................................... 18
Control System Design and Analysis........................................................................19
Compensator......................................................................................................... 19
Designing of PID Controller:.................................................................................. 20
Results of PID Controller........................................................................................ 24
Discussion................................................................................................................ 26
Conclusion................................................................................................................ 28
References................................................................................................................ 29
Page 3 of 35
Appendixes............................................................................................................... 30
List of Figure
Figure 1: description of the control system (Nise, 2011).................................3
Figure 2: open loop control system..................................................................4
Figure 3: closed loop control system................................................................5
Figure 4: Description of pitch control system. (Chegg, 2016)..........................6
Figure 5: Force, moments and velocity definition in body fixed coordinate.....7
Figure 6: open loop transfer function in MATLAB...........................................10
Figure 7: Close loop transfer function in MATLAB..........................................10
Figure 8: Codes of closed loop response syste..............................................10
Figure 9: open loop response original system................................................11
Figure 10: Close loop response original system.............................................11
Figure 11: Steady state from command window of MATLAB..........................13
Figure 12: poles location................................................................................14
Figure 13: PID compensator...........................................................................15
Figure 14: The step responce of PID compensted system.............................17
Figure 15: The step response for the original system and the compensated
system...........................................................................................................18
Page 4 of 35
List of Tables
Page 5 of 35
Introduction
Page 6 of 35
give a desired output. There are two types of control system open-loop
control systems and a closed-loop control systems.
Open loop
Open loop control system (a non-feedback control system) is a control
system in which the control action is totally independent of output of the
system then it. Manual control system is also an open loop control system.
Figure (2) shows the block diagram of open loop control system in which
process output is totally independent of controller action.
Closed loop
Closed loop control system can be defined as control system in which the
output has an effect on the input quantity in such a manner that the input
quantity will adjust itself based on the output generated. Open loop control
system can be converted in to closed loop control system by providing a
feedback. This feedback automatically makes the suitable changes in the
output due to external disturbance. In this way closed loop control system is
called automatic control system (Johan, 2016). Figure (3) shows the block
diagram of closed loop control system in which feedback is taken from
output and fed in to input.
Page 7 of 35
Figure 3: closed loop control system
Objective
The main objective of this assignment is to design a pitch control system for
aircraft. Design consideration as following:
Page 8 of 35
Research and control design:
System modeling:
Figure 4 shows the physical modeling design of the angles of elevator and
pitch which the elevator angle represent the input while the output is pitch
angle .Also shows the basic coordinate axes and forces acting on an aircraft.
Page 9 of 35
of aircraft system. Aerodynamic torque component for roll, pitch and yaw
axis is denoted as L, M and N terms P, Q, R representative of angular rate
about roll, pitch and yaw axis item u, V, W designates a roller velocity
component, pitch and yaw axis. and are expressed as an attack and
sideslip angle (Nelson, R.C., 1998).
Mathematical modelling
Model is a mathematical representation of a physical, biological or
information system. Models allow us to reason about a system and make
predictions about who a system will behave. In this section, it will be mainly
interested in models describing the input and output behavior of systems
and often in so-called state space form. Moreover, the first step in the
control design process is to develop appropriate mathematical models of the
system derived either from physical laws or experimental data. Therefore, in
this part it will be introducing the state-space and transfer function
representations of dynamic systems."
Page 10 of 35
Z mgC C m(w pv qu)
(2)
M = Iy q + rq(Ix Iz ) + Ixz (p2 r2)
.(3)
It is required to completely solved the aircraft problem with considering the
following assumption:
P = S .. ..(Rolling rate)
r = C C S( Pitching rate)
u u o u v vo v w w o w u uo u
v vo v w wo w p=p0+p q=q0+q
r=r0+r X=X0+X M=M0+MY Z=Z0+Z
= 0 +
Therefore, for convenience the reference flight condition is assumed to be
symmetric and the propulsive forces are assumed to remain constant. This
means that:
v0 = p0 = q0=r0 = 0 = w0 = 0.
Page 11 of 35
( dtd X ) u Xw w+( g cos ) =Xe e
(4)
-Zu u = [ (1Zw )
d
dt ]
Zw w - [ (uo +Zq )
d
dt ]
g cos o =Ze e
.(5)
.(6)
MZe MZe MZ
q (S ) 1
=
(
Me+
u0
S
u0
u0 ) ( )
e(S) s 2 Z ZMq
(
S Mq + M+
u0
S+
u0
M ) ( )
Page 12 of 35
Xw = 0 Zw = 0 Mw = -0.05
Angle of Attack X = 0 Z = -355.42 M = -8.8
X = 0 Z = 0 M = -0.8976
Pitching Rate Xq = 0 Zq = 0 Mq = -2.05
Elevator X e =0 Z e = -28.15 M e = -11.874
Deflection
1.151 s+0.1774
G(s)=
S + 0.7391 S2 +0.921 S
3
Open loop transfer function is same as the main transfer function that was
obtained above which is given as following:
1.151 s+0.1774
G(s)=
S + 0.7391 S2 +0.921 S
3
G(S)
Formula of unity closed loop transfer function is: Gc(S)=
1+G(S )(1)
Where;
Page 13 of 35
By substitution the open loop transfer function G(S) into closed loop transfer
function formula above, the closed loop transfer function can be seen in the
following equation below:
1.151 s+0.1774
Gc(s)= 3 2
S +0.7391 S +2.072 S+0.1774
Page 14 of 35
Design simulation and analysis
A program was created to analyze the optimal values of the pitch and the
elevator angel. But, before it have been start testing student need to choose
an input to the system. Surely, in reality the input is random, but a random
input will make the system impossible to analyze. Because the input will
keep changing and therefore determining any improvement by changing
values of elevator deflection angle delta which was chosen to to be 0.2 rad
(11 degrees). Hence, we need a constant input. Figure (6)shows the open
loop transfer function in command window of MATLAB.
The coding for closed loop transfer function is similar to open loop transfer
function. In addition, the function feedback (name of open loop system,
type of the feedback) is used to find out the closed loop transfer function.
Due to the unity feedback the type of feedback was used as 1. Figure 7
shows the close loop transfer function in command window of MATLAB after
it have been add the feedback to the the transfer function.
Page 15 of 35
Figure 8: Codes of closed loop response system.
Page 16 of 35
Figure 10: Close loop response original system
In general, the steady-state error is the difference between the input and the
output on the system. SSE can be used to define the accuracy of the system
response respect to the input. The steady-state error is depends on the type
of the input used and the type of the system.
N (s)
The system type can be defined using formula: G ( s )= By comparing
S n D( s)
the system type formula with the transfer function obtained in part 1, it
shown that no s can be factored from the denominator, which mean the
system type for the transfer function is type 0.
Table 1 shows the value of steady state error (ess) respects to the system
type. Steady-state error for every system type respect to step, ramp and
parabolic can be obtained.
Page 17 of 35
Table 2: Steady State Error table
In this point, we can conclude that the type 0 system to the ramp and
parabolic inputs will have steady state error (ess) with value of infinite.
To calculate Kp:
Kp=lim Gc( s)
s0
1.151(0)+ 0.1774
Kp = (0)+0.7391(0)+2.072(0)+0.1774
0.1774
Kp = 0.1774
Kp = 1
By substitute the value of Kp that has been obtained above in the following
formula in order to evaluate the steady state error:
1
ess = 1+1 , ess = 0.5000
Page 18 of 35
However, the Figure 11 below from the command window of MATLAB shows
the same values of Kp and steady state that had been calculate.
Stability
Page 19 of 35
Figure 12: poles location
Based on the above graph it can see clearly, there are three poles and one
zero. Therefore, the location of poles and zeros are being in negative side.
That means the system is stable because all poles are located at left side of
plane .Furthermore, the transfer function is a third order system has 3 poles
as shows in the Figure above. All 3 poles are located in the stable region of
the Pole-Zero Map. Based on that, system is stable because all poles are
located at left side of plane (negative plane). Not only that, if you have the
closed loop transfer function of a system, only the poles matter for closed-
loop stability.
Page 20 of 35
output represent the desired response and the actual response respectively.
A control system provides an output or response for a given input or
stimulus. Furthermore, the system will be improved by using the
compensator. A proportional compensator is typically applied in first order
procedures with single energy storage to stabilize the unstable process. The
P controller is used to decrease the steady state error (ess) of any system. If
the gain factor K increases, the steady state error (ess) of the system
reduces. However, despite the reduction, the steady state error of the
system cant eliminate during using P controller. PI compensator is mostly
used to remove the steady state error resulting from P controller. Though, in
terms of the speed of the response and overall stability of the system, it has
an undesirable effect. PD compensator used to increase the stability of the
system, by increasing the numerator of the transfer function (Oscar Liang,
2013)
Page 21 of 35
Figure 13: PID compensator
In this assignment, the controllers with the best performance have been
chosen for this system which is PID. It have been used PID controller to
control the pitch angel which is the output of the system and the elevator
angel which is the input of the system . In order to improve the overshoot
and settling time of this particular system, a PID compensator is needed to
connect to closed loop. The transfer function of the PID compensator is
Gc ( S )=Kp+ KDS+ KI /S
From OS =e / (1 ) x 100
20 =e / (1 ) x 100
20/100 = e / (1 )
Page 22 of 35
e
20
ln ( / (1 2 ))=ln( )
100
20
( )=ln( )
1 2 100
( )=(1.609 )
1 2
( )2=(1.609)2
1 2
2 2
2 = (2.59) ( 1
2 2
2 = 2.59 2.59
2 2
2 + 2.59 =2.59
2
= 0.208
= 0.456
4
n=
0.456 x 3.645
n=0.602 rad /s
Dominant pole
Sd = n+ j n (1 2)
Page 23 of 35
Sd = -(0.456 x 0.602 + j0.602 (10.456 2)
Sd = -1.0974 +j2.1421
2
|Sd| = -1.0974 + 2.14212)
Or
Sd = 2.4068 177.956
D=n=2.4068 rad / s
From =cos
1
=cos
=cos1 0.456
=62.871
Determining beta.
=18062.871
=117.13
Determine magnitude.
1.151 s+0.1774
Gc(s)=
S +0.7391 S 2+2.072 S+0.1774
3
Page 24 of 35
By using calculator to simplify the denominator in order to find the
magnitude:
1.151 s +0.1774
Gc ( S )=
( s+0.0881)(s+0.3255 j 1.382)(s+ 0.3255+ j 1.382)
1.151 sd +0.1774
Gc ( Sd )=
( sd +0.0881)(sd + 0.3255 j1.382)( sd +0.3255+ j1.382)
G ( Sd )=
[ 1.08571+ j 2.4656
(1.0093+ j 2.1421 )(0.7719+ j 0.7601 ) (0.7719+ j3.5241 ) ]
2 2
1.08571 +2.4656
1.0093
( 2+ 2.14212)
0.7719
( 2+ 0.76012)
0.7719
( 2+ 3.52412)
A (d )=
Ad= 0.2912.
Page 25 of 35
2.4656
d=
tan 1 ( 1.08571 )
2.1421 0.761 3.5241
tan 1 ( 1.0093 ) tan ( 0.7719
1
) tan ( 0.7719
1
)
d=66.2323(64.7831+ 135.4259+ 102.3563)
d=117.1261
sin ( d + )
Kp=
Adsin
sin ( 117.1261+117.13 )
Kp=
0.2912 sin117.13
Kp=3.487
sin (d)
KD=
DAdsin
sin ( 117.1261)
K D=
2.4068 x 0.2912 sin 117.13
K D =4.465
Dsin ( d )
KI=
Adsin
Page 26 of 35
KI= 7.996
KI
C ( s )=Kp+ + Kds
s
7.996
C ( s )=3.487 + + 4.465 s
s
8
C ( s ) 3.5+ +4.5 s
s
Graph in Figure 14 shows the step response of close loop system after used
PID control which the system has rise time of 0.0723 seconds, an overshoot
of 1.02%, settling time of 0.117 seconds and a steady state value of 1.
Page 27 of 35
Figure 14: The step responce of PID compensted system.
Table 3: Step response for the original system and the PID compensated system
Table 2 shows the step response for the original system and the PID
compensated system. Its important to note that, the steady state error
appears to be driven to zero and there is no overshoot in the response before
control the system, though the settling time requirements are not met. But,
after control the system the overshoot become 1.02%.
Page 28 of 35
Figure 15: The step response for the original system and the compensated system
Page 29 of 35
Discussion
MATLAB has been used to study the transfer function of the system designed
as well as to design and analyze the controller. By this software the way of
designing and analyzing the controller become too easy comparing to the
hand calculation.
Page 30 of 35
input is 0.2 rad (11 degrees), then the pitch angle will not exceed 0.22 rad,
reaches 0.2 rad within 2 seconds, settles 2% of the steady state within 10
seconds, and stays within 0.196 to 0.204 rad at the steady state. Moreover,
table 3 shows the step response of close loop system befor and after used
PID control which the overshoot less than 10% and the rise time not exceed
2 second.
Table 4: Step response for the original system and the PID compensated system.
Based on the table above, it can be note that the design requirements are
fulfilled by the PID controller design. This is because the response with PID
compensator meets all of the given requirements as given below.
Overshoot = 1.02% < 10%, Rise time = 0.0723 seconds < 2 seconds,
Steady state error = 0.5000% < 2%. Hence, from the mechanical point of
view using a PID with reasonable parameter values is a preferable option.
Based on the results, the system responses indicate the performance of pitch
control system using PID controller has been improved and satisfied
compared to the system response before applied the PID controller .
Page 31 of 35
Conclusion
Page 32 of 35
References
Oscar Liang. (2013). Quadcopter PID Explained and Tuning - Oscar Liang.
[online] Available at: https://oscarliang.com/quadcopter-pid-explained-tuning/
[Accessed 17 Sep. 2016].
Page 33 of 35
Appendixes
Page 34 of 35
sys = tf(num,den);
t= 0:0.01:10; % t is the time in second
system = feedback(sys,1)%to get the transfer function of unity closed loop
step(de*system)
ylabel('pitch angle (rad)')
title('closed loop step response')
3- Closed loop steady state
Step input
close all; clear all; clc;
de=0.2;
num=[1.151 0.1774];
den=[1 0.739 0.921 0];
sys = tf(num,den);
t= 0:0.01:10; % t is the time in second
system = feedback(sys,1)
step(system,t)
'step input';%unit step function
kp = dcgain(system)%to get the value of kp
ess = 1/(1+kp)%steady state error
ylabel('pitch angle (rad)')
title('closed loop step response')
system = feedback(sys,1)
step(de*system)
Kp = 3.5
Ki = 8
Kd = 4.5
C = pid(Kp,Ki,Kd)
controlled = feedback(C*system,1) %the closed loop controlled system
%lsim(system,controlled,r,t)%to plot the the time response of the
subplot(211), step(de*system);%subplt to plot both of the systems separately
%and this function to ploot the closed loop system before control
subplot(212), step(de*controlled)%to plot the time response of the closed loop
%system after control
step(de*controlled)%to get the LTI to chose any type of plotting
%and it used to plot the system and controlled system
Page 35 of 35