Docsity

Solved Questions on Digital Control Systems | ECE 4700, Study notes of Electrical and Electronics Engineering

Partial preview of the text

Download Solved Questions on Digital Control Systems | ECE 4700 and more Study notes Electrical and Electronics Engineering in PDF only on Docsity!

Chapter 13: Digital Control Systems

G C ( ) z GP ( s )

R ( ) z Y ( ) s

H C ( ) z H S ( s )

+

_

H P ( s )

+

_

Process

Sensor

Electronic Control

DAC

ADC

Discrete Time Steps Continuous in Time

Fs

Z-Domain Operations for the Closed Loop

From the previous example, we see an input to output relationship with a corresponding

transformation as seen in continuous time systems. Therefore, we use (b) to represent

processing of the digitized signal r(t) from (a) below.

The discrete feedback equation:

E ( z ) = R ( ) z − Y ( ) z

Y ( z ) = G ( ) z ⋅ E ( ) z

Y^ (^ z )^ = G ( ) z^ ⋅(^ R ( ) z^ − Y ( ) z )

Y ( ) z ⋅ ( 1 + G ( ) z ) = G ( ) z ⋅ R ( ) z

G ( ) z

Gz

Rz

Yz

Note: If a discrete system is driving a continuous time system, the goal of a discrete

time representation is to provide the same result as the continuous time system at

the sampling points. It will not describe the behavior of the continuous time signal

between the sampling points.

Determining the output response:

Y ( z ) = G ( ) z ⋅ R ( ) z

( ) R ( ) z

z z e

z e e Y z ⋅ ⎥ ⎦

−

− −

2 1

1 1

For a step response ( )

z

z Rz

2 1

1 1

−

− −

z

z

z z e

z e e Y z

( ) ⎥ ⎦

− −

− −

3 2 1 1

2 1 1

z z z z z e e

z e z e Y z

( )

( ) ( )

− −

− −

3 2 1 1

2 1 1

z z z e e

z e z e Y z

Perform long-hand polynomial division and the solution will be of the form

( ) = ⋅ + ⋅ + ⋅ +L

− − − 3 3

2 2

1 Yz a 1 z a z a z

The output sequence observed will then be the coefficients in time …

Y ( kT ) = ak

Using MATLAB Chap13_Ex

MATALB:

Ts=1;

num=1;

den=[1 1 0];

sys=tf(num,den)

sysCL=feedback(sys,1)

sysd=c2d(sys,Ts,'ZOH')

sysdCL=feedback(sysd,1)

step(sysCL,sysdCL);

legend('Cont','c2d')

grid

Result: Transfer function: 1


s^2 + s

Transfer function: 1


s^2 + s + 1

Transfer function: 0.3679 z + 0.


z^2 - 1.368 z + 0.

Sampling time: 1

Transfer function: 0.3679 z + 0.


z^2 - z + 0.

Sampling time: 1

0 5 10 15 20 25

0

1

Step Response

Time (sec)

Amplitude

Cont c2d

and

0 2 4 6 8 10 12

0

1

Step Response

Time (sec)

Amplitude

Cont c2d@8x

The gain and phase margins for the open loop systems are

0

20

Magnitude (dB)

10

  • 10 - 10 0 10 1 10 2

0

Phase (deg)

Bode Diagram Gm = 23.7 dB (at 3.96 rad/sec) , Pm = 79.2 deg (at 1.06 rad/sec)

Frequency (rad/sec)

Cont c2d@8x

The sample rate is everything in digital and discrete time systems.

The Nyquist sampling rate and theory are valid, but …normal analog approaches that are

“transformed” to digital will not perform in a similar fashion to the analog system! The

sample rate must be significantly higher than the Nyquist rate.

Digital systems and controls can be designed to perform at ar near the Nyquist rate, but

they should be designed using digital techniques, not analog techniques!

Using the element z – digital filters

− 1 z represents a time period delay in a sampled system. So,

( ) R ( ) z

a a z a z

b b z b z Y z ⋅

  • ⋅ + ⋅ +

− −

− −

L
L

2 3

1 1 2

2 3

1 1 2

Y ( ) ( z ⋅ a + a ⋅ z + a ⋅ z + ) =( b + b ⋅ z + b ⋅ z + ) ⋅ R ( ) z

− − − − L L

2 3

1 1 2

2 3

1 1 2

a 1 ⋅ y ( ) k + a 2 ⋅ y ( k − 1 ) + a 3 ⋅ y ( k − 2 ) +L = b 1 ⋅ r ( ) k + b 2 ⋅ r ( k − 1 ) + b 3 ⋅ r ( k − 2 ) +L

a 1 ⋅ y ( ) k =− a 2 ⋅ y ( k − 1 ) − a 3 ⋅ y ( k − 2 ) −L + b 1 ⋅ r ( ) k + b 2 ⋅ r ( k − 1 ) + b 3 ⋅ r ( k − 2 ) +L

( ) = − ⋅ ( − 1 ) − ⋅ ( − 2 ) −L + ⋅ ( ) + ⋅ ( − 1 ) + ⋅ ( − 2 ) +L

1

3

1

2

1

1

1

3

1

2 rk a

b rk a

b rk a

b yk a

a yk a

a yk

The next output is based on the weighted sum of previous outputs and the weighted sum

of the inputs.

P.S. We just repeated the first order difference estimate using z transforms.

Special Case

If the denominator coefficients are zero except for a 1 (^) = 1 , then the output has a finite

impulse response (FIR).

( ) = ⋅ ( ) + ⋅ ( − 1 ) + ⋅ ( − 2 ) +L

1

3

1

2

1

1 rk a

b rk a

b rk a

b yk

Meaning, that if r(k) is an impulse (one for only one sample, then zero), the output will

last for a finite period of time and go to zero. This is where an FIR filter comes from.

Example Section 13.

Roots to roots comparison.

s s

G (^) ps

( )

( ) ( )

( )

( )

T T

T T T

T

T T T

z z e e

z T e T e e

z z e

z T e T e e G z − −

− − −

−

− − −

2

The z-plane root are based on

( ) ( )

T T z z z e e

− − Δ = − ⋅ 1 + +

2

which have roots

( ) ( ) (^) T

T T

e

e e z z

−

− −

⎥ − ⎦

2

1 2 2

( ) ( ) ( )

2 1 2

T T T T

T e e e e

e z z

− − − −

− − ±

T z z e

− 1 ,^2 =^1 ,

The system is marginally stable; one of the roots is on the unit circle.

Therefore, marginally stable in the s-plane and marginally stable in the z-plane.

What if this was a closed loop system with gain K.?

s ( s w )

w G (^) p s ⋅ +

K G ( ) z

K Gz

Rz

Yz

( ) ( )

s ( s w )

w G s e

sT

⋅ +

− 2

( ) ( ) ⎥

−

s w

w

s s

w G z z Z

z

2

− w ⋅ T z e

w

z

z

T z

z

w

z

z

z Gz

2

− w ⋅ T − w ⋅ T z e

z

z

w T

z e w

w

z

z

T

w

G z

( ) ( ) ( ) ( )

( ) ( )

−⋅

−⋅ −⋅

w T

wT wT

z z e

z z e w T z e z

w

G z 1

2

( )

( ) ( )

−⋅

−⋅ −⋅ −⋅

w T

wT wT wT

z z e

z z z e z e wT z w T e

w

G z 1

2 2

( ) ( )

( ) ( )

−⋅

−⋅ − ⋅

w T

wT wT

z z e

e wT z w T e

w

G z 1

The characteristic equation would become

( ) ( )

( ) ( )

−⋅

−⋅ −⋅

w T

wT wT

z z e

e wT z w T e

w

z K 1

( ) ( ) ( ) (( ) ( ) )

w T wT wT e wT z w T e w

z z z e K

− ⋅ −⋅ −⋅ Δ = − 1 ⋅ − + ⋅^1 ⋅ − 1 + + ⋅ ⋅ + 1 − 1 + ⋅ ⋅

( ) ( ) ( ( ) )

w T wT wT wT w T e w

K

e w T e w

K

z z z e

− ⋅ −⋅ −⋅ −⋅ ⎟+ + ⋅ − + ⋅ ⋅ ⎠

2

The conditions for all roots to be inside the unity circle are (given without proof)

Δ ( ) 0 < 1 , Δ ( 1 ) > 0 , and Δ( − 1 ) > 0

For performance of a second order system

From text

w =^1 ; therefore, w

K ⋅τ = K and T^ = w ⋅ T

Figure 13.19 The maximum overshoot │ y│ for a second-order sampled system for a

unit step input.

Figure 13.21 The steady-state error of a second-order sampled system for a unit ramp

input r ( t ) = t, t > 0_._

The Z-Domain Root Locus

Δ ( z ) = 1 + K ⋅ G ( ) z = 0

Repeating the same old problem (Example 13.5) for T=

s s

G p s with ( )

( ) ( ) ( )

2 1 1

1 1

1

1 1

− −

− −

−

− −

z z e e

z e e

z z e

z e e Gz

K G ( ) z

K Gz

Rz

Yz

( )

2 1 1

1 1

− −

− −

z z e e

z e e z K Gz K

( ) ( ) ( )

2 1 1 1 1 1 1 2

− − − − Δ z = z − z ⋅ + e + e + K ⋅ z ⋅ e + − ⋅ e

( ) 0 ( 1 2 ) 1

1 1 Δ = + ⋅ − ⋅ <

− − e K e

1

1

1

1

−

−

−

−

e

e K e

e or − 5. 1766 < K < 2. 3922

( ) 1 1 1 ( 1 ) ( 1 1 2 ) 0

2 1 1 1 1 Δ = − ⋅ + + + ⋅ ⋅ + − ⋅ >

− − − − e e K e e

( 1 ) 0

1 ⋅ − >

− K e

( 1 ) 1 1 ( 1 ) ( 1 2 ) 0

1 1 1 1 Δ − = + ⋅ + + + ⋅− + − ⋅ >

− − − − e e K e e

( )

1

1

−

−

e

e K or K < 26. 397

Therefore

0 < K < 2. 3922

The Z-Domain Root Locus Example 13.

Δ ( z ) = 1 + K ⋅ D ( ) z ⋅ G ( ) z = 0

Repeating the same old problem (Example 13.5) for T=

2

s

G p s = with ( )

2

2

3

2

z

T z

z

T z z

z

z Gz

Note: this Z-Transform with a ZOH is not in Table 13.1 (I have other books …)

K D ( ) z G ( ) z

K Dz Gz

Rz

Y z

2

2

z

T z z K Dz Gz K

Calculate real break-away points. Let z = σ

2

2

T
F K

2

2

2

T
F

[ 2 ( 1 ) ( 1 ) ( 1 )] 0

2

(σ − 1 ) ⋅[ 2 ⋅(σ + 1 ) −(σ − 1 )] =(σ − 1 ) (⋅σ + 3 ) = 0

From MATLAB

-7 -6 -5 -4 -3 -2 -1 0 1 2

-2.

-1.

-0.

0

1

2

Root Locus

Real Axis

Imaginary Axis

Method #2: Use a z-domain root locus method in the digital domain

K G ( ) z D ( ) z

K Gz Dz

Rz

Y z

The characteristic equation is

Δ ( z ) = 1 + K ⋅ G ( ) z ⋅ D ( ) z

and all conditions and/or requirements for forming the root locus (now in the z-domain)

are identical to the continuous time case. See Table 13.4 on p. 922!

Evaluation of the root locus must now be done using the z-domain (unit circle) stability

criteria.

Example 13.7 Method #1: Plant compensated with a phase-lead network

s s

G (^) p s

Phase lead compensation to provide 45 deg. margin at w=125 rad/sec.

s

s G (^) c s

Converting the compensation to a digital compensator for T=0.001,

z B

z A D z C −

Where 0. 95

  1. 05 = =

− A e and 0. 73

  1. 312 = =

− B e and 4. 85 1 0. 73

C = ⋅ ⋅

z

z Dz