EE16B, Spring 2018 UC Berkeley EECS Maharbiz and Roychowdhury Lectures...
Transcript of EE16B, Spring 2018 UC Berkeley EECS Maharbiz and Roychowdhury Lectures...
![Page 1: EE16B, Spring 2018 UC Berkeley EECS Maharbiz and Roychowdhury Lectures …inst.eecs.berkeley.edu/~ee16b/sp18/lec/Lecture4B.pdf · 2018. 2. 20. · EE16B, Spring 2018, Lectures on](https://reader036.fdocuments.us/reader036/viewer/2022062403/610e8cbadcdd0624196e43b5/html5/thumbnails/1.jpg)
EE16B, Spring 2018, Lectures on Linearization and Stability (Roychowdhury) Slide 1
EE16B, Spring 2018UC Berkeley EECS
Maharbiz and Roychowdhury
Lectures 4B & 5A: Overview Slides
Linearization and Stability
![Page 2: EE16B, Spring 2018 UC Berkeley EECS Maharbiz and Roychowdhury Lectures …inst.eecs.berkeley.edu/~ee16b/sp18/lec/Lecture4B.pdf · 2018. 2. 20. · EE16B, Spring 2018, Lectures on](https://reader036.fdocuments.us/reader036/viewer/2022062403/610e8cbadcdd0624196e43b5/html5/thumbnails/2.jpg)
EE16B, Spring 2018, Lectures on Linearization and Stability (Roychowdhury) Slide 2
Linearization
● Approximate a nonlinear system by a linear one➔ (unless it’s linear to start with)
● then apply powerful linear analysis tools➔ gain precise understanding → insight and intuition
● Consider a scalar system first● in state space form with additive input (for simplicity)
● step 1: choose DC input u*➔ find DC soln. x*
➔ x* is an equilibrium point● aka DC operating point
● for input u*
: solve for x*
![Page 3: EE16B, Spring 2018 UC Berkeley EECS Maharbiz and Roychowdhury Lectures …inst.eecs.berkeley.edu/~ee16b/sp18/lec/Lecture4B.pdf · 2018. 2. 20. · EE16B, Spring 2018, Lectures on](https://reader036.fdocuments.us/reader036/viewer/2022062403/610e8cbadcdd0624196e43b5/html5/thumbnails/3.jpg)
EE16B, Spring 2018, Lectures on Linearization and Stability (Roychowdhury) Slide 3
Linearization (contd. - 2)● DC operation (equilibrium), viewed in time
● Now, perturb the input a little:● Suppose x(t) responds by also changing a little
● ● Goal: find system relating Du(t) and Dx(t) directly
“small”
ASSUMED “small”
LinearizedSystem
![Page 4: EE16B, Spring 2018 UC Berkeley EECS Maharbiz and Roychowdhury Lectures …inst.eecs.berkeley.edu/~ee16b/sp18/lec/Lecture4B.pdf · 2018. 2. 20. · EE16B, Spring 2018, Lectures on](https://reader036.fdocuments.us/reader036/viewer/2022062403/610e8cbadcdd0624196e43b5/html5/thumbnails/4.jpg)
EE16B, Spring 2018, Lectures on Linearization and Stability (Roychowdhury) Slide 4
Linearization (contd. - 3)
● Basic notion: replace f(x) by its tangent line at x*● Mathematically: expand f(x*+Dx) in Taylor Series
accurate forsmall Dx
inaccurate forlarger Dxslope
![Page 5: EE16B, Spring 2018 UC Berkeley EECS Maharbiz and Roychowdhury Lectures …inst.eecs.berkeley.edu/~ee16b/sp18/lec/Lecture4B.pdf · 2018. 2. 20. · EE16B, Spring 2018, Lectures on](https://reader036.fdocuments.us/reader036/viewer/2022062403/610e8cbadcdd0624196e43b5/html5/thumbnails/5.jpg)
EE16B, Spring 2018, Lectures on Linearization and Stability (Roychowdhury) Slide 5
Linearization (contd. - 4)● applying the Taylor linearization
● (move to xournal)
ORIGINAL
LINEARIZED
![Page 6: EE16B, Spring 2018 UC Berkeley EECS Maharbiz and Roychowdhury Lectures …inst.eecs.berkeley.edu/~ee16b/sp18/lec/Lecture4B.pdf · 2018. 2. 20. · EE16B, Spring 2018, Lectures on](https://reader036.fdocuments.us/reader036/viewer/2022062403/610e8cbadcdd0624196e43b5/html5/thumbnails/6.jpg)
EE16B, Spring 2018, Lectures on Linearization and Stability (Roychowdhury) Slide 6
Linearization of Vector S.S. Systems
● Now: the full S.S.R:
● step 1: find a DC. op. pt. (equilibrium pt.)●
● The linearized system is (see handwritten notes for derivation)
● What are and ?● called Jacobian or gradient matrices
DC input
DC solution
Solving for this is often difficult,even using computational methods
n-vector nxn matrix m-vectornxm matrix
![Page 7: EE16B, Spring 2018 UC Berkeley EECS Maharbiz and Roychowdhury Lectures …inst.eecs.berkeley.edu/~ee16b/sp18/lec/Lecture4B.pdf · 2018. 2. 20. · EE16B, Spring 2018, Lectures on](https://reader036.fdocuments.us/reader036/viewer/2022062403/610e8cbadcdd0624196e43b5/html5/thumbnails/7.jpg)
EE16B, Spring 2018, Lectures on Linearization and Stability (Roychowdhury) Slide 7
Jacobian (Gradient) Matrices
● If: , then
nxn matrix
nxm matrix
![Page 8: EE16B, Spring 2018 UC Berkeley EECS Maharbiz and Roychowdhury Lectures …inst.eecs.berkeley.edu/~ee16b/sp18/lec/Lecture4B.pdf · 2018. 2. 20. · EE16B, Spring 2018, Lectures on](https://reader036.fdocuments.us/reader036/viewer/2022062403/610e8cbadcdd0624196e43b5/html5/thumbnails/8.jpg)
EE16B, Spring 2018, Lectures on Linearization and Stability (Roychowdhury) Slide 8
Example: Linearizing the Pendulum
● Pendulum: ● (move to xournal)
● Compare against sin(q)≈q approximation (prev. class)
![Page 9: EE16B, Spring 2018 UC Berkeley EECS Maharbiz and Roychowdhury Lectures …inst.eecs.berkeley.edu/~ee16b/sp18/lec/Lecture4B.pdf · 2018. 2. 20. · EE16B, Spring 2018, Lectures on](https://reader036.fdocuments.us/reader036/viewer/2022062403/610e8cbadcdd0624196e43b5/html5/thumbnails/9.jpg)
EE16B, Spring 2018, Lectures on Linearization and Stability (Roychowdhury) Slide 9
This and future lectures
Where We Are Now
Any kind of system(EE, mech., chem.,
optical, multi-domain,...)
STATE SPACEFORMULATION
continuous AND discrete systems
LINEAR
NONLINEAR
LINEARIZATION
stability
controllabilityobservability
FEEDBACK
practicallyuseful
engineeredsystems
![Page 10: EE16B, Spring 2018 UC Berkeley EECS Maharbiz and Roychowdhury Lectures …inst.eecs.berkeley.edu/~ee16b/sp18/lec/Lecture4B.pdf · 2018. 2. 20. · EE16B, Spring 2018, Lectures on](https://reader036.fdocuments.us/reader036/viewer/2022062403/610e8cbadcdd0624196e43b5/html5/thumbnails/10.jpg)
EE16B, Spring 2018, Lectures on Linearization and Stability (Roychowdhury) Slide 10
Pendulum: Inverted Solution
● Pendulum:
● DC input: b(t) = b*● DC solution: dx/dt = 0 → ,
inverted position
![Page 11: EE16B, Spring 2018 UC Berkeley EECS Maharbiz and Roychowdhury Lectures …inst.eecs.berkeley.edu/~ee16b/sp18/lec/Lecture4B.pdf · 2018. 2. 20. · EE16B, Spring 2018, Lectures on](https://reader036.fdocuments.us/reader036/viewer/2022062403/610e8cbadcdd0624196e43b5/html5/thumbnails/11.jpg)
EE16B, Spring 2018, Lectures on Linearization and Stability (Roychowdhury) Slide 11
Inverted Pendulum: Linearization
●
●
● Linearization:
non-inverted
![Page 12: EE16B, Spring 2018 UC Berkeley EECS Maharbiz and Roychowdhury Lectures …inst.eecs.berkeley.edu/~ee16b/sp18/lec/Lecture4B.pdf · 2018. 2. 20. · EE16B, Spring 2018, Lectures on](https://reader036.fdocuments.us/reader036/viewer/2022062403/610e8cbadcdd0624196e43b5/html5/thumbnails/12.jpg)
EE16B, Spring 2018, Lectures on Linearization and Stability (Roychowdhury) Slide 12
Pole & Cart (Inverted Pendulum ++)● Slightly more complicated example
● → discussion / HW
![Page 13: EE16B, Spring 2018 UC Berkeley EECS Maharbiz and Roychowdhury Lectures …inst.eecs.berkeley.edu/~ee16b/sp18/lec/Lecture4B.pdf · 2018. 2. 20. · EE16B, Spring 2018, Lectures on](https://reader036.fdocuments.us/reader036/viewer/2022062403/610e8cbadcdd0624196e43b5/html5/thumbnails/13.jpg)
EE16B, Spring 2018, Lectures on Linearization and Stability (Roychowdhury) Slide 13
Stability
● Basic idea: perturb system a little from equilibrium● does it come back? yes → STABLE
● More precisely:● small perturbations → small responses
“small”
remains “small”
BIBO STABLEBIBO = bounded input bounded output
![Page 14: EE16B, Spring 2018 UC Berkeley EECS Maharbiz and Roychowdhury Lectures …inst.eecs.berkeley.edu/~ee16b/sp18/lec/Lecture4B.pdf · 2018. 2. 20. · EE16B, Spring 2018, Lectures on](https://reader036.fdocuments.us/reader036/viewer/2022062403/610e8cbadcdd0624196e43b5/html5/thumbnails/14.jpg)
EE16B, Spring 2018, Lectures on Linearization and Stability (Roychowdhury) Slide 14
Stability (contd. - 2)
“small”becomes large
UNSTABLE
![Page 15: EE16B, Spring 2018 UC Berkeley EECS Maharbiz and Roychowdhury Lectures …inst.eecs.berkeley.edu/~ee16b/sp18/lec/Lecture4B.pdf · 2018. 2. 20. · EE16B, Spring 2018, Lectures on](https://reader036.fdocuments.us/reader036/viewer/2022062403/610e8cbadcdd0624196e43b5/html5/thumbnails/15.jpg)
EE16B, Spring 2018, Lectures on Linearization and Stability (Roychowdhury) Slide 15
Stability: the Scalar Case
● Analysis: start w scalar case:➔ [already linear(ized); everything is real]
● Solution:● [obtained by, eg, the method of integrating factors (Piazza: @88)]
● The initial condition term: . Say
real
initial condition term input term (convolution)
a<0: dies downSTABLE
a>0: blows upUNSTABLE
a=0: stays the sameMARGINALLY STABLE
![Page 16: EE16B, Spring 2018 UC Berkeley EECS Maharbiz and Roychowdhury Lectures …inst.eecs.berkeley.edu/~ee16b/sp18/lec/Lecture4B.pdf · 2018. 2. 20. · EE16B, Spring 2018, Lectures on](https://reader036.fdocuments.us/reader036/viewer/2022062403/610e8cbadcdd0624196e43b5/html5/thumbnails/16.jpg)
EE16B, Spring 2018, Lectures on Linearization and Stability (Roychowdhury) Slide 16
Stability: Scalar Case (contd.)
● Solution:
● Can show (see handwritten notes):
● if a<0: bounded if Du(t) bounded: BIBO stable● if a>0: unbounded even if Du(t) bounded: UNSTABLE
● if a=0: unbounded even if Du(t) bounded: UNSTABLE
input term (convolution)
a<0: BIBO STABLE a≥0: UNSTABLE
![Page 17: EE16B, Spring 2018 UC Berkeley EECS Maharbiz and Roychowdhury Lectures …inst.eecs.berkeley.edu/~ee16b/sp18/lec/Lecture4B.pdf · 2018. 2. 20. · EE16B, Spring 2018, Lectures on](https://reader036.fdocuments.us/reader036/viewer/2022062403/610e8cbadcdd0624196e43b5/html5/thumbnails/17.jpg)
EE16B, Spring 2018, Lectures on Linearization and Stability (Roychowdhury) Slide 17
The Vector Case: Eigendecomposition
● The vector case:➔ [already linear(ized); everything is real]
● Can be “decomposed” into n scalar systems● the key idea: to eigendecompose A
● (recap) eigendecomposition: given an nxn matrix A:*
real matrices
eigenvectors eigenvalues
same thing
* diagonalization always possible if all eigenvalues distinct (assumed)
if time, move to xournal
![Page 18: EE16B, Spring 2018 UC Berkeley EECS Maharbiz and Roychowdhury Lectures …inst.eecs.berkeley.edu/~ee16b/sp18/lec/Lecture4B.pdf · 2018. 2. 20. · EE16B, Spring 2018, Lectures on](https://reader036.fdocuments.us/reader036/viewer/2022062403/610e8cbadcdd0624196e43b5/html5/thumbnails/18.jpg)
EE16B, Spring 2018, Lectures on Linearization and Stability (Roychowdhury) Slide 18
Eigendecomposition (contd.)
● eigenvalues and determinants●
● i.e.,
●
● the roots of the char. poly. are the eigenvalues● factorized form:● in general, n roots → n eigenvalues {l
1, l
2, …, l
n}
must be singular in order to support a non-zero solution for
characteristic polynomial of A
![Page 19: EE16B, Spring 2018 UC Berkeley EECS Maharbiz and Roychowdhury Lectures …inst.eecs.berkeley.edu/~ee16b/sp18/lec/Lecture4B.pdf · 2018. 2. 20. · EE16B, Spring 2018, Lectures on](https://reader036.fdocuments.us/reader036/viewer/2022062403/610e8cbadcdd0624196e43b5/html5/thumbnails/19.jpg)
EE16B, Spring 2018, Lectures on Linearization and Stability (Roychowdhury) Slide 19
The Vector Case: Diagonalization● Applying eigendecomposition: diagonalization
➔ (move to xournal)
![Page 20: EE16B, Spring 2018 UC Berkeley EECS Maharbiz and Roychowdhury Lectures …inst.eecs.berkeley.edu/~ee16b/sp18/lec/Lecture4B.pdf · 2018. 2. 20. · EE16B, Spring 2018, Lectures on](https://reader036.fdocuments.us/reader036/viewer/2022062403/610e8cbadcdd0624196e43b5/html5/thumbnails/20.jpg)
EE16B, Spring 2018, Lectures on Linearization and Stability (Roychowdhury) Slide 20
Stability: the Vector Case
●
● System stable if each system is stable● Complication: eigenvalues can be complex
● reason: real matrices A can have complex eigen{vals,vecs}● examples: (also demo in MATLAB)
➔
➔
provided li is REAL
![Page 21: EE16B, Spring 2018 UC Berkeley EECS Maharbiz and Roychowdhury Lectures …inst.eecs.berkeley.edu/~ee16b/sp18/lec/Lecture4B.pdf · 2018. 2. 20. · EE16B, Spring 2018, Lectures on](https://reader036.fdocuments.us/reader036/viewer/2022062403/610e8cbadcdd0624196e43b5/html5/thumbnails/21.jpg)
EE16B, Spring 2018, Lectures on Linearization and Stability (Roychowdhury) Slide 21
Stability: the Vector Case (contd.)● If A real, eigen{v,v}s come in complex conjugate pairs
● ● Implications (details in handwritten notes)
● internal quantities in the decomposition come in conjugate pairs➔ the rows of P-1, Db
i(t), the eigenvalues , Dy
i(t), the cols of P
● complex conjugatepair (say): sum is real real (say)
real (say)always real
just like the real scalar case
derived from
Dy2(0) and
derived fromDb
2(t) and
jth componentof vector IC term
input term (convolution)
![Page 22: EE16B, Spring 2018 UC Berkeley EECS Maharbiz and Roychowdhury Lectures …inst.eecs.berkeley.edu/~ee16b/sp18/lec/Lecture4B.pdf · 2018. 2. 20. · EE16B, Spring 2018, Lectures on](https://reader036.fdocuments.us/reader036/viewer/2022062403/610e8cbadcdd0624196e43b5/html5/thumbnails/22.jpg)
EE16B, Spring 2018, Lectures on Linearization and Stability (Roychowdhury) Slide 22
Stability: the Vector Case (contd. - 2)
● Initial condition terms:
● Input conv. terms:● can show (see notes) that:
➔ if lr<0: bounded if Du(t) bounded: BIBO stable
➔ if lr>0: unbounded even if Du(t) bounded: UNSTABLE
➔ if lr=0: unbounded even if Du(t) bounded: UNSTABLE
lr<0: envelope dies down
STABLE
lr>0: envelope blows up
UNSTABLEl
r=0: const. envelope
MARGINALLY STABLE
same as for real eigenvalues, butusing the real parts of complex eigenvalues
![Page 23: EE16B, Spring 2018 UC Berkeley EECS Maharbiz and Roychowdhury Lectures …inst.eecs.berkeley.edu/~ee16b/sp18/lec/Lecture4B.pdf · 2018. 2. 20. · EE16B, Spring 2018, Lectures on](https://reader036.fdocuments.us/reader036/viewer/2022062403/610e8cbadcdd0624196e43b5/html5/thumbnails/23.jpg)
EE16B, Spring 2018, Lectures on Linearization and Stability (Roychowdhury) Slide 23
Eigenvalues and Responses (continuous)complex plane for plotting eigenvalues
![Page 24: EE16B, Spring 2018 UC Berkeley EECS Maharbiz and Roychowdhury Lectures …inst.eecs.berkeley.edu/~ee16b/sp18/lec/Lecture4B.pdf · 2018. 2. 20. · EE16B, Spring 2018, Lectures on](https://reader036.fdocuments.us/reader036/viewer/2022062403/610e8cbadcdd0624196e43b5/html5/thumbnails/24.jpg)
EE16B, Spring 2018, Lectures on Linearization and Stability (Roychowdhury) Slide 24
Eigenvalues of Linearized Pendulum
● (move to xournal)
plot eigenvalues as k changesplot eigenvalues as k changes
(run pendulum_root_locus.m)
always stable if non-zero friction
![Page 25: EE16B, Spring 2018 UC Berkeley EECS Maharbiz and Roychowdhury Lectures …inst.eecs.berkeley.edu/~ee16b/sp18/lec/Lecture4B.pdf · 2018. 2. 20. · EE16B, Spring 2018, Lectures on](https://reader036.fdocuments.us/reader036/viewer/2022062403/610e8cbadcdd0624196e43b5/html5/thumbnails/25.jpg)
EE16B, Spring 2018, Lectures on Linearization and Stability (Roychowdhury) Slide 25
Eigenvalues of Inverted Pendulum
●
always unstable!
always real, always greater than
one eigenvalue always positive!
![Page 26: EE16B, Spring 2018 UC Berkeley EECS Maharbiz and Roychowdhury Lectures …inst.eecs.berkeley.edu/~ee16b/sp18/lec/Lecture4B.pdf · 2018. 2. 20. · EE16B, Spring 2018, Lectures on](https://reader036.fdocuments.us/reader036/viewer/2022062403/610e8cbadcdd0624196e43b5/html5/thumbnails/26.jpg)
EE16B, Spring 2018, Lectures on Linearization and Stability (Roychowdhury) Slide 26
Stability for Discrete Time Systems
● The scalar case: , IC Dx[0]➔ [already linear(ized); everything is real]➔ (move to xournal?)
●
● Initial Condition term:
real
IC term input term (discrete convolution)
0<a<1: dies downSTABLE
-1<a<0: dies downSTABLE
a>1: blows upUNSTABLE
a<-1: blows upUNSTABLE
a=1: constantMARGINALLY STABLE
a=-1: constantMARGINALLY STABLE
0
-1 1STABLE STABLEUNSTABLE UNSTABLE
MARGINALLY STABLE MARGINALLY STABLE
![Page 27: EE16B, Spring 2018 UC Berkeley EECS Maharbiz and Roychowdhury Lectures …inst.eecs.berkeley.edu/~ee16b/sp18/lec/Lecture4B.pdf · 2018. 2. 20. · EE16B, Spring 2018, Lectures on](https://reader036.fdocuments.us/reader036/viewer/2022062403/610e8cbadcdd0624196e43b5/html5/thumbnails/27.jpg)
EE16B, Spring 2018, Lectures on Linearization and Stability (Roychowdhury) Slide 27
Scalar Discrete-Time Stability (contd.)
● Solution:
● Can show (see handwritten notes):
● if |a|<1: bounded if Du(t) bounded: BIBO stable● if |a|>1: unbounded even if Du(t) bounded: UNSTABLE
● if |a|=1: unbounded even if Du(t) bounded: UNSTABLE
input term (d. convolution)
|a|<1: BIBO STABLE |a|≥1: UNSTABLE
![Page 28: EE16B, Spring 2018 UC Berkeley EECS Maharbiz and Roychowdhury Lectures …inst.eecs.berkeley.edu/~ee16b/sp18/lec/Lecture4B.pdf · 2018. 2. 20. · EE16B, Spring 2018, Lectures on](https://reader036.fdocuments.us/reader036/viewer/2022062403/610e8cbadcdd0624196e43b5/html5/thumbnails/28.jpg)
EE16B, Spring 2018, Lectures on Linearization and Stability (Roychowdhury) Slide 28
Discrete Time Stability: the Vector Case
● The vector case:➔ [already linear(ized); everything is real]
● Eigendecompose A: ● Define:
● ● Decomposed system:
● same as scalar case, but li now complex
● same form for as for the continuous case➔ complex conjugate terms always present in pairs → real
● Stability:● BIBO stable iff ,
real matrices
scalar
1 .
..
.
.
.
.
![Page 29: EE16B, Spring 2018 UC Berkeley EECS Maharbiz and Roychowdhury Lectures …inst.eecs.berkeley.edu/~ee16b/sp18/lec/Lecture4B.pdf · 2018. 2. 20. · EE16B, Spring 2018, Lectures on](https://reader036.fdocuments.us/reader036/viewer/2022062403/610e8cbadcdd0624196e43b5/html5/thumbnails/29.jpg)
EE16B, Spring 2018, Lectures on Linearization and Stability (Roychowdhury) Slide 29
Eigenvalues and IC Responses (discrete)complex plane for plotting eigenvalues
![Page 30: EE16B, Spring 2018 UC Berkeley EECS Maharbiz and Roychowdhury Lectures …inst.eecs.berkeley.edu/~ee16b/sp18/lec/Lecture4B.pdf · 2018. 2. 20. · EE16B, Spring 2018, Lectures on](https://reader036.fdocuments.us/reader036/viewer/2022062403/610e8cbadcdd0624196e43b5/html5/thumbnails/30.jpg)
EE16B, Spring 2018, Lectures on Linearization and Stability (Roychowdhury) Slide 30
Summary
● Linearization● scalar and vector cases
➔ example: pendulum, (pole-cart)● Stability
● scalar and vector cases➔ continuous: real parts of eigenvalues determine stability
● pendulum: stable and unstable equilibria● eigenvalue vs friction plots (root-locus plots)
➔ discrete: magnitudes of eigenvalues determine stability