5
Analysis and Design of Robust Feedback Control Systems for a Nonlinear Two-Wheel Inverted Pendulum system Mao-Lin Chen Department of Automation Engineering & Institute of Mechatronoptic Systems Chienkuo Technology University, Taiwan e-mail: [email protected] AbstractTwo-wheel inverted pendulum is an open loop unstable system, and is a nonlinear system. But can use at many practice application, like SEGWAY etc. This paper research the theorems nonlinear property of the two-wheel inverted pendulum model and simulation its nonlinear output response. Simulation results show that system has robustness. Can maintain stable when suffer nonlinear inference and not change controller gain, And if we design a gain compensator controller cause by nonlinear property influence , simulation result show can improve the two-wheel inverted pendulum output response. Keywords- two-wheel Inverted Pendulum, nonlinear system, nonlinear inference, robustness Introduction Two-wheel inverted pendulum [1] is an open loop unstable system, and is a nonlinear system. Nonlinear system output property is limit cycle[5], and can break the system stable when system suffer inference and load varying. Reduce the system nonlinear property and increase system robustness can improve system output response and reliability. And improve the inverted pendulum like products safety reliability. Inverted Pendulum Car nonlinear property can induce from three areas. First is theorem nonlinear character. That can get from its ideal system models. The second is from its power driver, power translate mechanical and friction. Like the motor nonlinear character and gear nonlinearity. The third nonlinearity is from the measurement equipment time delay and nonlinear character. The paper uses the tilt-meter measure the tilt angle and Gyro meter measure the tilt angle velocity. But the tilt meter has time- delay character and inference by cross axis accelerates, and Gyro meter response time is quick, but is sense at noise inference. This paper main purpose is research its theorem nonlinear property and design a relate compensator control method. This paper system structure is as Fig. 1. Have evoked a lot of interest recently and at least one commercial product (Segway) is available. Two-wheeled inverse pendulum in this consideration has two independent driving wheels in same axis, and the gyro type sensor to know the inclination angular velocity of the body and rotary encoders to know wheels rotation [6], ~ [9]. [10] is proposed to perform the robust stabilization and disturbance rejection of the system. r m M h w 2 ) ( 1 t q ) ( 1 t u ) (t θ y x z α Fig. 1. Two-wheel Inverted Pendulum structure The two-wheel parameter describe as follow: Car body weight: M (Kg) Car wheels weight: m1, m2 (Kg) Car wheels radius: r1=r2=r (m) Car Height: h (m) Car wheel friction constant: B (N-sec/m) Gravimeter constant: g (m/sec2) Car wheels cross distance: :( m) Car wheels rotate angle (move distance): (deg) Car tilt angle : (deg), Car tile angle cause by load or structure: (deg) Car wheel rotate angle: Car wheel server motor input voltage: u1 and u2, Wheel motor output torque: , is torque constant. I. MATHEMATICAL MODEL AND NONLINEAR PROPERTY We use the Euler-Lagrange model to derivate the system mathematical model [2][3] assume :L is Lagrange function, K is Kinetic energy, P is potential energy. The kinetic energy can express as 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 ) 2 1 ( ) ) ( ) (( 2 1 ) sin ( ) sin ( ) ) cos (( 2 1 ) 2 1 ( ) ( 2 1 ) ( 2 1 φ φ θ θ φ θ θ θ φ w m M rq q r m h h rq h q r M w m M z y x m z y x M K + + + + + + = + + + + + + + = (1) And the potential energy can express as θ cos Mgh P = θ φ φ θ φ θ φ θ θ θ cos ) 2 1 ( sin 2 1 sin ) ( 2 1 cos 2 1 ) ( 2 1 2 2 2 2 2 2 2 2 2 2 2 2 2 g h M w m M Mh Mrqh q r m M q h r M h M q r m M P K L + + + + + + + = = (2) The Euler-Lagrange can express as: 2012 International Symposium on Computer, Consumer and Control 978-0-7695-4655-1/12 $26.00 © 2012 IEEE DOI 10.1109/IS3C.2012.248 952 2012 International Symposium on Computer, Consumer and Control 978-0-7695-4655-1/12 $26.00 © 2012 IEEE DOI 10.1109/IS3C.2012.248 952 2012 International Symposium on Computer, Consumer and Control 978-0-7695-4655-1/12 $26.00 © 2012 IEEE DOI 10.1109/IS3C.2012.248 949

[IEEE 2012 International Symposium on Computer, Consumer and Control (IS3C) - Taichung, Taiwan (2012.06.4-2012.06.6)] 2012 International Symposium on Computer, Consumer and Control

  • Upload
    mao-lin

  • View
    215

  • Download
    3

Embed Size (px)

Citation preview

Analysis and Design of Robust Feedback Control Systems for a Nonlinear Two-Wheel Inverted Pendulum system

Mao-Lin Chen

Department of Automation Engineering & Institute of Mechatronoptic Systems Chienkuo Technology University, Taiwan

e-mail: [email protected]

Abstract—Two-wheel inverted pendulum is an open loop unstable system, and is a nonlinear system. But can use at many practice application, like SEGWAY etc. This paper research the theorems nonlinear property of the two-wheel inverted pendulum model and simulation its nonlinear output response. Simulation results show that system has robustness. Can maintain stable when suffer nonlinear inference and not change controller gain, And if we design a gain compensator controller cause by nonlinear property influence , simulation result show can improve the two-wheel inverted pendulum output response.

Keywords- two-wheel Inverted Pendulum, nonlinear system, nonlinear inference, robustness

Introduction

Two-wheel inverted pendulum [1] is an open loop unstable system, and is a nonlinear system. Nonlinear system output property is limit cycle[5], and can break the system stable when system suffer inference and load varying. Reduce the system nonlinear property and increase system robustness can improve system output response and reliability. And improve the inverted pendulum like products safety reliability. Inverted Pendulum Car nonlinear property can induce from three areas. First is theorem nonlinear character. That can get from its ideal system models. The second is from its power driver, power translate mechanical and friction. Like the motor nonlinear character and gear nonlinearity. The third nonlinearity is from the measurement equipment time delay and nonlinear character. The paper uses the tilt-meter measure the tilt angle and Gyro meter measure the tilt angle velocity. But the tilt meter has time-delay character and inference by cross axis accelerates, and Gyro meter response time is quick, but is sense at noise inference. This paper main purpose is research its theorem nonlinear property and design a relate compensator control method. This paper system structure is as Fig. 1. Have evoked a lot of interest recently and at least one commercial product (Segway) is available. Two-wheeled inverse pendulum in this consideration has two independent driving wheels in same axis, and the gyro type sensor to know the inclination angular velocity of the body and rotary encoders to know wheels rotation [6], ~ [9]. [10] is proposed to perform the robust stabilization and disturbance rejection of the system.

r

m

M

h w2)(1 tq

)(1 tu

)(tθ

y

x

z

α

Fig. 1. Two-wheel Inverted Pendulum structure

The two-wheel parameter describe as follow: Car body weight: M (Kg) Car wheels weight: m1, m2 (Kg) Car wheels radius: r1=r2=r (m) Car Height: h (m) Car wheel friction constant: B (N-sec/m) Gravimeter constant: g (m/sec2) Car wheels cross distance: :( m) Car wheels rotate angle (move distance): (deg) Car tilt angle : (deg), Car tile angle cause by load or structure: � (deg) Car wheel rotate angle: � Car wheel server motor input voltage: u1 and u2, Wheel motor output torque: , is torque constant.

I. MATHEMATICAL MODEL AND NONLINEAR PROPERTY

We use the Euler-Lagrange model to derivate the system mathematical model [2][3] assume :L is Lagrange function, K is Kinetic energy, P is potential energy. The kinetic energy can express as

22222

222

2222222

)21())()((

21)sin(

)sin())cos((21

)21()(

21)(

21

φφθθ

φθθθ

φ

����

���

�������

wmMrqqrmh

hrqhqrM

wmMzyxmzyxMK

+++++

−+−=

+++++++= (1)

And the potential energy can express as θcosMghP =

θφφθφθ

φθθθ

cos)21(sin

21sin

)(21cos

21)(

21

222222

2222222

ghMwmMMhMrqh

qrmMqhrMhMqrmM

PKL

−+++−

++−++=

−=

���

����� (2)

The Euler-Lagrange can express as:

2012 International Symposium on Computer, Consumer and Control

978-0-7695-4655-1/12 $26.00 © 2012 IEEE

DOI 10.1109/IS3C.2012.248

952

2012 International Symposium on Computer, Consumer and Control

978-0-7695-4655-1/12 $26.00 © 2012 IEEE

DOI 10.1109/IS3C.2012.248

952

2012 International Symposium on Computer, Consumer and Control

978-0-7695-4655-1/12 $26.00 © 2012 IEEE

DOI 10.1109/IS3C.2012.248

949

���

���

−=∂∂−

∂∂

−=∂∂−

∂∂

=∂∂−

∂∂

φτφφ

τ

θθ

��

��

bLLdtd

qbqL

qL

dtd

LLdtd

d

0 (3)

Whereτ is the forward torque (move forward and backward torque) and dτ is rotate torque. Set Eq. (2) into Eq. (3) we can get system dynamic equation as below:

����

����

−=++++−

−−+++

−=−

+++−+=−

+++−

φτφφθφθθθφθφθφθθφφ

τφθθθφθθ

θφθθφθθθθθ

�����������������

��������

��������

bwmMMhMhMrqhhqMrMrqhqrmMqqrmM

qbMrhhrMqrmMhrMqrmM

ghMMhMhrqqMrhqhrMhM

d2222

222

2

2222

2222

)2(sincossin2sin2sin2cos22)(2)(

sinsin)(cos)(

0sincossincossincos

(4) For simple above system dynamic equation, we assume system at up-right position, and linearization dynamic equation can express as: ��0, θθ ≈sin , 1cos ≈θ

��

��

=+++−

+++++−+

=+−+++−+=−+++−

dbMhqqMrhqqrmMwmMMhMrqhqrmM

qbMrhqrmMMrhhrMqrmMghMMhMrqhqMrhqhrMhM

τφθθθθφθθ

τφθθθθθφθφθθθ

�������

�������

��������

)2)(2)(2())2(22)((

))(()(0

2

222222

2222

2222

(5) Let

���

+++−++−

−=

))(22)((000)(0

2222

2

2

wmMMhMrqhqrmMrmMhrMhrMhM

Tθθ

���

�+

���

+++

=

dCqCqCC

CCC

ττ

φθ

φθ 0

36

252221

1611

��

)2)(2)(2(

)(

)(

)(

2236

25

2222

2221

16

2211

bMhqqMrhqqrmMC

bCrmMC

MrhMrhC

MrqhC

MhgMhqMrhC

+++−+−=

−=+=

+−=

−=

+−−=

θθθθ

φφθ

φφθ

����

���

����

���

θ

����

��

qD , CTD =

We can get CTD 1−=

���

�=−

333231

232221

1312111

ttttttttt

T

Linearization dynamic space equation can express as

udtxctytubtxAtx +=+= )()(,)()()(�

��������

=+=

��������

=

φ

θφ

θ

φ

θφ

θ

��

����

����

q

q

xbuAx

q

q

x ,

��������

++++++

=

363316312532223221321131

362316212522222221221121

361316112512221221121111

000000

100000010000001000

CtCtCtCtCtCtCtCtCtCtCtCtCtCtCtCtCtCt

A

��������

=

ff

ff

ff

ktktktktktkt

B

3322

2322

1312

000000

, ��

�=

d

uττ

��������

=���

�+

���

�=+=

���

�=

φ

θφ

θ

φ

θ

��

q

q

xuxducxqy ,000

000100000010000001

(6)

If we use above linearization equation to design a linear controller by LQR method[4], we can show that A matrix is a time varying system. For simple the controller, we analysis the nonlinear property to reduce the control complexity. From the A matrix , nonlinear term θ��q , 2θ� will

influence θ and q stability ,and qq � , θ�q , θq� , θθ � term will influence φ stability. Because system is a nonlinear system, we assume system will generate stable limit cycle when system at stable control status, so we can assume the system nonlinear property as a time-varying linear system.

0*))(( AtfIA A+= 0*))(( BtfIB B+= (7) So system model can express as

953953950

UtfIXAtfIXA BA ))((*))(( 0 +++=� (8)

DUCXY += If we can design a control as

0))((, KtfIKKXU k+=−= (9) Then the system feedback state is like as

)))(())(()*))((())(( 0000 XKtfIBtfIXAtfIXAtfI kBAA ++−+=+ �

))()()()(())(( 000000000 XKtfBtfXKBtfAtfXKBXAXAtfI kBBAA −−+−=+ �

If let below equation establish XKfIBtfAtfXAtf kBAA 0000 )()()()( +−=�

(10) We can reduce the nonlinear property influence. We use the optimal control method to find the 0)( Ktfk is

0001

000 )()'())()'(( KAtQfBfBfQBfRKf ABBBk −+= − (11)

II. SIMULATE RESULT (1)System model varying when system from stand state to

up state. If we set a command as 5.0,5,0 === φθ q , the system output Tilt, Gyro and Move distance as follow Fig 3~Fig 4.

0 2 4 6 8 10 12 14 16 18 20-0.25

-0.2

-0.15

-0.1

-0.05

0

0.05

0.1Double Wheel Pendulum Tilt

Tilt

Var

y (rad

)

Time(s) Fig. 2 command 5.0,5,0 === φθ q andθ (Tile angle) varying

diagram

0 2 4 6 8 10 12 14 16 18 20-2

-1

0

1

2

3

4

5

6Double Wheel Pendulum Tilt

Dis

tanc

e V

ary

(rad

)

Time(s) Fig. 3 command 5.0,5,0 === φθ q q

(wheel rotate angle) varying

0 2 4 6 8 10 12 14 16 18 20-0.1

0

0.1

0.2

0.3

0.4

0.5

0.6Double Wheel Pendulum Tilt

rota

te a

ngle

Var

y (rad

)

Time(s) Fig. 4 command 5.0,5,0 === φθ q ,φ (the rotate angle) varying

The A matrix varying as follow Fig 5~Fig 7.

0 2 4 6 8 10 12 14 16 18 20-10

-5

0

5

10

15

20Inverted pendulum Theorem Nonlinear phenomenon

Par

amet

er A

41 V

ary

Time(s) Fig. 5 Parameter a41 varying

0 2 4 6 8 10 12 14 16 18 20-30

-20

-10

0

10

20

30

40Inverted pendulum Theorem Nonlinear

Par

amet

er A

51 V

ary

Time(s) Fig. 6 Parameter a51 varying

0 2 4 6 8 10 12 14 16 18 20-2

-1.5

-1

-0.5

0

0.5

1

1.5

2

2.5

3Inverted pendulum Theorem Nonlinear

Par

amet

er A

66 V

ary

Time(s) Fig. 7 Parameter a66 varying

The B matrixes varying as follow Fig 8.

954954951

0 2 4 6 8 10 12 14 16 18 20-25

-20

-15

-10

-5

0Inverted pendulum Theorem Nonlinear

Par

amet

er B

61 V

ary

Time(s) Fig. 8 Parameter B61 (blue) & B62 (Red) varying

The feedback gain tuning as a compensator cause the system model varying as below Fig 9~ Fig 14.

Fig. 9 Parameter K11 (blue) & K21 (Red) varying as compensator

Fig. 10 Parameter K12 (blue) & K22 (Red) varying as compensator

Fig. 11 Parameter K13 (blue) & K23 (Red) varying as compensator

Fig. 12 Parameter K14 (blue) & K24 (Red) varying as compensator

Fig. 13 Parameter K15 (blue) & K25 (Red) varying as compensator

Fig. 14 Parameter K16 (blue) & K26 (Red) varying as compensator

(2)Use the above feedback gain tuning as compensator simulation result. Set command as 5.0,5,0 === φθ q ,and let K(1,1) add 1.2 and let K(2,6) add 1.2 after T =1.8 Simulation results as follow Fig 15~Fig 17.

From simulation result show that feed-back gain tuning compensator can approve the system output response. Can reduce the overshoot amount and reduce limit cycle amplitude.

III. CONCLUSION

This paper researches the inverted pendulum car nonlinear phenomena. The system nonlinear phenomena limit cycle will cause the system model time varying. This paper simulates the system model time varying property. And use that property design a time–varying feedback gain tuning compensator. The simulation results show that system has robustness with constant feedback gain, when

955955952

system has time-varying model cause by system nonlinear character. Use a feed-back gain tuning as compensator will approve the response character when system model time-varying cause by system nonlinear property.

REFERENCES

[1] Grasser, Felix. Aldo D’Arrigo, Silvio Colombi, and Alfred Rufer, 2002,

“JOE: A Mobile Inverted Pendulum”, IEEE Trans. on Industrial Electronics, Vol. 40,No. 1, pp. 107--114.

[2] Kaustubh Pathak, JaumeFranch, and Sunil K. Agrawal ,2005,” Velocity and Position Control of a Wheeled Inverted Pendulum by Partial Feedback Linearization”, IEEE TRANSACTIONS ON ROBOTICS, VOL. 21, NO. 3, JUNE 2005,pp 505-513

[3] Kaustubh Pathak, Grad. Jaume Franch, Sunil K. Agrawal,2004,” Velocity Control of a Wheeled Inverted Pendulum by Partial Feedback Linearization”, 43rd IEEE Conference on Decision and Control December 14-17, 2004 Atlantis, Paradise Island, Bahamas, pp 3962—3967

[4] Rich Chi Ooi, Thomas Bräunl, Jie Pan,2003,”Balancing a Two-Wheeled Autonomous Robot”, The University of Western Australia School of Mechanical Engineering ,Final Year Thesis 2003

[5] HASSAN K. KHALIL , 2002, “NONLINEAR SYSTEMS”,Prentice Hall, 3rd. 2002

[6] Salerno, A. and Angeles, J., “Nonlinear Controllability of Quasiholonomic Mobile Robot”. Proc. IEEE ICRA, Taiwan, 2003.

[7] Salerno, A. and Angeles, J.,”The control of semi- autonomous two-wheeled robot undergoing large payload variations”. Proc. IEEE ICRA, New Orleans, April 2004, pp. 1740-1745.

[8] Baloh, M. and Parent, M.,”Modeling and Model Verification of an intelligent self-balancing two-wheeled vehicle for an autonomous urban transportation system”. Conf. Comp. Intelligence, Robotic and Autonomous systems, Singapore, Dec, 15, 2003.

[9] Robotic and Autonomous systems, Singapore, Dec, 15, 2003. [10] Nawawi S.W, Ahmad M.N, Osman J.H.S, Husain A.R and Abdollah

M.F, ” Controller Design for Two-wheels Inverted Pendulum Mobile Robot Using PISMC”. 4th Student Conference on Research and Development (SCOReD 2006), Shah Alam, Selangor, MALAYSIA, 27-28 June, 2006

0 2 4 6 8 10 12 14 16 18 20-0.25

-0.2

-0.15

-0.1

-0.05

0

0.05

0.1Double Wheel Pendulum Tilt

Tilt

Var

y (rad

)

Time(s) 0 2 4 6 8 10 12 14 16 18 20

-2

-1

0

1

2

3

4

5

6Double Wheel Pendulum Tilt

Dista

nce

Var

y (rad

)

Time(s) Fig. 15 5.0,5,0 === φθ q ,θ varying (After Compensator) Fig. 16 5.0,5,0 === φθ q , q varying (After Compensator)

0 2 4 6 8 10 12 14 16 18 20-0.1

0

0.1

0.2

0.3

0.4

0.5

0.6Double Wheel Pendulum Tilt

rota

te a

ngle

Var

y (rad

)

Time(s)

Fig. 17 5.0,5,0 === φθ q ,φ varying (After Compensator)

956956953