System Identification and Model Predictive Control of SI ... · Case Study : Idle Speed Control of...

21
System Identification and Model System Identification and Model Predictive Control of SI Engine in Idling Predictive Control of SI Engine in Idling 1 Predictive Control of SI Engine in Idling Predictive Control of SI Engine in Idling Mode using Mathworks Tools Mode using Mathworks Tools Shivaram Kamat*, KP Madhavan**, Tejashree Saraf* *Engineering and Industrial Services, TATA Consultancy Services Limited **Professor Emeritus, IIT Bombay © Copyright 2014, Tata Consultancy Services Limited. All Rights Reserved

Transcript of System Identification and Model Predictive Control of SI ... · Case Study : Idle Speed Control of...

Page 1: System Identification and Model Predictive Control of SI ... · Case Study : Idle Speed Control of 2.9L V6 SI engine MPC based ISC Basis of the work : ‘Model Predictive Idle Speed

System Identification and Model System Identification and Model Predictive Control of SI Engine in Idling Predictive Control of SI Engine in Idling

1

Predictive Control of SI Engine in Idling Predictive Control of SI Engine in Idling Mode using Mathworks ToolsMode using Mathworks ToolsShivaram Kamat*, KP Madhavan**, Tejashree Saraf *

*Engineering and Industrial Services, TATA Consultancy Services Limited**Professor Emeritus, IIT Bombay

© Copyright 2014, Tata Consultancy Services Limited. All Rights Reserved

Page 2: System Identification and Model Predictive Control of SI ... · Case Study : Idle Speed Control of 2.9L V6 SI engine MPC based ISC Basis of the work : ‘Model Predictive Idle Speed

Agenda

� Introduction

� MPC Overview

� Case Study – MPC � Work Flow and Virtual Set up � System Identification of engine model for idle mode

2

� System Identification of engine model for idle mode� Plant Model Validation� Controller Synthesis� MIL results

� Benefits

� Future Scope

Page 3: System Identification and Model Predictive Control of SI ... · Case Study : Idle Speed Control of 2.9L V6 SI engine MPC based ISC Basis of the work : ‘Model Predictive Idle Speed

Introduction

� A stable and fuel efficient idle running of automotive engines has been crucial part of engine management system for OEMs and Tier-1s

� Low rpm idling : Trade off between fuel consumption, stability and disturbance performance

3

� Prevalent ISC scenario• EMS’ address ISC using variants of PI/PID/FF/compensators • Use of maps/LUTs for idle air requirement and idling load compensation• No / indirect use of model for idle behavior for the tuning of the controller

� Proposed scenario • Use of simplified, linear discrete state space model in idling• Receding Horizon Model Predictive Control• Inherently stable , constrained optimal control with improved tracking and

disturbance rejection performance

Page 4: System Identification and Model Predictive Control of SI ... · Case Study : Idle Speed Control of 2.9L V6 SI engine MPC based ISC Basis of the work : ‘Model Predictive Idle Speed

MPC Overview : What, Why ?

MPC = Model + Prediction + Correction (Control)

predicted

input profile

error

futurepast

predicted

input profile

error

futurepast

Target Predictive model

EMSth, spk, FPW..

Engine

4

� Established and proven beneficial in the process control domain � Potential to leverage it for automotive with the advent and abundance of high

capacity, faster processors � A constrained MPC algorithm holds promise to achieve stable and tighter idle

speed control

A Model of the Process (Plant) is used to Predict the future evolution of the process and control signal is computed to minimize the deviation of the predicted output from the target by exercising the correction at every time interval

feedback

Page 5: System Identification and Model Predictive Control of SI ... · Case Study : Idle Speed Control of 2.9L V6 SI engine MPC based ISC Basis of the work : ‘Model Predictive Idle Speed

MPC : How ?

q

Sjk

q

Q

P

j

yjk

M

j

j

ue

uJMinimize

+=

+ ∆+∑

=

1

)(

desired

predicted

input profilehistory

error

futurepast

desired

predicted

input profilehistory

error

futurepast

5

1a. At time instant k, construct and solve optimal control problem to minimize the error between the target and predicted output over finite prediction steps, m.

1b. Deploy only the first element of the solution vector, i.e. the control move for k +1…. (RHC)

2. At time k +1 read the output feedback and repeat the step 1. …

Structure of Model Predictive Control

Desired Output

Process Output

Controller Process

Model

Predicted Error

-+

-+

Page 6: System Identification and Model Predictive Control of SI ... · Case Study : Idle Speed Control of 2.9L V6 SI engine MPC based ISC Basis of the work : ‘Model Predictive Idle Speed

MPC : How ?

( ) ( )( ) ( )∑∑−

==

+++−+=1

0

2

1

2 111l

i

m

lpset kUkykyJ λObjective

function:Penalty on

control moves

Error term

( ) 10; −=≤+≤ ltoiUjkUU ul

10;)( maxmin −=≤+≤ ltojujkuu

mtojyjkyy upl 1;)( =≤+≤

Constraints:

OBSERVATION HORIZON

γ (t)

Yp (t) - FUTURE TRAJECTURY WITH NO CHANGE IN CONTROL

Ym (t) - PREDICTION

6

Tuning� Prediction horizon

� Control horizon

� Penalty factors on control moves

� Weights on output variables

� Hard / soft Constraints on inputs and outputs

�Constraints on rate of change of inputs

mtojyjkyy upl 1;)( =≤+≤

u (k-2) u (k-1)

u (k) u (k + 1)

u (k + 2)

CONTROL HORIZON

k k + 1 k + 2 PAST FUTURE

Page 7: System Identification and Model Predictive Control of SI ... · Case Study : Idle Speed Control of 2.9L V6 SI engine MPC based ISC Basis of the work : ‘Model Predictive Idle Speed

Case Study : Idle Speed Control of 2.9L V6 SI engine

� MPC based ISC

Basis of the work : ‘Model Predictive Idle Speed Control: Design, Analysis, and Experimental

Evaluation’, Stefano Di Cairano,Diana Yanakiev, Alberto Bemporad, Ilya. V. Kolmanovsky, and Davor

Hrovat, IEEE Transactions on Control Systems Technology, Vol. 20, No. 1, January2012

1.5

2

2.5x 10

-5 Fuel mass in Kg

750 rpm1000 rpm

� Lower the idle rpm, lesseris the fuel consumption

7

0 500 1000 1500 2000 25000

0.5

1

1.5� However, the tradeoff is with stable running, disturbance rejection performance and tracking performance

Fuel consumption for idle running at 750 and 1000 rpm

idling of enDYNA* simulator

* enDYNA is engine simulator from Tesis-Dynaware.

Page 8: System Identification and Model Predictive Control of SI ... · Case Study : Idle Speed Control of 2.9L V6 SI engine MPC based ISC Basis of the work : ‘Model Predictive Idle Speed

Case Study : Work Flow and Virtual Set up

• enDYNA engine simulator for system identification of model during idling

• MISO model with throttle opening and spark advance as inputs and rpm as output

• Step response and PRBS excitation

• IDENT tool for transfer function identification

EMS

enDYNAEngine

Simulator Actuator Signals

8

identification

•Linear discrete (Ts =10ms) MISO state space model from SISO TFs (throttle and spark advance as inputs and rpm as output)

• Controller synthesis using MPC Toolbox

• Closed Loop simulation with MPC controller

Simulator

Sensors’ signals

Page 9: System Identification and Model Predictive Control of SI ... · Case Study : Idle Speed Control of 2.9L V6 SI engine MPC based ISC Basis of the work : ‘Model Predictive Idle Speed

Case Study : SysID – Step response

0 100 200 300 400 500 600 7000

0.5

1

1.5

800

900

1000

Throttle deg

speed in rpm

Throttle step response SysID using IDENT toolbox

9

0 100 200 300 400 500 600 700700

800

ΔThrottle/ Δrpm TF output

comparisonΔspk/ Δrpm TF output comparison

Page 10: System Identification and Model Predictive Control of SI ... · Case Study : Idle Speed Control of 2.9L V6 SI engine MPC based ISC Basis of the work : ‘Model Predictive Idle Speed

Case Study : SysID – PRBS response

30

0 500 1000 1500 2000 2500 3000 35000

0.5

1

1.5

throttle deg

PRBS signal applied to SA in open loop with constant throttle

Assuming throttle/rpm and spk/rpm relationships as linear, a combined

5.5 5.6 5.7 5.8 5.9 6 6.10.1

0.2

0.3

0.4

0.5

0.6

0.7

0.8

0.9

1

100 500 1000 1500 2000 2500 3000 3500

700

750

800

850

900

950

0 500 1000 1500 2000 2500 3000 35005

10

15

20

25

Ignition angle deg

rpm

interval for sysID

interval for sysID

Comparison of the outputs by PRBS SS model and enDYNA

0 5 10 15-20

0

20

40

60

80

100

Time

Measured and simulated model output

P3DZU output , accuracy 47.91%

enDYNA output

relationships as linear, a combined MISO state space model is obtained.

Page 11: System Identification and Model Predictive Control of SI ... · Case Study : Idle Speed Control of 2.9L V6 SI engine MPC based ISC Basis of the work : ‘Model Predictive Idle Speed

600

800

1000

1200

Comparison of the outputs of state space Δ / Δ models (Step Response) and enDYNA

Case Study : Plant Model Validation

11

0 500 1000 1500 2000 25000

200

400

enDYNA rpm

step response model rpm

PRBS model rpm

Controller was constructed using the step response model as the predictive model for MPC

Page 12: System Identification and Model Predictive Control of SI ... · Case Study : Idle Speed Control of 2.9L V6 SI engine MPC based ISC Basis of the work : ‘Model Predictive Idle Speed

Case Study : Controller Synthesis

� Using the MPC toolbox, MPC object was created

12

Plant Model directly imported from IDENT

session

Page 13: System Identification and Model Predictive Control of SI ... · Case Study : Idle Speed Control of 2.9L V6 SI engine MPC based ISC Basis of the work : ‘Model Predictive Idle Speed

Case Study : Controller Synthesis….

13

Tuning : Horizons

Tuning : Constraints on

inputs and output

Page 14: System Identification and Model Predictive Control of SI ... · Case Study : Idle Speed Control of 2.9L V6 SI engine MPC based ISC Basis of the work : ‘Model Predictive Idle Speed

Plant Inputs

0 0.5 1 1.5 2 2.5 3-20

0

20

40

60

80

100

120Plant Output: Out1

Time (sec)

delta rpm

Delta RPM

Case Study : Controller Synthesis ….

14

0

0.2

0.4

0.6

0.8

1

1.2

In1

0 0.5 1 1.5 2 2.5 3

-10

-5

0

5

In2

Time (sec)

delta throttle

delta spark adv

Delta Spark

Delta throttle

� Pre-closed loop simulation � Simple and straight forward tuning

iterations

Page 15: System Identification and Model Predictive Control of SI ... · Case Study : Idle Speed Control of 2.9L V6 SI engine MPC based ISC Basis of the work : ‘Model Predictive Idle Speed

ThrottleAng [deg ]

4

Crank Ang [rad ]

3

Injection Time [s]

2

IgnitionAng [rad ]

1

base idle speed

750 /9.5493

Simulation Time [s]

Manual Switch 2

Manual Switch 1

Intended _1|lambda

1

Engine On or Off

ECU EMULATOR SI

AccPedalPos [0_1]

CrankSpd [rad /s]

EngineAirMFlow [kg /s]

IdleSpd [rad/s ]

InverseIntLambda [-]

BatteryVolt [V]

FuelPres [Pa ]

ManifoldPres [Pa ]

IgnitionAng [rad ]

InjectionTime [s ]

CrankAng [rad ]

ThrottleAng [deg ]

Clock

7

FuelPres [Pa]

6

BatteryVolt [V]

5

EngineStateCtrl [0/1]

4

EngineAirMFlow [kg/s]

3

CrankSpd [rad /s]

2

AccPedalPos [0_1]

1

Case Study : MIL closed loop validation

Drive EMS

Default EMS

15

throttle _bias

0.1514 th

spk_bias

17 .45

spk

rpm _bias

750

rpm

rad /s to rpm

-K-

for bumplesstransfer

0

deg to rad

-K-

Signal Builderrpm _setpoint _bias

Signal 1

Signal 2

Manual Switch 4

Manual Switch 3

Manual Switch 2

MPC controller

feedback

setpoint

MVs

ManifoldPres [Pa ]

MPC

EMS

Idle

Page 16: System Identification and Model Predictive Control of SI ... · Case Study : Idle Speed Control of 2.9L V6 SI engine MPC based ISC Basis of the work : ‘Model Predictive Idle Speed

� Engine cranked by electric motor, target idle speed 750 rpm regulated by default PID control loop

� The MPC controller switched on after matching the initial conditions for the bump-less transfer.

� The idle set point ramped from 750 rpm to 850 rpm @100rpm/s

Case Study : MIL closed loop validation scenario

16

� The idle set point ramped down from 850 rpm to 750 rpm @100rpm/s

� The step load of 25Nm applied as disturbance @ 750 rpm (hostile) idle rpm , removed in 1 or 2 seconds

� The scenario applied for predictive model that included additional integral state

Page 17: System Identification and Model Predictive Control of SI ... · Case Study : Idle Speed Control of 2.9L V6 SI engine MPC based ISC Basis of the work : ‘Model Predictive Idle Speed

700

750

800

850

900ISC with default PID controller (may not be optimally tuned)

enDYNA rpmFuel cut for

reaching the

limit

Reference

ramp

applied to

set point

Disturbance

load

removed

PID

regulationset point

restored

Disturbance

load applied

Case Study : ISC with default PID controller

17

0 500 1000 1500 2000 2500 3000500

550

600

650

set point removed

responserestored

� The controller may not be optimally tuned for KP, KI, KD

� Under-damped behavior at set point change and disturbance � Marginal improvement after conducting Simulink response optimization

Page 18: System Identification and Model Predictive Control of SI ... · Case Study : Idle Speed Control of 2.9L V6 SI engine MPC based ISC Basis of the work : ‘Model Predictive Idle Speed

Case Study : Closed Loop Simulation Results

600

650

700

750

800

850

900

950

1000 set point

rpm

(a) Fuel cut forreachingthe limit

(b) PIcontroller'sregulation action

(c) Switchoverto MPC(bumpless)

(e) steady stateat new setpoint

(f) setpointrestored

(g) disturbance applied

(h) disturbance applied

18

0 200 400 600 800 1000 1200 1400 1600500

550

0 200 400 600 800 1000 1200 1400 1600-15

-10

-5

0

5

10

15

0 200 400 600 800 1000 1200 1400 1600-10

0

10

20

30

40

throttle deg

spk deg

Time Scale (sec)

Page 19: System Identification and Model Predictive Control of SI ... · Case Study : Idle Speed Control of 2.9L V6 SI engine MPC based ISC Basis of the work : ‘Model Predictive Idle Speed

Case Study : Addition of Integral Element for Disturbance Rejection

MVs1

rpm _Integration _setpoint

0 MPC Controller _int

Linear _MPC mv

mo

ref

Discrete-TimeIntegrator

K Ts (z+1

2(z-1)

setpoint

2

feedback

1

1000

190 500 1000 1500 2000 2500 3000 3500650

700

750

800

850

900

950

1000

set point

rpm

(b) PIcontroller'sregulation action

(c) Switchoverto MPC(bumpless)

(a) Fuel cut forreachingthe limit

(d) Reference ramp applied to setpoint

(e) steady stateat new setpoint

(f) setpointrestored

(g) disturbance applied

(h) disturbance applied

Time Scale (sec)

Page 20: System Identification and Model Predictive Control of SI ... · Case Study : Idle Speed Control of 2.9L V6 SI engine MPC based ISC Basis of the work : ‘Model Predictive Idle Speed

Benefits and Future Scope

Benefits� The approach

• Stable low rpm idling saving fuel • Improved performance for idle loads such as AC, PS, lighting• Constraints imposition

� The tools• GUI based Time effective and simplified system identification using IDENT

20

• GUI based Time effective and simplified system identification using IDENT• GUI based simple and time effective controller synthesis • Seamless interface between the tools

Future Scope� Real Time overheads calculations to include MPC-ISC in the EMS� HiL validation on RCP ECU and virtual tuning/calibration� Modeling disturbance for rejection performance / improving the

integral action for tracking performance � Explore fast MPC on embedded hardware for automotive applications

Page 21: System Identification and Model Predictive Control of SI ... · Case Study : Idle Speed Control of 2.9L V6 SI engine MPC based ISC Basis of the work : ‘Model Predictive Idle Speed

Thank You

21

Thank You

© Copyright 2014, Tata Consultancy Services Limited. All Rights Reserved