bode_lect

59
Frequency Domain Analysis Using Bode Plot Swagat Kumar July 11, 2005 September 6, 2011 Control Systems Laboratory, IIT Kanpur Page 1

Transcript of bode_lect

Page 1: bode_lect

Frequency Domain Analysis Using Bode Plot

Swagat Kumar

July 11, 2005

September 6, 2011 Control Systems Laboratory, IIT Kanpur Page 1

Page 2: bode_lect

Topics to be covered

• Frequency response of a linear system

• Bode plots

• Effect of Adding zero and poles

• Minimum and Non-minimum phase

• Relative stability: Gain Margin and Phase margin

• Lead and Lag compensator Design

• PID compensator design using bode plot

• Summary

September 6, 2011 Control Systems Laboratory, IIT Kanpur Page 2

Page 3: bode_lect

Frequency response of a linear system

Consider a stable linear system whose transfer function is given by

G(s) =Y (s)

U(s)

For a sinusoidal input u(t) = Asinωt, the output of the system is given by

y(t) = Y sin(ωt+ φ)

where

Y = A|G(jω)|

φ = ∠G(jω) = tan−1

[

Im[G(jω)]

Re[G(jω)]

]

A stable linear system subjected to a sinusoidal input will, at steady state, have a

sinusoidal output of the same frequency as the input. But the amplitude and phase

of output will, in general, be different from those of the input.

September 6, 2011 Control Systems Laboratory, IIT Kanpur Page 3

Page 4: bode_lect

Graphical tools for frequency response analysis

• Bode Diagram

• Nyquist plot or polar plot

• Log-magnitude versus phase plot

In this lecture, we will only study about “Bode Diagram” and its application in

compensator design.

September 6, 2011 Control Systems Laboratory, IIT Kanpur Page 4

Page 5: bode_lect

Bode Plot

A Bode diagram consists of two graphs:

• a plot of 20 log |G(jω)| (in dB) versus frequency ω, and

• a plot of phase angle φ = ∠G(jω) versus frequency ω.

Advantages of Bode plot:

• An approximate bode plot can always be drawn with hand.

• Multiplication of magnitudes get converted into addition.

• Phase-angle curves can easily be drawn if a template for phase-angle curve of

(1 + jω) is available.

September 6, 2011 Control Systems Laboratory, IIT Kanpur Page 5

Page 6: bode_lect

Construction of Bode plot

Any transfer function is composed of 4 classes of terms

1. K

2. (jω)±1

3. (jωτ + 1)±1

4.[

( jωωn

)2 + 2ζ jωωn

+ 1]±1

The gain K:

• Log-magnitude curve is a straight line at 20 logK and phase angle is zero for

all ω

• The effect of varying the gain K in the transfer function is that it raises or lowers

the log-magnitude curve by a constant amount without effecting its phase curve.

September 6, 2011 Control Systems Laboratory, IIT Kanpur Page 6

Page 7: bode_lect

Construction of bode plot

Integral and derivative term (jω)∓1: The logarithmic magnitude of 1/jω in

decibel is

20 log

1

= −20 logω dB

The phase angle of jω is constant and equal to −90◦.

• Octave: A frequency band from ω1 to 2ω1

• Decade: A frequency band from ω1 to 10ω1

For (jω)±n term,

- slope of log-magnitude curve = ±20n dB/decade or ±6n dB/octave.

- phase angle = ±(n× 90)◦

September 6, 2011 Control Systems Laboratory, IIT Kanpur Page 7

Page 8: bode_lect

Construction of Bode Plot

|G(jω)| Slope = -20dB/decade20

10

−10

−20

0.1 1 10 100 1000

(a) Magnitude Plot

∠G(jω)

−90o

0.1 1 10 100 1000

(b) Phase Plot

Figure 1: Magnitude and Phase plot of G(jω) = 1jω

September 6, 2011 Control Systems Laboratory, IIT Kanpur Page 8

Page 9: bode_lect

Construction of Bode Plot

|G(jω)|

Slope = 20dB/decade

20

10

−10

−20

0.1 1 10 100 1000

(a) Magnitude Plot

∠G(jω)

−90o

90◦

0.1 1 10 100 1000

(b) Phase Plot

Figure 2: Magnitude and Phase plot of G(jω) = jω

September 6, 2011 Control Systems Laboratory, IIT Kanpur Page 9

Page 10: bode_lect

Construction of Bode Plot

First order factors (1 + jωT )∓1: The log magnitude of the first order factor1

(1+jωT ) is

20log

1

(1 + jωT )

= −20 log√

1 + ω2T 2 dB

The phase angle is φ = − tan−1 ωT . The log-magnitude curve can be

approximated by two asymptotes as given below:

For ω << 1T , −20 log

√1 + ω2T 2 ≈ −20 log 1 = 0 dB

For ω >> 1T , −20 log

√1 + ω2T 2 ≈ −20 logωT dB

Phase curve

ω 0 1/T ∞φ 0 −45◦ −90◦

September 6, 2011 Control Systems Laboratory, IIT Kanpur Page 10

Page 11: bode_lect

Construction of Bode Plot

Corner frequency

Asymptote

10

0

−10

−20

1

20T

1

10T

1

2T

1

T

2

T

10

T

20

T

|G(jω)|

Slope = -20 dB/decade

(a) Magnitude plot

30◦

0◦

−30◦

−60◦

−90◦1

20T

1

10T

1

2T

1

T

2

T

10

T

20

T

∠G(jω)

(b) Phase plot

Figure 3: Magnitude and phase plot of 1(1+jωT )

September 6, 2011 Control Systems Laboratory, IIT Kanpur Page 11

Page 12: bode_lect

Construction of Bode Plot

Corner frequency

Asymptote

30

20

10

0

−101

20T

1

10T

1

2T

1

T

2

T

10

T

20

T

|G(jω)|

(a) Magnitude plot

90◦

60◦

30◦

0◦

−30◦1

20T

1

10T

1

2T

1

T

2

T

10

T

20

T

∠G(jω)

(b) Phase plot

Figure 4: Magnitude and phase plot of (1 + jωT )

Error at corner frequency ≈ 3 dB and slope is +20 dB/decade.

September 6, 2011 Control Systems Laboratory, IIT Kanpur Page 12

Page 13: bode_lect

Construction of Bode Plot

Quadratic factors [1 + 2ζ(

j ωωn

)

+(

j ωωn

)2

]∓1: The log-magnitude curve for

1/(1 + 2ζ(

j ωωn

)

+(

j ωωn

)2

) is given by

20 log

1

1 + 2ζ(

j ωωn

)

+(

j ωωn

)2

= −20 log

(

1− ω2

ω2n

)2

+

(

2ζω

ωn

)2

The asymptotic frequency-response curve may be obtained by making following

approximations:

For ω << ωn, log-magnitude = −20 log 1 = 0 dB

For ω >> ωn, log-magnitude = −20 log ω2

ω2n

= −40 log ωωn

dB

At corner frequency ω = ωn, the resonant peak occurs and its magnitude depends

on damping ratio ζ .

September 6, 2011 Control Systems Laboratory, IIT Kanpur Page 13

Page 14: bode_lect

Construction of Bode Plot

The phase angle of 1

1+2ζ(j ω

ωn)+(j ω

ωn)2 is

φ = tan−1

2ζ ωωn

1−(

ωωn

)2

The phase curve passes through following points

ω 0 ωn ∞φ 0◦ −90◦ −180◦

September 6, 2011 Control Systems Laboratory, IIT Kanpur Page 14

Page 15: bode_lect

Construction of Bode Plot

September 6, 2011 Control Systems Laboratory, IIT Kanpur Page 15

Page 16: bode_lect

Frequency domain specifications

• The resonant peak Mr is the maxi-

mum value of |M(jω)|.• The resonant frequency ωr is the fre-

quency at which the peak resonance

Mr occurs.

• The bandwidth BW is the frequency at

which M(jω) drops to 70.7% (3 dB)

of its zero-frequency value.

10.707

Mr

0 ωr

|M(jω)|

ωBW

September 6, 2011 Control Systems Laboratory, IIT Kanpur Page 16

Page 17: bode_lect

Frequency domain specification

For a second order system, following relationships between frequency and

time-domain responses can be obtained.

Resonant Frequency:

ωr = ωn

1− 2ζ2

Resonant Peak:

Mr = |G(jω)|max = |G(jωr)| =1

2ζ√

1− ζ2

for 0 ≤ ζ ≤ 0.707. For ζ > 0.707, ωr = 0 and

Mr = 10 0.2 0.4 0.6 0.8 1.0

2

4

6

8

10

0.707

Mr

indB

ζBandwith:

BW = ωn[(1− 2ζ2) +√

(ζ4 − 4ζ2 + 2)]1/2 = [ω2r +

ω4r + ω4

n]1/2

September 6, 2011 Control Systems Laboratory, IIT Kanpur Page 17

Page 18: bode_lect

Frequency domain specification

• Mr indicates the relative stability of a stable closed loop system.

• A large Mr corresponds to larger maximum overshoot of the step response.

Desirable value: 1.1 to 1.5

• BW gives an indication of the transient response properties of a control system.

• A large bandwidth corresponds to a faster rise time. BW and rise time tr are

inversely proportional.

• BW also indicates the noise-filtering characteristics and robustness of the

system.

• Increasing ωn increases BW.

• Increasing ζ decreases BW as well as Mr .

• BW and Mr are proportional to each other for 0 ≤ ζ ≤ 0.707.

September 6, 2011 Control Systems Laboratory, IIT Kanpur Page 18

Page 19: bode_lect

Examples

Effect of adding a zero to the forward path transfer function

Consider following open loop transfer function

G(s) =1

s(s+ 1.414)

Adding a zero to the forward path transfer function leads to

G1(s) =(1 + Ts)

s(s+ 1.414)

The closed loop transfer function is given by

H1(s) =1 + Ts

s2 + (T + 1.414s) + 1

The general effect of adding zero to the forward path transfer function is to

increase the bandwith of the closed loop system.

September 6, 2011 Control Systems Laboratory, IIT Kanpur Page 19

Page 20: bode_lect

Examples

−5

−4

−3

−2

−1

0

Mag

nitu

de (

dB)

10−1

100

−180

−135

−90

−45

0

Pha

se (

deg)

Bode Diagram

Frequency (rad/sec)

T = 0T = 0.2T = 0.5T = 2T = 5

Figure 5: Effect of adding a zero

September 6, 2011 Control Systems Laboratory, IIT Kanpur Page 20

Page 21: bode_lect

Examples

2 4 6 8 10 12 14 16 180

0.2

0.4

0.6

0.8

1

Step Response

Time (sec)

Am

plitu

de

T = 0T = 0.2T = 0.5T = 2 T = 5

Figure 6: Effect of adding a zero: Step response

September 6, 2011 Control Systems Laboratory, IIT Kanpur Page 21

Page 22: bode_lect

Example: adding a zero

Observations

• A zero provides a phase lead to the transfer function.

• For very low values of T , bandwidth decreases.

• For higher values bandwith increases and hence faster rise time.

• For very high values of T , zero (s = − 1T ) moves very close to origin, causing

the system to have larger time constant and hence longer settling time.

September 6, 2011 Control Systems Laboratory, IIT Kanpur Page 22

Page 23: bode_lect

Example

Adding a pole to the forward-path transfer function

Reconsider the previous open loop system

G(s) =1

s(s+ 1.414)

Adding a pole to the forward-path transfer function leads to

G1(s) =1

s(s+ 1.414)(1 + Ts)

The closed loop transfer function is given by

H1(s) =1

Ts3 + (1.414T + 1)s2 + 1.414s+ 1

The effect of adding a pole to the forward path transfer function is to make

the closed-loop system less stable while decreasing bandwidth

September 6, 2011 Control Systems Laboratory, IIT Kanpur Page 23

Page 24: bode_lect

Example

−10

−5

0

5

10

Mag

nitu

de (

dB)

10−1

100

−270

−225

−180

−135

−90

−45

0

Pha

se (

deg)

Bode Diagram

Frequency (rad/sec)

T = 0T = 0.5T = 1T = 5

Figure 7: Effect of adding a pole

September 6, 2011 Control Systems Laboratory, IIT Kanpur Page 24

Page 25: bode_lect

Example

Step Response

Time (sec)

Am

plitu

de

0 5 10 15 20 250

0.2

0.4

0.6

0.8

1

1.2

1.4T = 0T = 0.5T = 1

Figure 8: Effect of adding a pole

September 6, 2011 Control Systems Laboratory, IIT Kanpur Page 25

Page 26: bode_lect

Example: Adding a pole

Observation

• For smaller values of T , BW increases slightly but Mr increases.

• For higher values of T , BW decreases but Mr increases.

• In step response, the rise time increases with decreasing of BW.

• Peak overshoot and settling time increses with increasing value of T .

September 6, 2011 Control Systems Laboratory, IIT Kanpur Page 26

Page 27: bode_lect

Effect of adding a pole or a zero to a transfer function

Figure 9: G = 1s(s+2) , zero is (s+ 0.5) and pole is 1

s+3

September 6, 2011 Control Systems Laboratory, IIT Kanpur Page 27

Page 28: bode_lect

Minimum and nonminimum-phase system

Minimum-phase system Transfer functions having neither poles or zeros in the

right-half s plane are minimum-phase transfer functions.

Nonminimum-phase system Those having poles and/or zeros in the right-half s

plane are called nonminimum-phase system.

Consider following two systems

G1(s) = 10s+ 1

s+ 10

G2(s) = 10s− 1

s+ 10

|G1(jω)| = |G2(jω)|∠G1(jω) 6= ∠G2(jω)

September 6, 2011 Control Systems Laboratory, IIT Kanpur Page 28

Page 29: bode_lect

minimum and non-minimum phase system

0

5

10

15

20

Mag

nitu

de (

dB)

10−2

10−1

100

101

102

103

0

45

90

135

180

Pha

se (

deg)

Bode Diagram

Frequency (rad/sec)

10(s−1)/(s+10)

10(s+1)/(s+10)

In a minimum-phase system, the magnitude and phase-angle are uniquely related.

This does not hold for a NMP system.

September 6, 2011 Control Systems Laboratory, IIT Kanpur Page 29

Page 30: bode_lect

Relative Stability

Phase Margin It is the amount of additional lag at the gain crossover frequency ωg

required to bring the system to the verge of instability. At gain crossover

frequency, the magnitude of open loop gain is unity, i.e., |G(jωg)| = 1. The

phase margin γ is given by

γ = 180◦ + φ

where φ = ∠G(jωg).

Gain Margin It is the amount of additional gain at phase crossover frequency ωp

that can bring the system to the verge of instability. At phase crossover

frequency, the phase angle of open loop transfer function equals −180◦, i.e.,

∠G(jωp) = −180◦. The gain margin is given by

Kg =1

|G(jωp)|or Kg dB = −20 log |G(jωp)|

September 6, 2011 Control Systems Laboratory, IIT Kanpur Page 30

Page 31: bode_lect

Stability analysis using bode plot

• The phase margin and gain margin must be positive for a minimum-phase

system to be stable.

• Negative margins indicate instability.

• For satisfactory performance, the phase margin should be between 30◦ and

60◦ and gain margin should be greater than 6 dB.

• Either the gain margin or the phase margin alone does not give a sufficient

indication of the relative stability. Both should be given in order to determine the

relative stability.

• For first order and second order system, gain margin is always infinity.

Disadvantage of Bode plot:

Bode plot can’t be used for stability analysis of non minimum-phase system.

September 6, 2011 Control Systems Laboratory, IIT Kanpur Page 31

Page 32: bode_lect

stability analysis using bode plot

−100

−50

0

50

100

Mag

nitu

de (

dB)

10−2

10−1

100

101

102

−270

−225

−180

−135

−90

Pha

se (

deg)

Bode DiagramGm = 9.54 dB (at 2.24 rad/sec) , Pm = 25.4 deg (at 1.23 rad/sec)

Frequency (rad/sec)

Gain crossover frequency

Phase crossover frequency

Stable System+ve gainmargin

+ve phaseMargin

Figure 10: Bode plot of 10s(s+1)(s+5)

September 6, 2011 Control Systems Laboratory, IIT Kanpur Page 32

Page 33: bode_lect

stability analysis using bode plot

−100

−50

0

50

100

Mag

nitu

de (

dB)

10−2

10−1

100

101

102

−270

−225

−180

−135

−90

Pha

se (

deg)

Bode DiagramGm = −10.5 dB (at 2.24 rad/sec) , Pm = −23.7 deg (at 3.91 rad/sec)

Frequency (rad/sec)

Unstable System

−ve gain margin

−ve phase margin

Figure 11: Bode plot of 100s(s+1)(s+5)

September 6, 2011 Control Systems Laboratory, IIT Kanpur Page 33

Page 34: bode_lect

Lead Compensators

A lead compensator is given by following transfer

function

Gc(s) = αTs+ 1

αTs+ 10 < α < 1

We see that the zero is always located to the right

of the pole in complex plane.

× •− 1

T− 1αT

σ

The maximum phase angle contributed by a lead compensator is given by

sinφm =1− α

1 + α

at a frequency ωm = 1T√α

September 6, 2011 Control Systems Laboratory, IIT Kanpur Page 34

Page 35: bode_lect

Lead compensator

0

1

2

3

4

5

6

7

8

Mag

nitu

de (

dB)

10−1

100

101

102

0

5

10

15

20

Pha

se (

deg)

Bode Diagram

Frequency (rad/sec)

20 log 1/a

20 dB/decade

a < 1

Maximum phase angle

Figure 12: Bode plot of Gc(s) =1+s

1+0.5s

September 6, 2011 Control Systems Laboratory, IIT Kanpur Page 35

Page 36: bode_lect

Lead compensator design

Consider following second order system

G(s) =4

s(s+ 2)

Design a compensator for the system so that the static velocity error constant

Kv = 20 sec−1 and phase margin is at least 50◦.

Design steps:

• The open loop transfer function of the compensated system is given by

Gc(s)G(s) = KTs+ 1

1 + αTsG(s) =

Ts+ 1

1 + αTsKG(s)

where 0 < α < 1 and K = Kcα. Kc is a gain constant. The attenuation

factor α is assimilated into constant gain factor K . Determine gain K to satisfy

the requirement on given static error constant.

September 6, 2011 Control Systems Laboratory, IIT Kanpur Page 36

Page 37: bode_lect

Lead compensator design

Kv = lims→0

sGc(s)G(s) = lims→0

sTs+ 1

1 + αTsK

4

s(s+ 2)= 20

This gives K = 10.

• Using the gain K , draw a Bode diagram of KG(jω). Evaluate phase margin.

The phase margin is about 18◦.

• Determine the necessary phase lead angle φ to be added to the system.

For a PM of 50◦, a phase lead angle of 32◦ is required. However, in order to

compensate for the shift in gain crossover frequency due to the lead

compensator, we assume that the maximum phase lead required

φm = 32 + 6 = 38◦.

• Using equation sinφm = 1−α1+α , Determine the attenuation factor α.

For φm = 38◦, α = 0.24.

September 6, 2011 Control Systems Laboratory, IIT Kanpur Page 37

Page 38: bode_lect

Lead compensator design

Bode DiagramGm = Inf dB (at Inf rad/sec) , Pm = 18 deg (at 6.17 rad/sec)

Frequency (rad/sec)

−50

0

50

System: untitled1Frequency (rad/sec): 8.95Magnitude (dB): −6.24

Mag

nitu

de (

dB)

10−1

100

101

102

−180

−135

−90

System: untitled1Frequency (rad/sec): 6.13Phase (deg): −162

System: untitled1Frequency (rad/sec): 1.68

Phase (deg): −130

Pha

se (

deg)

NewGain crossover

Frequency

Figure 13: Bode plot of gain adjusted but uncompensated system KG(jω)

September 6, 2011 Control Systems Laboratory, IIT Kanpur Page 38

Page 39: bode_lect

Lead compensator design

• Determine the frequency ω = ωm where

20 log |Gc(jωm)G(jωm)| = 0dB

20 log |KG(jωm)| = −20log

jωmT + 1

jαωmT + 1

= −20 log1√α

(∵ ωm =1

T√α)

Get this frequency from the magnitude plot of KG(jω). This is our new gain

crossover frequency and maximum phase shift φm occurs at this frequency.

Here, −20 log 1√α= −6.2 dB which occurs at ωm = 9 rad/sec.

• Determine the time constant T from the equation ωm = 1T√α

.

Here, T = 0.2278 seconds.

The compensated open loop transfer function is given by

Gc(s)G(s) =(0.2278s+ 1)40

s(s+ 2)(0.0547s+ 1)

September 6, 2011 Control Systems Laboratory, IIT Kanpur Page 39

Page 40: bode_lect

Lead compensator design

−80

−60

−40

−20

0

20

40

60

Mag

nitu

de (

dB)

10−1

100

101

102

103

−180

−135

−90

Pha

se (

deg)

Bode DiagramGm = Inf dB (at Inf rad/sec) , Pm = 50.6 deg (at 8.92 rad/sec)

Frequency (rad/sec)

Figure 14: Bode plot of compensated system

September 6, 2011 Control Systems Laboratory, IIT Kanpur Page 40

Page 41: bode_lect

Lead compensator design

Step Response

Time (sec)

Am

plitu

de

0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.90

0.2

0.4

0.6

0.8

1

1.2

1.4

Figure 15: Closed loop step response of the compensated system

September 6, 2011 Control Systems Laboratory, IIT Kanpur Page 41

Page 42: bode_lect

Lead compensator design

Discussion

• Lead compensator is a high-pass filter.

• It adds more damping to the closed-loop system.

• Bandwidth of closed loop system is increased. This leads to faster time

response.

• The steady state error is not affected.

• In lead compensator design, the phase of forward-path transfer function in the

vicinity of gain crossover frequency is increased.

September 6, 2011 Control Systems Laboratory, IIT Kanpur Page 42

Page 43: bode_lect

Lag Compensator

A lag compensator is given by following

transfer function

Gc(s) = αTs+ 1

αTs+ 1α > 1

We see that the pole is always located to

the right of the zero in complex plane.

ו− 1

αT− 1T

σ

September 6, 2011 Control Systems Laboratory, IIT Kanpur Page 43

Page 44: bode_lect

−15

−10

−5

0

Mag

nitu

de (

dB)

10−2

10−1

100

101

102

−60

−30

0

Pha

se (

deg)

Bode Diagram

Frequency (rad/sec)

20 log 1/a

−20 dB/decade a > 1

Maximum phase angle

Figure 16: Bode plot of Gc(s) =1+s1+5s

September 6, 2011 Control Systems Laboratory, IIT Kanpur Page 44

Page 45: bode_lect

Lag compensator Design

Consider following open loop transfer function

G(s) =1

s(s+ 1)(0.5s+ 1)

Design a compensator so the velocity error constant is Kv = 5 sec−1, the PM is

at least 40◦ and GM is atleast 10 dB.

Design steps:

• The open loop transfer function of the compensated system is given by

Gc(s)G(s) = KTs+ 1

1 + αTsG(s) =

Ts+ 1

1 + αTsKG(s)

where α > 1 and K = Kcα. Determine forward path gain K so as to satisfy

the requirement of steady state performance.

September 6, 2011 Control Systems Laboratory, IIT Kanpur Page 45

Page 46: bode_lect

Lag compensator design

Kv = lims→0

sGc(s)G(s) = lims→0

sTs+ 1

1 + αTs

K

s(s+ 1)(0.5s+ 1)= K = 5

• Plot the bode diagram of KG(jω).

• Assuming that the PM is to be increased, locate the frequency at which the

desired phase margin is obtained, on bode plot. To compensate for excessive

phase lag, the required phase margin is the specified PM + 5 to 12◦. Call the

corresponding frequency new gain crossover frequency ω′g .

The new gain crossover frequency for a PM of 40 + 12 = 52◦ is ωg = 0.5

rad/sec.

• To bring the magnitude curve down to 0 dB at this new gain crossover

frequency, the phase-lag controller must provide the amount of attenuation

equal to the value of magnitude curve ω′g . In other words

|KG(jω′g)| = 20 log10

1

αα > 1

September 6, 2011 Control Systems Laboratory, IIT Kanpur Page 46

Page 47: bode_lect

Lag compensator design

Bode DiagramGm = −4.44 dB (at 1.41 rad/sec) , Pm = −13 deg (at 1.8 rad/sec)

Frequency (rad/sec)10

−210

−110

010

110

2−270

−225

−180

−135

−90

System: untitled1Frequency (rad/sec): 0.637

Phase (deg): −140

System: untitled1Frequency (rad/sec): 0.461Phase (deg): −128

Pha

se (

deg)

−150

−100

−50

0

50

100 System: untitled1Frequency (rad/sec): 0.462Magnitude (dB): 19.6

Mag

nitu

de (

dB)

Figure 17: Bode diagram of KG(jω)

September 6, 2011 Control Systems Laboratory, IIT Kanpur Page 47

Page 48: bode_lect

Lag compensator design

The magnitude of KG(jω′g) is 20 dB and thus we have −20 logα = −20 and

this gives α = 10.

• Choose the corner frequency ω = 1T corresponding to the zero of lag

compensator 1 octave to 1 decade below the new gain crossover frequency ω′g .

We choose the zero of lag compensator at ω = 1T = 0.1 rad/sec. This gives T

= 10.

• Plot the bode diagram of compensated system.

The compensated open loop transfer function is given by

KGc(s)G(s) =5(1 + 10s)

s(1 + 100s)(s+ 1)(0.5s+ 1)

September 6, 2011 Control Systems Laboratory, IIT Kanpur Page 48

Page 49: bode_lect

Lag compensator design

−150

−100

−50

0

50

100

150

Mag

nitu

de (

dB)

10−4

10−3

10−2

10−1

100

101

102

−270

−225

−180

−135

−90

Pha

se (

deg)

Bode DiagramGm = 14.3 dB (at 1.32 rad/sec) , Pm = 41.6 deg (at 0.454 rad/sec)

Frequency (rad/sec)

Figure 18: Bode diagram of compensated system KGc(s)G(s)

September 6, 2011 Control Systems Laboratory, IIT Kanpur Page 49

Page 50: bode_lect

Lag compensator design

Discussion

• Lag compensator is a low-pass filter.

• The gain crossover frequency is decreased and thus the bandwidth of the

system is reduced.

• The rise and settling time increases.

• The steady state error reduces.

• In phase lag control, the objective is to move the gain crossover frequency to a

lower frequency where desired PM is realized while keeping the phase curve

relatively unchanged at new gain crossover frequency. In other words,

phase-lag control utilizes attenuation of controller at high frequencies.

September 6, 2011 Control Systems Laboratory, IIT Kanpur Page 50

Page 51: bode_lect

PID control design

Consider following open loop system

G(s) =(s+ 1)

s2(s+ 8)

Design a PID compensator such that the compensated system has a PM of 60◦ and

a gain crossover frequency of 5 rad/sec and an acceleration error constant Ka = 1.

The PID compensator is of following form

Gc(s) = KP +KDs+KI

s

Gc(jω) = KP + j(KDω − KI

ω)

= |Gc(jω)|(cos θ + j sin θ)

September 6, 2011 Control Systems Laboratory, IIT Kanpur Page 51

Page 52: bode_lect

design of PID compensator

−150

−100

−50

0

50

100

Mag

nitu

de (

dB)

10−2

10−1

100

101

102

103

−180

−150

−120

Pha

se (

deg)

Bode DiagramGm = Inf dB (at Inf rad/sec) , Pm = 17.4 deg (at 0.365 rad/sec)

Frequency (rad/sec)

Figure 19: Bode plot of uncompensated system

September 6, 2011 Control Systems Laboratory, IIT Kanpur Page 52

Page 53: bode_lect

design of PID compensator

0 10 20 30 40 50 60 70 80 90 1000

0.2

0.4

0.6

0.8

1

1.2

1.4

1.6

1.8

System: h Peak amplitude: 1.65 Overshoot (%): 64.9 At time (sec): 7.89

System: h Settling Time (sec): 71.1

Step Response

Time (sec)

Am

plitu

de

Figure 20: Step response of uncompensated closed loop system

September 6, 2011 Control Systems Laboratory, IIT Kanpur Page 53

Page 54: bode_lect

design of PID compensator

For the PID compensator, we can write

KP = |Gc(jω)| cos θ

KDω − KI

ω= |Gc(jω)| sin θ

We know that at gain crossover frequency, |Gc(jωg)||G(jωg)| = 1. This gives

|Gc(jωg)| =1

|G(jωg)|

Substituting for |Gc(jω)| from previous equation, we get

Kp =cos θ

|G(jωg)|

Similarly, we have

KDωg −KI

ωg=

sin θ

|G(jωg)|

September 6, 2011 Control Systems Laboratory, IIT Kanpur Page 54

Page 55: bode_lect

design of PID compensator

Now at ωg = 1 rad/s,

G(jωg) = 0.1754∠− 142.1250◦

For the compensated system to have a phase margin of 60◦ at ωg = 1 rad/sec, we

should have

−180 + φm = θ + ∠G(jω) (φm = PM)

θ = −180◦ + 60◦ + 142.1250◦ = 22.1250◦

Hence,

KP =cos 22.1250◦

0.1754= 3.9571

Lets choose KI = 0, then KD can be computed to be

KD =sin 22.1250◦

0.1754+ 1 = 3.1471

Hence we have a PD compensator Gc(s) = 3.9571 + 3.1471s.

September 6, 2011 Control Systems Laboratory, IIT Kanpur Page 55

Page 56: bode_lect

design of PID compensator

−50

0

50

100

150

Mag

nitu

de (

dB)

10−2

10−1

100

101

102

−180

−135

−90

−45

Pha

se (

deg)

Bode DiagramGm = Inf , Pm = 60 deg (at 1 rad/sec)

Frequency (rad/sec)

Figure 21: Bode plot of compensated system Gc(s)G(s) = (3.9571+3.1471s)(s+1)s2(s+8)

September 6, 2011 Control Systems Laboratory, IIT Kanpur Page 56

Page 57: bode_lect

design of PID compensator

0 2 4 6 8 10 12 14 160

0.2

0.4

0.6

0.8

1

1.2

1.4

System: h Peak amplitude: 1.26

Overshoot (%): 26 At time (sec): 3.24

System: h Settling Time (sec): 9.89

Step Response

Time (sec)

Am

plitu

de

Figure 22: Step response of compensated system

September 6, 2011 Control Systems Laboratory, IIT Kanpur Page 57

Page 58: bode_lect

Summary

Following topics were covered in this lecture

• Frequency domain specifications.

• Bode plot construction

• Relative stability

• Design of Lead and Lag compensators

• PID control design example.

September 6, 2011 Control Systems Laboratory, IIT Kanpur Page 58

Page 59: bode_lect

The Principle of Argument

September 6, 2011 Control Systems Laboratory, IIT Kanpur Page 59