PID Controller Design for Nonlinear Systems Using Discrete-Time Local Model Networks 4. Workshop für Modellbasierte Kalibriermethoden Nikolaus Euler-Rolle, Christoph Hametner, Stefan Jakubek Christian Mayr (AVL List GmbH) 08.11.2013 4. Workshop für Modellbasierte Kalibriermethoden: Euler-Rolle - PID Controller Design for Nonlinear Systems 1/26
Feedback Control of Nonlinear Systems Motivation Implementation of Two-Degrees-of-Freedom control using local model networks Feedforward part improves the dynamic performance - Reference tracking - Deadtime - Input saturation Controller design on (semi)-physical process models instead of testbed runs Opportunity of inexpensive feasibility studies and rapid prototyping w u* w* PID u Plant y 4. Workshop für Modellbasierte Kalibriermethoden: Euler-Rolle - PID Controller Design for Nonlinear Systems 2/26
Feedback Control of Nonlinear Systems Motivation Implementation of Two-Degrees-of-Freedom control using local model networks Feedforward part improves the dynamic performance - Reference tracking - Deadtime - Input saturation Controller design on (semi)-physical process models instead of testbed runs Opportunity of inexpensive feasibility studies and rapid prototyping Approach Globally nonlinear process model (based on input/output measurements) Design of nonlinear PID controllers with guaranteed global stability Fully automated generation of a dynamic feedforward control 4. Workshop für Modellbasierte Kalibriermethoden: Euler-Rolle - PID Controller Design for Nonlinear Systems 2/26
Controller Design Workflow DoE Signals Maps [n, q, u] Testbed y Identification LMN SS-Model Local PIDs Parameter Simulation Controller Maps Stability Optimisation Performance DoE 4. Workshop für Modellbasierte Kalibriermethoden: Euler-Rolle - PID Controller Design for Nonlinear Systems 3/26
Controller Design Workflow DoE Signals Dynamic FF-Control Maps [n, q, u] Testbed y Identification LMN SS-Model Local PIDs Parameter Simulation Controller Maps Stability Optimisation Performance DoE 4. Workshop für Modellbasierte Kalibriermethoden: Euler-Rolle - PID Controller Design for Nonlinear Systems 3/26
2 PID Controller Design 4. Workshop für Modellbasierte Kalibriermethoden: Euler-Rolle - PID Controller Design for Nonlinear Systems 4/26
Local Model Network Overview Injection Mass, mg/stroke 30 25 20 15 10 5 local global 1000 1500 2000 2500 Engine Speed, rpm Local Model Network Globally nonlinear dynamical system represented by local linear models Found by system identification Local stability proof & controller design using linear methods Global approach necessary (due to transition, model interpolation...) o for nonlinear systems o based on Lyapunov stability theory 4. Workshop für Modellbasierte Kalibriermethoden: Euler-Rolle - PID Controller Design for Nonlinear Systems 5/26
Typical PID Controller Structure Example: Engine Control Unit n q n q Map w - y e P-Part I-Part anti windup DT1-Part Feedback- Feedforward- Control u fb u ff max min u n q Map 4. Workshop für Modellbasierte Kalibriermethoden: Euler-Rolle - PID Controller Design for Nonlinear Systems 6/26
Feedback Controlled Local Model Network Concept One local controller (LC) per local model (LM) Scheduling of parameters according to the validity functions of local models (Parallel Distributed Compensator) K PID(Φ) = Φ ik (i) PID Formal split into inputs used for control u and disturbances z Nonlinear process is approximated by a local model network Trade-Off: model fit simple controller design Closed-loop state-space representation necessary (to prove Lyapunov stability) 4. Workshop für Modellbasierte Kalibriermethoden: Euler-Rolle - PID Controller Design for Nonlinear Systems 7/26
Closed-Loop State-Space Representation Including Error Signal Adaptation K PID (Φ,e) System w(k) Pre-Filter v(k) - f(φ) B(Φ) x(k +1) q 1 I c T ŷ(k) z(k) Input Scheduler ẑ(k) E(Φ) A(Φ) x(k) w e(φ,e) B(Φ) Figure: Local model network with PID controller in state-space representation State Equation x(k +1) =[A(Φ) B(Φ)K PID (Φ,e)]x(k)+B(Φ)G(Φ,e)w(k)+E(Φ)ẑ(k) +f(φ)+b(φ)w e(φ,e) ŷ(k) =c T x(k) 4. Workshop für Modellbasierte Kalibriermethoden: Euler-Rolle - PID Controller Design for Nonlinear Systems 8/26
Overview of the Design Procedure Controller Design Basic calibration (linear design methods per local model) Generation of a suitable performance sequence (DoE) - Operating range (e.g.: 1000 4000 rpm, 0 70 mg/stroke) - Holding time - Gradients (e.g.: engine speed) - Filtering Nonlinear, multi-objective optimisation of controller parameters considering - Performance - Stability Multi-objective optimisation of the parameters of the error signal adaptation (optional) 4. Workshop für Modellbasierte Kalibriermethoden: Euler-Rolle - PID Controller Design for Nonlinear Systems 9/26
Multi-Objective Genetic Algorithm Objective Function min f m(x opt) subject to g j (x opt) 0 h k (x opt) = 0 x (lb) i x i x (ub) i GA Population Individuals 1 n f S Stability (by Lyapunov s direct method) f P Performance (by a closed-loop simulation) Genome Fitness Genome Fitness f P Stability Performance Stability Performance 0 Paretofrontier f S 4. Workshop für Modellbasierte Kalibriermethoden: Euler-Rolle - PID Controller Design for Nonlinear Systems 10/26
Fitness Function: Stability Lyapunov s Direct Method for Discrete-Time Systems Stability of Dynamic Systems A positive definite, scalar Lyapunov function V (k) = V (x(k)) with state vector x(k) proves global asymptotic stability if: o V(x(k) = 0) = 0 o V(k) > 0 for x(k) 0 o V(k) as x(k) o V(k + 1) < V(k) k N + or global exponential stability if: o V(k + 1) α 2 V (k) k N + with decay rate 0 < α < 1 Results in Linear Matrix Inequalities (LMIs), which are solved by optimisation Sufficient but not necessary condition Common Quadratic Lyapunov Function V(k) = x T (k)px(k) LMI Problem P 0 { inf 0 < α < 1 : } Λ T ij PΛ ij +X ij α 2 P 4. Workshop für Modellbasierte Kalibriermethoden: Euler-Rolle - PID Controller Design for Nonlinear Systems 11/26
Fitness Function: Performance Requirements Assessment of the closed-loop performance for a given set of parameters Representative synthetic reference is generated by DoE Desired trajectory is PT1-filtered Fitness Function Closed-loop simulation of the reference cycle for each genome Sum of squared errors f P = k (ŷ(k) y dmd(k)) 2 2 1.5 1 0.5 0 0 5 10 15 Time 4. Workshop für Modellbasierte Kalibriermethoden: Euler-Rolle - PID Controller Design for Nonlinear Systems 12/26
Pareto-Optimal Solutions 4 x 107 3.5 3 2.5 A Performance fp 2 1.5 Stability 1 B 0.995 1 1.005 1.01 1.015 1.02 1.025 1.03 f S 4. Workshop für Modellbasierte Kalibriermethoden: Euler-Rolle - PID Controller Design for Nonlinear Systems 13/26
3 Feedforward Control 4. Workshop für Modellbasierte Kalibriermethoden: Euler-Rolle - PID Controller Design for Nonlinear Systems 14/26
Feedforward Control State of the Art: Static Model Inversion Steady state input is found by static model inversion u(φ) = [c T (I A(Φ)) 1 B(Φ)] 1 (w(φ) c T (I A(Φ)) 1 (E(Φ)ẑ(Φ) + f(φ))) Stored in a map Dynamic Feedforward Control w u* w* PID u Plant y Dynamic feedforward control improves the closed-loop performance. 4. Workshop für Modellbasierte Kalibriermethoden: Euler-Rolle - PID Controller Design for Nonlinear Systems 15/26
Dynamic Feedforward Control Generation using Local Model Networks Benefits Automatic generation of a dynamic feedforward control law for nonlinear dynamic systems Exploits the generic model structure of local model networks Model complexity may be arbitrarily high Applicable online for any reference trajectory without pre-planning Properties Based on an open-loop state-space model Realised by a feedback linearizing input transformation Restricted to globally minimum-phase local model networks 4. Workshop für Modellbasierte Kalibriermethoden: Euler-Rolle - PID Controller Design for Nonlinear Systems 16/26
Feedback Linearization Undamped Nonlinear Oscillation Consider an undamped oscillator with a nonlinear spring force characteristic f(y), which is to be stabilized using constant c and input u ÿ +f(y) = cu Figure: Air suspension Exact Linearization For this second order system, the state variables are chosen as y = x 1 ẏ = ẋ 1 = x 2 ÿ = ẍ 1 = ẋ 2 = cu f(y) 4. Workshop für Modellbasierte Kalibriermethoden: Euler-Rolle - PID Controller Design for Nonlinear Systems 17/26
Feedback Linearization Undamped Nonlinear Oscillation Consider an undamped oscillator with a nonlinear spring force characteristic f(y), which is to be stabilized using constant c and input u ÿ +f(y) = cu Figure: Air suspension Exact Linearization For this second order system, the state variables are chosen as y = x 1 ẏ = ẋ 1 = x 2 ÿ = ẍ 1 = ẋ 2 = cu f(y) = v v 1 s 1 s y 4. Workshop für Modellbasierte Kalibriermethoden: Euler-Rolle - PID Controller Design for Nonlinear Systems 17/26
Feedforward Control Undamped Nonlinear Oscillation Exact Linearization For a two times differentiable desired trajectory w, the nonlinear feedforward control input u can be found from v! = ẅ = cu f(w) u = ẅ +f(w) c ẅ u = ẅ +f(w) c u 1 s 1 s w C u y 4. Workshop für Modellbasierte Kalibriermethoden: Euler-Rolle - PID Controller Design for Nonlinear Systems 18/26
Demonstration Example Automatic Feedforward Control Design Wiener Model G(z) = P(z) U(z) = 0.6z 3 1 1.3z 1 +0.8825z 2 0.1325z 3 y(k) = f(p(k)) = arctan(p(k)) Figure: Wiener Model approximated by an LMN: 1 0.5 6 2 ŷ(k 1) 0 0.5 4 3 1 1 5 3 2 1 0 1 2 3 u(k 3) 4. Workshop für Modellbasierte Kalibriermethoden: Euler-Rolle - PID Controller Design for Nonlinear Systems 19/26
Feedforward Controlled Simulation Wiener Model 1 ywiener u w, ŷ 0 1 3 0 3 1 0 1 40 60 80 100 120 140 160 180 200 220 40 60 80 100 120 140 160 180 200 220 40 60 80 100 120 140 160 180 200 220 Samples 4. Workshop für Modellbasierte Kalibriermethoden: Euler-Rolle - PID Controller Design for Nonlinear Systems 20/26
Feedforward Controlled Simulation Wiener Model 1.5 1 0.5 ŷ 0 0.5 1 w yffc 1.5 0 50 100 150 200 250 300 350 400 450 500 Samples w u* w* PID u Plant y 4. Workshop für Modellbasierte Kalibriermethoden: Euler-Rolle - PID Controller Design for Nonlinear Systems 21/26
Two-Degrees-of-Freedom Control Wiener Model 1.5 1 0.5 ŷ 0 0.5 w 1 yffc y2dof 1.5 0 50 100 150 200 250 300 350 400 450 500 Samples w u* w* PID u Plant y 4. Workshop für Modellbasierte Kalibriermethoden: Euler-Rolle - PID Controller Design for Nonlinear Systems 22/26
Two-Degrees-of-Freedom Control Wiener Model 1.5 1 0.5 ŷ 0 0.5 w 1 ypid y2dof 1.5 0 50 100 150 200 250 300 350 400 450 500 Samples w u* w* PID u Plant y 4. Workshop für Modellbasierte Kalibriermethoden: Euler-Rolle - PID Controller Design for Nonlinear Systems 23/26
4 Conclusion & Outlook 4. Workshop für Modellbasierte Kalibriermethoden: Euler-Rolle - PID Controller Design for Nonlinear Systems 24/26
Conclusion & Outlook Two-Degrees-of-Freedom Control Nonlinear PID controller design using local model networks Multi-objective optimisation of controller parameters considering Stability Performance Automatic feedforward control law generation for minimum-phase local model networks Outlook Application of a Lyapunov function to check internal stability Considering input constraints Assessment of Two-Degrees-of-Freedom control on a physical process 4. Workshop für Modellbasierte Kalibriermethoden: Euler-Rolle - PID Controller Design for Nonlinear Systems 25/26
Thank you for your attention! 4. Workshop für Modellbasierte Kalibriermethoden: Euler-Rolle - PID Controller Design for Nonlinear Systems 26/26
Fitness Function: Stability Common Quadratic Lyapunov Function for Closed-Loop Systems Exponential stability with decay rate α of the closed-loop feedback system is shown, if symmetric matrices P and X ij exist and the following conditions are fulfilled: P 0 { } inf 0 < α < 1 : Λ T ij PΛij + Xij α2 P X 11 X 12 X 1I X 12 X 22 X 2I X =....... 0 X 1I X 2I X II i I, i j I using Gij + Gji Λ ij =, 2 G ij = A i B ik T PID,j C. 4. Workshop für Modellbasierte Kalibriermethoden: Euler-Rolle - PID Controller Design for Nonlinear Systems 27/26
Fitness Function: Stability Common Quadratic Lyapunov Function for Closed-Loop Systems Exponential stability with decay rate α of the closed-loop feedback system is shown, if symmetric matrices P and X ij exist and the following conditions are fulfilled: P 0 { } inf 0 < α < 1 : Λ T ij PΛij + Xij α2 P X 11 X 12 X 1I X 12 X 22 X 2I X =....... 0 X 1I X 2I X II i I, i j I using Gij + Gji Λ ij =, 2 G ij = A i B ik T PID,j C. Simultaneous solving for P and k T PID,j is not possible! f S = α 4. Workshop für Modellbasierte Kalibriermethoden: Euler-Rolle - PID Controller Design for Nonlinear Systems 27/26