You are on page 1of 29

State‐Space Design

N.H. Jo,  H. Shim,  Y.I. Son

Lecture Topics
자동화 및 DSP 연구실

ƒ State space representation


ƒ Stability
ƒ Controllability & Observability
ƒ RHP pole/zero cancellation
ƒ State feedback
ƒ Observer
ƒ Integral controller
ƒ Internal model principle
State Variables
자동화 및 DSP 연구실

ƒ Electrical circuit example

ƒ Differential equations in terms of energy storage


variables
ƒ Inductor currents
ƒ capacitor voltages

State Variables
자동화 및 DSP 연구실

ƒ Inverted pendulum

ƒ State variables

ƒ State space representation


SS Representation is NOT Unique
자동화 및 DSP 연구실

ƒ State space representation is NOT unique

ƒ State variables x1, x2


ƒ x1: inductor current
ƒ x2: capacitor voltage

SS Representation is NOT Unique


자동화 및 DSP 연구실

ƒ State space representation is NOT unique (continued)

ƒ State variables
ƒ : inductor current
ƒ : capacitor voltage
SS Representation from Transfer Function
자동화 및 DSP 연구실

ƒ How to write a state space representation


from given transfer function ?

ƒ Control canonical form


ƒ Observer canonical form

Control/Observer Canonical Form


자동화 및 DSP 연구실

ƒ Control canonical form

ƒ Observer canonical form


Phase Variable Form
자동화 및 DSP 연구실

ƒ Phase variable form

Transfer Function from SS Representation


자동화 및 DSP 연구실

ƒ How to obtain the transfer function from state


space representation ?
ƒ
ƒ Matlab commands
ƒ [nu,de]=ss2tf(a,b,c,d)
ƒ [A,B,C,D]=tf2ss(num,den)
ƒ Example: Single-input single-output system
Transfer Function from SS Representation
자동화 및 DSP 연구실

ƒ Example: Multi-input multi-output system

State Transformations
자동화 및 DSP 연구실

ƒ State Transformation
ƒ How can we go from one state space realization to
another ?
ƒ New state vector z :
ƒ P : nonsingular matrix
ƒ Transformed equation

ƒ Two important properties


ƒ Transfer function is NOT changed by state transformation

ƒ Eigenvalues are NOT changed by state transformation


State Transformations
자동화 및 DSP 연구실

ƒ State Transformation into Modal Canonical Form


ƒ State transformation

ƒ λi , vi : eigenvalue & eigenvector of A, i.e.,


ƒ New state space representation

ƒ Eigenvalues and Eigenvectors


ƒ Eigenvalue λ
ƒ For x ≠ 0, λ x = A x
ƒ Characteristic equation : det (λI – A) = 0
ƒ Eigenvector xi
ƒ For each eigenvalue λi , λi xi = A xi

State Transformations
자동화 및 DSP 연구실

ƒ State Transformation into Control canonical Form


ƒ State transformation

ƒ New state space representation

ƒ Controllability is NOT affected by the state transformation


ƒ
State Transition Matrix
자동화 및 DSP 연구실

ƒ Time domain response


ƒ Linear system

ƒ Laplace transform

ƒ State transition matrix

ƒ Time domain response

State Transition Matrix


자동화 및 DSP 연구실

ƒ Example
ƒ The linear system

ƒ The state transition matrix


Stability
자동화 및 DSP 연구실

ƒ BIBO Stability
ƒ Based on transfer function representation
ƒ A system is BIBO stable if system output is bounded for
all bounded inputs
ƒ Necessary and Sufficient Condition
ƒ All the transfer function poles must be in the LHP

ƒ Asymptotic Stability (A.S.)


ƒ Based on the state space representation
ƒ is asymptotically stable if all the states
approach zero with time, i.e.,

ƒ Necessary and Sufficient Condition


ƒ All eigenvalues must be in the LHP

Stability
자동화 및 DSP 연구실

ƒ What is the difference between BIBO stability and A.S. ?


Does one imply the other ?
ƒ Transfer function

ƒ In the absence of pole-zero cancellations, BIBO stability and


Asymptotic stability are equivalent
ƒ Two stabilities differ only when RHP pole-zero cancellations
occur (including imaginary axis pole-zero cancellation)
ƒ Example

ƒ Asymptotic stability
ƒ Eigenvalues = 1, -2 ⇒ unstable
ƒ BIBO stability

ƒ Pole= -2 ⇒ stable
Stability
자동화 및 DSP 연구실

ƒ Two stabilities are different for the system

ƒ BIBO stable but not asymptotically stable


ƒ Why does this happen ?
ƒ Diagonalization by state transformation

ƒ The unstable mode at +1 is not connected to the output


ƒ So, even if the first state may “blow up,” you will not be
aware of it

Stability - Lyapunov Theorem


자동화 및 DSP 연구실

ƒ Positive definiteness
ƒ A symmetric matrix M is said to be positive definite,
denoted by M >0, if x’Mx > 0 for every nonzero x
ƒ Lyapunov theorem
ƒ All eigenvalues of A have negative real parts ⇔
for any positive definite matrix N, the Lyapunov equation

has a unique solution M and M is positive definite


ƒ The solution can be expressed as

ƒ The sketch of the proof


Internal Stability
자동화 및 DSP 연구실

ƒ Motivating exam.

ƒ Is it O.K. to cancel RHP plant poles by compensator zero, for example,

ƒ BIBO stability of TYR(s)

ƒ How about BIBO stability of TYD(s) ?

ƒ The slightest disturbances in the system will grow unbounded


ƒ A design lesson
ƒ We must NEVER cancel the RHP plant poles by RHP compensator zeros, for
this will render the closed-loop system internally unstable
ƒ A controller example

Internal Stability
자동화 및 DSP 연구실

ƒ Block diagram of a feedback system


ƒ Plant, controller, sensor dynamics
ƒ Reference input, sensor noise,
disturbance inputs are included

ƒ Internal stability
ƒ All signals within the feedback system should remain bounded for
all bounded inputs
ƒ All possible Transfer function between all inputs and outputs should
be stable
Only nine Transfer function between (R,D,N) and (U,Y,W) are sufficient
ƒ How to check this ?
ƒ Necessary and sufficient condition
ƒ The product of KGH has NO pole-zero cancellations in the RHP
(including jw-axis)
ƒ Transfer function (1+KGH) has NO zeros in the RHP
(including jw-axis)
ƒ Previous example revisited :
ƒ KGH has RHP pole-zero cancellation at +1 ⇒ Unstable !!
Controllability
자동화 및 DSP 연구실

ƒ Motivating example 1
ƒ Can the input u control x2 ?

ƒ Open circuit across y ⇒ cannot control x2


ƒ Motivating example 2
ƒ Can the input u transfer
x1 and x2 to any values ?
ƒ If, x1(0)=x2(0)=0
⇒ x1(t)=x2(t), ∀ t ≥ 0
ƒ x1 and x2 cannot be controlled independently

Controllability
자동화 및 DSP 연구실

ƒ Definition
ƒ The system is controllable if there exists a
control u(t) that will take the state of the system from any initial
state x0 to any desired final state xf in a finite time interval
ƒ Theorem: Controllability
ƒ The system (A,B) is controllable iff the controllability matrix C
has full row rank

ƒ PBH rank test: The system (A,B) is controllable iff the matrix
has full row rank at every eigenvalue λ of A
ƒ The system (A,B) is controllable iff
K can be chosen s.t. λ (A-BK) are arbitrary

ƒ How to find an uncontrollable mode ?


ƒ The modes associated with λ are uncontrollable ⇔
Controllability
자동화 및 DSP 연구실

ƒ Theorem: Controllability
ƒ The system (A,B) is controllable ⇔ the controllability
Gramian

is nonsingular for any t>0


ƒ How to transfer x0 to x1 at time t1 ?
ƒ A control input, that transfers x0 to x1 at time t1, is
given by

ƒ Why ?

Observability
자동화 및 DSP 연구실

ƒ Motivating example 1
ƒ Can we estimate the behavior of x1 by measuring y ?

ƒ The current passing through 2-Ω resistor always equals the current
source u
⇒ The response excited by the initial state x1 will not appear in y
⇒ The initial state x1 cannot be observed from the output
ƒ Motivating example 2
ƒ Can we estimate the behavior of x
by measuring y ?
ƒ If, u(t) = 0, ∀ t ≥ 0 ⇒ y(t) = 0, ∀ t ≥ 0
ƒ No matter what x(t) is
ƒ x(t) cannot be estimated by measuring y
Observability
자동화 및 DSP 연구실

ƒ Definition
ƒ The system

is observable if, for any x(0), there is a finite time τ such that x(0)
can be determined from u(t) and y(t) for 0 · t · τ
ƒ Roughly speaking, observability condition is required in order to
design an observer
ƒ Theorem: Observatility
ƒ The system (A,C) is observable iff the observability matrix O has full
column rank

ƒ PBH rank test: The system (A,C) is observable iff the matrix
has full column rank at every eigenvalue λ of A

ƒ The system (A,C) is observable iff


L can be chosen s.t. λ (A-LC) are arbitrary

Controllability, Observability
자동화 및 DSP 연구실

ƒ Theorem of duality
ƒ The pair (A,B) is controllable ⇔
The pair (AT,BT) is observable
ƒ Canonical decomposition
ƒ Kalman decomposition theorem
ƒ Controllable and observable
ƒ Controllable and unobservable
ƒ Uncontrollable and observable
ƒ Uncontrollable and unobservable
ƒ Controllability vs. Observability
ƒ Controllability: whether or not the state can be
controlled from the input
ƒ Observability: whether or not the initial state can be
observed from the output
Lack of Controllability or Observability
자동화 및 DSP 연구실

ƒ Example

ƒ Transfer function

ƒ If b1=0
ƒ The mode at 1: uncontrollable, pole 1: canceled out
ƒ If c1=0
ƒ The mode at 1: unobservable, pole 1: canceled out
ƒ If b2=0
ƒ The mode at 2: uncontrollable, pole -2: cancelled out
ƒ If c2=0
ƒ The mode at 2: unobservable, pole -2: cancelled out
ƒ Lack of either controllability or observability ⇒
pole-zero cancellation in the transfer function

Unstable Pole-Zero Cancellation


자동화 및 DSP 연구실

ƒ When an unstable pole is canceled by a zero,


ƒ it does not really disappear,
ƒ it simply becomes either uncontrollable or
unobservable
ƒ If uncontrollable, you will observe the state blow up,
but you can do nothing about it
ƒ If unobservable, you will not even be aware that
something is wrong because the unstable state
does not appear at the output
ƒ In either case, the results are disastrous
Inverted Pendulum Example
자동화 및 DSP 연구실

ƒ Transfer function

ƒ Measuring θ alone
ƒ Unstable pole/zero cancellation (at 0)
ƒ A.S.: unstable ⇒ stabilization is NOT possible by measuring θ alone

ƒ Measuring x alone
ƒ No pole/zero cancellation
ƒ A.S.: stable ⇒ Stabilization is possible by measuring cart position x
alone

Inverted Pendulum Example


자동화 및 DSP 연구실

ƒ State space representation

ƒ Controllable ?

ƒ Full row rank ⇒ controllable


Inverted Pendulum
자동화 및 DSP 연구실

ƒ Stabilizable by measuring pendulum angle θ only ?


ƒ Observability check
ƒ Sensing pendulum angle ⇒ C=[1 0 0 0]
ƒ Observability matrix

: singular ⇒ unobservable

ƒ Unobservability can be expected by pole/zero cancellation


ƒ Stabilizable by measuring cart positioin x only ?
ƒ Sensing cart position : C=[0 0 1 0]

: nonsingular ⇒ observable

ƒ Sensor location problem


ƒ It makes a big difference which state variable we
measure !!

State Feedback Control Law


자동화 및 DSP 연구실

ƒ Control-law design for


ƒ Reference input is set to zero at this time

ƒ Choose K so that eigenvalues of


(A-BK)
are in desirable locations, e.g., LHP
ƒ MATLAB
ƒ K=acker(a,b,p)
ƒ Calculation of K for u = -K x
ƒ Useful for small( · 10 ) number of state variables
ƒ K=place(a,b,p)
ƒ Numerically more reliable than ‘acker’
ƒ Restriction : NONE of the desired poles may be repeated
Pole Placement Theorem
자동화 및 DSP 연구실

ƒ Example 1

ƒ Desired pole location : -4, -4, -5


⇒ K=[75 49 10]
ƒ Example 2

ƒ Desired pole location : -2, -3


ƒ No such controller exist !

ƒ Mode at -1 cannot be moved


ƒ Pole Placement Theorem
ƒ For arbitrary pole placement, system must be controllable

Stabilizability
자동화 및 DSP 연구실

ƒ For uncontrollable systems, which poles can be moved ?


ƒ Previous example
ƒ Mode at 1 : cannot be moved ⇒ uncontrollable mode
ƒ Mode at 2 : can be placed anywhere ⇒ controllable mode
ƒ PBH rank test
ƒ Uncontrollable modes are fixed

ƒ Controllable modes can be shifted

ƒ Is the controllability necessary for a system to be


stabilized by using state feedback ?
ƒ Stabilizability condition is sufficient !!
ƒ Stabilizability
ƒ A system is stabilizable if
ƒ The unstable modes are controllable, or
ƒ The uncontrollable modes are stable
Observer Design
자동화 및 DSP 연구실

ƒ A weak point of state feedback control


ƒ Not all the states are measurable
ƒ Some sensors are very expensive
ƒ Physically impossible to measure all the states
ƒ How to reconstruct all the states from a few
measurements ?
ƒ Observer Design

ƒ When does
ƒ Observer error go to zero ⇔ (A-LC) is a stable matrix
ƒ If (A,C) observable
⇒ L can be chosen s.t. λ (A-LC) are arbitrary

Observer Design
자동화 및 DSP 연구실
Observer Design Example
자동화 및 DSP 연구실

ƒ Example: a simple pendulum

ƒ An observer is given by

ƒ How to compute an observer gain


ƒ Duality
ƒ Observer gain can be computed using state feedback design procedure
ƒ λ [(A-LC)] = λ [(AT-CTLT)]⇔ LT = [state feedback gain for (AT,CT)
system]

Separation Principle
자동화 및 DSP 연구실

ƒ Control using observers


ƒ How to stabilize the system when all the states are not available ?
ƒ Combined control law
ƒ State feedback control law is combined with an observer
ƒ Separation principle
ƒ Plant equation with feedback

ƒ The overall system dynamics (plant + observer error)

ƒ Characteristic Equation

⇒ Closed-loop poles = controller poles + observer poles


ƒ The designs of the control law & the observer can be carried out
independently, yet when they are used together in this way, the
poles remain unchanged
Observer-Based Controller
자동화 및 DSP 연구실

ƒ Observer-based controller
ƒ Observer-based controller = Control using observers
(= Output feedback controller)
ƒ Observer-based controller can be used when full state are not available
ƒ But, No guaranteed stability margins
ƒ A simple Pendulum System

ƒ State feedback control


ƒ Desired control roots: -2, -2

ƒ Observer
ƒ Desired observer roots: -10, -10

ƒ Observer-based controller

Observer-Based Controller
자동화 및 DSP 연구실
Observer-Based Controller
자동화 및 DSP 연구실

Robustness & Stability Margins


자동화 및 DSP 연구실

ƒ Robustness & Stability Margins


ƒ Usually, we have imperfect model of our systems
ƒ Stability margins provide some protection against
model uncertainties
ƒ System designed with low margins
ƒ are inherently sensitive to model errors and
ƒ may become unstable in actual operation
ƒ High margins provide good robustness properties
ƒ Robustness of LQR design
ƒ Return-difference inequality
ƒ Stability margins of open loop system
ƒ GM : ½ < GM < ∞
ƒ LQR gain matrix K can be multiplied by a large scalar or
reduced by half with guaranteed closed-loop systems stability
ƒ PM : PM ≥ 60
Integral Control
자동화 및 DSP 연구실

ƒ How to handle tracking problem ?


ƒ Adding an integrator will increase the system type
ƒ Integral control
ƒ New state variable

ƒ The augmented plant

ƒ The Integral controller

ƒ K0 & KI should be chosen s.t.

is stable
ƒ System type is increased (+1) ⇒ Tracking error = 0 is guaranteed (step
input)

Integral Control
자동화 및 DSP 연구실

ƒ The double integrator system example

ƒ Desired pole location : -1±j, -5


ƒ Control gain

ƒ Integral controller

ƒ Tracking error verification


ƒ SS output due to unit step reference input
Integral Control
자동화 및 DSP 연구실

Internal Model Principle


자동화 및 DSP 연구실
Internal Model Principle
자동화 및 DSP 연구실

ƒ Disk-drive Servomechanism

ƒ Because the data on the disk is not exactly on a


centered circle, the servo must track a sinusoid of
radian frequency w0 determined by the spindle speed

Internal Model Principle


자동화 및 DSP 연구실

ƒ Objective
ƒ Tracking a non-decaying input (with zero SSE) such
as
ƒ step
ƒ ramp
ƒ sinusoidal input
ƒ Rejecting a non-decaying disturbance (with zero
SSE)
ƒ The key idea
ƒ including the equations satisfied by these external
signals as part of the problem formulation and
solving the problem of control in an error space
ƒ so we are assured that the error approaches zero
even if the output is following a non-decaying
command
Internal Model Principle
자동화 및 DSP 연구실

ƒ System equation

ƒ Assumption
ƒ Reference input & disturbance satisfy differential
equations of
order 2

ƒ The extension to more complex signals are not difficult


ƒ Initial conditions on the 2nd order differential equations (of
reference input and disturbance) are unknown
ƒ For example, the input could be a ramp whose slope and
initial value are unknown

Internal Model Principle


자동화 및 DSP 연구실

ƒ Tracking error

ƒ Error-space
ƒ The state in error space

ƒ The control in error space

ƒ Overall system
Internal Model Principle
자동화 및 DSP 연구실

ƒ Control law in the error space


ƒ Assumption : is controllable
ƒ In fact, it is controllable if (A,B) is controllable and (A,B) does not
have a zero at any of the roots of the reference-signal characteristic
equation

ƒ Control law

ƒ Robustness: the state z will tend to zero for all perturbations


as long as is stable

Disk-Drive Servomechanism
자동화 및 DSP 연구실

ƒ A simple normalized model of a computer disk-drive


servomechanism

ƒ Tracking reference input r (t) = A sin w0t with zero SSE


ƒ
ƒ Controller Design
ƒ Error space representation

ƒ Characteristic Equation of (A-BK)

ƒ Controller
Internal Model Principle
자동화 및 DSP 연구실

Internal Model Principle


자동화 및 DSP 연구실
자동화 및 DSP 연구실

END

You might also like