Professional Documents
Culture Documents
Outline
1 Reachability and Observability 2 Balancing 3 Balanced Truncation 4 Preservation of Stability 5 Error Bounds 6 The POD method revisited 7 Numerical Computation of Balanced Truncation Decomposition 8 Application
CME 345: MODEL REDUCTION - Balanced Truncation Reachability and Observability Systems Considered
The following stable LTI full-order systems are considered: d x(t ) dt y(t ) x(0) = Ax(t ) + Bu(t ) = Cx(t ) = x0
x Rn : vector state variables u Rp : vector of input variables, typically p y R : vector output variables, typically q Recall the solution x(t ) of the linear ODE:
t q
n n
e A(t ) Bu( )d , t t0
CME 345: MODEL REDUCTION - Balanced Truncation Reachability and Observability Reachability, Controllability and Observability
Denition (1) A state x Rn is reachable if there exists an input function u(.) of nite energy and a time T < such that under that input and zero initial condition, the state of the system becomes x. Denition (2) A state x Rn is controllable to the zero state if there exist an input function u(.) and a time T < such that (T , u; 0, x) = 0n .
CME 345: MODEL REDUCTION - Balanced Truncation Reachability and Observability Completely Controllable Dynamical System
Denition (4 - R.E. Kalman 1963) A linear dynamical system (A, B, C) is completely controllable at time t0 if it is not equivalent, for all t t0 to a system of the type d x(1) = A(1,1) x(1) + A(1,2) x(2) + B(1) u dt d x(2) = A(2,2) x(2) dt y(t ) = C(1) x(1) + C(2) x(2) Interpretation: it is not possible to nd a coordinate system in which the state variables are separated into two groups x(1) and x(2) such that the second group is not aected either by the rst group or by the inputs to the system. Controllability is only a property of (A, B) This denition can be extended to linear time variant systems
David Amsallem & Charbel Farhat Stanford University cfarhat@stanford.edu CME 345: MODEL REDUCTION - Balanced Truncation
CME 345: MODEL REDUCTION - Balanced Truncation Reachability and Observability Completely Observable Dynamical System
Denition (5) A linear dynamical system (A, B, C) is completely observable at time t0 if it is not equivalent, for all t t0 to any system of the type d x(1) = A(1,1) x(1) + B(1) u dt d x(2) = A(2,1) x(1) + A(2,2) x(2) + B(2) u dt y(t ) = C(1) x(1) Dual of the previous denition Interpretation: it is not possible to nd a coordinate system in which the state variables are separated into two groups x(1) and x(2) such that the second group is not aected either by the rst group or the outputs of the system. Observability is only a property of (A, C) This denition can be extended to linear time variant systems
David Amsallem & Charbel Farhat Stanford University cfarhat@stanford.edu CME 345: MODEL REDUCTION - Balanced Truncation
CME 345: MODEL REDUCTION - Balanced Truncation Reachability and Observability Example: Simple RLC Circuit
Equation of the network in terms of the current x1 owing through the inductor and the potential x2 across the capacitor (LC = R = 1). dx1 dt dx2 dt y1 1 = x1 + u1 L 1 = x2 + u 1 C 1 1 = x1 + x2 + u1 L C
CME 345: MODEL REDUCTION - Balanced Truncation
CME 345: MODEL REDUCTION - Balanced Truncation Reachability and Observability Example: Simple RLC Circuit
CME 345: MODEL REDUCTION - Balanced Truncation Reachability and Observability Canonical Structure Theorem
Theorem (Kalman 1961) Consider a dynamical system (A, B, C). Then: (i) there is a state space coordinate system in which the components of the state vector can be decomposed into four parts: x = [x(a) , x(b) , x(c ) , x(d ) ]T (ii) the sizes na , nb , nc and nd of these vectors do not depend choice of basis (iii) the systems matrices take the form (a,a) (a) A A(a,b) A(a,c ) A(a,d ) B (b ,b ) (b ,d ) 0 B(b ) A 0 A ,B = A= 0 0 0 A(c ,c ) A(c ,d ) (d ,d ) 0 0 0 0 A C= 0 C(b) 0 C(d ) . on the ,
CME 345: MODEL REDUCTION - Balanced Truncation Reachability and Observability Canonical Structure Theorem
CME 345: MODEL REDUCTION - Balanced Truncation Reachability and Observability Reachable and Controllable Subspaces
Denition (6) The reachable subspace Xreach Rn of a system (A, B, C) is the set containing all the reachable states of the system. R(A, B) = [B, AB, , An1 B, ] is the reachability matrix of the system. Denition (7) The controllable subspace Xcontr Rn of a system (A, B, C) is the set containing all the controllable states of the system
CME 345: MODEL REDUCTION - Balanced Truncation Reachability and Observability Reachable and Controllable Subspaces
Theorem Consider the system (A, B, C). Then Xreach = im R(A, B) (1)
Corollary (i) AXreach Xreach (ii) The system is completely reachable if and only if rank R(A, B) = n (iii) Reachability is basis independent
CME 345: MODEL REDUCTION - Balanced Truncation Reachability and Observability Reachability and Observability Gramians
Denition The reachability (controllability) Gramian at time t < is dened as the n-by-n symmetric positive semidenite matrix
t
P (t ) =
0
e A BB e A d
Denition The observability Gramian at time t < is the n-by-n symmetric positive semidenite matrix
t
Q(t ) =
0
e A C Ce A d
CME 345: MODEL REDUCTION - Balanced Truncation Reachability and Observability Reachability and Observability Gramians
Proposition: The columns of P (t ) span the reachability subspace R(A, B). Corollary A system (A, B, C) is reachable if and only if P (t ) is symmetric positive denite at some time t > 0.
CME 345: MODEL REDUCTION - Balanced Truncation Reachability and Observability Equivalence Between Reachability and Controllability
Theorem The notions of controllability and reachability are equivalent for continuous linear dynamical systems, that is Xreach = Xcontr
CME 345: MODEL REDUCTION - Balanced Truncation Reachability and Observability Unobservability Subspace
Denition The unobservability subspace Xunobs Rn is the set of all unobservable states of system. O(C, A) = [C , A C , , (A )i C , ] is the observability matrix of the system.
CME 345: MODEL REDUCTION - Balanced Truncation Reachability and Observability Unobservability Subspace
Theorem Consider the system (A, B, C). Then Xunobs = ker O(C, A) (2)
Corollary (i) AXunobs Xunobs (ii) The system is completely observable if and only if rank O(A, B) = n (iii) Observability is basis independent
CME 345: MODEL REDUCTION - Balanced Truncation Reachability and Observability Innite Gramians
Denition The innite reachability (controllability) Gramian is dened as the n-by-n symmetric positive semidenite matrix
P=
0
e At BB e A t dt
Denition The innite observability Gramian is the n-by-n symmetric positive semidenite matrix Q=
0
e A t C Ce At dt
CME 345: MODEL REDUCTION - Balanced Truncation Reachability and Observability Innite Gramians
Using the Parseval theorem, the two Gramians can be written in the frequency domain:
The innite reachability Gramian Z 1 P= (j In A)1 BB (j In A )1 d 2 The innite observability Gramian Z 1 Q= (j In A )1 C C(j In A)1 d 2
CME 345: MODEL REDUCTION - Balanced Truncation Reachability and Observability Innite Gramians
The two innite Gramians are solution of the following Lyapunov equations: for the innite reachability Gramian AP + P A + BB = 0n for the innite observability Gramian A Q + QA + C C = 0n
CME 345: MODEL REDUCTION - Balanced Truncation Reachability and Observability Energetic Interpretation
P and Q are respective bases for the reachable and observable subspaces.
P 1
and
are semi-norms
The inner product based on P 1 characterizes the minimal energy required to steer the state from 0 to x as t x
2 P 1
= xT P 1 x.
The inner product based on Q indicates the maximal energy produced by observing the output of the system corresponding to an initial state x0 when no input is applied x0
2 Q
= xT 0 Qx0 .
CME 345: MODEL REDUCTION - Balanced Truncation Balancing Model Reduction Based on Balancing
Model reduction strategy: eliminate the states x that are at the same time:
dicult to reach, ie require a large energy x 2 P 1 to be reached dicult to observe, ie produce a small observation energy x 2 Q
These notions are basis depend We would like to place ourselves in a basis where both concepts are equivalent, ie where the system is balanced
CME 345: MODEL REDUCTION - Balanced Truncation Balancing The Eect of Basis Change on the Gramians
Balancing requires changing the basis for the state using a transformation T GL(n) x = Tx Then:
e At B Te At T1 TB = Te At B B e A t B T T e A t T = B e A t T The reachability Gramian becomes = TP T P Ce At CT1 Te At T1 = Ce At T1 e A t C T e A t T T C = T e A t C The observability Gramian becomes = T QT1 Q
where the entries in are ordered decreasingly compute the transformations Tbal
1 T bal
= =
2 K U1 UK 2
1
Denition (Hankel Singular Values) = diag(1 , , n ) contains the Hankel singular values of the system
David Amsallem & Charbel Farhat Stanford University cfarhat@stanford.edu CME 345: MODEL REDUCTION - Balanced Truncation
Computing the balancing transformation Tbal is equivalent to minimizing the following function:
TGL(n)
For the optimal transformation Tbal , the function takes the value
n
f (Tbal ) = 2tr() = 2
i =1
CME 345: MODEL REDUCTION - Balanced Truncation Balanced Truncation Block Partitioning of the System
Applying the change of variable x = Tbal x, the dynamical system , B , C ) where becomes (A
1 1 Tbal AT bal = A, Tbal B = B, CTbal = C
= B = C
1 B 2 B 1 C
CME 345: MODEL REDUCTION - Balanced Truncation Balanced Truncation Block Partitioning of the System
The blocks with subscript 1 correspond to the most observable and reachable states. The blocks with subscript 2 correspond to the least observable and reachable states. The reduced-order model of size k obtained by balanced truncation is then the system 11 , B 1, C 1 ) Rk k Rk p Rqk (Ar , Br , Cr ) = (A The left and right reduced-order bases are respectively W = T bal (:, 1 : k ), V = Sbal (:, 1 : k )
1 where Sbal = T bal .
Theorem (Stability Preservation) 11 , B 1, C 1 ), a ROM obtained by balanced Consider (Ar , Br , Cr ) = (A truncation. Then: 1 has no eigenvalues on the open right half plane. (i) Ar = A 11 , B 1, C 1 ) and (A 22 , B 2, C 2 ) have no (ii) Furthermore, if the systems (A Hankel singular values in common, Ar has no eigenvalues on the imaginary axis.
Theorem (Error Bounds) The Balanced Truncation procedure yields the following error bound for the output of interest. n SV Let { i }n i =1 {i }i =1 denote the distinct Hankel singular values of the nSV system and { i }i =nk +1 the ones that have been truncated. Then
nSV
y(t ) yr (t )
2
i =nk +1
i u(t ) 2 .
G(s ) Gr (s )
2
i =nk +1
i .
where G(s ) and Gr (s ) are the full- and reduced-order transfer functions. Equality holds when nk +1 = nSV (all truncated singular values are equal).
David Amsallem & Charbel Farhat Stanford University cfarhat@stanford.edu CME 345: MODEL REDUCTION - Balanced Truncation
Consider the error system E(s ) = G(s ) Gr (s ). Show that if all the truncated singular values are all equal to , then E(s )
H
= 2
E(s )
2
i =nk +1
CME 345: MODEL REDUCTION - Balanced Truncation The POD method revisited POD
Recall the theorem giving the POD basis: Theorem denote the n-by-n real symmetric matrix Let K
T
= K
0
x(t )x(t )T dt .
1 2 n 0 be the eigenvalues of K and Let i Rn , i = 1, , n their associated eigenvectors i = i i , i = 1, , n. K k > k +1 . The subspace V ) minimizing J ( ) is the = span(V Assume associated with the eigenvalues 1, , k invariant subspace of K
CME 345: MODEL REDUCTION - Balanced Truncation The POD method revisited POD for an Impulse Response
For an single impulse input with zero initial condition, the response for an LTI system is x(t ) = e At B Consequence:
T T
= K
0
x(t )x(t )T dt =
0
e At BBT e A t dt = P
is the reachability gramian. Unlike the Balanced Truncation method, the method does not take the observability gramian into account to determine the ROM: very observable states may be truncated.
CME 345: MODEL REDUCTION - Balanced Truncation Numerical Computation of Balanced Truncation Decomposition Numerical Methods
is usually ill-advised for numerical stability (computation of inverses). Instead, it is better advised to use the following procedure:
1
CME 345: MODEL REDUCTION - Balanced Truncation Numerical Computation of Balanced Truncation Decomposition Cost and Limitations
Balanced Truncation leads to ROM having quality and stability guarantees, however:
Computation of the Gramians is expensive as it requires computing the solution of a Lyapunov equation (O(n3 ) operations) As such, Balanced Truncation is generally impractical for large systems of size n 105
Goal is to model the position of the lens controlled by a swing arm 2-inputs/2-outputs system
David Amsallem & Charbel Farhat Stanford University cfarhat@stanford.edu CME 345: MODEL REDUCTION - Balanced Truncation
Bode plot of the Full-Order Model (n = 120) Each column represents one input and each row a dierent output
Bode Diagram From: In(1) From: In(2)
100
To: Out(1)
0 100
Magnitude (dB)
200 100 0
To: Out(2)
100 200
10
10
5
Frequency (rad/sec)
10
10
Bode plot of the balanced truncation-based reduced-order models Each column represents one input and each row a dierent output
Bode Diagram From: In(1) From: In(2)
150 100
To: Out(1)
50 0 50
Magnitude (dB)
100 50 0
To: Out(2)
50 100 150 10
5
Frequency (rad/sec)
10