ame30315 spr2013 homework 12 solution

Upload: arshad-ali

Post on 02-Mar-2018

231 views

Category:

Documents


0 download

TRANSCRIPT

  • 7/26/2019 AME30315 Spr2013 Homework 12 Solution

    1/14

    1Homework 12 Solution - AME30315, Spring 2013

    Problem 1:[20 pts] The Aerotech AGS 1500 is a linear motor driven XY positioning system (see attachedproduct sheet). A friend of mine, through careful experimentation, identified the following plant model forthe X axis:

    P(s) = 1738.42

    s2 + 8.24s+ 1.061 104 s2 + 25.6s+ 1.024 105

    s (s+ 0.57)(s2 + 10.7s+ 1.145 104) (s2 + 142.5s+ 1.406 105) .

    (a)Use the Matlab GUIs rltoolor sisotooland hand-calculations to design a controller such that the overshootis < 20% and rise time is less than 0.1 sec for a step reference signal, ess for a unit ramp reference is lessthan 0.01, the gain margin is greater than 6dB, and the closed-loop bandwidth is greater than 30 rad/sec.Some specifications may already be met by the uncompensated system.General Procedure to do so:

    Use the open-loop bode plot to determine the uncompensated phase margin Design a controller K(s) that has a low-frequency gain and phase margin such that you can achieve

    the design specifications.

    Estimate the system closed-loop system bandwidth from the complementary sensitivity function. Iterate on design if necessary

    Display any plots and useful insight used in your controller design. For time-domain plots, plot your refer-ence signal on the same plot as the output.

    (b) A smoothed step input signal is attached to the homework problem; 500mm move in 1 second, hold at500mm for 1 second. With the smoothed step as a reference signal, evaluate the controller performance.Does youress calculation compare well with the ramped portion of the smoothed step simulation? Does theerror increase during the parabolic region of the smoothed step? Plot your reference signal on the same plotas the output.

    (c)Change your reference signal to a sine wave. Test two different sine wave references. One with a frequency20 rad/s lower than your closed loop bandwidth, one with a frequency 20 rad/s higher than your closed loopbandwidth. Discuss your observed relationship between the frequency of a reference signal, closed-loop band-width, and the tracking error. Plot your reference signal on the same plot as the output.

    Solution: Plotting the system on siso tool reveals that the system is unstable. The system has a gain marginof -5.58 dB and a phase margin of -0.866 degrees. We will be stabilizing the system with a lead controller.For now we will look at the ess for a ramp.From closed loop response

    Y(s)

    R(s) =

    K(s)P(s)

    1 +K(s)P(s)

    Steady state response error is

    E(s)R(s)

    = 11 +K(s)P(s)

    ess = lims0

    s 1

    1 +K(s)P(s)R(s)

    Wantess< 0.01 for ramp input R(s) = 1s2

    ess= lims0

    s 1

    1 +K(s)P(s)

    1

    s2 = lim

    s0

    1

    s

    1

    1 +K(s)P(s)

  • 7/26/2019 AME30315 Spr2013 Homework 12 Solution

    2/14

    2LetP(s) = 1s

    P(s)

    ess = lims0

    s 1

    1 +K(s)1s

    P(s))

    1

    s2

    = lims

    0

    1

    s

    1

    1 +K(s)1

    s P(s))

    = lims0

    1

    s+K(s)P(s)

    = lims0

    1

    0 +K(s)P(0)

    = lims0

    1

    K(s)(2058.28)

    = 1

    2058.28lims0

    1

    K(s)

    Recap:

    ess = 1

    2058.28

    lims0

    1

    K(s)

    0.45 from our vs. maps. Also weknow that= m

    100, so we want m 45o.

    We want to design a lead controller with max to boost our phase margin. Allowing 10o extra, we want

    max = 55o. From fig.10.30, should be 10. max should be chosen at the frequency where | K(s)P(s) |dB=

    0 dB. max = 34 rad/sec.max = z

    , z=10.75, z = 107.5.

    This gives a controller design of

    K(s) =s

    10.75+ 1

    s107.5

    + 1

    Fig.2 demonstrates the 1st design iteration. As you can see, we did not quite reach the desired m = 450.We can make larger to achieve this. By moving the pole to higher frequencies, we achieve the desired m(see Fig.3 )

    K(s) =s

    10.75+ 1

    s

    177

    + 1

    Fig.4 demonstrates that we now achieve the desired specifications.[5 pts]

    Test with smoothed step input. Our design appears to do quite well since the designed steady state error isalmost 0.01. The error does increase during the parabolic region.[1 pt]. Smoothed step performance Fig.5.Zoomed in region demonstrates that the performance is worse in parabolic region, Fig.6. [5 pts]

    CL bandwidth is approximately 85 rad/sec. Test a sine wave at 65 rad/sec Fig.7 and at 115 rad/sec Fig.8.[5 pts]If the frequency is less than the bandwidth, there is an increase in amplitude, however not that much. The

  • 7/26/2019 AME30315 Spr2013 Homework 12 Solution

    3/14

    3phase differs only by a little bit.If the frequency is greater than the bandwidth, the amplitude of the responseis decreased and the phase differs quite a bit. [1 pt]Overall the tracking error s smaller for frequencies inside the bandwidth compared to frequencies outside thebandwidth.

    Figure 1: Controller plot

  • 7/26/2019 AME30315 Spr2013 Homework 12 Solution

    4/14

    4

    Figure 2: Controller plot

  • 7/26/2019 AME30315 Spr2013 Homework 12 Solution

    5/14

    5

    Figure 3: Controller plot

  • 7/26/2019 AME30315 Spr2013 Homework 12 Solution

    6/14

    6

    Figure 4: step response

    Figure 5: smoothed step signal

  • 7/26/2019 AME30315 Spr2013 Homework 12 Solution

    7/14

    7

    Figure 6: Zoomed in region of smoothed step signal

    Figure 7: Sine wave of 65 rad/sec

  • 7/26/2019 AME30315 Spr2013 Homework 12 Solution

    8/14

    8

    Figure 8: Sine wave of 115 rad/sec

  • 7/26/2019 AME30315 Spr2013 Homework 12 Solution

    9/14

    9Bonus Problem 2: 10pts added to HW12 homework grade.For the system shown in Fig. 9,supposethat:

    P(s) = 5

    s (s+ 1) (s/5 + 1).

    Design a lead compensator K(s) so that the m > 40 using Bode plot sketches. You must show all your

    calculations to receive full credit. Once designed by hand, verify and refine your design using Matlab.

    R(s) Y(s)+

    -

    K(s) P(s)

    Figure 9: Feedback Loop for Bonus Problem 2.

    Solution: Plot uncompensated system using the standard bode plotting procedure(Fig. 10)| G(i)|dB= 0 at approximated 2 rad/sec. Here, our hand drawn bode plot tells us that we are unstable,m 10o.Therefore, we need to increase m by 50

    o to achieve a m of 40o. Choose max = 50

    o + 10o = 60o. FromFig.10.30, this means = 20.Choose max to be frequency where| G(i) |dB= 0 dB. max = z

    for a lead controller [2ts].

    z=max

    0.5rad/sec

    p= z = 10rad/sec

    Here we replot the change in phase and magnitude on the same plot as Fig.10. Notice that we did notachieve the m we desired. Plots in Matlab confirm this(see Fig.11). The hand drawn plot gives us a basisfor further improvement. By moving the zero to -0.8 and the pole to -36 we get the phase margin we desire(see Fig. 12).

  • 7/26/2019 AME30315 Spr2013 Homework 12 Solution

    10/14

    10

    Figure 10: Bode plot [3pts uncompensated, 3pts compensated]

  • 7/26/2019 AME30315 Spr2013 Homework 12 Solution

    11/14

    11

    101

    100

    101

    102

    103

    360

    180

    0

    Frequency (rad/s)

    200

    100

    0

    100Bode Editor for Closed Loop 1 (CL1)

    102

    100

    102

    104

    270

    225

    180

    135

    90

    45

    P.M.: 16.7 degFreq: 5.68 rad/s

    Frequency (rad/s)

    150

    100

    50

    0

    50

    100

    G.M.: 4.8 dBFreq: 7.58 rad/sStable loop

    OpenLoop Bode Editor for Open Loop 1 (OL1)

    30 20 10 0 1020

    15

    10

    5

    0

    5

    10

    15

    20Root Locus Editor for Open Loop 1 (OL1)

    Figure 11: Controller plot

  • 7/26/2019 AME30315 Spr2013 Homework 12 Solution

    12/14

    12

    101

    100

    101

    102

    103

    360

    180

    0

    Frequency (rad/s)

    200

    100

    0

    100Bode Editor for Closed Loop 1 (CL1)

    101

    100

    101

    102

    103

    270

    225

    180

    135

    90

    P.M.: 44.1 degFreq: 4.32 rad/s

    Frequency (rad/s)

    120

    100

    80

    60

    40

    20

    0

    20

    40

    G.M.: 17.3 dBFreq: 13.6 rad/sStable loop

    OpenLoop Bode Editor for Open Loop 1 (OL1)

    100 50 0 50100

    50

    0

    50

    100Root Locus Editor for Open Loop 1 (OL1)

    Figure 12: Controller plot [2pts]

  • 7/26/2019 AME30315 Spr2013 Homework 12 Solution

    13/14

    13Bonus Problem 3: 10pts added to HW12 homework grade, 1 kernel of knowledge added toyour brain.This problem is similar to Problem 10.11 of Goodwine (with some extra and without the typo). The standardlead or lag compensator has the general form:

    K(s) =sz

    + 1s

    p + 1

    .

    Find the frequency, max, at which K(s) has a maximum phase lead or lag, max. Then calculate max.Your solution should verify the equation just prior to Eqn. (10.3) and the phase lead calculation in Eqn.(10.4).Solution:K(i) is a function of frequency. We wish to find the frequency at which K(i) is maximized and thevalue of that maximum point. To find the frequency of maximum phase (max), we differentiate K(i)with respect to and set equal to 0.

    K(s) =sz

    + 1sp

    + 1

    K(i) =

    i

    z + 1ip

    + 1

    K(i) = tan1

    z tan1

    p

    u=

    z,

    du

    d =

    1

    z

    y= a tan u, dy

    du=

    1

    u2 + 1dy

    d =

    1

    z

    1

    (z

    )2 + 1

    d

    dK(i) =

    1

    z

    1

    (z

    )2 + 1 1

    p

    1

    (p

    )2 + 1

    =p((

    p)2 + 1) z((

    z)2 + 1)

    zp((z

    )2 + 1)((p

    )2 + 1) [2pts]

    Set dd

    K(i) = 0

    2

    p +p

    2

    z z = 0

    2(1

    p 1

    z) = z p

    2 = z p1

    p 1

    z

    =z pzppz

    =pz

    max = zp[3pts]

  • 7/26/2019 AME30315 Spr2013 Homework 12 Solution

    14/14

    14We next substitute maxintoK(i) to solve for the maximum phase angle, max:

    max = tan1

    p

    z tan1

    z

    p

    = tan1

    pzp

    z

    1 +p

    zz

    p

    = tan11

    2(

    p

    z

    z

    p)

    = tan11

    2

    p zzp

    zp+

    1

    4(p2 2pz+z2) =

    1

    4p2 +

    1

    2pz+

    1

    4z2

    = 12

    p2 + 2pz+z2

    = 1

    2(p+z)

    Therefore,

    max= = sin1

    1

    2(p z)

    1

    2(p+z)

    = sin1p zp+z

    [5pts]