Practical Adaptive Control
Practical Adaptive Control
Anuradha Annaswamy
Active-Adaptive Control Laboratory
Department of Mechanical Engineering
Outline
• Foundations
– Parameter Adaptation
– Robust parameter estimation
– Nonlinear Dynamics
– Large Delays
– Unmatched uncertainties
• Validation
– High Fidelity Simulations
– Hardware-in-the-loop (HIL) Tests
– Stand-alone Hardware Tests
Foundations: Adaptive Control
Adaptive Control
Adaptive
Controller
On-line information
Parameter estimate
θ : parameter, unknown
x,y,u: state, output, input
e: tracking error
θc: control parameter estimate
• A stable solution:
• An optimal solution:
•
• Adaptive control solution: u = (θ (t ) + K )x + r θ
• Reference Model
Command
xp e
( sI − Am )
−1
θT Bp
(
e Pe + Trace θT Γ −1θ
V= T
) ⇒ V =
−eT Qe ≤ 0
•
Plant + controller: p m p m p
x = a x + b r + b λ ( (θ x (t ) − θ *
x ) x p + (θ r (t ) − θ r ) r ) + bp d
*
≤ − | e | (| am || e | −2 | bp λ | d max )
| am | V > 0?
Robust Parameter Estimation
• Plant: x p =a p x p + bp (λu + d ) a p , bp known,λ unknown
• Adaptive controller: = u θ x (t ) x p + θ r (t )r
• Plant + controller:
x p = am x p + b m r + b p λ ( (θ x (t ) − θ *
x ) x p + (θ r (t ) − θ *
r ) r ) + bp
• Reference model: = xm am xm + bm r
• Error model: e = am e + bp λ (θx (t ) x p + θr (t )r ) + bp d
θ = − sgn ( bp λ ) eω − σθ
Lyapunov function candidate V > 0?
(
V = e + bp λ (θx2 + θr2 )
1 2
)
= V 2am e 2 + 2bp ed − σθθ 2
(
≤ − | e | (| am || e | −2 | bp | d max ) − σ θ θ − θ max
*
)
(
≤ − | am | (| e | −a1 ) (
+ σ | θ | −a2 ))
2
+ c 2 ≤ 0 outside an ellipse
2
Nonlinearities
1. Robustness approach:
e = Ae + BΛ (θT ω + ε 0 ( x) ) ε 0 ( x) ≤ µ x + c0
m
Adaptive law:
θ = −Γe PBω − σ f (θ , e)
T
Parametric
Time Delay:
Controller Uncertainty:
Signal Processing,
Actuator Failure,
Computation,
Electrical fault,
Communication
Damage
∫ λ (σ )u(t + σ )dσ
Rm e(t )
−τ Σ
u (t ) Zp − sτ
y p (t )
r (t ) θ 4 (t ) Σ kp e
+ Rp
+
Λ, l
Λ, l
θ(t ) = − Γe(t )ω (t − τ )
ω1
θ1T
ω2
θ2 T
→ Krasovskii functional.
t ~ 2
[ ]≤0
0
~2
( )
V = e + θ + ∫ ∫ θ ξ dξ dν
2
V = −e(t ) α − 2τ ω (t − τ )
2
for small τ .
−τ t +ν
* Niculescu and Annaswamy, Systems and Control Letters , vol. 49, pp. 347-358, 2003.
Large Delays: Posicast + CMRAC
• Adaptive Posicast Control (APC)***
– Explicitly accounts for known delay in the system
– Gives a time delay margin τ*
• Combined / Composite MRAC (CMRAC)*
– Uses information from 2 sources to adjust parameters: tracking error
and prediction error
– Results in smoother transients
• Bounded-Gain-Forgetting (BGF) adaptive gains**
– Adaptive gains become time-varying
– Allows faster parameter convergence, smoother parameter estimates
• Time-delay Resistant adaptive control+
* Duarte, Narendra, “A new approach to model reference adaptive control,” Int J Adaptive Control, 1988.
* Slotine, Li, “Composite adaptive control of robot manipulators,” Automatica, 1989.
** Slotine, Li, “Parameter estimation strategies for robotic applications,” ASME Winter Annual Meeting, 1987.
*** Yildiz, et al. “Adaptive posicast controller for time-delay systems with relative degree n* ≤2," Automatica, 2010.
+ Dydek, Annaswamy, Slotine, Lavretsky, “Time delay resistant adaptive control of mini-UAVs,“ IFAC TDS Workshop,
2010.
Time Delay Resistant Adaptive Control*
• Time Delay Resistant (TDR) Adaptive Control:
– Combines all of the modifications into one coherent
structure
– Has guaranteed stability via a Lyapunov-based approach
Theorem:
Given initial conditions on the adaptive parameters at t = 0 and
initial conditions on the states for –τ ≤ t ≤ 0, there exists a τ* such
that for all τ ≤ τ*, the adaptive system has bounded trajectories
for all t > 0. Time Delay Margin
£ ¡ 2 ¢ ¤
V_ · ¡ e (t) Q ¡ 2¿ ° 0 + 1 jj! (t ¡ ¿)jj PB B P e(t)
T 2 T
T
£ 2 2 2
¤
¡ eY (t) ° c ¡ ¿° c ° 0 jj! f (t ¡ ¿)jj eY (t)
Verification
Uncertainties, Modeling
Errors, Anomalies
+ Adaptive
Cmd Plant
Controller
-
+ Baseline
Adaptive Mag &
Cmd + Rate limits Plant
Network
Controller
Controller
-
• Baseline designs:
– LQR+Integral action
– Gain-scheduling (see the above example)
– Optimal controllers
• Augmentation is nontrivial, especially with partial states
accessible
Validation: X-15
Summary of X-15 Project
• Developed a full nonlinear model of the X-15 aircraft and original
1960’s MH-96 adaptive controller
– Reproduces anomalous behavior, fatal crash from 1967
24 Adaptive Parameters
ri i δ ad i
H cmd , Vcmd
δ δ nom θ = −Γ i BTpi Pe
i uω
T
δ nom = K x xh
h i
ucmd
θ
H, V
H, V
δ ad i
Can we bridgeθ this i
gap?
δ ad = θ T ω
= −Γ B Pe ω
r h H, Vx i
T
pi i u
T
i θ
δ ad
i
θ
ucmd x
x (coupling removed)
δ θ ω = T
3 Adaptive Parameters
3 Adaptive Parameters
x (α, β, integral
(PCstates
Adaptive law replaced
removed;
eu replaced with e) MH-96 logic)
PC Adaptive law is key!
Anti-windup solutions: 1. Magnitude Saturation
Input u R (u ) P
Saturation Plant
Magnitude Constraints
Generate a signal eu
λˆ = Γλ diag (∆u ) B T Peu
e = x p − xm where AmT P + PAm = −Q, Q > 0
eu = e − e∆
e∆ = Am e∆ + Bdiag (λˆ )∆u Semi-global stability can be shown.
28
* S. Karason and A.M. Annaswamy, IEEE Trans. Autom. Control, 1994.
Results: HSV with Flexible Effects
Multiplicative uncertainty Initial conditions Reference commands
Mach 8
85,000 ft
29
2. Adaptive Reset Control
Controller
+ Integral u sat (u )
Action
P
Resetting
- State resetting in
error integral state
xct r(tj rj+ ) = sat ( xc (t rj ))
where trj is the time instance
at which (i) xc (trj ) = 0 (ii) u (trj ) ≥ u0
tracking performance 30
Adaptive Reset Control: Control Architecture
Reference Model
xm = Am xm + Br r λˆ = Γλ diag (∆u + K c ∆c) B T Peu
Error AmT P + PAm = −Q, Q > 0
e = x − xm
Resetting xc (t rj+ ) = sat ( xc (t rj ))
eu = e − e∆
when (i) xc (t rj ) = 0 (ii) u (t rj ) ≥ u0 31
e∆ = Am e∆ + Bdiag (Λ
ˆ )(∆u + K ∆c)
c
Semi-global stability can be shown.
Adaptive Reset Control: A First-order Example
States
Resetting occurs
(twice)
32
A Transport Aircraft (uncertainty: CG shift)
States
Nominal Controller Adaptive Reset Controller
Input u R (u ) 1 ua
s P
Saturation Plant
Plant x p = Ap x p + B p Λua
Input Constraints u ≤ um 0 , u ≤ ur 0
Problem: Ensure stability and performance in the presence of rate and magnitude limits
35
An Adaptive Solution
Control Signal
(Suggested Adaptive Controller)
rate saturation magnitude saturation
37
Optimization of Non-adaptive Components
Reference
Model
Plant
Nominal
Controller
Saturation
Adaptive
Controller mux
• Uncertainty / Failure p
• Controller parameter d
• nominal point p0
One-dimensional Setting:
• critical requirement g1; g2
S1 • critical point p*
g1 g2
S • safety domain S
• Determine d so
that the safety
p* p0 p domain is
p*
maximized
39
S2
Margins of Adaptive Systems
• System:
- Plant: x (t ) = Aλ x(t ) + bλu (t − τ ) y (t ) = cT x(t )
Theorem. The system, in the presence of (n, n) Pade approximation, with the
controller based on the adaptive law, there existτ m > 0 and ymax > 0 such that θ (t ) , x(t )
have bounded trajectories for all t > t0 if
i. 0 < τ < τ m
ii. || y (0) ||< ymax
τ m is defined as a delay margin.
Adaptive Control for an Embedded System
– The total delay consists of two parts: a known part due to the
schedule and an unknown part due to communication constraints
Adaptive Control of a NCS
• Linear system
• Sampled system
• Control input
• Update laws
• Stability proof
Results
Fixed Controller
– Linear plant
– At , the sampling
rate changes from 1ms
to 10ms
– This can happen due to
power consumption
constraints or changes in
the environment Adaptive Controller
– The adaptive controller
follows the reference
input whereas the fixed
controller cannot deal
with this change in the
protocol
Validation
KS , KD
J ′′
“ParaFlex”
Manipulation with UAV
“QuadPush, QuadPull,
QuadGrip, QuadFlex”
F τ
F sin (θ )
PUSH
Contact
Time
Adaptive Control of the GTM
Baseline
AoA
•LQR-PI
Baseline
Adaptive Controller
Roll
•Saturation
Time
•Anti Windup
•Nonlinear Engine Model
•20ms Analog Delay in reference
•60ms Digital Delay in reference
Scenario
Analog time delay 60 ms (nominal 20ms)
Digital time delay 105 ms (nominal 60ms)
Left aileron Locked -10 deg
Adaptive
Hardware-in-the-Loop tests
High Fidelity simulation studies
Integration with Baseline
adaptive Components
Optimization of Non-
Embedded adaptive
Verification Tools
Anti-windup:
Margins
Designs
control
Unmatched Uncertainties
Foundation
Collaborators: Sponsors:
Eugene Lavretsky (Boeing) Boeing
Ilya Kolmanovsky (U Michigan) Ford
Jean-Jacques Slotine (MIT) NASA (Aeronautics & Aviation Safety)
Jonathan How (MIT) TU München Institute for Advanced Study
Nick Roy (MIT)