Stabilization of Rotary Arm Inverted Pendulum using State Feedback Techniques

DOI : 10.17577/IJERTV4IS070483

Download Full-Text PDF Cite this Publication

Text Only Version

Stabilization of Rotary Arm Inverted Pendulum using State Feedback Techniques

Jithin Babu

Electrical & Electronics Department

Mar Baselios College of Engineering & Technology Trivandrum, Kerala, India

Elizabeth Varghese

Associate Professor, Electrical & Electronics Department

Mar Baselios College of Engineering & Technology Trivandrum, Kerala, India

AbstractInverted pendulum is a pendulum which has its mass above its pivot point and owing to its inherent non-linear nature the control of inverted pendulum is difficult and therefore suitable to test modern control algorithms.The main idea of this paper is to compare and analyse the performance of different control algorithms in order to balance the inverted pendulum in its upright position. Pole placement technique and LQR methods are used to stabilize the pendulum. In this work, the inverted pendulum system was modelled and constructed using Simulink and the performance of the proposed controllers are compared through simulations using Mat lab. Simulation results shows that both LQR Controller and pole placement controller are far more superior in achieving desired response and are more robust when compared to conventional controllers. LQR controller provides better steady state response compared to state feedback controllers and state feedback controller improves transient characteristics.

Keywords- LQR, Pole Placement, Rotary arm Inverted pendulum, Stabilization

1. INTRODUCTION

By the time of launching a rocket or space craft the main difficulty is to maintain the rocket in the upright position against gravity and keep it on a pre-specified trajectory by overcoming all external disturbances and internal non- linearity present with the system. In the real world examples like balancing a broom stick on hand, Segway, Crane balancing, Robotics, air craft stabilization in the turbulent air flow etc. the stabilization about a desired point is a problem owing to the inherent non-linearity present with these systems. The risk behind these balancing problems can be studied with the help of Inverted pendulum models. Unlike simple pendulum an inverted pendulum has its centre of gravity over its axis of rotation and is highly nonlinear and an open loop unstable system that makes control more challenging and therefore it is well suited for verification and practice of ideas emerging in control theory and robotics. Rotary arm Inverted Pendulum (RIP) is one among the famous inverted pendulum model which is a simple structure, unstable non-minimum phase system subjected to many nonlinear characteristics.

Stabilization of RIP system using classical PID controller is still popular because of its ease of implementation. However in practical RIP system, there may be disturbances which come internally or externally. But for a classical PID controller it is difficult to limit these disturbances rapidly and hence difficult to achieve optimal performance. Only one of the systems parameters can be controlled by PID controller at a time [1]. Therefore for a multivariable system like RIP, more than one PID controller is required. In order to control arm angle and pendulum angle at the same time we need two PID controllers [1] [3], one for controlling the position of arm angle and other for pendulum angle.

Placing poles at the pre-defined locations is another technique so that the characteristics of the system response can be controlled effectively. Dominant pole placement [4]

  1. technique and LQR [1][2] methods are very powerful methods which can stabilize the pendulum with minimum control effort and time. The dynamics of the system can be controlled by these methods by changing the location of poles.

    Figure.1 represents RIP system which consists of a PMDC servo motor and to the shaft of this motor an L-shaped rotary arm is attached. The position of the PMDC motor is measured by using a quadrature encoder. The pendulum rotates freely in a vertical plane about a shaft mounted on double ball bearings attached to the rotary arm. One end of the shaft (on which the pendulum is locked) drives a servo potentiometer via a shaft coupler. The servo potentiometer measures the position (or angle) of the pendulum in the vertical plane. In its middle, there is a proprietary coupling mechanism which transfers DC power to the servo potentiometer and also transfers a voltage corresponding to pendulum position or angle back to the terminal blocks on the circular base. The stabilizing controller will work only when the pendulum is about a few degrees apart from the vertical position. Once the pendulum is close to vertical position, stabilizing controller will take the control of the pendulum and keep it in upright position. In this paper two different method of stabilization of rotary arm inverted pendulum is discussed viz., Full State Feedback method and LQR.

    Fig.1. Rotary arm Inverted Pendulum system

    The paper is organized as follows: Section 2 deals with the mathematical dynamic model of the system used both for the computer simulations (MATLAB) and for the mathematical design of the controllers. Section 3 goes through the main steps in the design of the control algorithms. Section 4 presents simulation results of the different method discussed, and finally several conclusions are drawn in Section 5.

    II. MATHEMATICAL MODELING OF RIP SYSTEM

    To analyze the system we need to obtain a mathematical model which describes the dynamics of RIP system. Derivation of mathematical model includes a non-linear model and a linear model of RIP system. The non-linear model describes the whole dynamics of the system. For designing a balancing controller linearized model is useful.

    The controlling parameters are motor position, pendulum

    TABLE.I SYMBOLS TO DESCRIBE EQUATION PARAMETERS

    Symbol

    Description

    Unit

    r

    Length of arm pivot to pendulum pivot

    m

    Motor shaft position

    radians

    Angular velocity of motor

    m/s2

    Pendulum angular deflection

    radians

    Pendulum angular velocity

    m/s2

    l p

    Pendulum length

    m

    m

    Mass of pendulum

    kg

    L

    Length of pendulum center of mass

    from pivot

    m

    g

    Gravitational acceleration

    m/s2

    v

    Input voltage

    volt

    Fig.2. Schematic representation of RIP system

    The governing differential equations of the system are as follows:

    2

    1

    ( + ) cos + 2

    angle and motor velocity. By adjusting these three parameters

    1 sin 2 +

    =

    (1)

    we control the RIP system. For deriving the mathematical 2

    model, pendulum is initially assumed in the direction of gravitational force i.e., in equilibrium state and therefore the initial conditions are taken as zero. Linear model shows close response to the non-linear model only for a particular range of pendulum angle and therefore stabilization controller take its role if the pendulum is of few degrees away from the vertical. Figure.2 shows the arm is rotating about z-axis and reference of arm position is taken to the x-axis nd the reference of pendulum angle is taken from the upward

    1 2 1 cos 1 sin = 0 (2)

    2 2 2

    where,

    = 1 2 (3)

    vertical. Parameters of RIP system is shown in Table.1

    or,

    =

    1

    2

    =

    (4)

    cos + sin 2 + = 1 2

    cos sin = 0 (5)

    e ac b2 p Beq K2

    (13)

    where,

    a (Jeq mr 2 ) 1

    The state space model is obtained from the linearized model.

    = +

    = (14)

    b mLr

    2

    c 1 mL2 (6)

    3

    d 1 mgL

    2

    The states of RIP system is chosen as

    () = [ ] (15)

    The linear state space model is given by

    Solving for from equation (5), we have

    0 0 1 0

    0 0 0 1

    0

    0

    [] =

    [] + 1 (16)

    = sin (7)

    cos cos

    0

    0

    1

    Substituting for in (5) from (7) and solving for and

    [0

    0] [ ]

    results in the following nonlinear equations

    1

    For obtaining state space model the frictional coefficient of both pendulum section and motor is assumed to be zero.

    =

    [ sin cos 2 cos sin 2

    + 1 cos ]

    After substituting the parameter values from Table II, the state space model is given by

    = 1 [ cos sin sin 2 + ] (8)

    0 0 1 0 0

    0 0 0 1 0

    1

    [] = [0 2.1440 0.1417 0] [] + [1.0928] (17)

    where,

    p Beq K2

    0 82.5677 0.19440 0

    1.4991

    f a c b2 cos2

    (9)

    1 0 0 0 0

    y v

    (18)

    1. Linearized model

      Equation (8) can be linearized by considering the

      0 1 0 0

      0

      Symbol

      Description

      Value

      (SI unit)

      Kt

      Motor torque constant

      0.1331

      Km

      Back emf

      0.1298

      J eq

      Equivalent moment of inertia at load

      0.0200484

      m

      Mass of pendulum

      0.035

      L

      Length of pendulum center of mass from pivot

      0.1848

      r

      Length of arm pivot to pendulum pivot

      0.169

      Ra

      Armature resistance of motor

      6

      equilibrium state of the system. If we assume is small (i.e., when the Inverted Pendulum is near its equilibrium point), we can linearize these equations.

      TABLE.II. TYPICAL CONFIGURATION OF RIP SYSTEM

      For small , sin( ) and cos( ) 1. Also, for small ,

      square of pendulum angular velocity is negligible, and we get the following linearized equations

      + = 1 2 (10)

      = 0 (11)

      = + 1 (12)

      where,

      1. CONTROLLER DESIGN

        1. Pole Placement Controller

          In this paper, controllers used for balancing pendulum in upright position are linear state feedback controllers. The state feedback controller can be used only if the system is controllable and it tracks the input signal or improve damping of the system. Figure.3 shows the block diagram of a pole placement controller. For a given system, the state feedback gain matrix K is not same but depends on the desired closed loop pole location. This will also determine the speed and damping of the response.

          Fig.3. Block diagram of pole placement controller

          The linearized state space model (17-18) is used to design balance controller. The dominant pole is chosen so that the damping ratio is 0.7 and natural frequency 4 rad/s. For rest of the two poles, two real poles with very small time constants 0.125 second and 0.025 second are selected. The gain matrix obtained using Ackermann formula is

          K 58.9063 501.4796 29.5578 57.2090.

        2. LQR controller

        Linear Quadratic Regulator is an optimal controller used to achieve desired target value with minimum control effort and time. A performance index J is defined in this technique and the control engineer have to find a controller u Kx which will minimize the performance index.

        J (xT Q x uT R u) dt

        where, Q and R are weighing matrices which allow the relative weighting of individual state variables and individual control inputs.

        In MATLAB, the command [K] = lqr (A, B, Q, R) calculates the optimal feedback matrix K such that it minimizes the cost function subject to the constraint defined by the state equation. The response of system for different set of state feedback gain matrix is determined by varying Q values, keeping R=1, and chooses the one which give best performance.

        The different sets of Q chosen are as follows Q1=diag( 60 5 11), Q2=diag( 60 0.05 60 0.05),

        Q3=diag( 1000 2000 600 200)

      2. SIMULATION RESULTS

        The pole placement controller and LQR controller can be considered as robust controllers. The simulation results for pendulum position and arm position for pole placement and LQR controllers are shown in the figure 4(a), 4(b), 5(a), 5(b).

        Fig.4(a) Step response of pendulum angle-Pole placement

        controller

        Fig.4(b) Step response of pendulum angle for different set of Q- LQR controller

        Fig. 5(a) Step response of arm position-Pole placement controller

        Fig.5(b) Step response of arm position-LQR controller

        On observing above figures, LQR controller is better to settle the response with in less time than pole placement controller and pole placement controller is better in reducing the overshoot of the system. However by proper choice of weighing matrices Q and R, LQR response can further improved and is more dominant than state feedback controller. The gain matrix K chosen for the state feedback controller is almost perfect for stabilizing the pendulum. It is always not easy to obtain the gain matrix for state feedback controller easily. But in the case of LQR controller the gain matrix K can be tuned easily to obtain the desired response.

      3. CONCLUSION

In this paper state feedback and LQR control methods are discussed for the stabilization of Rotary arm Inverted pendulum system. From the simulation results, it is found that both pole placement technique and LQR method are efficient in satisfying the design requirements and are robust to the parameter variations. The LQR control shows better results in minimizing the steady state value when compared to state feedback control method while pole placement method is better to improve the transient response of the system. Both pole placement and LQR controllers are capable of maintaining the pendulum in its upright position.

ACKNOWLEDGEMENT

This work has been carried out as a part of thesis work done in the Department of Control systems in Mar Baselious College of Engineering. Gratitude is extended to the entire faculty of Electrical Department

REFERENCES

  1. Vinodh Kumar E, Jovitha Jerome, Stabilizing Controller design for self-erecting single inverted pendulum using Robust LQR, Australian Journal of Basic and Applied Sciences,vol.7, pp. 494-504, 2013

  2. Kurella Pavan Kumar, Dr.G V Shivakrishna Rao, Modelling and Controller Designing of Rotary Inverted Pendulum- Comparison by using various design methods, International Journal of Science, Engineering and Technology Research (IJSETR), vol. 3, no.10, pp.2747-2752, October 2014

  3. Melba Mary P and Marimuthu N. S, Design Of Intelligent Hybrid Controller For Swing-up And Stabilization Of Rotry Inverted Pendulum, ARPN Journal of Engineering and Applied Sciences , Vol. 3, no. 4, pp.60-70, 2008

  4. Irfan Jamil, Rehan Jamil, Zhao Jinquan, Rizwan Jamil & Abdus Samee, Mathematical Model Analysis and Control Algorithms Design Based On State Feedback Method of Rotary Inverted Pendulum, IMPACT: International Journal of Research in Engineering & Technology (IMPACT: IJRET), vol.1, no.3, pp.41-50, Aug 2013

  5. Slavka Jadlovska, Jan Sarnovsky, A Complex Overview of Modelling and Control of the Rotary Single Inverted Pendulum System, Department of Cybernetics and Articial Intelligence, Faculty of Electrical Engineering and Informatics, Technical University of Kosice, Letna 9, 042 00 Kosice, Slovak Republic,vol.11, no: 2,pp.73-85, 2013

Leave a Reply