state feedback

16
State Feedback State Feedback U G(s) Y U G(s) Y G c (s) R U G(s) Y G c (s) R G c (s) R 1 U G(s) Y K R K R 1 U G(s) Y K R K 1 R 1

Upload: aurelia-evans

Post on 02-Jan-2016

25 views

Category:

Documents


1 download

DESCRIPTION

State Feedback. State Feedback. State Feedback. Closed loop matrices. R=0 the system is called regulator. State Feedback. The CL state matrix is a function of K. => Faster/stable system. By appropriate changing K we can change eig( A CL ). This method is called pole placement. - PowerPoint PPT Presentation

TRANSCRIPT

Page 1: State Feedback

State FeedbackState Feedback

UG(s)

Y UG(s)

YGc(s)

R

UG(s)

Y

Gc(s)

RGc(s)

R1 UG(s)

Y

K

RK

R1

UG(s)

Y

K

RK1

R1

Page 2: State Feedback

State FeedbackState Feedback

BU dt C

DX X Y

A

BU dt C

DX X Y

A

K

K1

R

BU dt CDX X Y

A

ControllerR

X

Page 3: State Feedback

State FeedbackState Feedback

BU dt CDX X Y

A

ControllerR

X

)()()(

)()()( 1

ttt

ttt

BUAXX

KXRKU )()()()( 1 tttt KXRKBAXX

)()()()( 1 ttt RBKXBKAX

)()()()()()( ttttt RDKXDKCDUCXY 1

)()()(

)()()(

ttt

ttt

CLCL

CLCL

UDXCY

RBXAX

1DKD

DKCC

BKB

BKAA

CL

CL

CL

CL

1

)( Closed loop matrices

R=0 the system is called regulator.

Page 4: State Feedback

State FeedbackState Feedback

BU dt CDX X Y

A

ControllerR

X

1DKD

DKCC

BKB

BKAA

CL

CL

CL

CL

1

)(

The CL state matrix is a function of K

By appropriate changing K we can change eig(ACL) => Faster/stable system

This method is called pole placement.

WE MUST CHECK IF THE SYSTEM IS CONTROLLABLE

Page 5: State Feedback

State FeedbackState Feedback

10,3 xuxx

kxu

xkx 3

Eigenvalues of CL system: 3-k

CL eigenvalues at -10

k=13

Page 6: State Feedback

State FeedbackState Feedback

)(01)(

0

1)(

43

21)(

tty

utt

X

XX If the system is unstable create a controller that will stabilise the system.

>> eig(A) >> rank(ctrb(A,B))

ans = -0.3723 5.3723

ans = 2

43

21

0

1

43

21 2121

kkkkACL

43

21 21 kkeig 0

43

21 21

s

kks

0143

2110

4103

2110 2121 kkkk

036141540231114 2121 kkkk

0153

2120

4113

2111 2121 kkkk

036151800231215 2121 kkkk

26174315

1483141

21

21

kkk

kk

722 k

Page 7: State Feedback

State FeedbackState Feedback

)(01)(

0

1)(

43

21)(

tty

utt

X

XX -10 and -11 261 k

722 k 210

1

43

21kkACL

Matlab

If the system is n x n then you need to solve an n x n system of equations!

K=place(A,B, [-10 -11])

010

001

125022520

A T001B

C=[0 0 1],

D=0.

P=[-10 -20 -30];

Matlab

Page 8: State Feedback

State Feedback - LQRState Feedback - LQR

)(10

01)(

)(43

21)(

tty

tt

X

XXK =[26 72]T

P=[-10 -11]

Matlab: State feedbackResponse of the systemReference signalStudy the signal u=-KxPlace the poles at [-100 -110] Response of the systemStudy the signal u=-Kx

Page 9: State Feedback

State Feedback - LQRState Feedback - LQR

Compromise between speed and energy that we use. Similar problem/dilemma if we had an input.

Solution: Linear Quadratic Regulator (optimum controller)

BUAXX

KXU

0

dtJ TT RUUQXX

Q and R are positive definite matrices

Square symmetric matrices, positive eigenvalues 0QXXT for all nonzero X

Q: Importance of the error, R: Importance of the energy that we use

XBKAX

(assume that BKA is stable)

Page 10: State Feedback

State Feedback - LQRState Feedback - LQR

BUAXX

KXU

0

dtJ TT RUUQXX XBKAX

(assume that BKA is stable)

0

dtJ TT KXRKXQXX

0

dtJ T XRKKQX T

PXXXRKKQX TT

dt

dT P is positive definite

XBKAX

TTT

BKAXX

X=1

BKAPPBKARKKQ T T

XPXPXX

PXX TT

T

dt

d

dt

d

dt

d

PBRK T1

01 QPBPBRPAPA TTReduced Riccati Equation

Page 11: State Feedback

State Feedback - LQRState Feedback - LQR

Steps to design an LQR controller:

1.To find the optimum P solve: 01 QPBPBRPAPA TT

2.Find the optimum gain PBRK T1

[K, P, E]=lqr(sys, Q, R) E are the eigenvalues of A-BK

1

0,

10

10BA

Find K,

The eigenvalues of A-BK

The response of the system

For R=1 and Q=eye(2) and Q=2*eye(2) (X(0)=[1 1]).

Matlab

CAD Exercise

Page 12: State Feedback

Estimating techniquesEstimating techniques

Magic trick

BU dt CDX X Y

A

ControllerR

X

BU dt CDX X Y

A

Page 13: State Feedback

Estimating techniquesEstimating techniques

A

U BU +

+dt

X X

AX

CB

Plant

Y

A

U BU +

+dt

X X

AX

CB

Plant

Y

A

BU +

+dt CB

Estimator

X~ X

~

XA~

Y~

XCY

BUXAX~~

~~

Example: A=[1 2;3 4]; B=[1 0]'; C=[1 0]; D=0;

Page 14: State Feedback

Estimating techniquesEstimating techniques

The error between the estimated and real state is

ttt XXE~

ttt XXE

~ ttttt BUXABUAX~

tt AEE

Homogeneous ODE

00 E

A is unstable

tE

A is slow

A=[1 2;3 4]; B=[1 0]'; C=[1 0]; D=0; U=1, 9.09.00~,110 XX

Page 15: State Feedback

Estimating techniquesEstimating techniques

A

U BU +

+dt

X X

AX

CB

Plant

Y

A

BU +

+dt CB

Estimator

X~ X

~

XA~

Y~

A

U BU +

+dt

X X

AX

CB

Plant

Y

A

BU +

+dt

X~

X~

XA~

CB Y~

Estimator

-

+-

YY~

Y~

A

U BU +

+dt

X X

AX

CB

Plant

Y

A

BU +

+dt

X~

X~

XA~

CB Y~

Estimator

-

+-

G

YY~

Page 16: State Feedback

Estimating techniquesEstimating techniques

A

U BU +

+dt

X X

AX

CY

B

F

BU

+

+dt

X~

X~

XF~

CY~

B

GYG+

Estimator

PlantY

GYBUXFX

ttt~~

tEGCA

tXBKAX

G=place(A’, C’, P)

But the system must be observable

A=[1 2;3 4]; B=[1 0]'; C=[1 0]; D=0; U=1,

9.09.00~,110 XX

Where to place these eigenvalues???Where to place these eigenvalues???

YGBUXAX

tttt~~

YYGBUXAX~~~

tttt

XCYGBUXAX~~~

tttt

GYBUXGCAX

tttt~~

ttt XGCAXGCAE~

GCXBUXGCAX

tttt~~

ttt BUXAX