Professional Documents
Culture Documents
LinearSystemsControlandVibrationsforMechanicalEngineersbyDr RobertL WilliamsII PDF
LinearSystemsControlandVibrationsforMechanicalEngineersbyDr RobertL WilliamsII PDF
net/publication/312844861
Linear Systems Control and Vibrations for Mechanical Engineers by Dr. Robert L.
Williams II
CITATIONS READS
0 227
1 author:
SEE PROFILE
Some of the authors of this publication are also working on these related projects:
All content following this page was uploaded by Osama Mohammed Elmardi Suleiman Khayal on 25 January 2017.
williar4@ohio.edu
people.ohio.edu/williar4
6. VIBRATIONAL RESPONSES......................................................................................................... 51
Solution
x(t )
5
1252
e50t 25sin 2t cos 2t
0.08
0.06
0.04
0.02
x(t) (m)
-0.02
-0.04
-0.06
-0.08
-0.1
0 1 2 3 4 5 6 7 8
t (sec)
sin 2t 25 C cos
cos 2t 1 C sin
sin 1 1
tan 1 0.04 rad
cos 25 25
B2 xP (t ) B1 sin 2t B2 cos 2t
In general: C B12 B22 tan 1 when
B1 C sin 2t
5
A Final First-Order ODE example R, C series electrical circuit (voltage v(t) input, current i(t) output)
R
+
v(t) i(t) C
-
1
C
Model (from KVL and electrical circuit element table) Ri(t ) i(t )dt v(t )
Given R = 50 and C = 0.2 mF, solve 50q(t) 5000q(t) 1 subject to q(0) 0 and a unit step voltage
input v(t). Solution
q (t )
1
5000
1 e 100t
1
i (t ) q (t ) e 100t
50
-4
x 10
2
1.5
q(t)
0.5
0
0 0.01 0.02 0.03 0.04 0.05 0.06
0.02
0.015
i(t)
0.01
0.005
0
0 0.01 0.02 0.03 0.04 0.05 0.06
t (sec)
As expected from the circuit dynamics, the charge q(t) in the capacitor builds up to a constant
given a constant voltage input.
Also as expected, the capacitor current i(t) goes to zero at steady-state.
The steady state charge value is qSS = 1/5000.
The time constant is = RC = 0.01, so at 3 time constants (t = 0.03 sec) both the q(t) and i(t)
values have approached 95% of their respective final values.
6
2.1.2 Second-Order ODEs
x (0) 0.10m
x(t ) 7x(t) 12x(t ) f (t ) 3u(t)
Solve subject to
x (0) 0.05m / s
1. Homogeneous Solution xH (t ) 6 x H (t ) 9 xH (t ) 0
2. Particular Solution xP (t ) 6 x P (t ) 9 xP (t ) 3
xP (t ) B 0 6(0) 9B 3 so xP (t ) B 1/ 3
3. Total Solution
x(t ) xH (t ) xP (t ) A1e3t A2te3t 1/ 3
x (t ) 3 A1e 3t A2e 3t 3 A2te3t
A1 0.233
A2 0.65
Check solution
Plug answer x(t) plus its two derivatives into the original ODE. Also check the initial conditions.
Plot – check transient and steady state solutions, plus total solution.
8
Second-Order System Example 2 – Forced m-c-k System
x(0) 0.10m
x(t) 6x(t) 9x(t) 3u(t)
x(0) 0.05m / s
s2 6s 9 (s 3)2 0
1
Solution x(t ) (0.233 0.65t )e3t
3
0.3
0.2
0.1
x(t)
-0.1
-0.2
0 1 2 3 4
t (sec)
The total solution x(t) starts at 0.1 m, x (t ) is non-zero, as specified by the initial conditions.
Transient approaches zero after t = 2.5 sec
Critically damped; –3 root goes to zero slightly faster alone than with t
Steady-state value is xSS = 1/3 m.
9
Second-Order System Example 4: Forced m-k System
x(0) 0.10m
x(t) 9x(t) 3u(t)
x (0) 0.05m / s
s 2 9 ( s 3i )( s 3i) 0
4. Transient Response
4.5 System Type
Since only two of these ODEs are familiar in our previous analytical ODE solutions in ME 3012
(the stable first- and stable underdamped second-order systems), let us perform an analytical solution for
one example: the second-order Type I system from above. Solve
for y(t), given that input u(t) is a unit step function and subject to given zero initial conditions y(0) 0
and y(0) 0 .
For fun let us solve this problem in three ways, two alternate methods using the slow ME Way
and also using the Laplace Transform approach. Since this is a linear ODE, all methods must yield the
one correct answer, stated earlier in the Analytical Unit Step Response Solutions table.
1. Homogeneous Solution
y H (t ) sAest
Assume: y H ( t ) Ae st
so that
yH (t ) s 2 Aest
y H ( t ) A1 e s1t A2 e s 2 t A1 e ( 0 ) t A2 e ( 1) t A1 A2 e t
Our standard particular solution assumption of yP (t) B will not work in this case so we immediately
try:
yP (t) B
where B is an unknown constant, which must be determined in this step. Clearly yP (t) 0 and so:
And so the particular solution for velocity is yP (t) B 1. However, we need the particular solution for
y(t), not its first derivative, and so we must integrate:
t t
yP (t) yP (t)dt dt t c
0 0
3. Total Solution
y ( t ) y H ( t ) y P ( t ) A1 A2 e t t c
An alert student may ask, how can we solve for three constants A1, A2, and c with only two initial
conditions? The solution to this little dilemma is quite easy, recognizing that A1 c is simply a single
constant, call it A3 A1 c . Then the total solution is expressed by:
y ( t ) A3 A2 e t t
to which we apply the two given initial conditions y(0) 0 and y(0) 0 in order to solve for the
unknown constants A1 and A3.
y (0) 0
y(0) 0
0 A2e(0) 1
0 A3 A2e(0) (0) y ( t ) A2 e t 1
1 A2 0
A2 A3 0
A2 1
The transient part of this solution is e t and the steady-state part of this solution is t 1 .
To demonstrate the transient and steady-state components of this solution better, it is instructive
to plot this response, both its components and the total solution (which was shown previously, the center
Type I case).
Detailed Plot for Center Type I System Example Unit Step Response
Transient, Steady-State, and Total Responses
13
In order to check this solution, we can first check the resulting initial conditions. From the
solution y (t ) e t t 1 we clearly see that y (0) e0 0 1 1 0 1 0 as required. Also, for the
first derivative of the solution y (t ) e t 1 , we have y (0) e0 1 1 1 0 as required.
A more complete solution check involves substituting the solution y(t) and its two time
derivatives into the original ODE and prove than an equality results.
Since an equality results, 1 = 1, this proves that the solution is the correct one.
14
1b. Slow ME Way – first-order solution
A clever alternate solution method arises (either the Slow ME Way or using Laplace Transforms)
when we use the equivalence v(t) y(t) in the original ODE to be solved. Solve
for v(t), given that input u(t) is a unit step function and subject to given zero initial condition
v(0) y(0) 0 . Then find y(t) by integration, using the second given initial condition y(0) 0 .
1. Homogeneous Solution
The system characteristic polynomial is s1, leading to a system characteristic equation s1 0, whose
one root is s1 1 . The homogeneous solution form is then:
v H ( t ) A1 e s1t A1 e t
2. Particular Solution
Assume vP (t) B , where B is an unknown constant which must be determined in this step. Clearly
vP (t) 0 and so:
3. Total Solution
v ( t ) v H ( t ) v P ( t ) A1e t 1
Applying the given initial condition v(0) y(0) 0 in order to solve for the unknown constant A1:
15
v(0) 0
0 Ae
1
(0)
1
A1 1
v (t ) 1 e t
However, we need the total solution for y(t), not its first derivative v(t), and so we must integrate:
t t
y(t) v(t)dt (1 et )dt t et c
0 0
where c is a constant of integration, that is found by applying the remaining initial condition y(0) 0 .
y (t ) e t t 1
1
s Y (s) s(0) (0) sY (s) (0) s
2
Solve for the variable of interest, Y(s) – the Laplace transform of the answer, y(t).
1
Y (s) 2
s ( s 1)
The partial fraction expansion for this Y(s) is given below, where the constants C1,2,3 are the residues.
1 C sC C
Y (s) 2 1 2 2 3
s ( s 1) s s 1
Equate like powers of s in the numerator to get 3 equations to solve for the residues C1,2,3.
s 2 0 C1 C3 C1 1
s1 0 C1 C2 C2 1
s 0 1 C2 C3 1
y (t ) 1 t e t
which agrees with the solutions we previously derived, but as expected is a more-direct one-stage
process and faster to obtain.
17
5. Controller Design
5.12 Disturbance Evaluation after Controller Design
D(s)
This is called a regulator, where the desired output (reference input) is R(s) = 0.
D(s)
-1
YSENS (s) Y(s)
H(s)
Change this into a diagram that looks more similar to the standard closed-loop feedback diagram.
Y (s) G (s)
TD ( s )
D ( s ) 1 GC ( s ) G ( s ) H ( s )
This is for MATLAB implementation, to simulate the effects of the disturbance input separately.
Then use linear superposition in MATLAB to find the total solution as the sum of the reference input
response (with zero disturbance) plus the disturbance input (with zero reference input).
19
There are possible drawbacks with this method, the biggest being: the order of the closed-loop system
must match the number of controller unknowns. If the number of unknowns is less, there is no solution
(overconstrained) and if the number of unknowns is greater, there are infinite solutions
(underconstrained). In either of the mismatch cases we can use trial-and-error controller design. This
can be frustrating and ineffective since there are n solutions, where n is the number of controller
unknowns. See Section 5.10 in this ME 3012 NotesBook.
Further drawbacks include the need for most standard controllers to add a correction factor for
output attenuation and a pre-filter transfer function GP(s) to cancel the unwanted introduced zero(s).
There is a potentially better method, here called the whole T(s) Matching Controller Design, or
simply the J-Method. This is named after ME student Jason Denhart who, in Spring 2008, posed the
question “Why can’t we just specify the entire numerical T(s) and solve for the exact GC(s) necessary to
provide that T(s)?”
20
The J-Method
Step 1. Analyze the as-given open-loop system behavior.
Step 2. Specify and evaluate the desired behavior for the closed-loop system. This step
yields a numerical desired characteristic polynomial for the T(s) denominator (see Note 1 below),
plus the desired T(s) numerator.
Step 3. State the controller design problem to be solved. The former Step 3 is skipped, i.e.
the J-Method determines the controller form in the solution procedure so there is no need to
assume a standard controller form for GC(s).
Given The plant and sensor transfer functions G(s) and H(s) in the context of our
standard closed-loop negative feedback diagram.
The desired closed-loop behavior, expressed by a whole numerical T(s) (as
opposed to the desired closed-loop characteristic polynomial only as before).
Find The form and the unknowns (gains) of the controller transfer function GC(s).
Step 4. Solve for the unknown controller form including the unknown gains. Use the
standard equation
GC ( s )G ( s )
T (s)
1 GC ( s )G ( s ) H ( s )
Substitute your whole numerical desired T(s), plus the known numerical plant and sensor transfer
functions G(s) and H(s), and solve for the unknown controller transfer function GC(s), without
the need to assume a certain controller form.
T (s)
GC ( s )
G ( s )(1 H ( s )T ( s ))
Notes
1. The order of the denominator of your desired T(s) must be equal or greater than the order of the
denominator of G(s). If the G(s) denominator is of higher order than the T(s) denominator, your
resulting GC(s) will have a higher order in the numerator than the denominator, which is impossible to
implement in MATLAB or Simulink, unless it happens to boil down to a PID form.
2. You do not need a correction factor – this is loaded into your desired T(s).
3. You do not need a pre-filter transfer function GP(s) since we are matching the entire desired T(s).
4. The resulting controller GC(s) will not necessarily be of any recognizable classical controller form.
5. MATLAB was used to help with the algebra (either symbolically or numerically). This should work;
however, problems were encountered with large integers and excessive controller numerator and
denominator orders.
6. If you follow the requirement for T(s) denominator order and make no algebra mistakes, the
performance you obtain will be theoretically identical to a good classical controller with appropriate pre-
filter and correction factor.
7. There are three major drawbacks of the J-Method
The J-Method does not handle disturbances well, as most other controllers do (presented later).
The J-Method requires perfect knowledge of the open-loop plant, which is impossible. Thus, it
is less robust to modeling uncertainties than other controllers.
The J-Method cannot handle unstable open-loop plants (this is no problem for other controllers).
21
Controller Design Example 1 – The J-Method
Step 1. Analyze the as-given open-loop system behavior.
10
This step is the same as in Controller Example 1, with G ( s ) .
s s 10
2
Step 2. Specify and evaluate the desired behavior for the closed-loop system, to achieve 5%
overshoot and 1.5 sec settling time. We have used these performance specifications before; the
associated desired whole closed-loop transfer function is (assuming a final value of 1 is desired from a
unit step input):
14.93
T ( s) 2
s 5.33s 14.93
Step 4. Solve for the unknown controller form including the unknown gains.
1.493( s 2 s 10)
The result is GC ( s )
s ( s 5.33)
What type of controller is this?
How does the J-Method controller work?
22
Step 5. Simulate the resulting closed-loop system performance.
Simulink Evaluation for the J-Method Controller Design Example 1
10
s2 +s+10
Step Plant1
1.493*[1 1 10] 10
s2 +5.33s s2 +s+10
Scope
Step1 Gc Plant2
Let’s do a few of these examples now. Assume unity negative feedback for all examples.
Example 1a
1
Given open-loop plant G ( s ) , ideal sensor transfer function H(s) = 1, and desired whole
s 1
2
T ( s) , determine GC(s) via whole T(s) matching:
s2
2( s 1)
Answer GC ( s ) (what kind of controller is this?)
s
24
Simulink simulation results
The open-loop time constant of = 1 sec is halved to the closed-loop time constant of = 0.5 sec, which
doubles the speed of the closed-loop system to reach 95% of the final value of 1.
25
Example 1b
1
Given open-loop plant G ( s ) , ideal sensor transfer function H(s) = 1, and desired whole
s 1
15
T ( s) , determine GC(s) via whole T(s) matching:
s 6s 15
2
15( s 1)
Answer GC ( s) (what kind of controller is this?)
s( s 6)
26
Simulink simulation results
The open-loop time constant was = 1 sec and the desired closed-loop performance specs of 2.13%
overshoot and 1.38 sec settling time are met in simulation.
27
Example 2a
10
Given open-loop plant G ( s ) , ideal sensor transfer function H(s) = 1, and desired whole
s s 10
2
2
T ( s) , determine GC(s) via whole T(s) matching.
s2
s 2 s 10
Answer GC ( s) (what kind of controller is this?)
5s
This is an exception to the rule that the T(s) denominator must of order equal or greater than the order of
the G(s) denominator, since it is a PID controller.
28
Simulink simulation results
The open-loop behavior is the familiar stable underdamped system and the closed-loop time constant is
= 0.5 sec which allows closed-loop system to reach 95% of the final value of 1 in 1.5 sec, thus meeting
the design goals in simulation.
29
Examples Summary Table
For the combinations of examples considered, the table below summarizes the numerator and
denominator orders using the J-Method. Also given is the resulting form of the controller transfer
function GC(s) (n.r.f. stands for ‘no recognizable form’).
T(s)
a. 1st-order b. 2nd-order c. 3rd-order
1st 1st 1st
1st , PI , Lead/I , n.r.f.
1st 2nd 3rd
2nd 2nd 2nd
2nd st
, PID 1 , n.r.f. , n.r.f.
G(s) 1 2nd 3rd
3rd 3rd 3rd
3rd , n.r.f. 2 , n.r.f. 2 , n.r.f.
1st 2nd 3rd
For the nine example combinations considered, the table below summarizes the resulting
controller transfer functions GC(s) using the J-Method.
T(s)
st
a. 1 -order b. 2nd-order c. 3rd-order
2( s 1) 15( s 1) 450( s 1)
1st s s ( s 6) s ( s 36s 195)
2
1
Exception to the rule that the order of the denominator of your desired T(s) must be equal or greater
than the order of the denominator of G(s).
2
Impossible to implement.
30
In addition to this set of nine examples, the J-Method has been successfully tested with the following
(where the a-c cases represent the same desired closed-loop transfer functions as above).
Integrating open-loop transfer function G(s) (an s can be factored out in the denominator, i.e.
there is no ‘spring’). This is called a Type I system since there is one integrator in the
denominator of G(s), as explained in Section 4.5 of the ME 3012 NotesBook.
10 10
G(s) 2
s s s ( s 1)
s 1 1.5( s 1) 45( s 1)
a. GC ( s ) b. GC ( s ) c. GC ( s)
5 ( s 6) s 36s 195
2
PD Lead n.r.f.
2( s 2 5s 4) 15( s 2 5s 4) 450( s 2 5s 4)
a. GC ( s ) b. G ( s ) c. G ( s )
s 2 6s 6 s 3 10s 2 39 s 45 s 4 40 s 3 339 s 2 1230 s 1350
C C
All examples work as desired – except for the unstable cases which all have numerical instability
problems, with the negative KP gains – the unstable poles cannot be cancelled perfectly. So we
CANNOT use the J-Method for unstable open-loop systems.
31
Note that the full-T(s)-matching J-Method does not experience any problems with handling
open-loop G(s) models with zeroes or higher-order systems. The J-Method controller includes its own
internal pre-filter, identical to the one presented in Section 5.9.
Also, problems of denominator parameter matching with higher-order and lower-order systems
as exposed in Section 5.10 of the ME 3012 NotesBook are not a problem for the J-Method.
For Controller Design Example 1, we first present the output unit step response, followed by the
input effort plot, both in comparison to the open-loop case.
The J-Method requires no pre-filter – its maximum input effort requirement is 1.5 actuator input
units. The J-Method controller does not require a steep rate of change for the actuator input effort.
33
J-Method Controller Disturbance Evaluation
Again for Controller Design Example 1, we now present how well the J-Method rejects
disturbances.
A unit step disturbance was turned on at t = 1 sec. Clearly the J-Method controller is very poor
at rejecting the disturbance in this example. The disturbed J-Method controller overshoots relatively
high, with poor transient dynamics. This disturbed response is heading towards zero steady-state error,
however, given enough time.
The PID controller disturbance rejection presented in Section 5.12 of the ME 3012 NotesBook is
much better than that of the Lead or J-Method controllers in this example. The PID controller was not
designed for disturbance rejection, it just handles the disturbances better.
34
L R n
cL
J L (t)
cM
+ + L (t)
v A (t) v B (t) JM
- - L (t)
i A (t) M (t) L (t)
M (t)
M (t)
We will design a controller to control the load angular velocity L(t). Assume a perfect
tachometer sensor, H(s) = Kt = 1, so there is negative unity feedback. Note that G2(s) = KT, the motor
torque constant, is different from H(s) = Kt, the feedback sensor (tachometer) constant. Here are the
open- and closed-loop feedback control system diagrams.
KB
KB
Kt
1 1
where G1 ( s ) G2 ( s ) K T G3 ( s ) H(s) = Kt = 1
Ls R J E s cE
35
Step 1. Analyze the as-given open-loop system behavior.
Earlier the open-loop transfer function was derived and the real-world parameters for the NASA
ARMII robot shoulder joint were substituted.
KT
L (s) n 5
G ( s ) 2
V A ( s ) Ls R J E s cE K T K B s 11s 1010
11 11
n 1010 31.8 rad/sec 0.173 s1,2 5.5 31.3i
2 n 2 1010
This open-loop system has a different time scale than Controller Design Example 1; its output
L(t) rises much faster in response to a unit step input vA(t). Also, the steady-state value is 5/1010,
whereas it was 1.0 for Controller Design Example 1.
36
First, take a look at the root-locus plots and unit step responses, for the proportional controller GC(s) =
K, first for angular velocity output.
L
Root Locus
50
40
30
20
10
Im
0
-10
-20
-30
-40
-50
-50 0 50
Re
1 1 1
Amplitude
Amplitude
0 0 0
0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1 0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1 0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1
Time (sec) Time (sec) Time (sec)
1 1 1
Amplitude
Amplitude
Amplitude
0 0 0
0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1 0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1 0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1
Time (sec) Time (sec) Time (sec)
K values legend
0 52 96
179 334 622
37
Here are the root-locus plot and unit step responses, for the proportional controller GC(s) = K, for angle.
L
Root Locus
50
40
30
20
10
Im
0
-10
-20
-30
-40
-50
-50 0 50
Re
0.08 0.4
0.5
0.06 0.3
Amplitude
Amplitude
Amplitude
0
0.04 0.2
-0.5
0.02 0.1
-1 0 0
0 0.2 0.4 0.6 0.8 1 0 0.2 0.4 0.6 0.8 1 0 0.2 0.4 0.6 0.8 1
Time (sec) Time (sec) Time (sec)
0.8
1.5 5
0.6
Amplitude
Amplitude
Amplitude
1 0
0.4
0.5 -5
0.2
0 0 -10
0 0.2 0.4 0.6 0.8 1 0 0.2 0.4 0.6 0.8 1 0 0.2 0.4 0.6 0.8 1
Time (sec) Time (sec) Time (sec)
4 11 20
x 10 Step Response x 10 Step Response x 10 Step Response
1 2 1
1.5
0.5 1 0.5
0.5
Amplitude
Amplitude
Amplitude
0 0 0
-0.5
-0.5 -1 -0.5
-1.5
-1 -2 -1
0 0.2 0.4 0.6 0.8 1 0 0.2 0.4 0.6 0.8 1 0 0.2 0.4 0.6 0.8 1
Time (sec) Time (sec) Time (sec)
The closed-loop system becomes unstable for K 2222 ! Clearly the simple proportional controller will
not work, since the angular velocity root-locus plot shows that the closed-loop dimensionless damping
ratio must decrease as K increases.
38
Step 2. Specify and evaluate the desired behavior for the closed-loop system.
To determine the numerical desired characteristic polynomial, let’s try something different:
ITAE third-order. Arbitrarily let n = 5.
DES ( s ) s 3 1.75 n s 2 2.15 n2 s n3 s 3 8.75 s 2 53.75 s 125
The associated desired closed-loop poles from third-order ITAE are 2.60 5.34i , 3.54 .
Step 5. Solve for the unknown gains to achieve the desired behavior for the closed-loop system.
Derive the closed-loop transfer function as a function of the PID controller gains.
5 KD s2 KP s KI 5 KD s2 KP s KI
GC ( s )G ( s ) s s 2 11s 1010 s s 2 11s 1010
T ( s)
1 GC ( s )G ( s ) 5 KD s2 KP s KI s s 2 11s 1010 5 K D s 2 K P s K I
1
s s 2 11s 1010 s s 2 11s 1010
5 KD s2 KP s KI
T ( s)
s s 2 11s 1010 5 K D s 2 K P s K I
5 KD s2 K P s K I
T ( s)
s 3 11 5 K D s 2 1010 5 K P s 5 K I
Match the symbolic form (function of KP, KI, KD) with the numerical ITAE desired characteristic
polynomial.
2 0.01
0 0
-2 -0.01
-4 -0.02
L(t)
L(t)
-6 -0.03
-8 -0.04
-10 -0.05
-12 -0.06
-14 -0.07
-16 -0.08
0 0.5 1 1.5 2 2.5 3 0 0.5 1 1.5 2 2.5 3
t (sec) t (sec)
Open-Loop Open-Loop
Closed-Loop PID Closed-Loop PID, corrected
Again: Controller design can easily make matters worse, if not done properly! With negative KP,
the closed-loop step response initially goes down while open-loop goes up. The is a huge (negative)
overshoot, and the transient response is slower than the open-loop case.
Step 2. Specify and evaluate the desired behavior for the closed-loop system.
So let’s choose a higher n in the third-order ITAE desired closed-loop numerical characteristic
polynomial for faster response and positive KP, KD. KP is the limiting case, i.e. if we force it to be
positive, KD will be positive also.
11 5K D 1.75n
@ KD = 0, n = 6.29, but then KP will still be negative (KP = –185); therefore let us instead set n so
that KP will be positive.
1010 5 K P 2.15 n2 @ KP = 0, n = 21.7
So try n = 30 DES ( s ) s 3 52.5 s 2 1935 s 27000
40
The new associated desired closed-loop poles from third-order ITAE are 15.63 32.04 i , 21.24
Step 5. Solve for the unknown gains to achieve the desired behavior for the closed-loop system.
Denominator parameter matching (fully-decoupled)
s 1 1
3
K D 8.3
s 2 11 5K D 52.5
K P 185 KP and KD are both positive as planned!
s1 1010 5 K P 1935
K I 5400
s 0 5 K I 27000
5
L(t)
0
0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1
t (sec)
Open-Loop
Closed-Loop PID
The controller response is much better with the positive KP and KD, but the third-order bend in
the closed-loop response is not as desired. The desired ITAE response is different, i.e. it doesn’t look
like this closed-loop response. Therefore, we need a pre-filter.
41
Step 8. Include a pre-filter transfer function if necessary.
Two unwanted zeroes were introduced by the PID controller; these can be cancelled by a pre-
filter.
27000
Pre-filter transfer function GP ( s )
42 s 925 s 27000
2
Note we specify the 27000 pre-filter transfer function numerator since the pre-filter shouldn’t attenuate
the output. When we plot the resulting unit step responses we see in the left plot below that the
controller design is now successful.
Open-, PID Closed-, and Pre-filtered Response
-3
x 10
L
-3 Open-, PID Closed-, and Pre-filtered L
Response
8 x 10
5
7 4.5
4
6
3.5
5
3
L(t)
4 L(t)
2.5
3 2
1.5
2
1
1
0.5
0 0
0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1 0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1
t (sec) t (sec)
Open-Loop
Closed-Loop PID
Closed-Loop PID with Pre-Filter
5 27000
T (s) 3
1010 s 52.5s 1935s 27000
2
The final closed-loop unit step response is now theoretically identical to the specified third-order
ITAE behavior. Note with the ITAE specification we didn’t need to specify percent overshoot, settling
time, or peak time.
For this controller, the angle L(t) unit step response in time is given in the right plot above (note
the steady-state error since the closed-loop PID lags the open-loop and the closed-loop PID with pre-
filter lags even further). We just integrated the L(t) response to get these results, i.e. we included
another s factor in the closed-loop system denominator.
42
Step 6. Evaluate the PID controller performance in simulation.
Simulink Model
1
s
V Integrator2
Plant
OmegaL
27000 ThetaL
1
-K- PID
s
42s2 +925s+27000
Reference Integrator
OmegaL Corr Pre-filter PID Controller Plant
The Plant blocks above are Simulink masks for the (identical) open-loop plant shown below.
tau dist
1 1
1 100 -K- 1
s+10 0.1s+0.1
in_1 Km 1/n out_1
RL Circuit Jc rotational dynamics
Kb
43
J-Method Controller
Alternate design method for Term Example L(t) controller design.
Step 2. Specify the desired behavior for the closed-loop system We specify the entire desired closed-
loop T(s), not just the denominator. To determine the numerical desired entire closed-loop T(s) transfer
function, let’s try something different: ITAE second-order.
5(900)
T ( s ) 2 1010
s 42 s 900
Step 4. Solve for the unknown controller form including the unknown gains. J-Method
T (s)
GC ( s )
G ( s ) 1 H ( s )T ( s )
5
with G (s) and H(s) = 1
s 11s 1010
2
5(900)
1010
GC ( s ) s 2
42 s 900
5(900)
5 1010
2 1 (1) 2
s 11s 1010 s 42 s 900
450
101 s 2 11s 1010
2
s 42 s 900 5
GC ( s )
2 450
s 42s 900 101
s 2 42 s 900
s 11s 1010
90 2
101
GC ( s )
1
s 2 42 s 450 2
101
44
Step 5. Simulate the resulting closed-loop system performance.
Simulink Evaluation for the J-Method Term Example Controller Design, Angular Velocity
5
s2 +11s+1010
Plant
90/101*[1 11 1010] 5
s2 +42s+450*(2-1/101) s2 +11s+1010 Scope
Step Gc Plant
This J-Method controller for the Term Example load shaft angular velocity L(t) control was
successful as shown in the left plot above. But how does this controller handle disturbances?
As we have seen before, the J-Method controller is very poor at handling disturbances, in this
case a unit step disturbance in voltage, subtracted at t = 1 sec. The disturbed J-Method controller output
response, shown in the right figure above, has unacceptable transient response and unacceptable steady-
state error.
46
L R n
cL
J L (t)
cM
+ + L (t)
v A (t) v B (t) JM
- - L (t)
i A (t) M (t) L (t)
M (t)
M (t)
Though we have not presented it, it is possible to design controllers specifically to reject
disturbances. This last example, the conclusion of the Term Example, discusses controller design to
reject disturbances, specifically for achieving lower steady-state error.
KB
where VA(s) is the armature voltage input, L(s) is the load shaft angular velocity output, and D(s) is the
disturbance modeled at the actuator input level (disturbance in torque, Nm).
1 1
where G1 ( s ) G2 (s) KT G3 ( s )
Ls R J E s cE
Let VA(s) = 0 and monitor changes in L(s) given a disturbance input. Since VA(s) = 0, any L(s)
is the steady-state error, that is, we wish as low an output as possible for the open-loop system.
L (s)
Derive the open-loop disturbance transfer function GD ( s ) .
D(s)
M (s) 1
TM ( s ) D ( s ) J E s cE
47
TM ( s ) KT
Since V(s) = 0 M ( s) n L ( s )
K B M ( s ) Ls R
nL (s) 1 KT K B n L ( s ) Ls R D ( s )
n L ( s ) J E s cE
KT KB nL (s)
D(s) J E s cE Ls R
Ls R
L (s) Ls R
GD ( s)
D( s) n J E s cE Ls R KT K B
D
Open-loop steady-state error for a step disturbance of magnitude D, D( s)
s
EOL ( s) LDES ( s) L ( s) L ( s)
Ls R D( s )
n J E s cE Ls R KT K B
RD
essOL
n RCE KT K B
D(s)
KB
Kt
where LDES(s) is the desired load shaft angular velocity output, and the other terms have been
previously defined.
48
Let LDES(s) = 0 and check changes in L(s) given a disturbance input. Since LDES(s) = 0, any
L(s) is the steady-state error, that is, we wish as low an output as possible for the closed-loop system.
L ( s)
Derive the closed-loop disturbance transfer function TD ( s ) .
LDES ( s )
M (s) 1 TM ( s) KT
M ( s) n L ( s )
TM ( s ) TD ( s ) J E s cE A( s) Ls R
KT KKt nK B L (s)
TM ( s)
Ls R
n L ( s ) 1
K T KK t nK B L ( s ) J E s cE
D(s)
Ls R
KT KKt nK B L ( s) Ls R D( s )
n L ( s) J E s cE
Ls R
L ( s) Ls R
TD ( s)
LDES ( s) n J E s cE Ls R KT KKt nK B
D
Closed-loop steady-state error for a step disturbance of magnitude D, D( s)
s
ECL ( s) LDES ( s) L ( s ) L ( s )
ECL ( s)
Ls R D( s )
n J E s cE Ls R KT KKt nK B
essCL lim s
Ls R D
s0 n J E s cE Ls R KT KKt nK B s
49
RD
essCL
nRcE K T KK t nK B
For disturbance-rejecting controller design, ensure the closed-loop steady-state error is less than the
open-loop steady-state error.
essCL RD n RcE KT K B
essOL nRcE KT KK t nK B RD
essCL n RcE KT K B
essOL nRcE KT KK t nK B
essCL
Design so 1
essOL
50
Numerical example from Term Example
RD RD
essOL essCL
n RcE KT K B nRcE KT KK t nK B
10 D 10 D
200 1 100 200 100 KK t 200
10 D 10 D
20200 20200 100 KK t
essCL 10 D 20200
essOL 20200 100 KK t 10 D essCL 20200
1
20200 essOL 20200 100 KK t
20200 100 KK t
Kt tachometer selection
K proportional controller gain
Assume the tachometer gain is fixed. Then the only way to reduce the closed-loop steady-state
error is to increase proportional controller gain K as much as possible.
Now, this proportional controller for disturbance rejection is not very satisfying – we know from
the root-locus plot that the higher we make K, the worse the transient response will be (stable but more
highly underdamped as K increases). So this demonstrates another tradeoff in controller design – to
ensure lower steady-state errors due to unknown, unwanted disturbances, we must accept worse
transient response performance.
51
6. Vibrational Responses
6.1 Free Vibrational Responses
6.1.1 Undamped Second-Order System Free Responses: Simple Harmonic Motion
Let us solve the same general unforced Harmonic Oscillator second-order IVP ODE using an
alternative method: Laplace Transforms. Since we are solving a linear ODE, there is a unique solution,
which we have found using the Slow ME Way and validated by direct substitution.
x(t ) a0 x(t ) 0 for x(t) given a2, a0, and values for the initial conditions:
Solve a2
x(0) x0
x(0) v0
In contrast to the Slow ME Way, ODE solution via Laplace Transforms is accomplished
algebraically in the Laplace frequency domain, in a single step, including the initial conditions.
The first step is to take the Laplace Transform of both sides of the ODE, including the initial
conditions, and solving algebraically for the unknown in the Laplace domain, X (s) L{x(t)}.
L a2
x(t ) a0 x(t ) 0
a2 ( s 2 X ( s ) sx(0) x (0)) a0 X ( s ) 0
(a2 s 2 a0 ) X ( s ) a2 ( x0 s v0 )
a2 ( x0 s v0 )
X (s)
a2 s 2 a0
Note that the system characteristic polynomial a2 s 2 a0 appears when using the Laplace
Transform method. To find the solution in the time domain, x(t), we must take the inverse Laplace
Transform of X(s).
52
Consulting a table of Laplace Transforms, such as in Appendix B, we find two applicable entries.
s
sin t cost 2
s
2 2
s 2
The left term in x(t) above is ready to go and will yield a cosine term; the right term must be
a a0
manipulated algebraically, multiplying by a ‘1’ ( 0 ) and rearranging.
a2 a2
a0
s v a
1
x(t ) x0 L1
a
0
L
2
s 2 a0 0 s a0
2
a2 a2 a2
a0
n
a2
to yield
s v0 1 n2
1
x(t ) x0 L 2 2
2L 2 2
s n n s n
s v0n 1 n
x(t ) x0 L1 2 2
2 L 2 2
s n n s n
s v0 1 n
x(t ) x0 L1 2 2
L 2 2
s n n s n
We can finally take the two inverse Laplace Transforms to yield the solution x(t)
53
v0
x (t ) x0 cos n t sin n t
n
As predicted, this solution agrees with the solution derived via the Slow ME Way – we have validated
this solution, presented some equivalent alternative solution forms, and presented a numerical example
so we needn’t repeat this work since it is the same.
54
6.1.2 Underdamped Second-Order System Free Responses
Undamped SHM Numerical Example x(t) and Time Derivatives Time Response
55
Underdamped SHM Numerical Example x(t) and Time Derivatives Time Response
Critically-damped SHM Numerical Example x(t) and Time Derivatives Time Response
Overdamped SHM Numerical Example x(t) and Time Derivatives Time Response
Note that if n > 1 then the magnitude of the acceleration is greater than the magnitude of the velocity,
which is greater than the magnitude of the position, in all four cases.
Let us solve the same general harmonically-forced undamped second-order IVP ODE using an
alternative method: Laplace Transforms. Since we are solving a linear ODE, there is a unique solution,
which we have found using the Slow ME Way and validated by direct substitution.
x (t ) a0 x (t ) u (t ) for x(t) given a2, a0, u(t) U sint , and zero initial conditions
Solve a2
x(0) x0 0
x(0) v0 0
In contrast to the Slow ME Way, ODE solution via Laplace Transforms is accomplished
algebraically in the Laplace frequency domain, in a single step, including the forcing function and initial
conditions.
The first step is to take the Laplace Transform of both sides of the ODE, including the initial
conditions and forcing function, and solving algebraically for the unknown in the Laplace domain,
X (s) L{x(t)}.
L a2
x(t ) a0 x(t ) U sin t
a2 ( s 2 X ( s ) sx(0) x (0)) a0 X ( s ) U
s 2
2
(a2 s 2 a0 ) X ( s ) U 2
s 2
U
X ( s)
(a2 s a0 )( s 2 2 )
2
Note that the system characteristic polynomial a2s2 a0 appears when using the Laplace
Transform method. To find the solution in the time domain, x(t), we must take the inverse Laplace
Transform of X(s).
We find no Laplace Transform entries matching this X(s), so we must first perform the Heaviside Partial
Fraction Expansion on X(s) to break it into manageable pieces that are found in the Laplace Transform
Table.
57
U C1s C2 C3s C4
X (s)
(a2s2 a0 )(s2 2 ) (a2s2 a0 ) (s2 2 )
Where the Heaviside Partial Fraction unknown constants C1, C2, C3, C4 are called the residues. Note
that we break X(s) into a sum of terms each with a single denominator factor from the original. Also
note that the order of each numerator polynomial in s must be one less that the order of its denominator.
If you can factor a denominator into real factors, do so – if they are imaginary, do not factor.
Immediately upon breaking apart X(s) into the partial fraction expansion, we express it again over a
common denominator, and equate it to the original X(s).
Balancing the powers of s coefficients on the left- and right-hand-sides of the above equation yields four
linear equations in four unknowns.
s3 C1 a2C3 0
s 2 C2 a2C4 0 1 a2 C1 0 1 a2 C2 0
2 2 a C U
s1 C1 2 a0C3 0 a0 C3 0 0 4
s 0 C2 2 a0C4 U
The solution to the Heaviside Partial Fraction unknown constants C1, C2, C3 (the residues) is:
a2U U
C1 0 C2 C3 0 C4
a0 a22 a0 a22
C1s C2 C s C4
X ( s) 32
(a2 s a0 ) (s 2 )
2
C2 C a U 1 U 1
X ( s) 2 4 2 2
(a2 s a0 ) (s )
2
a0 a2 (a2 s a0 ) a0 a2 (s 2 )
2 2 2 2
a0
U 1 U a2
X ( s)
a0 a2 2 a0 (s ) a0 a2 2
2 2 2
a0 2 a0 (s 2 2 )
s s
a2 a2 a2
sin t
s 2
2
a0
U a2
x (t ) L1 X ( s ) L1 2 2
a0 a2 2
a0 2 a0 (s ) a0
s where n
a2 a2 a2
U
x (t ) 2
sin n t sin t
a0 a2 n
As predicted, this solution agrees with the solution derived via the Slow ME Way – we have validated
this solution and presented a numerical example so we needn’t repeat this work since it is the same.
59
6.2.2 Damped Second-Order System Harmonically-Forced Responses
a. Critically-damped Solution 1
characteristic polynomial s2 2 s 2 roots ,
c 62.83
1 x(t ) (0.0000192 0.002t )e t 0.0000779sin(8 t 2.89)
2 km 2 100 2
2 2 1
T sec
8 4
As seen in the time response plot below for the total x(t), one steady-state mode of vibration is
superimposed onto the non-oscillatory critically-damped transient response. We see that the transient
response disappears (the total solution approaches the steady-state solution) by around 3 sec. The
particular solution remains for as long as the input harmonic forcing function is applied. At t = 0, the
initial value is 0 m and the slope is also zero, as specified by the zero initial conditions.
The natural frequency n is unchanged and the new second-order response x(t) is:
10 2 rad
n x(t ) (0.0032 0.0064t )e t 0.0041sin( t 0.93)
10 sec 2
Again in the total time response x(t), one steady-state mode of vibration is superimposed onto the
non-oscillatory critically-damped transient response. We see that the transient response again
disappears (the total solution approaches the steady-state solution) by around 3 sec. The particular
solution remains for as long as the input harmonic forcing function is applied. At t = 0, the initial value
is 0 m and the slope is also zero, as specified by the zero initial conditions.
The two plots below show the same second critically-damped system harmonically-forced
example, first the position, velocity, and acceleration and second the phase plot.
63
c 125.66
2 x(t ) 0.000183e 0.84t 0.000150e 11.72t 0.000072sin(8 t 2.67)
2 km 2 100 2
2 2 1
T sec
8 4
As seen in the time response plot below for the total x(t), one steady-state mode of vibration is
superimposed onto the non-oscillatory overdamped transient response. We see that the transient
response disappears (the total solution approaches the steady-state solution) by around 6 sec, slower than
the critically-damped case. The particular solution remains for as long as the input harmonic forcing
function is applied. At t = 0, the initial value is 0 m and the slope is also zero, as specified by the zero
initial conditions.
The natural frequency n is unchanged and the new second-order response x(t) is:
10 2 rad
n x (t ) 0.000183e 0.84 t 0.000150e 11.72 t 0.000072sin(8 t 2.67)
10 sec
Again in the total time response x(t), one steady-state mode of vibration is superimposed onto the
non-oscillatory critically-damped transient response. We see that the transient response again
disappears (the total solution approaches the steady-state solution) by around 7 sec. The particular
solution remains for as long as the input harmonic forcing function is applied. At t = 0, the initial value
is 0 m and the slope is also zero, as specified by the zero initial conditions.
The two plots below show the same second critically-damped system harmonically-forced
example, first the position, velocity, and acceleration and second the phase plot.
68
An important topic in vibrations and machine design is vibration isolation. For a given
machine, designers specify the mountings (combinations of springs and dashpots) to reduce the shaking
forces and moments on the ground as much as possible. Passive vibration isolation indicates using fixed
components for isolation. Active vibration isolation requires sensors, a processor, actuation, and control
theory, which is much more complicated, but with potential improvements in vibration isolation
compared to the passive case.
Transmissibility is defined as the ratio of the maximum force transmitted to the base over the
maximum input force magnitude and is thus unitless or can be expressed as a percentage. In a good
vibration isolation system, the transmissibility should be low, much less than 1.
Consider the standard forced m-c-k system. Recall from the ME 3012 NotesBook section on
resonance that the maximum normalized amplitude M is:
M
A
1
r
Fk (1 r 2 )2 (2 r)2 n
where A is the amplitude of vibration, F is the input sinusoidal force magnitude, and k is the spring
constant. In this system the ground force is transmitted through the spring and dashpot elements. Recall
that the spring and dashpot forces are f S kx(t ) and f D cx (t ) . Further recall that the velocity x (t )
always leads the position x(t) by 90 . Therefore the total maximum transmitted force Ft is:
2
c 2
2
Ft (kA) (cA) kA 1 kA 1 kA 1 2 r
2 2 2
k n
kA 1 2 r
2
F
TR t
F kA (1 r 2 )2 (2 r )2
1 (2 r )2
TR
(1 r 2 )2 (2 r )2
Note that this TR result has the same denominator as the M ratio from the resonance discussion, but a
different numerator. Below we plot TR vs. frequency ratio r, for various values.
70
Transmissibility vs. r
We see all curves pass through the same ratio point of 1 at r = 0 and r 2 . From these
graphical results we see that the designer must keep the frequency ratio r as large as possible and the
damping as small as possible to achieve low transmissibility TR 1 .
The vibrational model for a second-order m-c-k system with input displacement u(t) instead of
input external force f(t) is:
x ( t ) cx ( t ) kx ( t ) cu ( t ) ku ( t )
m
X
Due to the similarity of these models, the transmissibility TR is identical to the transmissibility
U
Ft
TR and so the above plot covers the displacement input case also, with the same design
F
conclusions.
71
6.2.2.6 Rotating Imbalance
The model for a machine with a rotating imbalance is shown below.
x(t)
m1
e
t
x(t ) cx(t ) kx(t ) m1e 2 sin t
m2
m2
k c
where the unbalanced mass is m1, the total machine mass is m2, e is the effective offset length of the
imbalance, and the equivalent spring and damping coefficients connecting the machine to ground are k
and c, respectively. Following the same method we used for deriving the resonance plots we obtain the
dimensionless ratio E expressing the machine motion relative to the unbalanced motion.
mA r2
E 2
m1e (1 r 2 )2 (2 r )2
This E relationship is plotted below vs. frequency ratio r, for various values.
The transmissibility results for this rotating imbalance case are different than for the two cases
presented previously in the last section. The transmissibility in this case is defined as the force
transmitted to ground through the springs and dashpots, relative to the normalized unbalanced mass.
Ft k r 2 1 (2 r )2
TRU
m1e m2 (1 r 2 ) 2 (2 r )2
This TRU relationship is plotted below vs. frequency ratio r, for various values.
We see all curves pass through the same transmissibility point of 2 at r 2 . Again, we
desire very low values of transmissibility in the rotating unbalance case, that is we want TRU 1 . In
the TRU plots above we see that all cases will yield T RU 1 , some even yield TRU 1 . For all r
values greater than 1, (and for many r values less than 1), higher damping causes higher transmissibility,
which is undesirable. The best way to limit transmissibility in this case is to minimize the rotating
imbalance m 1 e by balancing the rotating shaft.
MATLAB file Transmiss.m was used to generate the above two plots.
73
6.2.3 General Forcing Functions
In forced vibrations analysis we considered only periodic harmonic input forcing of the form
f (t) F sint
We could have equally considered periodic harmonic input forcing of the form f (t) F cost . All
derived results would be very similar so we needn’t repeat our derivations for the cosine input function.
This section discusses more general input functions for forced vibrations of dynamic systems.
We consider both periodic and non-periodic general input forcing functions. These topics used to be
central in learning classical vibrations, but, with the advent of MATLAB/Simulink, these types of
general input functions are easy to represent using computer simulation. These simulations are much
more accurate and far easier to perform than earlier in history.
Periodic forcing functions used as external inputs to vibratory systems have classically been
represented by the Fourier series. Any periodic forcing function f(t) with a time period of T 2 can
be represented by an infinite Fourier series.
a0
f (t ) a p cos p t b p sin p t
2 p 1 p 1
where
2 T
T 0
ap f (t )cos ptdt p 0,1,2,
2 T
T 0
bp f (t )sin ptdt p 1,2,
It is up to the engineer to decide how many p terms to include in the series to obtain the desired fidelity
and accuracy.
An alternate form for the Fourier series, suitable for the frequency response, is obtained by using
a familiar transformation (sine sum-of-angles formula); the result is:
f (t ) A0 Ap sin p t p
p 1
where
a0 ap
A0 Ap a2p bp2 p tan 1
2 b p
74
Fourier Series Examples
1. Square Wave. Represent the f(t) square wave below by using a Fourier series. The time period
in this example is T 2 sec (thus 2 T 1 rad/sec) and this input repeats periodically as
long as desired. The discontinuous square wave function f(t) is:
f (t) 1 0t
f (t) 1 t 2
Solution.
Evaluating the Fourier series coefficients for this given square-wave and given time period T, we
find the following coefficients.
ap 0 p 0,1,2,
4
bp p 1,3,5,
p
bp 0 p 2,4,6,
2 2 rad
1
T 2 sec
and the harmonic frequencies of a periodic function, the components contributing to the Fourier series,
are:
Any guitar player knows that harmonic frequencies are integer multiples of the fundamental
frequency for each string.
As shown above, only the odd sine terms are non-zero in the Fourier series for the square wave.
The subplots below show the Fourier series approximation for the given square wave, for p = 1, 7, 13,
19.
75
We see that higher p values represent the discontinuous square wave more faithfully. However,
the harmonic frequencies increase, though with relatively low amplitude, as p increases. Also, the
amount of overshoot shown for p = 19 is no longer decreasing for higher p.
It is pretty cool to animate this in MATLAB – demonstrate this using MATLAB file
FourierSeries.m.
2. Saw-Tooth Wave. Represent the f(t) saw-tooth wave below by using a Fourier series. The time
period in this example is again T 2 sec (thus 2 T 1 rad/sec) and this input repeats
periodically as long as desired. The discontinuous saw-tooth wave function f(t) is:
f (t) t 0t
f (t) t 2 t 2
Solution
Evaluating the Fourier series coefficients for this given saw-tooth wave and given time period T,
we find the following coefficients.
76
ap 0 p 0,1,2,
2( 1) p 1
bp p 1,2,3,4,
p
As shown above, only the sine terms are non-zero in the Fourier series for the saw-tooth wave, in
this case, all p terms (not just the odds as in the square wave). The subplots below show the Fourier
series approximation for the given saw-tooth wave, for p = 1, 4, 7, 10.
We can also represent Fourier Series example results using a frequency spectrum. That is, we
can plot the amplitude A of each Fourier Series component vs. p, the frequency counter for each term.
Remember p = 1 is associated with the fundamental frequency , and p > 1 are the harmonic
frequencies, where p is always an integer. The frequency spectrum plots are given below for the square-
and saw-tooth wave examples from before.
Remember for the square wave that only the odd sine terms were active. The plot above shows the
Fourier Series amplitude for each component in the square wave approximation, up to p = 19. The curve
gives the amplitude formula, 4 p , but it is only in effect for the odd integer p values.
78
Remember for the saw-tooth wave that only the sine terms were active, this time odds and evens for p.
The plot above shows the Fourier Series amplitude for each component in the saw-tooth wave
approximation, up to p = 10. The curve gives the amplitude formula, 2 p , but it is only in effect for the
integer p values. Note that the amplitudes A(p) above are shown to be positive only; in the saw-tooth
Fourier Series approximation, all the even terms are negative.
These two plots were generated using MATLAB files FourierSeries.m. and
FourierSeriesSaw.m, respectively.
The 3D plot below shows a diagram to better explain the relationships amongst amplitude, time,
and frequency in sinusoidal functions.
The model for a standard m-c-k system with a general input periodic forcing function is:
a0
mx(t ) cx (t ) kx (t ) f (t ) a p cos p t b p sin p t
2 p 1 p 1
Classically, this problem can be solved by utilizing linear superposition, i.e. solving this linear second-
order ODE separately for each of the three forcing terms above, and then adding the three solutions to
obtain the overall solution. In this section, instead, we will use MATLAB/Simulink to solve some
example numerical problems with periodic forcing functions.
Example 1
Solve the following ODEs given that u(t) is a periodic square pulse wave of time period 4 sec,
with a value of 1 for half the cycle and a value of zero for the second half of the cycle (see the yellow
curve below).
As presented earlier, to communicate a system to MATLAB’s Simulink, we must use state space
matrices. For a first order system, all state-space matrices are scalars:
The Simulink model SquareInput.mdl to simulate the time responses of these two systems
to the given square wave pulse is shown below. The Simulink time response plots are shown next.
For case a. the time constant is = 0.2 sec and we see the square wave pulse response does have
time to reach its steady-state value of 1 before the pulse magnitude switches. For case b. the time
constant is = 1 sec and we see the square wave pulse response does not have sufficient time to reach its
steady-state value of 1 before the pulse magnitude switches.
Example 2
Re-solve the case a. ODE from Example 1, given that u(t) is a periodic triangular saw wave of
time period 4 sec, with a value of u(t) = t for the cycle and a discontinuity leading to the next cycle (see
the yellow curve below).
The Simulink model SawInput.mdl to simulate the time responses of this first-order system
a. to the given saw-tooth wave is shown below. The Simulink time response plots are shown next.
We see that now case a. cannot keep up with the input triangular wave. There is time lag in the response
and the magnitudes do not reach the desired values either at the maximum or minimum saw-tooth
points.
Inverted Pendulum
84
Controlled via Quanser/Simulink (continued)
Here the Simulink closed-loop feedback diagram for the 7-cable robot appears to be open (split)
and incomplete; the plant is missing. However, the real-world machine under control serves as the plant
and no model of this plant is required since the real-world behaves as it will, much better than any model
we can construct. So the gap (split) in this diagram is where the real-world plant is (motors outputs to
and sensors readings (stringpots in this example) from the real-world).
The seventh motor is controlled in a different way for tensioning the cables and entire end-
effector.
88
L1 L2
115 VAC
GND
E-Stop Off On
Fuse
MCR1 MCR2
Fuse
PWM
PLC MCR1 Servo Amp.
Outputs To
Axis 1-5 + 24 VDC Sensors
Switches and
MCR2 Indicators
Fuse
+ Outputs To
DC Power Supply
40VDC
DC Power Supply +5 VDC Digital
Unregulated Regulated Encoders
- MCR2
COM
PC Programming Terminal
Power Supply
+
24 VDC 5 VDC
-
+ - + -
Serial Port
Interface
PLC Space
Power
PLC Supply
0 1 2 3 4 5 6 For
Expansion
(0-10 V)
(1-10 V) IR
Sensor
(+/- 10 VDC)
PWM DC Motor
Servo
Amp. Axis 1
(+/- 10 VDC)
PWM DC Motor
Servo & Encoder
Amp. Axis 2
Encoder Feedback
PWM DC Motor
(+/- 10 VDC)
Servo & Encoder
Amp. Axis 5
Encoder Feedback
V i e w p u b l i c a t i o n s t a t s