Transcript lecture_27
ECE
8443
– PatternContinuous
Recognition
EE
3512
– Signals:
and Discrete
LECTURE 27: DIFFERENTIAL EQUATIONS
• Objectives:
First-Order
Second-Order
Nth-Order
Computation of the Output Signal
Transfer Functions
• Resources:
PD: Differential Equations
Wiki: Applications to DEs
GS: Laplace Transforms and DEs
IntMath: Solving DEs Using Laplace
URL:
First-Order Differential Equations
• Consider a linear time-invariant system defined by:
dy ( t )
ay ( t ) bx ( t )
dt
• Apply the one-sided Laplace transform:
sY ( s ) y ( 0 ) aY ( s ) bX ( s )
• We can now use simple algebraic manipulations to find the solution:
( s a )Y ( s ) y ( 0 ) bX ( s )
Y (s)
y (0 )
sa
bX ( s )
sa
• If the initial condition is zero, we can find the transfer function:
H (s)
Y (s)
X (s)
b
sa
• Why is this transfer function, which ignores the initial condition, of interest?
(Hints: stability, steady-state response)
• Note we can also find the frequency response of the system:
H (e
j
) H (s)
s j
b
j a
• How does this relate to the frequency response found using the Fourier
transform? Under what assumptions is this expression valid?
EE 3512: Lecture 27, Slide 1
RC Circuit
• The input/output differential equation:
dy ( t )
dt
1
1
y (t )
RC
RC
Y (s)
x (t )
y (0 )
s 1 / RC
1 / RC
s 1 / RC
X (s)
• Assume the input is a unit step function:
x (t ) u (t )
X (s)
1
s
y (0 )
1
1
1
Y (s)
s 1 / RC
s 1 / RC s s 1 / RC
s s 1 / RC
y (0 )
1 / RC
• We can take the inverse Laplace transform to recover the output signal:
y (t ) y ( 0 ) e
(1 / RC ) t
1 e
(1 / RC ) t
,
t0
• For a zero initial condition:
y (t ) 1 e
(1 / RC ) t
,
t0
• Observations:
How can we find the impulse response?
Implications of stability on the transient response?
What conclusions can we draw about the complete response to a sinusoid?
EE 3512: Lecture 27, Slide 2
Second-Order Differential Equation
• Consider a linear time-invariant system defined by:
2
d y (t )
dt
2
a1
dy ( t )
a 0 y ( t ) b1
dt
dx ( t )
dt
b 0 x (t )
assume
x (0 ) 0
• Apply the Laplace transform:
dy ( t )
s Y ( s ) y (0 ) s
2
dt
Y (s)
a 1 [ sY ( s ) y ( 0 )] a 0 Y ( s ) b1 sX ( s ) b 0 X ( s )
t0
y ( 0 ) s y ( 0 ) a 1 y ( 0 )
s a1 s a 0
2
b1 s b 0
s a1 s a 0
• If the initial conditions are zero:
H (s)
Y (s)
X (s)
b1 s b 0
s a1 s a 0
2
2
dt
2
6
8 y (t ) 2 x (t )
H (s)
dt
x (t ) u (t )
Y (s)
dy ( t )
• What is the nature of the impulse response of
this system?
• How do the coefficients a0 and a1 influence the
impulse response?
• Example:
d y (t )
X (s) 1 / s
0 .5
0 . 25
1 0 . 25
2
s
s2 s4
s 6s 8 s
2
y ( t ) 0 . 25 0 . 5 e
2t
EE 3512: Lecture 27, Slide 3
0 . 25 e
X (s)
2
4t
,
t 0
2
s 6s 8
2
Nth-Order Case
• Consider a linear time-invariant system defined by:
d
N
dt
y (t )
N
N 1
a
i
i
dt
i0
i
M
d y (t )
i
b
d x (t )
i
i0
b 0 b1 s b 2 s ... b M s
2
H (s)
a 0 a 1 s a 2 s ... s
2
i
dt
(M N )
M
N
• Example:
s 2 s 16
2
H (s)
X (s)
s 4s 8s
3
2
1
s2
s 2 s 16
2
Y (s) H (s) X (s)
y (t ) e
2t
s
3
4 s 8 s s 2
2
1
2t
cos
2
t
sin
2
t
1
2
e
,
2
s 1
(s 2) 4
2
1
s
2
s2
t 0
Could we have predicted the final value of the signal?
• Note that all circuits involving discrete lumped components (e.g., RLC) can be
solved in terms of rational transfer functions. Further, since typical inputs are
impulse functions, step functions, and periodic signals, the computations for
the output signal always follows the approach described above.
• Transfer functions can be easily created in MATLAB using tf(num,den).
EE 3512: Lecture 27, Slide 4
Circuit Analysis
• Voltage/Current Relationships:
Diff. Eq. :
Laplace
v ( t ) Ri ( t )
V ( s ) RI ( s )
dv ( t )
V (s)
dt
v (t ) L
1
i (t )
C
Transform
1
I (s)
Cs
di ( t )
:
1
v (0)
s
V ( s ) LsI ( s ) Li ( 0 )
dt
• Series Connections (Voltage Divider):
V1 ( s )
V2 (s)
Z1 (s)
Z 1 (s) Z 2 (s)
Z 2 (s)
Z 1 (s) Z 2 (s)
EE 3512: Lecture 27, Slide 5
V (s)
V (s)
Circuit Analysis (Cont.)
• Parallel Connections (Current Divider):
I1 (s)
I 2 (s)
Z 2 (s)
Z 1 (s) Z 2 (s)
Z 1 (s)
Z 1 (s) Z 2 (s)
I (s)
I (s)
• Example:
Vc (s)
H (s)
1 / Cs
Ls R (1 / Cs )
Vc (s)
X (s)
V R (s)
H (s)
1 / LC
s ( R / L ) s (1 / LC )
2
R
Ls R (1 / Cs )
Vc (s)
X (s)
X (s)
X (s)
(R / L)s
s ( R / L ) s (1 / LC )
2
Note the denominator of the transfer
function did not change. Why?
EE 3512: Lecture 27, Slide 6
RLC Circuit
• Consider computation of the transfer
function relating the current in the
capacitor to the input voltage.
• Strategy: convert the circuit to its
Laplace transform representation,
and use normal circuit analysis tools.
• Compute the voltage across the
capacitor using a voltage divider,
and then compute the current
through the capacitor.
• Alternately, can use KVL, KVC, mesh
analysis, etc.
• The Laplace transform allows us to
reduce circuit analysis to algebraic
manipulations.
• Note, however, that we can solve for both the steady state and transient
responses simultaneously.
• See the textbook for the details of this example.
EE 3512: Lecture 27, Slide 7
Interconnections of Other Components
• There are several useful building blocks in signal processing: integrator,
differentiator, adder, subtractor and scalar multiplication.
• Graphs that describe interconnections of these components are often referred
to as signal flow graphs.
• MATLAB includes a very nice tool, SIMULINK, to deal with such systems.
EE 3512: Lecture 27, Slide 8
Example
EE 3512: Lecture 27, Slide 9
Example (Cont.)
• Write equations at each node:
sQ 1 ( s ) 4 Q 1 ( s ) X ( s )
sQ 2 ( s ) Q 1 ( s ) 3 Q 2 ( s ) X ( s )
Y (s) Q 2 (s) X (s)
• Subst. into the third and
solve for Y(s)/X(s):
• Solve for the first for Q1(s):
Q1 ( s )
1
s4
X (s)
2
H (s)
• Subst. this into the second:
Q2 (s)
1
s3
[ Q 1 ( s ) X ( s )]
EE 3512: Lecture 27, Slide 10
s 8 s 17
s5
( s 3 )( s 4 )
X (s)
( s 3 )( s 4 )
Interconnections
• Blocks can be thought of as subsystems that make up a system described by
a signal flow graph.
• We can reduce such graphs to a transfer function.
• Consider a parallel connection:
Y ( s ) Y1 ( s ) Y 2 ( s )
Y1 ( s ) H 1 ( s ) X ( s )
Y2 (s) H 2 (s) X (s)
Y (s) H 1 (s) X (s) H 2 (s) X (s)
H (s)
Y (s)
X (s)
H 1 (s) H 2 (s)
• Consider a series connection:
Y1 ( s ) H 1 ( s ) X ( s )
Y 2 ( s ) H 2 ( s )Y1 ( s )
H 2 ( s )H 1 ( s ) X ( s )
Y (s) H 1 (s)H 2 (s) X (s)
H (s)
Y (s)
X (s)
H 1 (s)H 2 (s)
EE 3512: Lecture 27, Slide 11
Feedback
• Feedback plays a major role in
signals and systems. For example,
it is one way to stabilize an unstable
system.
• Assuming interconnection does not load
the other systems:
Y1 ( s ) H 1 ( s ) X 1 ( s )
X 1 ( s ) X ( s ) Y 2 ( s ) X ( s ) H 2 ( s )Y 2 ( s )
Y ( s ) H 1 ( s ) X ( s ) H 2 ( s )Y ( s )
1 H 1 ( s ) H 2 ( s ) Y ( s )
Y (s)
H (s)
H 1 (s) X (s)
H 1 (s)
1 H 1 (s)H 2 (s)
Y (s)
X (s)
X (s)
H 1 (s)
1 H 1 (s)H 2 (s)
• How does the addition of feedback influence the stability of the system?
• What if connection of the feedback system changes the properties of the
systems? How can we mitigate this?
EE 3512: Lecture 27, Slide 12
Summary
• Demonstrated how to solve 1st and 2nd-order differential equations using
Laplace transforms.
• Generalized this to Nth-order differential equations.
• Demonstrated how the Laplace transform can be used in circuit analysis.
• Generalize this approach to other useful building blocks (e.g., integrator).
• Next:
Generalize this approach to other block diagrams.
Work another circuit example demonstrating transient and steady-state
response.
EE 3512: Lecture 27, Slide 13
Circuit Analysis Example
• Assume R = 1, C = 2, and:
x ( t ) [ 3 sin( 5 t ) 7 ]u ( t )
• Also assume v c ( t ) 0
• Can we predict the form of the output
signal? Or solve using Laplace:
X ( s ) (3)
H (s)
s
2
1 / RC
s 1 / RC
2
(7 )
1
(3)
s
5
s 5
2
2
(7 )
1
s
1/ 2
s 1/ 2
1
1
(3 / 2 )
(7 / 2)
1 / 2
Y (s) H (s) X (s)
(
7
)
(3) 2
2
2
2
s ( s 5 )( s (1 / 2 ))
s (( s (1 / 2 ))
s 5
s 1 / 2
( 3 / 2 ) s ( 7 / 2 )( s 5 )
2
2
s ( s (1 / 2 ))( s 5 )
2
y ( t ) DC term decaying
2
A
s
exponentia
B
s 1/ 2
Cs D
s 5
2
l sinewave
2
(amplitude
/phase shifted
)
• Class assignment: find y(t) using:
• Analytic/PPT – Laplace transform (last name begins with A-M)
• Numerical – MATLAB code + plot (last name begins with N-P)
• Email me the results by 8 AM Monday for 1 point extra credit (maximum)
EE 3512: Lecture 27, Slide 14