chapter 4 block diagrams of control systems

Upload: zeynal-abidin-sabas

Post on 05-Jul-2018

217 views

Category:

Documents


0 download

TRANSCRIPT

  • 8/15/2019 Chapter 4 Block Diagrams of Control Systems

    1/18

    22.02.2015

    1

    EEE 352 Automatic Control Systems

    Chapter 4: Block Diagrams of Control Systems

    Prof. Dr. Ahmet Uçar

    © Dr. Ahmet Uçar EEE 352 Chapter 4 1

    Block Diagrams of Control Systems

    © Dr. Ahmet Uçar EEE 352 Chapter 4 2

     A block diagram of a system is a pictorial representation of the functions

    performed by each component and of the flow of signals. Such a diagram depicts

    the interrelationshipsthat exist among the various components.

    Differing from a purely abstract mathematical representation, a block diagram

    has the advantage of indicating more realistically the signal flows of the actual

    system.

    The nonlinear and linear systems canbe represented by block diagrams.

    The nonlinear systems

    F ( x, u)y (t )

    Output

    signal 

    u(t )

    Input

    signal 

    State initial condition;

     x(t =0)  0

    The linear systems

    Transfer

    function

    G(s)

    R(s)

    Input

    signal 

    Y (s)

    Output

    signal 

    State initial condition;

     x(t =0)  0

  • 8/15/2019 Chapter 4 Block Diagrams of Control Systems

    2/18

    22.02.2015

    2

    Block Diagrams of Control Systems

    © Dr. Ahmet Uçar EEE 352 Chapter 4 3

    Drawing a Block Diagram of linear systems:

    The transfer functions of the components are usually entered in the

    corresponding blocks, which are connected by arrows to indicate the direction of 

    the flow of signals.

    Transfer

    function

    G(s)

    R(s)

    Input

    signal 

    Y (s)

    Output

    signal 

    Branch point

    G( s) R( s) Y ( s)

     H ( s)

     E (s)Gc( s)

    Summing point

    Block Diagrams of Control Systems

    © Dr. Ahmet Uçar EEE 352 Chapter 4 4

    Drawing a Block Diagram of linear systems with the Laplace transforms.

    •Write the equations that describe the dynamic behavior of each component.

    •Take the Laplace transforms of these equations, assuming zero initial

    conditions.

    •Represent each Laplace-transformed equation individually in block form.

    •Assemble the elements into a complete block diagram.

    ei   e0 R

    C  I 

    Example 4.1 a): Draw block diagram of the following RC circuit with the

    Laplace transforms?

    Solution 4.1 a): Let define the error between input and output signal as E (s)

    )1()()()( 0   s E  s E  s E  i  

     E i( s)

     E 0( s)

     E ( s)

  • 8/15/2019 Chapter 4 Block Diagrams of Control Systems

    3/18

    22.02.2015

    3

    Block Diagrams of Control Systems

    © Dr. Ahmet Uçar EEE 352 Chapter 4 5

    Example 4.1: a) Write current I(s)

    )2()(1

    )(   s E  R

     s I   

    )3()0()(1

    1),0(

    1

    00

    00

    e s I Cs

     E 

     sdt e Idt 

    C e

    Write output E 0(s)

    ei   e0 R

    C  I E (s)   I(s)

     R

    1

    Finally, assemble the elements into a complete

    block diagram.

    E 0(s)I(s)

    Cs

    1

    e0(0)0

     E i( s)  E 0( s) E ( s)   I ( s)

     R

    1

    Cs

    1

    e0(0)0

    Block Diagrams of Control Systems

    © Dr. Ahmet Uçar EEE 352 Chapter 4 6

    Drawing a Block Diagram of linear systems with time domain:

    •Write the equations that describe the dynamic behavior of each component.

    •Represent each equation individually'inblock form.

    •Assemble the elements into a complete block diagram.

    ei   e0, e0(0)0 R

    C  I 

    Example 4.1 b): Draw block diagram of the following RC circuit without Laplace

    transform ?

    Solution 4.1 b): Let define the error between input and output signal as e(t )

    )1()()()( 0   t et et e i  

    ei(t )

    e0(t )

    e(t )

  • 8/15/2019 Chapter 4 Block Diagrams of Control Systems

    4/18

    22.02.2015

    4

    Block Diagrams of Control Systems

    © Dr. Ahmet Uçar EEE 352 Chapter 4 7

    Example 4.1 b): Write current i (t )

    )2()(1

    )(   t e R

    t i  

    )3()0()(1

    )( 00       t edt t iC t e

    Write output e0(t )

    ei   e0 R

    C  I e(s)   i (t )

     R

    1

    Finally, assemble the elements into a complete block diagram.

    e0(t )i(t )

    e0(0)0

    ei(t ) e0(t )e(t )   i(t )

     R

    1

    e0(0)0

    1

    Block Diagrams of Control Systems

    © Dr. Ahmet Uçar EEE 352 Chapter 4 8

    Block diagram of continuous time control system represented in state space

    r mnm

    r nnn

     R D RC t  Dut Cxt  y

     R B R At  But  Axt  x

    ,)()()(

    ,)()()(

     s1 B

     D

     A

    C U ( s)   Y ( s) X ( s)

    In time domain:

    In Laplace domain:

    dt  B

     D

     A

    C u(t )   )(t  x   x(t )   y(t )

     x0(0)0

  • 8/15/2019 Chapter 4 Block Diagrams of Control Systems

    5/18

    22.02.2015

    5

    Block Diagrams of Control SystemsRules of Block Diagram Algebra

    © Dr. Ahmet Uçar EEE 352 Chapter 4 9

    Original Block Diagram Equivalent Block Diagram

    1.Combining blocks in

    cascade

    2. Moving a summing

    point behind a block

    A complicated block diagram involving many feedback loops can be simplified by

    a step-by-step rearrangement. Simplification of the block diagram by

    rearrangements considerably reduces the labour needed for subsequent

    mathematical analysis.The following rules block diagram algebra can be used.

    G1( s) G2( s)Y ( s) R( s)

    G1( s) R( s)

    G2( s)  Y ( s) X ( s)

     

     R( s)G1( s)

    Y ( s)

     B( s) 

     R( s) Y ( s)

    G1( s)

    G1( s)

     B( s)

    Block Diagrams of Control SystemsRules of Block Diagram Algebra

    © Dr. Ahmet Uçar EEE 352 Chapter 4 10

    Original Block Diagram Equivalent Block Diagram

    3. Moving a branch point

    ahead of a block   R( s)G1( s)

    Y ( s)

    Y ( s)

     R( s)   Y ( s)

    G1( s)

    G1( s)

    Y ( s)

    4. Moving a branch

    point behind a block  R( s)

    G1( s)  Y ( s)

     R( s)

     R( s) Y ( s)G1( s)

     R( s)

    )(

    1

    1   sG

     

     R( s)G1( s)

    Y ( s)

     B( s)

       R( s)G1( s)

     B( s)

     

    )(

    1

    1   sG

    Y ( s)

    5. Moving a summing point

    ahead of a block

  • 8/15/2019 Chapter 4 Block Diagrams of Control Systems

    6/18

    22.02.2015

    6

    Block Diagrams of Control SystemsRules of Block Diagram Algebra

    © Dr. Ahmet Uçar EEE 352 Chapter 4 11

    Original Block Diagram Equivalent Block Diagram

    6. Eliminating a feedback

    loop   Y ( s)G( s)

     

     R( s)   E ( s)+

     H ( s)

    Y ( s) R( s)

    )()(1

    )(

     s H  sG

     sG

    Example 4.2: Consider the system shown in the following Figure.

    Simplify this diagram?

    G1 R

     H 2

    G2   G3Y 

     H 1

    Block Diagrams of Control Systems

    Rules of Block Diagram Algebra

    © Dr. Ahmet Uçar EEE 352 Chapter 4 12

    Example 4.2:(cont.)

    G1 R

     H 2

    G2   G3Y 

     H 1

    G1 R

     H 2/G1

    G2   G3Y 

     H 1

    By moving the summing point of the negative feedback loop containing H2 outside the

    positivefeedback loop containing H1:

    Eliminating the positive feedback loop:

     R

     H 2/G1

    G3Y 

    121

    21

    1   H GG

    GG

  • 8/15/2019 Chapter 4 Block Diagrams of Control Systems

    7/18

    22.02.2015

    7

    Block Diagrams of Control Systems

    Rules of Block Diagram Algebra

    © Dr. Ahmet Uçar EEE 352 Chapter 4 13

    Example 4.2 : (cont.)

    The elimination of the loop containing H2/G1:

     R   Y 

    232121

    321

    1   H GG H GG

    GGG

     R

     H 2/G1

    G3Y 

    121

    21

    1   H GG

    GG

    Finally, eliminating the feedback loop results overall system transfer function:

     R   Y 

    321232121

    321

    1   GGG H GG H GG

    GGG

    Remark. The numerator of the closed-loop transfer function Y (s)/R(s) is the product of

    the transfer functions of the feedforward path: G1(s)G2(s)G3(s)

    The denominator of Y (s)/R(s) is equal to

    1 -  (product of the transfer functions around each loop)

    Block Diagrams of Control Systems

    Rules of Block Diagram Algebra

    © Dr. Ahmet Uçar EEE 352 Chapter 4 14

    Example 4.2 :(cont.)

    The system transfer function: R   Y 

    321232121

    321

    1   GGG H GG H GG

    GGG

    Remark.

    The numerator of the closed-loop transfer function Y (s)/R(s) is the product of

    the transfer functions of the feedforward path: G1(s)G2(s)G3(s)

    The denominator of Y (s)/R(s) is equal to

    1 - 

    (product of the transfer functions around each loop)

    G1 R

     H 2

    G2   G3Y 

     H 1

    321232121

    321232121

    1

    )(1

    GGG H GG H GG

    GGG H GG H GG

    The positive feedback loop yields a negative term in the denominator.

  • 8/15/2019 Chapter 4 Block Diagrams of Control Systems

    8/18

    22.02.2015

    8

    Block Diagrams of Control Systems in MATLAB

    © Dr. Ahmet Uçar EEE 352 Chapter 4 15

    Example 4.3: Find the transfer function of the following system with given blocks

    transfer functions.

    Y ( s)G2

     R( s) H 2

    G3   G4

     H 1

    G1

     H 3

    10

    1)(1

     s

     sGMATLAB Command

    %%%%%%%%%%%%%%%%%%%%%

    % Modelling blocks

    ng1=[1]; dg1=[1 10];sysg1=tf(ng1,dg1)

    ng2=[1]; dg2=[1 1];sysg2=tf(ng2,dg2)

    ng3=[1 0 1]; dg3=[1 4 4];sysg3=tf(ng3,dg3)ng4=[1 1]; dg4=[1 6];sysg4=tf(ng4,dg4)

    nh1=[1 1]; dh1=[1 2];sysh1=tf(nh1,dh1)

    nh2=[2]; dh2=[1];sysh2=tf(nh2,dh2)

    nh3=[1]; dh3=[1];sysh3=tf(nh3,dh3)

    1

    1)(2

     s

     sG

    44

    1

    )( 2

    2

    3

     s s

     s

     sG

    6

    1)(4

     s

     s sG

    2

    1)(1

     s

     s s H 

    2)(2    s H 

    1)(3    s H 

    Block Diagrams of Control Systems in MATLAB

    © Dr. Ahmet Uçar EEE 352 Chapter 4 16

    Example 4.3:

    Y ( s)G2

     R( s)

     H 2/G4

    G3   G4

     H 1

    G1

     H 3

    sys2

    sys4 sys3

    sys1

    sys6

    sys

    sys5

    MATLAB Command

    % Block Diagram Reduction

    sys1=sysh2/sysg4

    sys2=series(sysg3,sysg4)

    sys3=feedback(sys2,sysh1,+1)

    712219631282517106620512

    25664

    )(

    )(23456

    2345

     s s s s s s

     s s s s s sys

     s R

     sY 

    sys4=series(sysg2,sys3)

    sys5=feedback(sys4,sys1,-1)

    sys6=series(sysg1,sys5)

    sys=feedback(sys6,sysh3)

  • 8/15/2019 Chapter 4 Block Diagrams of Control Systems

    9/18

    22.02.2015

    9

    Block Diagrams of Control Systems in MATLAB

    © Dr. Ahmet Uçar EEE 352 Chapter 4 17

    MATLAB Command

    sysmr = minreal(sys)

    Eliminates cancels pole-zero pairs in transfer functions or zero-pole-gain

    models.

    The output sysmr has minimal order and the same response characteristics

    as the original model sys.

    Ones many feedback loops simplified it is difficult to observe pole zero pairs toreduce system transfer function futher. However this can readly achived with

    Matlab.

    712219631282517106620512

    25664

    )(

    )(23456

    2345

     s s s s s s

     s s s s s sys

     s R

     sY 

    Example 4.14: (cont.)

    Block Diagrams of Control Systems in MATLAB

    © Dr. Ahmet Uçar EEE 352 Chapter 4 18

    MATLAB Commandsysmr = minreal(sys)

    712219631282517106620512

    25664

    )(

    )(23456

    2345

     s s s s s s

     s s s s s sys

     s R

     sY 

    33.597.12313775.7208.16

    1667.025.025.025.008333.0

    )(

    )(2345

    234

     s s s s s

     s s s s sysmr 

     s R

     sY 

    Both transfer functions have the same response characteristics

    Example 4.3:

  • 8/15/2019 Chapter 4 Block Diagrams of Control Systems

    10/18

    22.02.2015

    10

    Block Diagrams of Control Systems in MATLAB

    © Dr. Ahmet Uçar EEE 352 Chapter 4 19

    Homework 4.1: Simplify the block diagram shown in Figure and obtain theclosed loop transfer function Y (s)/R(s).

    Homework 4.2: Simplify the block diagram shown in Figure and obtain the closed

    loop transfer function Y (s)/R(s).

     R( s)   Y ( s)

    G1( s)   G2( s)  G3( s)

     H 1( s)

     H 2( s)

     H 3( s)

     R( s) Y ( s) E 1(s)G1( s)   G2( s)

     H 1( s)   H 2( s)

     H 3( s)

    G3( s)   G4( s)

     E 2(s)

    Block Diagrams of Control Systems

    © Dr. Ahmet Uçar EEE 352 Chapter 4 20

    Drawing a Block Diagram of nolinear systems:

    •Write the equations that describe the dynamic behavior of each component.

    •Represent each equation individually'inblock form.

    •Assemble the elements into a complete block diagram.

    Example 4.4: Draw block diagram of the following nonlinear system for non

    zero state initial conditions? The system output is y = x ?

     x y

     x x x x

      036.0   2

  • 8/15/2019 Chapter 4 Block Diagrams of Control Systems

    11/18

    22.02.2015

    11

    Block Diagram of Nonlinear Systems

    © Dr. Ahmet Uçar EEE 352 Chapter 4 21

     x y

     x x x x

      036.0   2

    Solution 4.4: We start to draw the block diagram from the system output  y

    1 x(t )   y(t )

    and considering the integration process as; x(t )

     x0(0)0

    )(t  x

    1 y(t ) x(t )

     x0(0)0

    )(t  x

    )(t  x

    0)0(0    x

    0.6

    3

    ( )2

    Block Diagram of Nonlinear Systems

    © Dr. Ahmet Uçar EEE 352 Chapter 4 22

    Example 4.5: Draw block diagram of the following nonlinear system for non

    zero state initial conditions? The system output is y = x 1 ?

    1

    21

    2

    12

    21

    )1(

     x y

    u x x x x

     x x

    m  u

     x1 xe= 022 )(   x xc  

    3

    111)(   x x xk   

    Physical

    System

     f ( x )

    Output

    y s(t )

    Input

    u(t ) 0

    State initial

    condition ;

     x(t =0)  0

  • 8/15/2019 Chapter 4 Block Diagrams of Control Systems

    12/18

    22.02.2015

    12

    Block Diagram of Nonlinear Systems

    © Dr. Ahmet Uçar EEE 352 Chapter 4 23

    1

    21

    2

    12

    21

    )1(

     x y

    u x x x x

     x x

    m  u

     x1 xe= 022 )(   x xc  

    3

    111)(   x x xk   

    Solution 4.5: We start to draw the block diagram from the system output  y andconsidering the integration process.

    1 y(t ) x1(t )

     x10(0)0

    )(2   t  x

    )(2   t  x

    1

    ( )3

    u(t )

     x20(0)0

    Block Diagram of Nonlinear Systems

    © Dr. Ahmet Uçar EEE 352 Chapter 4 24

    Homework 4.3: Draw block diagram of the following nonlinear system for non

    zero state initial conditions? The system output is y = x .

    Homework 4.4: Draw block diagram of the following nonlinear system for non

    zero state initial conditions? The system output is y = x 1 .

    u x x x x       )1(   2

    2

    3

    112

    21

     x x x x

     x x

  • 8/15/2019 Chapter 4 Block Diagrams of Control Systems

    13/18

    22.02.2015

    13

    MATLAB/Simulink

    © Dr. Ahmet Uçar EEE 352 Chapter 4 25

    Simulink provides a graphical editor, customizable block libraries, and solvers for

    modeling and simulating dynamic systems. It is integrated with MATLAB, enabling

    you to incorporate MATLAB algorithms into models and export simulation results

    to MATLAB for further analysis.

    The construction of a model is simplified with click-and-drag mouse operations.

    Simulink includes a comprehensive block library of toolboxes to analyze and

    design the linear and nonlinear systems.

    Open Simulink Library Browser

    Start MATLAB, and then in the MATLAB Command Window,

    a) enter

    » simulink or

    b) by clicking the Simulink icon in the MATLAB toolbar or

    Simulink Block Diagram of Control Systems

    © Dr. Ahmet Uçar EEE 352 Chapter 4 26

    c ) by clicking the MATLAB Start button, then selecting Simulink > Library Browser

    The Simulink Library Browser in Figure 2 opens.

  • 8/15/2019 Chapter 4 Block Diagrams of Control Systems

    14/18

    22.02.2015

    14

    Simulink Block Diagram of Control Systems

    © Dr. Ahmet Uçar EEE 352 Chapter 4 27

    Create a New Simulink Model from Simulink Library Browser1. From the Simulink Library Browser menu, select File> New> Model.

    An empty model opens in the Simulink Editor;

    2. Use Simulink library and build the system block diagram.

    3. In the Simulink Editor, select File > Save.

    4. In the Save As dialog box, enter a name for your model, and then click Save.

    Simulink saves your model.

    Simulink Block Diagram of Control Systems

    © Dr. Ahmet Uçar EEE 352 Chapter 4 28

    Example 4.6: Obtain SIMULINK model the following RC circuit.

    ei   e0, e0(0)0 R

    C  I 

    The complete block diagram of the system is;

    ei(t ) e0(t )e(t )   i(t )

     R

    1

    e0(0)0

    1

  • 8/15/2019 Chapter 4 Block Diagrams of Control Systems

    15/18

    22.02.2015

    15

    Simulink Block Diagram of Control Systems

    © Dr. Ahmet Uçar EEE 352 Chapter 4 29

    The block diagram of the circuit/system can be directly implemented in

    SIMULINK, as shown in the following Figure:

    Solution 4.6:Assume ei(t ) is a DC input.

    ei(t ) e0(t )e(t )   i(t )

     R

    1

    e0(0)0

    1

    yo

    ei; e0

    ei; e0

    ei

    -1

    e0(0)

    1

    sxo

    Integrator 

    1

    Gain1

    1/2

    1/R

    1

    1/C

    Simulink Block Diagram of Control Systems

    © Dr. Ahmet Uçar EEE 352 Chapter 4 30

    Example 4.7: A Damped Pendulum System is depicted Figure shows it can

    rotate freely around its fixed point P. It consists of a rod with angle

    represented by  from the vertical position. Using the equation of motion for

    a damped pendulum given by

    Obtain SIMULINK model the following nonlinear systems.

    2122

    21

    sinml 

    T  x

     g  x

    ml 

    c x

     x x

    c

     v

    h

     P 

    2sin

    ml 

     g 

    ml 

    c   c        

    here   is the angle of the pendulum from the vertical (in radians),c= 0.15 is the velocity damping term (in 1/sec),

    m= 1 is the mass of the pendulum (in kilograms),

    l =2.5 is the length (in meters),

    g= 9.81 is the acceleration due to gravity (in m/s2) and

    T c is the force input (in N).

    Changing state variable as leads to),(),( 21   x x    

  • 8/15/2019 Chapter 4 Block Diagrams of Control Systems

    16/18

    22.02.2015

    16

    Simulink Block Diagram of Control Systems

    © Dr. Ahmet Uçar EEE 352 Chapter 4 31

    The SIMULINK model is given in the following Figure:

    Solution 4.7:

    2122

    21

    sinml 

    T  x

     g  x

    ml 

    c x

     x x

    c

    x2

    x2x1

    x1

    1

    s

    int x2

    1

    s

    int x1

    -K-c/ml1

    K

    c/ml

    XY Graph

    Tc

    sin

    Sin(x1)

    Scope

    K

    1/ml

    Simulink Block Diagram of Control Systems

    © Dr. Ahmet Uçar EEE 352 Chapter 4 32

    Open an Existing Model

    Open an existing Simulink model from the Simulink Library Browser.

    1. From the Simulink Library Browser menu, select File > Open.

    2. In the Open dialog box, select the model file that you want to open, and then

    click Open.

  • 8/15/2019 Chapter 4 Block Diagrams of Control Systems

    17/18

    22.02.2015

    17

    Block Diagram of Control Systems

    © Dr. Ahmet Uçar EEE 352 Chapter 4 33

    Homework 4.5: Model the following system in SIMULINK and depict the timeresponse of the system output y = x for;

    a) u=0 and state initial condition; x0=(1,2).

    b) u=1 and state initial condition; x0=(0,0).

    u x x x x       )1(   2

    2

    2

    112

    21

    )1(   x x x x

     x x

    Homework 4.6: Model the following system in SIMULINK and depict x1 versus

    x2 for

    a) state initial condition; x0=(0.2,0.2).

    b) state initial condition; x0=(4,4).

    Block Diagram of Nonlinear Systems

    © Dr. Ahmet Uçar EEE 352 Chapter 4 34

    2

    3

    112

    21

     x x x x

     x x

    Homework 4.7: Model the following system in SIMULINK.

    a) depict the time response of the system output y = x 1 for state initial condition;

    x0=(-1,1).

    and depict x1 versus x2 for

    b) state initial condition; x0=(-0.5,0).

    c) state initial condition; x0=(0.5,0).

    d) state initial condition; x0=(1.5,0).

  • 8/15/2019 Chapter 4 Block Diagrams of Control Systems

    18/18

    22.02.2015

    © Dr. Ahmet Uçar EEE 352 Chapter 6 35

    EEE 352 Automatic Control Systems

    Chapter 4: Block Diagrams of Control Systems

    Remarks and Questions?