iterative learning control for internal combustion engines

71
Stijn van Dooren Iterative Learning Control for Internal Combustion Engines Master’s thesis Institute for Dynamic Systems and Control Swiss Federal Institute of Technology (ETH) Zurich Supervision Norbert Zsiga Prof. Dr. Lino Guzzella April 2015 IDSC-LG-NZ-07

Upload: others

Post on 02-Dec-2021

3 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Iterative Learning Control for Internal Combustion Engines

Stijn van Dooren

Iterative Learning Control forInternal Combustion Engines

Master’s thesis

Institute for Dynamic Systems and ControlSwiss Federal Institute of Technology (ETH) Zurich

Supervision

Norbert ZsigaProf. Dr. Lino Guzzella

April 2015

IDSC-LG-NZ-07

Page 2: Iterative Learning Control for Internal Combustion Engines
Page 3: Iterative Learning Control for Internal Combustion Engines

Preface

First and foremost I would like to thank my supervisor Norbert Zsiga for his continuous supportduring the project. Furthermore, I want to thank the people from the IDSC, with some of whomI have become good friends. Also, I would like to express my gratitude to the ETH Zurichfor accepting me to the master’s programme. Not only has this made possible to study at anexcellent university, I have also really enjoyed living in such a beautiful city and country and thepeople that I have met. Finally, I would like to thank my notebook, which from the start of mybachelor’s programme in 2009 has endured many exhaustive simulations, but has never let medown.

i

Page 4: Iterative Learning Control for Internal Combustion Engines
Page 5: Iterative Learning Control for Internal Combustion Engines

Contents

Abstract iv

Nomenclature v

Introduction 1Motivation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1Objective . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1Structure of the Thesis . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2

1 Iterative Learning Control: Theory 31.1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3

1.1.1 System Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 31.1.2 Assumptions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 41.1.3 Problem Statement . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4

1.2 Analysis . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 51.2.1 Lifted System Representation . . . . . . . . . . . . . . . . . . . . . . . . . 51.2.2 Z-transform . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 61.2.3 Stability . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 71.2.4 Performance . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 81.2.5 Relations between Time and Frequency Domain . . . . . . . . . . . . . . 9

1.3 Design . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 101.3.1 PID-type ILC . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 111.3.2 Lead-lag-type ILC . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 111.3.3 Q-ILC . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11

1.4 Parallel vs Serial Arrangement . . . . . . . . . . . . . . . . . . . . . . . . . . . . 121.5 Systems with a Time Delay . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12

2 Experimental Setup 142.1 Engine Test-Bench . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 142.2 Engine Control Structure . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 142.3 Discrete-Time Events . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 152.4 Software Structure . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 16

3 Air Mass Flow: Modelling and Control 173.1 Preliminaries . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17

3.1.1 System Structure . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 173.1.2 Operating Regions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 183.1.3 Air Mass Estimation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19

ii

Page 6: Iterative Learning Control for Internal Combustion Engines

3.1.4 Filter Design . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 213.2 System Identification . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23

3.2.1 Actuator Dynamics . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 233.2.2 Parameter Identification . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23

3.3 Control System Design . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 243.3.1 Structure . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 243.3.2 Tuning . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 253.3.3 Gain Scheduling . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 253.3.4 Implementation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26

3.4 Experimental Results . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 273.5 Conclusions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28

4 Air/Fuel Ratio: Modelling and Control 294.1 Preliminaries . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 29

4.1.1 System Structure . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 294.1.2 Control System Structure . . . . . . . . . . . . . . . . . . . . . . . . . . . 294.1.3 Noise . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 30

4.2 System Identification . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 314.2.1 Modelling . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 314.2.2 Parameter Identification . . . . . . . . . . . . . . . . . . . . . . . . . . . . 32

4.3 Control System Design . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 344.3.1 Structure . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 344.3.2 Tuning . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 354.3.3 Emulation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 354.3.4 Implementation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 37

4.4 Experimental Results . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 374.5 Conclusions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 39

5 Iterative Learning Control: Practice 415.1 Implementation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 415.2 Air Mass Flow . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 42

5.2.1 Reference Trajectory . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 425.2.2 System Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 435.2.3 Design . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 435.2.4 Experimental Results . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 43

5.3 Air/Fuel Ratio . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 475.3.1 Reference Trajectory . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 475.3.2 System Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 475.3.3 Design . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 485.3.4 Experimental Results . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 48

5.4 Conclusions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 54

6 Conclusions and Outlook 556.1 Conclusions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 556.2 Outlook . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 56

Bibliography 58

Page 7: Iterative Learning Control for Internal Combustion Engines

Abstract

In classical feedback control, the controller reacts to a difference between the reference signal andthe system output. Therefore, even with a well-designed feedback controller, it is not possible toperfectly track a reference signal. For processes that occur repetitively, iterative learning control(ILC) algorithms are one possibility to overcome this downside. The idea is to use informationfrom past executions to improve the performance of the system in the next trial. Analogous tothe fact that humans learn skills by successive trials, iterative learning control "learns" from theerror and the reference tracking is improved with each iteration.

The objective of this thesis was to design and implement iterative learning control for two im-portant control systems of an SI engine and to assess the feasibility and performance of ILCon the engine test-bench. Two control systems were first developed and gain scheduling andinternal model control were used to obtain the same closed-loop dynamics for a wide range ofoperating points. Subsequently, several ILC algorithms were designed and implemented on theengine test-bench and various experiments were carried out to test the ILC algorithms in practice.

Iterative learning control was successfully applied on the engine test-bench. The stability andperformance in terms of convergence rate and error reduction were found to be very good. Fur-thermore, the behaviour of the algorithms on the engine corresponded very well to simulations,which proves that the theory can be conveniently used to design and apply iterative learningcontrol to engine systems. Finally, the behaviour of the control systems and the iterative learn-ing control were found to be very consistent over a wide range of operating point.

In this process, valuable experience was gained on how to efficiently implement ILC on theengine test-bench and the foundations were laid for possible further research.

iv

Page 8: Iterative Learning Control for Internal Combustion Engines
Page 9: Iterative Learning Control for Internal Combustion Engines

Nomenclature

Symbols

t Time [s]

k Discrete-time index [−]

i Iteration index [−]

N Finite horizon length [−]

ωe Engine rotational speed [rad/s]

mβ Air mass per engine cycle [kg/cyc]

mβ Air mass flow [kg/s]

λ Air/fuel ratio [−]

Ts Sampling time [s]

Td Time delay [s]

τ Time constant [s]

σ Tuning parameter [−]

ωc Cross-over frequency [rad/s]

Indices

act Actual

β Air mass

cyc Per engine cycle

cyl Cylinder

d Desired

FF Feedforward

ign Ignition

inj Injection

im Intake manifold

rot Per engine rotation

seg Per engine segment

th Throttle valve

van, iv Inlet valve timing

van, ev Exhaust valve timing

v

Page 10: Iterative Learning Control for Internal Combustion Engines

vvt Variable intake valve lift

wg Waste-gate

· Estimated parameter

Acronyms and Abbreviations

AF Air Filter

AFR Air/Fuel Ratio

AS Asymptotic Stability

CA Crank Angle

ECU Electronic Control Unit

ETH Eidgenössische Technische Hochschule

HFM Hot-Film air Mass-flow sensor

IC Intercooler

ICE Internal Combustion Engine

ILC Iterative Learning Control

IM Intake Manifold

IMC Internal Model Control

LTI Linear Time-Invariant

MC Monotonic Convergence

MIMO Multiple-Input Multiple-Output

MLIB MATLAB-dSPACE Interface Library

NA Naturally Aspirated

SI Spark Ignited

SISO Single-Input Single-Output

TC Turbocharged

TWC Three-Way Catalytic converter

WG Waste-gate

ZOH Zero Order Hold

Page 11: Iterative Learning Control for Internal Combustion Engines

Introduction

Motivation

In classical feedback control, the controller reacts to a difference between the reference signal andthe system output. Therefore, even with a well-designed feedback controller, it is not possibleto perfectly track a reference signal. Moreover, there is always a trade-off between speed of re-sponse and robustness to model uncertainties and noise. In general, good performance can onlybe achieved if the model used for the control design accurately describes the physical system. Formany control problems, the modelling of the physical system and the parameter identificationrequire a substantial amount of effort. This is particularly true for the modelling and control ofInternal Combustion Engine (ICE) systems. On the one hand, this is because ICEs generallycontain many control systems, most of which also influence each other. On the other hand, thebehaviour of the physical system varies widely because of the large operating range of ICEs.

For processes that occur repetitively, iterative learning control (ILC) algorithms are one pos-sibility to overcome these problems. The idea is to use information from past executions (alsoreferred to as runs, trials or iterations) to improve the performance of the system in the nextiteration. Typically, the error between the reference signal and the system output is used tocalculate a correction signal for the next trial. Analogous to the fact that humans learn skills bysuccessive trials, ILC "learns" from the error and the reference tracking is improved with eachiteration. A great potential benefit of ILC is that the physical system need not be modelled veryaccurately, because the ILC algorithm learns the dynamics of the plant and the control inputthat gives good reference tracking.

Objective

The engine considered in this thesis is a spark-ignited (SI) petrol engine. The torque outputfor this type of engine is linked to and controlled by the amount of air that is aspirated by theengine. Two very important control systems are therefore the air mass flow control system andthe air/fuel ratio control system. The objective of this thesis is to design and implement an ILCalgorithm for these two control systems on the engine test-bench and to assess the feasibility andperformance of ILC in practice.

1

Page 12: Iterative Learning Control for Internal Combustion Engines

2

Structure of the Thesis

This thesis is divided into the following chapters:

Iterative Learning Control: TheoryThis chapter provides an introduction to iterative learning control theory. It should help thereader to quickly get familiar with the theory and the notation that is used in this thesis.

Experimental SetupThis chapter introduces the experimental setup that was used for the experiments presented inthis thesis.

Air Mass Flow: Modelling and ControlThis chapter gives an overview of how the air mass flow system was modelled and how the controlsystem was designed. It also presents the experimental results of the control system being testedon the engine test-bench.

Air/Fuel Ratio: Modelling and ControlThis chapter gives an overview of the modelling of the air/fuel ratio system, as well as the stepsof the control system design. Moreover, the experimental results are shown and the performanceof the control system on the engine test-bench is evaluated.

Iterative Learning Control: PracticeThis chapter contains the results of the main objective of this thesis. Firstly, it is explained howILC was implemented on the engine test-bench. Then, for each of the above control systems,several ILC algorithms are designed and various experiments are carried out to assess the feasi-bility and performance.

Conclusion and OutlookThe thesis is closed with a brief summary and conclusions of the results and an outlook for futureresearch is given.

Page 13: Iterative Learning Control for Internal Combustion Engines

Chapter 1

Iterative Learning Control:Theory

This chapter provides an introduction to iterative learning control theory. It should help thereader to quickly get familiar with the theory and the notation that is used in this thesis.

1.1 Introduction

Iterative learning control (ILC) was first studied by Arimoto et al. in [5] as an intelligent learningmechanism for robot manipulators. A robot arm is typically used to repeatedly follow a desiredmotion trajectory, which is an example of a repetitive process. The basic idea of ILC is to utilisethe error between a desired reference trajectory yd(k) and the output of the system yi(k) atthe current iteration i to improve the performance in the subsequent trial i + 1. The theoryand design of ILC algorithms are the topics of this chapter. Before the problem statement isintroduced, the general system description is given and some important assumptions are made.

1.1.1 System Description

Consider the discrete-time, linear time-invariant (LTI), single-input single-output (SISO) system

yi(k) = P (q)ui(k) + d(k) (1.1)

where k is the discrete-time index, i is the iteration index, q is the forward shift operator, yi isthe output and ui is the control input. The signal d is an exogenous signal that repeats eachiteration. It can capture nonzero initial conditions, repeating disturbances, and other repeatingfeatures of the system. It is assumed that the plant P (q) is asymptotically stable and has relativedegree m ≥ 0 (i.e. the system is causal). The relative degree of a discrete-time system describesthe input-output delay and will, in general, be equal to 1, independent of the relative degree ofthe continuous-time system [28]. Therefore, m = 1 is assumed for P (q) throughout this thesis.

The system operates on a finite horizon with k ∈ [0, N ] and yd(k) is the desired output tra-jectory. The error or performance signal is defined as

ei(k) = yd(k) − yi(k) (1.2)

3

Page 14: Iterative Learning Control for Internal Combustion Engines

Chapter 1. Iterative Learning Control: Theory 4

The system description of (1.1) is very general and will be used for the analysis and design ofILC. It is usually straightforward to cast any LTI SISO system into this form. For example,suppose that the following discrete-time state-space model is known:

xi(k + 1) = Axi(k) + Bui(k) (1.3)

yi(k) = Cxi(k) + Dui(k) (1.4)

xi(0) = x0 (1.5)

Notice that (1.5) holds for all i, which is called the initial reset condition and is a key assumptionin ILC. This state-space model is equivalent to the general system description in the sense that

yi(k) = (C(qI − A)−1B + D)︸ ︷︷ ︸

P (q)

ui(k) + CAkx0︸ ︷︷ ︸

d(k)

(1.6)

It can be noted that the repeating initial condition is captured in d(k).

1.1.2 Assumptions

Some assumptions or postulates about the ILC system are usually introduced. The ones men-tioned here are taken from [4] and [19] and are reformulated to fit the notation of this thesis.

(A1) Every iteration ends in a fixed time of duration. Depending on the sampling time, thediscrete time will have a finite horizon of length N .

(A2) A desired output trajectory yd(k) is given a priori over k ∈ [0, N ].

(A3) Repetition of the initial setting is satisfied, i.e. (1.5) is satisfied for all i.

(A4) Invariance of the system dynamics is ensured throughout the iterations.

(A5) Every output yi(k) can be measured in a deterministic way.

(A6) Given a reference trajectory yd(k) with a piecewise continuous derivative, there exists aunique input ud(k) to the system (1.1) that exactly yields the output yd(k).

In practice, there are always disturbances and noise that affect the system, and therefore someassumptions may be too restrictive. As mentioned in [19], (A3) is often reformulated to includesome bounded error of the initial state, whereas (A5) can be reformulated to include measurementnoise. With these definitions and assumptions, the problem can now be formally stated.

1.1.3 Problem Statement

The process of iterative learning control consists of finding an input ui(k) to the system of (1.1),such that the output yi(k) converges to the desired output trajectory yd(k) for all k as the numberof iterations i tends to infinity. After each iteration i, the new input ui+1 is calculated with analgorithm (also called update law) that uses the error ei of the previous iteration (this is calledfirst-order ILC) or uses the error from multiple iterations in the past (this is called higher-orderILC). Usually the algorithm is restricted to first-order ILC, as is the case in this thesis. A widelyused update law has the form

ui+1(k) = H(q)[ui(k) + L(q)ei(k + 1)] (1.7)

Page 15: Iterative Learning Control for Internal Combustion Engines

Chapter 1. Iterative Learning Control: Theory 5

where H(q) is a filter function and L(q) is a learning function. In contrast to filters and controllersin ordinary control systems, these functions do not have to be causal, because all the data fork ∈ [0, N ] is available. The calculation of (1.7) is done between successive iterations, duringwhich the system is in rest or continuous to operate. This does not pose a problem as long as atthe start of the next iteration the initial reset condition (A3) is satisfied.

1.2 Analysis

The combination of the general system (1.1), the definition of the error (1.2) and the updatelaw (1.7) is referred to as an ILC system. The analysis of such systems in terms of stabilityand convergence is the topic of this section. The analysis can be carried out in both time-and frequency domain, and their usefulness and limitations will be discussed. Some importantproperties of ILC systems will be given in the form of theorems. But before that, some importantdefinitions are introduced.

1.2.1 Lifted System Representation

Many authors, e.g. in [2], use the so-called lifted system representation, which is used for theanalysis of ILC in the time domain. Firstly, the linear system (1.1) is expanded as an infinitepower series [24]:

P (q) = p0 + p1q−1 + p2q−2 + . . . (1.8)

where the coefficients pk form the impulse response of the system. For the state-space model(1.3)-(1.5) these are called Markov parameters [14] and are given by

pk =

{

D, if k = 0

CAk−1B, otherwise(1.9)

Since m = 1 is assumed, it follows that p0 = 0, p1 = CB, p2 = CAB, etc. Secondly, the signalsare stacked in column vectors (also called supervectors):

ui = [ui(0), ui(1), . . . , ui(N − 1)]T (1.10)

yi = [yi(1), yi(2), . . . , yi(N)]T (1.11)

d = [d(1), d(2), . . . , d(N)]T (1.12)

yd = [yd(1), yd(2), . . . , yd(N)]T (1.13)

ei = yd − yi (1.14)

The components of y, d and ei are shifted by one time step to accommodate the one-step delayin the plant. With these definitions, the linear system (1.1) can be written equivalently as

yi = Pui + d (1.15)

where P is a N × N matrix whose elements are the Markov parameters of the plant:

P =

p1 0 · · · 0p2 p1 · · · 0...

.... . .

...pN pN−1 · · · p1

(1.16)

Page 16: Iterative Learning Control for Internal Combustion Engines

Chapter 1. Iterative Learning Control: Theory 6

Note that P is a Toeplitz and lower triangular matrix, because P (q) is a time-invariant andcausal plant, respectively. Likewise, the learning algorithm (1.7) can be written in the liftedform. To this end, the filter and learning function are also expanded as an infinite power series:

H(q) = · · · + h−2q2 + h−1q1 + h0 + h1q−1 + h2q−2 + · · · (1.17)

L(q) = · · · + l−2q2 + l−1q1 + l0 + l1q−1 + l2q−2 + · · · (1.18)

With the definitions of (1.10) and (1.14), the update law (1.7) can be written equivalently as

ui+1 = H(ui + Lei) (1.19)

with

H =

h0 h−1 · · · h−N+1

h1 h0 · · · h−N+2

......

. . ....

hN−1 hN−2 · · · h0

and L =

l0 l−1 · · · l−N+1

l1 l0 · · · l−N+2

......

. . ....

lN−1 lN−2 · · · l0

(1.20)

When the filter and learning function are causal, it follows that h−1 = h−2 = · · · = 0 andl−1 = l−2 = · · · = 0, and thus the matrices H and L are lower triangular.

1.2.2 Z-transform

In the frequency domain analysis the one-sided z-transform is used, which for a signal x(k) isdefined as

X(z) = Z{x(k)} =

∞∑

k=0

x(k)z−k (1.21)

For a transfer function the z-transform is obtained by replacing q with z. In order for the z-transform to be applied to the ILC system with (1.1) and (1.7), it is required that N = ∞. Sinceall practical applications of ILC have a finite iteration duration, the frequency domain represen-tation is an approximation [20]. Nevertheless, the frequency domain analysis will be carried outfor N = ∞ and in Subsection 1.2.5 it will be discussed what can be inferred for the ILC systemwith finite duration.

Using the one-sided z-transform, the linear system (1.1) and the update law (1.7) can be repre-sented in the frequency domain as

Yi(z) = P (z)Ui(z) + D(z) (1.22)

and

Ui+1(z) = H(z)[Ui(k) + zL(z)Ei(z)] (1.23)

respectively, where the error in the frequency domain is defined as

Ei(z) = Yd(z) − Yi(z) (1.24)

Notice that the individual z in (1.23) comes from the forward time shift of the error in thedefinition of the update law.

Page 17: Iterative Learning Control for Internal Combustion Engines

Chapter 1. Iterative Learning Control: Theory 7

1.2.3 Stability

Definition 1.1 (Asymptotic stability). A system using ILC is asymptotically stable (AS) ifthere exists an equilibrium input trajectory u∞(k) that is asymptotically stable (as defined in[18]). The converged input trajectory is defined as

u∞(k) , limi→∞

ui(k) (1.25)

and for the dynamic system (1.1) the corresponding asymptotic error is

e∞(k) = limi→∞

ei(k) = yd(k) − P (q)u∞(k) − d(k) (1.26)

Theorem 1.1 (Asymptotic stability in the time domain). The ILC system with (1.1) and (1.7)is asymptotically stable (AS) if and only if

ρ(F) < 1 (1.27)

where F , H(I − LP) and ρ(·) is the spectral radius, which is defined as ρ(A) , maxi |λi(A)|where λi(A) is the ith eigenvalue of the matrix A.

Proof: Substituting (1.14) and (1.15) into (1.19) yields the closed-loop iteration domain inputdynamics

ui+1 = H(I − LP)ui + HL(yd − d) (1.28)

and the stability result follows directly from linear systems theory, see e.g. [24] or [14].

When the filter and learning function are causal, the matrix F will be lower triangular andToeplitz with repeated eigenvalues λ = h0(1 − l0p1), so that asymptotic stability is guaranteed if

|h0(1 − l0p1)| < 1 (1.29)

Theorem 1.2 (Asymptotic stability in the frequency domain). The ILC system with (1.1) and(1.7) and N = ∞ is asymptotically stable (AS) if and only if

‖F (z)‖∞ < 1 (1.30)

where F (z) , H(z)[1 − zL(z)P (z)] and ‖ · ‖∞ is the infinity norm, which for a scalar discretetime transfer function G(z) is defined as

‖G(z)‖∞ , supθ∈[−π,π]

|G(ejθ)| (1.31)

Proof: Combining (1.22) and (1.23), the closed-loop input dynamics in the frequency domain arefound to be

Ui+1(z) = H(z)[1 − zL(z)P (z)]Ui(z) + zH(z)L(z)[Yd(z) − D(z)] (1.32)

and the stability condition for this system is proven in [20] (Theorem 6).

Note that the stability requirement (1.30) means that F (z) be within a unit circle centered atthe origin of the complex plane.

Page 18: Iterative Learning Control for Internal Combustion Engines

Chapter 1. Iterative Learning Control: Theory 8

1.2.4 Performance

The performance of an ILC system is based on the value of the asymptotic error. Combining(1.15), (1.14) and (1.19), replacing the iteration index i with ∞, and solving for e∞ yields theasymptotic error in the lifted form:

e∞ = [I − P[I − H(I − LP)]−1HL](yd − d) (1.33)

Likewise, by combining (1.22) and (1.23), the asymptotic error in the frequency domain is ob-tained:

E∞(z) =1 − H(z)

1 − H(z)[1 − zH(z)P (z)][Yd(z) − D(z)] (1.34)

Theorem 1.3 (Zero asymptotic error in the time domain). The ILC system with (1.1) and (1.7)has e∞(k) = 0 for all k if and only if the system is AS and H = I.

Proof: Combining (1.15) and (1.14) for i and i + 1, the closed-loop iteration domain errordynamics are obtained:

ei+1 = (I − PHL)ei + P(I − H)ui (1.35)

In order to have e∞ = 0, it follows from (1.35) that P(I − H)u∞!= 0 and since P 6= 0 it is

necessary that H = I. For more information, see [23] (Observation 2).

Theorem 1.4 (Zero asymptotic error in the frequency domain). The ILC system with (1.1) and(1.7) and N = ∞ has e∞(k) = 0 for all k if and only if the system is AS and H(z) = 1.

Proof: Substituting (1.22) and (1.24) into (1.23) yields the closed-loop error dynamics in thefrequency domain

Ei+1(z) = H(z)[1 − zL(z)P (z)]Ei(z) + [1 − H(z)][Yd(z) − D(z)] (1.36)

In order to have E∞(z) = 0, which implies e∞(k) = 0 ∀k, it follows directly from (1.36) thatH(z) = 1 is necessary. For a similar proof, see [10] (Theorem 2).

Definition 1.2 (Monotonic convergence). A system using ILC is monotonically convergent (MC)under a given signal norm ‖ · ‖p with p ∈ {1, 2, ..., ∞} if for all i ∈ {1, 2, ...}

‖e∞(k) − ei+1(k)‖p ≤ γ‖e∞(k) − ei(k)‖p (1.37)

where 0 ≤ γ < 1 is the convergence rate. For a given discrete and scalar signal x(k) the signalnorm is defined as

‖x(k)‖p ,

(∞∑

k=0

|x(k)|p

)1/p

(1.38)

Note that if a signal is stacked in a vector, as is done in the lifted system representation, thesignal norm is simply a vector norm, i.e. ‖x(k)‖p = ‖x‖p. Also note that if the asymptoticerror equals zero, the MC condition (1.37) reduces to ‖ei+1(k)‖p ≤ γ‖ei(k)‖p. Furthermore, itis important to see that if γ is close to 1, this does not necessarily mean that the convergence isslow, since γ is just an upper bound, by definition. Often, the convergence rate is actually fasterduring the first few or tens of iterations.

Page 19: Iterative Learning Control for Internal Combustion Engines

Chapter 1. Iterative Learning Control: Theory 9

Theorem 1.5 (Monotonic convergence in the time domain). If the ILC system with (1.1) and(1.7) satisfies

σ(F∗) < 1 (1.39)

where F∗ , PH(I − LP)P−1 and σ(·) is the maximum singular value, then the system is mono-tonic convergent (MC) under the 2-norm with convergence rate γ1 = σ(F∗).

Proof: Combining and manipulating (1.15), (1.19) and (1.33) yields

(e∞ − ei+1) = PH(I − LP)P−1(e∞ − ei) (1.40)

and the result follows directly from the definition of the maximum singular value. Given z = Awwhere w is the input vector, z is the output vector and A a matrix, the maximum singular valueis defined as

σ(A) , maxw 6=0

‖Aw‖2

‖w‖2(1.41)

and therefore ‖z‖2 ≤ σ(A)‖w‖2. For more information, see [20] (Theorem 9) and [26] (AppendixA.5).

Note that if the filter and learning function are causal, the matrices P, H and L commute andtherefore F∗ = F as in (1.27).

Theorem 1.6 (Monotonic convergence in the frequency domain). If the ILC system with (1.1)and (1.7) and N = ∞ satisfies

‖F (z)‖∞ < 1 (1.42)

then the system is monotonic convergent (MC) under the ∞-norm in the frequency domain withconvergence rate γ2 = ‖F (z)‖∞, that is

‖E∞(z) − Ei+1(z)‖∞ ≤ γ2‖E∞(z) − Ei(z)‖∞ (1.43)

where ‖ · ‖∞ is defined in (1.31).

Proof: Combining and manipulating (1.22), (1.23) and (1.34) yields

[E∞(z) − Ei+1(z)] = H(z)[1 − zL(z)P (z)][E∞(z) − Ei(z)] (1.44)

and the result follows directly from the definition of the infinity norm. For more information,see [10] (Theorem 1) and [22] (Theorem 3).

Notice that (1.30) equals (1.43), hence in the frequency domain asymptotic stability also impliesmonotonic convergence, and vice versa. It is important to note, however, that MC in the fre-quency domain is based on the error signal in the frequency domain, which does not guaranteeMC in the time domain.

1.2.5 Relations between Time and Frequency Domain

An important question is to what extent the above results coincide for the time and frequencydomain. The following theorem gives an important result.

Page 20: Iterative Learning Control for Internal Combustion Engines

Chapter 1. Iterative Learning Control: Theory 10

Theorem 1.7. When H(q) and L(q) are causal, then AS or MC in the frequency domain alsoimplies AS and MC in the time domain.

Proof: The result follows from the fact that if F (z) is causal, then ‖F (z)‖∞ < 1 implies σ(F) < 1,for which the proof is given in [20] (Theorem 8).

This is a very important statement, for it means that the frequency domain analysis can beused for an ILC system with finite duration. In particular, the stability condition (1.30) in thefrequency domain provides AS and MC independent of N .

1.3 Design

In many cases, the dynamic system and requirements are given in continuous time, consisting of

1. a continuous-time plant P (s) describing the physical system, and

2. a reference trajectory yd(t) of finite duration tN .

Choosing a sampling time Ts, these are then discretized to give the discrete-time plant P (q) andreference trajectory yd(k) with a finite length N . The design of an ILC system now consists ofselecting H(q) and L(q) such that the desired monotonic convergence is achieved. The stabilityand performance analysis can be carried out in both time and frequency domain. However, itis not straightforward to use the time domain as a design tool, because it is unclear how L(q)must be chosen in order to obtain σ(F) < 1. Although H(q) and L(q) have to be causal in orderfor the frequency domain analysis to be used, this restriction is not severely limiting the designpossibilities. In fact, the following theorem provides a very useful design tool.

Theorem 1.8. Suppose that H(z) = 1 and L(z) is causal, then ‖F (z)‖∞ < 1 is equivalent to

∠(ejθL(ejθ)P (ejθ)) = ϕ ∈ [−π/2, π/2] (1.45)

and

supθ∈[−π,π]

|ejθL(ejθ)P (ejθ)| < 2 cos(ϕ) (1.46)

for all θ ∈ [−π, π].

Proof: If H(z) = 1, then F (z) = 1 − zL(z)P (z), so that ‖F (z)‖∞ < 1 can be restated as arequirement that zL(z)P (z) be within a unit circle centered at (1, 0) on the complex plane, whichis mathematically expressed by (1.45) and (1.46). For more information, see [1].

An important fact to note is that zL(z) should ensure that |ejθL(ejθ)P (ejθ)| → 0 as |ϕ| → π/2.Furthermore, the stability region for certain frequencies can be increased if H(z), which is typ-ically selected as a low-pass filter, has a gain less than one, albeit at the expense of a nonzeroasymptotic error.

Theorem 1.8 can be a very useful tool for the selection of the learning function L(z). Giventhe plant P (z), the first step is to look at the Bode magnitude and phase plots of zP (z). Thisdirectly shows which type of learning function is needed to keep the overall phase between −90◦

and 90◦. Ideally one would select L(z) = [zP (z)]−1, but this is impractical as P (z) cannot beidentified exactly for real systems. Instead, some standard types of learning functions are oftenused, which are described below, where H(q) = 1 is assumed.

Page 21: Iterative Learning Control for Internal Combustion Engines

Chapter 1. Iterative Learning Control: Theory 11

1.3.1 PID-type ILC

As the name implies, the PID-type learning function consists of a proportional, an integral anda derivative action on the error. The integrator term is rarely used since ILC has an inherentintegrator action from one iteration to the next [15]. The remaining PD-type update law can bewritten in discrete time as

ui+1(k) = ui(k) + βP ei(k + 1) + βD[ei(k + 1) − ei(k)] (1.47)

where βP and βD are called learning gains for the proportional and derivative action, respec-tively. Learning functions of this type rely on tuning and do not require an accurate model forimplementation. However, some model of the dynamics is still needed in order to verify stabilityand convergence of the ILC system. The learning function is

L(q) = (βP + βD) − βDq−1 (1.48)

and in the lifted system representation:

L =

(βP + βD) 0 · · · · · · 0

−βD. . .

. . .. . .

...

0. . .

. . .. . .

......

. . .. . .

. . . 00 · · · 0 −βD (βP + βD)

(1.49)

If βD = 0, then the well-known P-type learning function is obtained, which can be used if zP (z)has a phase between −90◦ and 90◦. If this is not the case, then a D-type learning function maybe suitable, which is another widely used type of learning function and is obtained by settingβP = 0.

1.3.2 Lead-lag-type ILC

If a PD-type learning function cannot ensure AS and MC, then a learning function in the formof a lead-lag compensator might be a solution. A single or multiple lead or lag compensators canbe used to increase or decrease the phase in a specific frequency range. It is often convenientto design the lead-lag compensator in continuous-time and then use some appropriate emulationmethod (e.g. the Tustin transformation) to transform it to discrete time. The resulting learningfunction L(q) can then be written in the state-space form of (1.3) and (1.4). Finally, the learningfunction L in the lifted system representation can be calculated using (1.9).

1.3.3 Q-ILC

A commonly used method to design a learning filter in the lifted system representation is basedon the principle of optimisation. Upon completion of the ith iteration, the input of the nextiteration is found by solving the minimum-norm optimisation problem

ui+1 = arg minui+1

Ji+1(ui+1) (1.50)

where Ji+1(·) is the cost criterion or cost function, which is often defined as

Ji+1(ui+1) = ‖ei+1‖22 + ‖ui+1 − ui‖

22 (1.51)

Page 22: Iterative Learning Control for Internal Combustion Engines

Chapter 1. Iterative Learning Control: Theory 12

This algorithm will result in monotonic convergence, as proven in [3] (Section 2.2) and [21](Section 5). A more general and practical form of (1.51) is often used:

Ji+1(ui+1) = eTi+1Qei+1 + ∆uT

i+1R∆ui+1 (1.52)

where ∆ui+1 , ui+1 − ui, and Q ≻ 0 and R � 0 are weight matrices that are used to penalizethe error and the change of the input, respectively. Solving the optimisation problem with thiscost function results in a quadratically optimal design, hence the name Q-ILC. Minimising thecost function with respect to ∆ui+1 yields the optimal learning gain

L = (PT QP + R)−1PT Q (1.53)

which is obtained by substituting ei+1 = ei − P∆ui+1 in (1.52) and solving the resulting leastsquares problem. The weight matrices are often chosen to be diagonal with a single tuningparameter, so that Q = βQ · I and R = βR · I.

1.4 Parallel vs Serial Arrangement

Iterative learning control is, in essence, an open-loop control technique, because during eachtrial the input ui(k) is a fixed trajectory. Only in the next iteration is the error used to adjustthe input. Consequently, ILC cannot compensate for non-repeating disturbances and noise, andsome type of feedback control system is therefore used in most practical situations. In additionto disturbance rejection, a feedback controller is normally also used for reference tracking. Thiscan greatly simplify the ILC because of two reasons. On the one hand, it can be used to setthe initial conditions, i.e. assumption (A3) in Subsection 1.1.2. On the other hand, it createsa good starting point for ILC, because in the first iteration the feedback controller does "thelargest part of the job" in finding the optimal input to the system for a desired output. However,if a feedback controller is used, robustness and stability problems can occur, and therefore thedynamics of the system have to be known to some extent.

Iterative learning control can be combined with a feedback controller in two ways. The firstarrangement, see Figure 1.1, is called serial ILC, because the ILC input is applied to the refer-ence before the feedback loop. The second arrangement, see Figure 1.2, is called parallel ILC,because the ILC input and the feedback control input are combined. For more information aboutboth architectures, the reader is referred to [8]. In this thesis, a slightly altered but equivalentversion of the serial arrangement will be used. Instead of adding the output ui+1 of the ILCalgorithm to the desired reference yd, it is directly used as the reference r to the system, so thatr = ui+1. This requires that at the first iteration, the ILC input u1 is set to yd.

1.5 Systems with a Time Delay

The theory presented in the previous sections is developed for systems without a time delay.However, a time delay is often present in many practical systems. If a system contains a timedelay, this means that assumption (A6) in Subsection 1.1.2 does not hold. The desired referencetrajectory and output of the system will always be separated by the time delay of the system.Therefore, the ILC, as defined above, cannot be applied for systems with a time delay. Fortu-nately, a simple modification is possible such that ILC can nevertheless be used for these systems.Suppose that the continuous system of interest contains a time delay Td. Choosing a sampling

Page 23: Iterative Learning Control for Internal Combustion Engines

Chapter 1. Iterative Learning Control: Theory 13

r yi(k)Controller Plant

yd(k)

ILC

ei(k)

ui+1(k)

Figure 1.1: Serial ILC arrangement.

yi(k)Controller Plant

yd(k)

ILC

ei(k)

ui+1(k)

Figure 1.2: Parallel ILC arrangement.

time Ts, the system is discretized, and the number of samples kd of the discrete-time delay iscalculated as

kd = round

(Td

Ts

)

(1.54)

The definition of the error signal in (1.2) can then be modified as follows:

ei(k) = yd(k) − yi(k + kd) (1.55)

By shifting the output of the system by the time delay, assumption (A6) is satisfied and theILC can be applied in the same way as if there were no delay. Obviously, this requires thedelay time to be accurately known. Moreover, the rounding in (1.54) inevitably leads to anerror in the time delay that is used for ILC. Both these effects may render the ILC unstable.Even though there exist ILC algorithms that can cope with time delay uncertainties, see e.g. [7](Chapter 8), [16] and [27], the design methods and implementations are generally cumbersomeand therefore outside the scope of this thesis. For the remainder of this thesis, the modified errorsignal definition (1.55) will be used if the system has a time delay.

Page 24: Iterative Learning Control for Internal Combustion Engines
Page 25: Iterative Learning Control for Internal Combustion Engines

Chapter 2

Experimental Setup

In this chapter, the experimental setup that was used for the experiments in this thesis is pre-sented.

2.1 Engine Test-Bench

The experiments in this thesis have been carried out on an engine test-bench at the Institutefor Dynamic Systems and Control at ETH Zurich. The test-bench is equipped with a 3-cylinderspark-ignited (SI) petrol engine that is turbocharged and uses direct injection. The basic pa-rameters of the engine are listed in Table 2.1. The engine is connected to a dynamometer thatis used to keep the engine speed constant.

Table 2.1: Basic engine data.

engine type turbocharged petrol SIinjection direct injectionnumber of cylinders ncyl 3displacement Vd 1.5 lbore, stroke B, S 82 mm, 94.6 mmconnecting rod length lcr 146 mmcompression ratio ǫ 10.1

2.2 Engine Control Structure

The engine is primarily controlled by the electronic control unit (ECU) that is provided by themanufacturer. In addition, a rapid prototyping system from dSPACE is used, consisting of:

• The dSPACE I/O board, which allows sensor values to be read and actuator commands tobe sent. It also provides the communication with the ECU.

• dSPACE ControlDesk, which is the interface and visualisation software.

• MATLAB/Simulink, which is used to create and compile the model that can be loadedonto the dSPACE board.

14

Page 26: Iterative Learning Control for Internal Combustion Engines

Chapter 2. Experimental Setup 15

2.3 Discrete-Time Events

Due to its reciprocating behaviour, an internal combustion engine is, by its very nature, adiscrete-event system. Three important time intervals are the duration of an engine cycle, anengine revolution and an engine segment:

τcyc =2π · N

ωeτrot =

ωeτseg =

2π · N

ωe · ncyl(2.1)

where N = 2 for a four-stroke engine and ncyl = 3 for the engine in this thesis. For instance, at2000 rpm, τcyc = 60 ms, τrot = 30 ms and τseg = 20 ms. Likewise, the ECU and dSPACE arediscrete-time systems, and several clock rates are utilised:

• 1 ms: the Simulink model that runs on the dSPACE board

• 10 ms1: the ECU and most of its sensors and actuators

• 1/2 segment (or half-segment): some of the ECU’s systems, sensors and actuators, such asthe injection and ignition system.

The ECU generates interrupts to execute its tasks, and these triggers can be read and used inthe Simulink model to synchronise certain control actions with the ECU. The ECU does notgenerate a 1 segment (or one-segment) interrupt, which could be used for a synchronisation withthe engine’s reciprocating action. Therefore, this trigger has to be created in the Simulink model.This is done by using the half-segment trigger and the crank angle (CA) sensor to determinein which half-segment the engine is located. For example, if the crank angle is between 0 and120◦, then the position of the crankshaft is located in the first half-segment. Furthermore, in thiscrank angle range, it is the first cylinder that has the power stroke. The criteria to determinethe current half-segment and the cylinder with the power stroke are listed in Table 2.2. Theone-segment trigger is generated in each first half-segment.

Table 2.2: Criteria to determine the current half-segment and cylinder with the power stroke.

CA [◦] half-segment [#] Cylinder [#][0, 120) 1 1[120, 240) 2 1[240, 360) 1 2[360, 480) 2 2[480, 600) 1 3[600, 720) 2 3

1On average, the sampling time is 10 ms, but also 9 and 11 ms occur and even larger deviations cannot be

ruled out.

Page 27: Iterative Learning Control for Internal Combustion Engines

Chapter 2. Experimental Setup 16

2.4 Software Structure

The input trajectory ui+1(k) that is generated by the ILC update law (1.7) has to be appliedto the system and at the same time a measurement must be made so that the necessary signalsare recorded and the data saved. The input trajectory data is stored in a lookup table in theSimulink model and the triggers are used to generate output at specific points in time. In fact,both the air mass flow and air/fuel ratio control system have their own lookup table, and outputis generated by the 10 ms and one-segment triggers, respectively.

A schematic overview of the software structure of the ILC in the Simulink model is shownin Figure 2.1 below. The RTI bypass blocks are part of the dSPACE Real-Time Interface (RTI).The RTI interrupt block retrieves the triggers from the ECU. In case of the air/fuel ratio system,the half-segment trigger is used to generate a one-segment trigger. In case of the air mass flowsystem, the 10 ms trigger is directly used. The triggers are subsequently used for the lookuptable and the control system, which are both located in a triggered subsystem. The sensor valuesare read using the RTI read block, which retrieves this data from the ECU. After the data isprocessed, it is used by the control system and the controller output is written to the ECU usingthe RTI write block.

INTERRUPT

One-segment

ControlREAD

Trigger

Generation

Lookup

Table

(half-segment)

(ECU data) System· · ·

RTI BYPASSRTI BYPASS

RTI BYPASS

WRITE

(to ECU)

Figure 2.1: Overview of the ILC software structure in the Simulink model. It shows the flowof data (solid lines) and triggers (dashed lines) that are used.

The implementation and procedure of ILC on the engine test-bench will be further discussed inChapter 5.

Page 28: Iterative Learning Control for Internal Combustion Engines
Page 29: Iterative Learning Control for Internal Combustion Engines

Chapter 3

Air Mass Flow: Modelling andControl

In this chapter, a control system for the air mass flow mβ is designed. The first part focuses onthe modelling of the air mass flow system. A model is developed to estimate the air mass flowthat enters the cylinders, and this estimation is then used to identify the dynamic behaviourof the system. In the second part, the controller is designed and implemented on the enginetest-bench. Finally, experiments are carried out to test the control system.

3.1 Preliminaries

The torque of an SI engine is controlled by the quantity of the air/fuel mixture in the cylindersduring each stroke. Under stoichiometric conditions, the torque produced by the engine is directlyproportional to the air mass flow. Therefore, the torque can be controlled by controlling the airmass flow, provided that the air/fuel ratio control system keeps the air/fuel ratio λ at 1.

3.1.1 System Structure

An overview of the engine system structure is depicted in Figure 3.1. It shows the path of theair as it passes through the engine. Typically, the air mass flow is varied by changing the intakepressure. In naturally aspirated (NA) SI engines, this is achieved by a throttle plate upstreamof the intake manifold. In turbocharged SI engines, the compressor can be used to compressthe intake air, allowing much more torque to be generated than NA engines. The power outputof the turbocharger depends on the amount of enthalpy that the turbine can extract from theexhaust gas. The boost pressure can therefore be controlled by the amount of exhaust gas thatenters the turbine, which is controlled by the waste-gate. Furthermore, the engine considered inthis thesis is additionally equipped with fully variable timing and lift valves, which allow for afast and precise adjustment of the amount of air entering the cylinders.

The air mass flow mβ of the engine in this thesis can thus be controlled by five actuators: thethrottle valve position uth, the waste-gate position uwg, the inlet and outlet valve timing uvan,iv

and uvan,ev, and the lift of the intake valves uvvt. With these actuators and the turbocharger, theengine is clearly a multiple-input multiple-output (MIMO) system with complicated and coupleddynamics.

17

Page 30: Iterative Learning Control for Internal Combustion Engines

Chapter 3. Air Mass Flow: Modelling and Control 18

AF

C T

uth

uinj

uvvt

uwgWG

ThIC

IM

Cyl

uign

mβ,HFM

HFM

λ

AFRTWC

AF air filter IM intake manifold uwg waste-gate commandAFR air/fuel ratio sensor T turbine uinj injection commandC compressor Th throttle uign ignition commandCyl cylinders TWC catalytic converter uvvt valve lift commandHFM air mass flow sensor WG waste-gate mβ,hfm measured air mass flowIC intercooler uth throttle command λ measured air/fuel ratio

Figure 3.1: Overview of the engine system structure.

3.1.2 Operating Regions

With so many actuators available to influence the air mass flow, there are many degrees offreedom to control the air mass flow. In order to simplify matters, the following actuators arekept constant:

• Throttle valve fully open (uth = 100 %)

• Inlet and outlet valve timing constant (uvan,iv = 75 and uvan,ev = 90)

Consequently, the air mass flow is solely controlled by the waste-gate position uwg and the valvelift uvvt. However, this still gives a MIMO system, whereas for the iterative learning controlin this thesis it is essential to have a SISO system. Figure 3.2 shows an important part of themeasured engine map. It has been observed that the operating range of the engine can be dividedinto two regions. In the first and lower region, the waste-gate is fully opened (uwg = 0%) andthe air mass flow is controlled by the lift of the intake valves, so that in this region the engine isvirtually naturally aspirated (NA). In the other region, in which the engine is turbocharged (TC),the intake valve lift is set to its maximum value (uvvt = 10 mm) and the waste-gate position isused to control the air mass flow. A smooth transition between both regions is guaranteed bymeans of a hysteresis mechanism.

By defining these two regions and operating the engine accordingly, the system is largely de-coupled, thus consisting of two SISO subsystems; one for each region. In this thesis, only the NA

Page 31: Iterative Learning Control for Internal Combustion Engines

Chapter 3. Air Mass Flow: Modelling and Control 19

Figure 3.2: Engine map with measured actuator values. Blue lines in grey region (whereuwg = 0 %) show values for uvvt [mm] and red lines in upper region (where uvvt = 10 mm)show values for uwg [%]. Dotted line represents the threshold between the NA and TC operationregions.

region is studied and the iterative learning control applied. The strategies and findings, however,should be similar for the turbocharged region.

3.1.3 Air Mass Estimation

The air mass flow entering the cylinders cannot be measured directly, and thus has to be esti-mated. The air mass flow mainly depends on the intake valve lift, intake manifold pressure andengine rotational speed:

mβ ≈ f(uvvt, pim, ωe) (3.1)

Since the throttle position is kept constant for the sake of simplicity, the air mass flow is solelycontrolled by the waste-gate position and lift of the intake valves. A model based on physicalprinciples that is commonly used [12] does not include the influence of a variable valve lift andcan therefore not be used. Therefore, a new model for the estimation of the air mass flow isdeveloped. Measurements are made over a wide range of values of the variables in (3.1), wherepim is changed by selecting different waste-gate positions:

uvvt ∈ [1 : 1 : 10] mm (3.2)

uwg ∈ [0 : 5 : 100] % (3.3)

ωe ∈ [1000 : 500 : 3000] rpm (3.4)

Page 32: Iterative Learning Control for Internal Combustion Engines

Chapter 3. Air Mass Flow: Modelling and Control 20

The actual air mass flow is obtained in steady-state conditions from the HFM air mass flowsensor, which is located downstream of the air filter. The resulting measurement map is fittedat different rotational speeds ωe using the following function:

mβ = (a1 · pim + b1) + (a2 · pim + b2) · log uvvt,act (3.5)

where the unit bar is used for pim and uvvt,act is the actual position of the actuator. For example,at 2000 rpm, the measurements and fitting function are shown in Figure 3.3, and the averageerror is less than 5%. The fitting parameters are listed in Table 3.1 for different ωe and the

Figure 3.3: Measurement map (dots) and fitting function (mesh) at 2000 rpm. The averageerror equals 4.8%.

parameters are linearly interpolated for intermediate rotational speeds. Additional measurementare made to validate the fitting, see Figure 3.4. It can be concluded that the fitting is veryaccurate, with a maximum absolute error less than 5% in the operating points of interest.

Table 3.1: Fitting parameters for air mass flow estimation.

ωe [rpm] a1 b1 a2 b2

1000 0.0020 0.0045 0.0093 -0.00531500 -0.0037 0.0091 0.0158 -0.00892000 -0.0079 0.0115 0.0223 -0.01142500 -0.0092 0.0109 0.0249 -0.01073000 -0.0104 0.0083 0.0258 -0.0066

The estimation model for the air mass flow developed in this subsection is used for all experimentsin this thesis.

Page 33: Iterative Learning Control for Internal Combustion Engines

Chapter 3. Air Mass Flow: Modelling and Control 21

Figure 3.4: Additional measurements for validation of fitting.

3.1.4 Filter Design

Due to the engine’s reciprocating behaviour, the intake manifold pressure pim is subject to heavyoscillations. Because for control purposes it is essential to have smooth signals, a causal filter forthe intake manifold pressure is designed and implemented. Looking at the frequency spectrumof the pressure signal, several peaks in the amplitude are visible. These are directly related tothe rotational speed and segment time in (2.1). For instance, at 2000 rpm, τrot = 30 ms (33.3Hz) and τseg = 20 ms (50 Hz), and high amplitude peaks are observed at 33.3, 50, 66.6 and 100Hz. Although they have very different amplitudes, all peaks are a multiple of some fundamentalfrequency:

f0 =ωe

2π · N(3.6)

which is the frequency of one engine cycle. Given these observations, a filter has to be designedsuch that the output is a smooth signal, that is, the oscillations are (almost) entirely filtered out.This could be achieved by a low-pass filter, but because f0 is generally small, this yields a veryslow filter. Ideally, only the peaks should be filtered out, leaving all other frequencies unaltered,resulting in a smooth output signal and a quick response. In practice, this can be approximatelyachieved by an adaptive moving average (MA) filter:

H(z) =1

Nfilt

Nfilt−1∑

n=0

z−n (3.7)

where Nfilt is the window length, which should be chosen as

Nfilt = round

(fs

f0

)

(3.8)

Page 34: Iterative Learning Control for Internal Combustion Engines

Chapter 3. Air Mass Flow: Modelling and Control 22

where fs is the sampling frequency. As a result, the filter depends on the rotational speed.Taking again the example of 2000 rpm, the magnitude of the moving average filter is shown inFigure 3.5. It can be seen that the peak frequencies are filtered out, whereas the intermediatefrequencies are still present in the output signal. The filter is tested on the engine at 2000 rpmand the performance is compared to a 2nd order filter of the form 502/(s + 50)2. The resultsare shown in Figure 3.6. The 2nd order filter has good performance but the output signal stillcontains some 50 Hz noise. The adaptive MA filter, on the other hand, produces a very smoothsignal and a has a quick response, which are both advantageous for control purposes.

Figure 3.5: Frequency response of the moving average filter at 2000 rpm.

Figure 3.6: Comparison of the raw and filtered measurement signal at 2000 rpm.

Page 35: Iterative Learning Control for Internal Combustion Engines

Chapter 3. Air Mass Flow: Modelling and Control 23

3.2 System Identification

In order to get a first insight into the dynamics of the air mass flow system, a step is applied tothe valve lift uvvt and the air mass flow mβ from the estimation is the output. The result showsthat the dynamics of the air mass flow system can be represented by a first-order lag with a timedelay:

P (s) = G(s) · e−sTd =k

τs + 1· e−sTd (3.9)

The identification of the parameters in (3.9) and the validation of the model based on measure-ments are the subjects of this section.

3.2.1 Actuator Dynamics

Actuators are an essential part of every system, and for the identification of the system it isbeneficial to know the actuator dynamics. In the case of the air mass flow system, the variableinlet valve is the most important actuator. The valve lift uvvt can be set between 0 and 10mm. To gain insight into the actuator dynamics, a step is applied and the response is examined.Figure 3.7 shows the desired uvvt and the actual lift uvvt,act. A delay of 40 ms is observed, aswell as a rate limiting behaviour, so that the maximum lift is reached in approximately 0.3 s.

Figure 3.7: Step response of the variable valve lift actuator.

3.2.2 Parameter Identification

To identify the parameters, the system is excited by −10% and +10% steps in the inlet valvelift uvvt and the air mass flow estimation is the output. This is done for the following operatingpoints in the NA region:

uvvt ∈ [1 : 1 : 10] mm (3.10)

ωe ∈ [1500 2000 2500] rpm (3.11)

A typical response is depicted in Figure 3.8. It shows a quick initial response to around 95% ofthe steady-state value, which is the result of a fast change of the inlet valve lift. It is followed by

Page 36: Iterative Learning Control for Internal Combustion Engines

Chapter 3. Air Mass Flow: Modelling and Control 24

a slow convergence to the steady-state value, which can be explained by the rather slow responseof the turbocharger. This effect, however, is small, so that the assumption of a SISO systemholds true.

The MATLAB functions iddata and pem from the System Identification Toolbox are foundto be very effective for fitting the parameters in (3.9) to the experimental data. The delay Td

is found to be 40 ms for all operating points, so clearly it is only the actuator that causes adelay. For the time constant τ , no correlation was found between τ and the operating points.Therefore, a range of values is defined based on two standard deviations above and below themean, so that τ = 31.4 ± 11.8 ms. The values for the gain k will not be given here. Instead,k = 1 is taken so that the plant is normalised, and gain scheduling will be used to account forthe different operating points, which will be discussed in Section 3.3.3.

Figure 3.8: Step response of the air mass flow system at uvvt = 5 mm and ωe = 2000 rpm.

3.3 Control System Design

3.3.1 Structure

For the control structure a PI-controller is chosen:

C(s) = Kp + Ki1

s(3.12)

which is augmented by a Smith predictor (SP) to compensate for the time delay. The controlstructure is depicted in Figure 3.9. The augmented controller C′(s) consists of the regularcontroller C(s) and a prediction structure, where a hat · indicates that an estimation of the trueparameter is used. In the case of perfect model matching, i.e. when the true parameters areknown exactly, the complementary sensitivity T (s) can be written as

T (s) =C(s)G(s)

1 + C(s)G(s)· e−sTd =

Kps + Ki

τs2 + (Kp + 1)s + Ki· e−sTd (3.13)

which shows that the SP cannot eliminate the time delay, but it allows for a valuable simplifica-tion, which is that the closed-loop response after the delay is exactly the same as the closed-loop

Page 37: Iterative Learning Control for Internal Combustion Engines

Chapter 3. Air Mass Flow: Modelling and Control 25

response for the system without a delay. For more information about the SP, see e.g. [17](Chapter 5) and [9].

r ye

G(s)(1 − e−Tds)

C(s) P (s)

C′

u

Figure 3.9: Control structure of the Smith predictor.

3.3.2 Tuning

The PI-controller is tuned for the normalised plant without a delay:

G(s) =1

τs + 1(3.14)

The MATLAB function pidtune from the Control System Toolbox is found to be very effectivefor the tuning of the controller. A proportional gain Kp = 0 and an integral gain Ki = 10.5 areobtained, resulting in a crossover frequency of approximately 10 rad/s and a phase margin of72.6◦ for the nominal time constant, and 78.6◦ and 67.3◦ for the minimum and maximum valuesof τ , respectively. Furthermore, it is assumed that Td = Td, since the delay is constant and couldbe very accurately identified. Therefore, the controller and SP are expected to be very robust.

3.3.3 Gain Scheduling

Gain scheduling is an approach to the control of non-linear systems, where the controller gains arealtered depending on the operating point of the system. This is done using a so-called schedulingvariable, which could be, for example, the air mass flow. In Section 3.2, the non-linear systemwas identified at different operating points. In this way, several linear systems were obtained,each around a different linearisation point (i.e. a steady-state operating point). When a con-troller is used for a linearised system, the steady-state input uss should be added to the controlleroutput u. Since a large range of operating points is considered, the steady-state input shouldalso depend on the scheduling variable. However, if the input or output of the plant is used asa scheduling variable, this introduces unwanted additional dynamics.

In order to tackle this problem, a single operating point is used as a basis, and the gains ofthe linear systems are calculated relative to this point. The base gain kbase is defined as:

kbase ,mβ − mβ,base

uvvt − uvvt,base(3.15)

where uvvt,base = 1 mm and the corresponding output mbeta,base = [5.9 4.9 4.1] g/s for therotational speeds in (3.11). The base gain is calculated for the operating points in Subsection

Page 38: Iterative Learning Control for Internal Combustion Engines

Chapter 3. Air Mass Flow: Modelling and Control 26

3.2.2 and is compared to several suitable scheduling variables. The choice of the schedulingvariable is the air mass per engine cycle mβ, which is related to the air mass flow by

mβ = mβ ·4π

ωe(3.16)

The base gain can also be expressed in the air mass per cycle by

kbase,cyc = kbase ·4π

ωe(3.17)

and a linear correlation is found between mβ and kbase,cyc, as shown in Figure 3.10. The basegain kbase can now be calculated as a function of mβ by using (3.16), (3.17) and the linear fit.Finally, the gain scheduling on the real system is achieved by dividing the controller output uby the base gain kbase.

Figure 3.10: Linear correlation between the base gain and the air mass per cycle.

3.3.4 Implementation

The controller is implemented in MATLAB/Simulink using discrete-time integrators. Further-more, the controller is synchronised with the 10 ms trigger of the ECU, so that it is exactlyknown which values are actually used for the actuators. The complementary sensitivity in (3.13)is discretized using its zero-order hold (ZOH) equivalent, which is defined as

GZOH = (1 − z−1) Z

{G(s)

s

}

(3.18)

and the MATLAB function c2d is used for the calculation, taking Ts = 10 ms.

Page 39: Iterative Learning Control for Internal Combustion Engines

Chapter 3. Air Mass Flow: Modelling and Control 27

3.4 Experimental Results

The performance of the control system is tested on the engine test-bench. To this end, a desiredtrajectory is used that covers a wide range of air mass flows, and experiments are carried outat several rotational speeds. The results are shown in Figure 3.11 and two important observa-tions can be made. Firstly, the closed-loop responses at different rotational speeds are almostidentical. Secondly, some overshoot is observed at higher air mass flows. This may be due tothe uncertainty of the time constant of the plant, but more likely it is caused by unmodelleddynamics, namely the dynamics of the turbocharger, as mentioned in Subsection 3.2.2.

Figure 3.11: Response of the closed-loop system at ωe ∈ [1500 : 500 : 3000] rpm and variousair mass flows. At 1500 rpm, the maximum air mass flow is 0.02 kg/s.

Furthermore, the behaviour of the system under steady-state conditions is analysed. A measure-ment was made at 2000 rpm and a fixed reference air mass flow of 0.02 kg/s. Figure 3.12 showsthe actual air mass flow, the desired valve lift (i.e. the control output) and the actual positionof the actuator. It can be seen that there are some very small oscillations in the valve lift and asa result also the estimated air mass changes slightly. Apparently, the actuator control system,which is part of the ECU, has some kind of hysteresis mechanism. The controller developed inthis chapter reacts to this behaviour and this creates oscillations. Nonetheless, the fluctuationsare extremely small and are therefore treated as measurement noise.

Finally, the noise of mβ under steady-state conditions is analysed. It was found that the noise canbe accurately described by a Gaussian distribution with a standard deviation of approximately0.015 g/s for all air mass flows. Even though this value is very small, it is useful to know theamount of noise for the evaluation of ILC in practice. It is reasonable to assume that the noise isnot correlated with the iterations of the ILC. Therefore, the amount of noise gives a lower boundon the error reduction that can be achieved by ILC on the engine test-bench.

Page 40: Iterative Learning Control for Internal Combustion Engines

Chapter 3. Air Mass Flow: Modelling and Control 28

Figure 3.12: Constant air mass flow (top) and desired and actual inlet valve lift position(bottom) at 2000 rpm.

3.5 Conclusions

In this chapter, a control system for the air mass flow was designed. A new model for theestimation of the air mass flow was developed. The controller was implemented on the enginetest-bench and experiments were carried out to test the control system. The following conclusionscan be made:

• The adaptive moving average filter for the intake manifold pressure produces a very smoothsignal and a has a quick response.

• The air mass flow estimation developed in this chapter is very accurate.

• The controller has good performance and robustness over a large range of operating points.

• The response of the closed-loop system is virtually identical for all operating points, sincethe nominal time constant τ is assumed to be constant. The nominal complementarysensitivity is

T (s) =10.5

0.0314 s2 + s + 10.5· e−s 0.04 (3.19)

The result of the last conclusion was achieved by successfully applying gain scheduling. It greatlysimplifies the design of an iterative learning control algorithm, because it requires only one updatelaw to be designed and implemented.

Page 41: Iterative Learning Control for Internal Combustion Engines

Chapter 4

Air/Fuel Ratio: Modelling andControl

In this chapter, a controller for the air/fuel ratio λ is designed. In the first part, a model for thefuel path is derived and the parameters are identified. The second part of this chapter focusses onthe actual control design and its implementation on the engine test-bench. Several experimentsare carried out to test and tune the controller on the engine. The chapter is largely based on[25], [6] and [12] (Section 4.3).

4.1 Preliminaries

As mentioned in the previous chapter, the torque of an SI engine is typically controlled bycontrolling the air mass flow that enters the cylinders. Another essential part of every SI engineis the air/fuel ratio control system, which is used to control the injected fuel mass such that thecombustion is stoichiometric, i.e. the air/fuel ratio λ = 1.

4.1.1 System Structure

The air/fuel ratio (AFR) is measured by a single wide-range λ sensor and the control input isapplied to all three cylinders, as is typically the case in production-type engines. The λ sensor islocated between the turbine and the three-way catalytic converter (TWC), as shown in Figure3.1. The TWC is the pollution abatement system that is used on the engine. The control of theoxygen level in the TWC is not part of this thesis. The interested reader is referred to [12].

4.1.2 Control System Structure

The overall structure of the air/fuel ratio controller is depicted in Figure 4.1. It comprises afeedforward and a feedback part. The feedforward controller uses the estimated air mass flowmβ from Chapter 3 and the desired air/fuel ratio λd to estimate the necessary opening timetinj,F F of the injection valve. This injection time is approximately proportional to the amountof injected fuel. The feedback controller uses the signal from the λ sensor to compensate fordeviations from the desired value λd. The output of the feedback controller is a multiplicationfactor F , and so the injection time is defined as

tinj = F · tinj,F F (4.1)

29

Page 42: Iterative Learning Control for Internal Combustion Engines

Chapter 4. Air/Fuel Ratio: Modelling and Control 30

This may come as a surprise, since normally the feedforward signal is added to the feedback sig-nal. However, a multiplication can be used here because of the physical properties of the systemand the manner in which the linearised model is defined. This will become clear in Subsection4.2.1.

λd

tinj,F F

λFeedback Fuel pathF tinj

Feedforward

e

Figure 4.1: Structure of the air/fuel ratio controller.

The feedforward controller was already available, so this chapter focuses on the design of thefeedback controller.

4.1.3 Noise

Since the λ sensor at the main confluence point is used, the air/fuel ratio of the individual cylin-ders will be measured consecutively. The individual air/fuel ratios can vary because of differencesin the air flow due to the geometry of the intake manifold, the conditions of the fuel injectors,and other physical phenomena. Even though the individual exhaust gasses will mix on their wayto the confluence point, the imbalanced air/fuel ratios of the cylinders may still be measurable.Experiments carried out on the engine test-bench indeed showed oscillations in λ, in additionto the usual measurement noise. Figure 4.2 shows the measured air/fuel ratio signal at variousrotational speeds and a constant air mass flow. The injection time is set manually to obtainλ ≈ 1.

It can be seen that oscillations are present at every rotational speed. A frequency spectrumanalysis reveals that the period of the oscillations is exactly one engine cycle. Furthermore,the amplitude is higher for lower rotational speeds, which can be explained as follows. For thesame overall air mass flow, the amount of air per cycle per cylinder is smaller at higher rota-tional speeds. Consequently, there exist more portions of air with different air/fuel ratios, andalso more boundaries between them, so that more mixing can occur before the λ sensor is reached.

Clearly, the amount of mixing and the intensity of the oscillations depend on both rotationalspeed and air mass flow or air mass per cycle. A more detailed analysis would be required tobe able to determine the separate influences, but this is beyond the scope of this thesis. Forthe analyses and results in this work, it is enough to realise that this form of noise is inher-ently present in the system. It may even impair the performance of the control system as theoscillations may be increased due to the control action.

Page 43: Iterative Learning Control for Internal Combustion Engines

Chapter 4. Air/Fuel Ratio: Modelling and Control 31

Figure 4.2: Measured air/fuel ratio at different rotational speeds and mβ = 0.02 kg/s. Injectiontime is set manually to obtain λ ≈ 1. Four measurements are made per rotational speed.

4.2 System Identification

4.2.1 Modelling

For the feedback controller design the air mass flow is treated as a disturbance and therefore onlythe modelling of the fuel path needs to be considered. The model of the fuel path is depicted inFigure 4.3. The first delay represents the time from the start of the injection to the subsequentopening of the exhaust valve. This time is in the range of a complete engine cycle. After theexhaust stroke, some residual gas always remains present in the cylinder, which mixes with theair of the subsequent cycle. Moreover, the burned gas from the different cylinders will mix in theexhaust manifold and turbine. Both these effects are included in the gas mixing dynamics. Thesecond delay captures the time it takes for the exhaust gas to flow from the exhaust valve to thesensor and as such is a transport delay. Finally, the dynamics of the λ sensor could be includedin the model, but they are very fast and can therefore be neglected [25] (Subsection 3.2.1).

tinj,F F

F tinj gasdelaydelay λ

mixingλ

sensor

Figure 4.3: Block diagram of the fuel path model.

The dynamics of the complete fuel path can be approximated by a first-order lag with a time

Page 44: Iterative Learning Control for Internal Combustion Engines

Chapter 4. Air/Fuel Ratio: Modelling and Control 32

delay:

P (s) =∆λ

∆F=

−1

τs + 1· e−sTd (4.2)

where the output is defined as ∆λ = λ−λd and the input as ∆F = F −1. Under these definitions,the multiplication is included in the plant, and at the same time P (s) describes the behaviourof the system around every steady-state operating point (as determined by tinj with F = 1and the corresponding λ). As mentioned before, the amount of injected fuel is approximatelyproportional to the injection time. As a result, also λ is more or less proportional to F . In fact,an increase of 10% of the injection time results in a 10% decrease of the air/fuel ratio. Therefore,the gain of the linearised plant P (s) equals −1, although this is of course an approximation.

4.2.2 Parameter Identification

To identify the parameters in (4.2), the system is excited by −10% and +10% steps in theinjection time (which corresponds to setting F to 0.9 and 1.1, respectively) and the air/fuel ratiois measured. This is done for the following operating points:

mβ ∈ [0.01 0.015 0.02 0.025] kg/s (4.3)

ωe ∈ [1500 2000 2500] rpm (4.4)

The air mass flow is kept constant using the controller developed in Chapter 3. A typical responseis depicted in Figure 4.4. It can be seen that the dynamics can be described very well by a first-order lag system with a delay. Furthermore, the steady-state value of λ does not equal 1, becauseboth the estimation of the air mass flow and the feedforward controller have some errors. It canalso be noted that the gain does not exactly equal −1, since the sensitivity to a 10% input changeis different depending on the direction. Nevertheless, the deviations are small, so it does not posea problem to the design of the controller.

Figure 4.4: Step responses of the air/fuel ratio system at mβ = 0.02 kg/s and ωe = 2000 rpm.

Page 45: Iterative Learning Control for Internal Combustion Engines

Chapter 4. Air/Fuel Ratio: Modelling and Control 33

The MATLAB functions iddata and pem from the System Identification Toolbox are again usedto fit the parameters of (4.2) to the experimental data. In [12] and [25], the time constant τ andtime delay Td are identified and shown as a map that depends on the rotational speed and airmass per engine cycle mβ. If instead the air mass flow mβ is used as an independent variable,then the influence of the rotational speed is very small and thus negligible. This can be explainedby the fact that the transport delay is generally much larger than the delay due to the enginecycle. In fact, the ratio Td/τseg is always larger than 5.

Figure 4.5 shows the identified time constant τ and time delay Td for various air mass flowsand rotational speeds. The average of each group of measurements is used for the linear in-terpolation. These values are listed in Table 4.1. It is yet unclear why the time constant issubstantially higher at 1500 rpm and mβ = 0.02 kg/s.

Figure 4.5: Time constant τ and time delay Td for various air mass flows. Four measurementsare made per rotational speed. The solid black line shows the linear interpolation.

Table 4.1: Average values of the time constant τ and time delay Td.

mβ [kg/s] τ [s] Td [s]0.01 0.1472 0.20840.015 0.1023 0.15100.02 0.0742 0.12110.025 0.0629 0.1185

Page 46: Iterative Learning Control for Internal Combustion Engines

Chapter 4. Air/Fuel Ratio: Modelling and Control 34

4.3 Control System Design

4.3.1 Structure

An internal model control (IMC) structure is chosen, which offers an intuitive control designprocedure and allows for a natural handling of the time delay. The control structure of the IMCis depicted in Figure 4.6.

y

r

d

ye

P (s)

Q(s) P (s)

C′

ue

Figure 4.6: Control structure of the internal model control.

The overall controller C′(s) consists of an internal controller Q(s) and an internal model ofthe plant P (s), hence the name. Again, the hat · denotes an estimation. The complementarysensitivity T (s) can be written as

T (s) =P (s)Q(s)

1 + (P (s) − P (s))Q(s)(4.5)

In the case of perfect model matching, i.e. when P (s) = P (s), the closed-loop transfer functionbecomes

T (s) = P (s)Q(s) (4.6)

The design of the internal controller Q(s) is explained in [12] (Section 4.3.4) and the result is

Q(s) = −τs + 1Td

σ s + 1(4.7)

where σ is a tuning parameter for the bandwidth of the control system and the minus sign comesfrom the gain of P (s). Combining (4.2), (4.6) and (4.7), the nominal complementary sensitivitycan now be written as

T (s) =1

Td

σ s + 1· e−sTd (4.8)

and the nominal open-loop transfer function L(s) can be calculated as

L(s) =T (s)

1 − T (s)=

e−sTd

Td

σ s + 1 − e−sTd

(4.9)

Finally, the sensitivity function S(s) is calculated as

S(s) =Td

σ s + 1 − e−sTd

Td

σ s + 1(4.10)

Page 47: Iterative Learning Control for Internal Combustion Engines

Chapter 4. Air/Fuel Ratio: Modelling and Control 35

4.3.2 Tuning

Figure 4.7 shows the Nyquist plot of the nominal open-loop gain L(jω) for different values of σ.The shape of the Nyquist curve is independent of the plant parameters, because L(s) does notdepend on τ and Td only appears as a factor for the Laplace variable s. The higher the parameterσ is chosen, the more derivative control action is required to achieve a higher bandwidth, whichleads to bubbles in the right half plane of the Nyquist plot. The dashed line shows the limit asσ → ∞, which comes from the fact that the real part of L(s) is greater than or equal to −0.5.Therefore, a phase margin of at least 60◦ and a gain margin of at least 2 is guaranteed, althoughthis is only valid for perfect model matching. In reality, perfect model matching cannot be

Figure 4.7: Nyquist plot of the nominal open-loop gain L(jω) for different values of σ. Thedashed line shows the Nyquist curve for σ → ∞.

achieved, and so L(s) must be directly calculated from (4.5). Whereas the shape of the Nyquistcurve does not change substantially due to a mismatch of the time constant τ , the open-loopgain is sensitive to errors in the estimated time delay Td. Figure 4.8 shows the Nyquist plot ofthe open-loop gain L(jω) for σ = 1 and different values of the estimated time delay. It can beseen that an underestimation of the delay, i.e. Td < Td, is more severe than an overestimation.Nonetheless, sufficient robustness is retained for small values of σ.

4.3.3 Emulation

The controller is discretized using a bilinear transform1 for the implementation on the hardware.A rule of thumb from [11] states that the sampling time Ts should be at least ten times fasterthan the cross-over frequency ωc of the open-loop:

Ts

!≤

1

10

ωc(4.11)

The largest cross-over frequency corresponds to the largest parameter σ and the smallest timedelay Td. Taking the worst case σ = 4 and Td = 0.11 s and using (4.9), the cross-over frequencyis calculated to be ωc = 7.6 rad/s and therefore

Ts

!≤ 82.7 ms (4.12)

1Bilinear or Tustin transform: s = 2

Ts

z−1

z+1

Page 48: Iterative Learning Control for Internal Combustion Engines

Chapter 4. Air/Fuel Ratio: Modelling and Control 36

Figure 4.8: Nyquist plot of the open-loop gain L(jω) for σ = 1 and different values of theestimated time delay Td.

The controller will be synchronised with the engine’s reciprocating behaviour, and therefore thesampling time Ts is chosen to be equal to the segment time τseg in (2.1). The largest segmenttime occurs at the minimum rotational speed ωe ≈ 700 rpm, which gives τseg = 57 ms andtherefore (4.12) is always satisfied.

The discretisation of the internal model (4.2) and the internal controller (4.7) using the Tustintransform are given below.

P (z) =Y (z)

U(z)=

b1z + b0

a1z + a0· z−kd (4.13)

y(k) =1

a1[b1u(k − kd) + b0u(k − kd − 1) − a0y(k − 1) (4.14)

Q(z) =U(z)

E(z)=

a1z + a0

c1z + c0(4.15)

u(k) =1

c1[a1e(k) + a0e(k − 1) − c0u(k − 1)] (4.16)

The values for the parameters are

a0 = Ts − 2τ

a1 = Ts + 2τ

b0 = Ts

b1 = Ts

c0 = Ts − 2Td/σ

c1 = Ts + 2Td/σ(4.17)

and the number of samples kd of the delay is calculated with (1.54). This inevitably leads to anerror in the time delay that is actually used for the controller. The largest errors occur at lowrotational speeds and high air mass flows, i.e. when the segment time is large and the time delaysmall. For example, at ωe = 888 rpm and when mβ > 0.02 kg/s, the values are τseg = 45 ms and

Td = 0.11 s, so that the ratio Td/Ts = 2.44 is rounded off to 2. This means that Td ≈ 0.82 Td,which is the worst underestimation that occurs due to sampling. Nonetheless, according to Fig-ure 4.8, sufficient robustness is retained, even for a 50% mismatch. Therefore, it can be concludedthat the rounding in (1.54) does not have a detrimental effect on the performance and robustnessof the controller.

Page 49: Iterative Learning Control for Internal Combustion Engines

Chapter 4. Air/Fuel Ratio: Modelling and Control 37

The plant (4.2) is discretized using its zero-order hold (ZOH) equivalent, which yields

P (z) =1 − X

z − X· z−kd with X = e−

Ts

τ (4.18)

and the discrete-time sensitivity functions can now be calculated. The correct way to calculatethese is by using the discrete-time variant of (4.5), even in the nominal case, because P (s) andP (s) are discretized using different methods. However, calculating the complementary sensitivityfunction with T (z) = P (z)Q(z) results in a negligible difference when looking at the Bode plotsand step responses. An even simpler approach is to discretize (4.8) and (4.10) directly usingtheir ZOH equivalents. Also in this case the difference is negligible and hence this approach willbe used. The resulting discrete-time nominal complementary sensitivity is

T (z) =1 − Y

z − Y· z−kd with Y = e

−σTs

Td (4.19)

and the discrete-time sensitivity S(z) is calculated as

S(z) = 1 − T (z) =zkd+1 − Y zkd − (1 − Y )

zkd+1 − Y zkd

(4.20)

4.3.4 Implementation

The amount of injected fuel, and thus the air/fuel ratio, can only be changed every time a cylinderstarts a new intake stroke, which happens each engine segment. Therefore, it makes sense tosynchronise the controller with the engine’s reciprocating behaviour. The synchronisation isaccomplished by using the one-segment trigger, which is created from each first half-segmenttrigger of the ECU, as explained in Section 2.3. Therefore, the controller is sampled with Ts =τseg .

4.4 Experimental Results

The performance of the control system is tested on the engine test-bench. To this end, an inputdisturbance signal d is applied to the system, as shown in Figure 4.6. The disturbance is definedas

d =

+10%, if t ∈ [2, 4) s

−10%, if t ∈ [6, 8) s

0, otherwise

(4.21)

These steps mimic the disturbances that occur when the air mass flow is changed.

The controller is tested for different σ and the disturbance response is examined, see Figure4.9. In general, the simulations correspond very well to the behaviour of the physical system.However, some overshoot occurs at t ≈ 5 s, and this effect is more pronounced for higher σ, i.e.when the bandwidth of the system is larger. The system even exhibits oscillations when σ > 2,and at the same time the noise mentioned in Subsection 4.1.3 is amplified when the engine runsat low rotational speeds. The overshoot and onset of oscillations are most likely due to a mis-match of the time delay, and in particular Td < Td. Also unmodelled sensor dynamics could playa role. But in spite of these effect, excellent robustness is achieved for σ ≤ 1.

Page 50: Iterative Learning Control for Internal Combustion Engines

Chapter 4. Air/Fuel Ratio: Modelling and Control 38

Figure 4.9: Disturbance response of the air/fuel ratio control system at mβ = 0.02 kg/s andωe = 2000 rpm, for different values of the tuning parameter σ. Four measurements (black) aremade for each plot and compared to the simulation (red).

Next, the controller with σ = 0.5 is tested at different rotational speeds. The same disturbancesteps are applied and the results are shown in Figure 4.10. The response is almost identical fordifferent rotational speeds. At 1500 rpm, the response is somewhat slower, and also more noiseis present, as mentioned in Subsection 4.1.3.

Finally, the controller is tested at different air mass flows. At the same time, σ is chosen suchthat the ratio Td

σ remains constant. This means that the same closed-loop dynamics are ob-tained, as can be seen from (4.8). The controller may not, however, become too aggressive,and the aforementioned limit of σ ≤ 1 is used to ensure good robustness. The ratio is chosenas 0.24, which is based on σ = 0.5 and mβ = 0.02 kg/s, where Td = 0.12 s. The range forthe tuning parameter can be calculated with the time delays given in Table 4.1 and this yields0.49 < σ < 0.88. Therefore, the control system has sufficient robustness. Figure 4.11 shows thedisturbance response of the system at different air mass flows. The simulations correspond verywell to the behaviour of the physical system.

For the remainder of this thesis, the tuning parameter is taken as σ = Td

0.24 .

Page 51: Iterative Learning Control for Internal Combustion Engines

Chapter 4. Air/Fuel Ratio: Modelling and Control 39

Figure 4.10: Disturbance response of the air/fuel ratio control system with σ = 0.5 at mβ =0.02 kg/s and different rotational speeds ωe. Four measurements (black) are made for each plotand compared to the simulation (red).

4.5 Conclusions

In this chapter, a control system for the air/fuel ratio was designed. The system was modelledand the parameters were identified. The controller was designed and implemented on the enginetest-bench and experiments were carried out to test the control system. The following conclusionscan be made:

• The controller has good performance and robustness over a large range of operating points.

• Apart from the time delay, the response of the closed-loop system is virtually identical forall operating points. The nominal complementary sensitivity is

T (s) =1

0.24 s + 1· e−s Td (4.22)

The result of the last conclusion was achieved by successfully applying internal model controland an appropriate choice of the tuning parameter. It greatly simplifies the design of an iterativelearning control algorithm, because it requires only one update law to be designed and imple-mented. However, the time delay still depends on the operating point of the engine. Moreover,it could not be identified as accurately as for the air mass flow system. This might make theiterative learning control for the air/fuel ratio system more challenging in practice.

Page 52: Iterative Learning Control for Internal Combustion Engines

Chapter 4. Air/Fuel Ratio: Modelling and Control 40

Figure 4.11: Disturbance response of the air/fuel ratio control system at ωe = 2000 rpm anddifferent air mass flows mβ. The parameter σ is chosen such that the ratio Td

σ remains constant.Four measurements (black) are made for each plot and compared to the simulation (red).

Page 53: Iterative Learning Control for Internal Combustion Engines

Chapter 5

Iterative Learning Control:Practice

In this chapter, iterative learning control is applied to the air mass flow system from Chapter3 and the air/fuel ratio system from Chapter 4. The theory presented in Chapter 1 is used todesign the update laws and the ILC is implemented on the engine test-bench. Experiments arecarried out to assess the feasibility and performance of ILC in practice.

5.1 Implementation

In this section, the implementation of ILC on the engine test-bench is explained. A MATLABscript forms the basis for the calculations of the ILC and its key element is the use of theMATLAB-dSPACE Interface Library (MLIB). This library allows on-line access to the real-timeprogram from within MATLAB. MLIB has a set of ready-made functions that can be used toread data from and send data to the model that runs on the dSPACE board. The input tra-jectory ui+1(k) calculated in the ILC is stored in a lookup table in the Simulink model and theMLIB functions are used to overwrite the data with the new values of the next iteration.

The procedure for using ILC on the engine test-bench is divided into five steps that repeatevery iteration and are described below.

Step 0: Initialisation.Before the ILC procedure is started, the system is initialised. A connection is first madewith the dSPACE board. Then, the type of ILC and the total number of iterations,which are both set by the user in ControlDesk, are read from the real-time program.Finally, the variables necessary for the ILC are calculated and loaded in the MATLABworkspace. These include the desired reference trajectory yd(k), the system descriptionsand the definition of the update law.

Step 1: Load new trajectory.The data in the lookup table is overwritten with the input trajectory ui+1(k) of theILC. In the first iteration, the input trajectory equals the desired reference trajectoryyd(k).

Step 2: Send trigger.A trigger is sent to the model running on the dSPACE board to simultaneously start

41

Page 54: Iterative Learning Control for Internal Combustion Engines

Chapter 5. Iterative Learning Control: Practice 42

the trajectory and a measurement. An option in ControlDesk allows the user to eitherlet the trajectory and measurement start directly, or wait and start at a specified crankangle.

Step 3: Wait.The script waits for the trajectory and measurement to finish, after which a triggeris enabled that is read by MATLAB. An additional pause of a few seconds is used toallow the measurement files to be written to a location of choice.

Step 4: Evaluate measurements.The measurement files are loaded and the relevant data is extracted. The measuredsignals are interpolated, since the Simulink model runs at 1 ms, whereas the ILC usesa sampling time of either 10 ms or τseg .

Step 5: Calculate new ILC input.In this last step, the error signal ei(k) is first calculated using the shifted output as in(1.55). The error signal and update law matrix L are then used to calculate the input ofthe next iteration ui+1(k). If the maximum number of iterations is reached, the scriptterminates and the ILC is finished. Otherwise, the iteration number i is increased byone and the ILC procedure restarts at Step 1.

5.2 Air Mass Flow

5.2.1 Reference Trajectory

The desired reference trajectory yd for the air mass flow system is chosen to have a duration of10 s, and with Ts = 10 ms this corresponds to N = 1000. It is desirable that the trajectorycontains interesting dynamics and covers a wide range of operating points. The choice for yd(k)is a trajectory consisting of five discrete sine waves with different amplitude, as shown in Figure5.1.

Figure 5.1: Desired reference trajectory for air mass flow system.

Page 55: Iterative Learning Control for Internal Combustion Engines

Chapter 5. Iterative Learning Control: Practice 43

5.2.2 System Description

Since serial ILC is considered, the input ui(k) to the ILC system (1.1) is in fact the referencer in Figure 3.9, whereas the output yi(k) equals y. The closed-loop response of the discretizedsystem is thus equivalent to the general ILC system description (1.1) in the sense that

yi(k) = y = T (z) r = P (q) ui(k) (5.1)

There is no signal d(k) that repeats every iteration, because xi(0) = 0 since the system islinearised around yd(0) = 0.01 kg/s and it is assumed that yi(0) = yd(0) for all i. The plantP (z) is found by discretizing the nominal complementary sensitivity in (3.19) without the delay.This is done by calculating the ZOH equivalent, as defined in (3.18), yielding

P (z) =0.01504z + 0.01352

z2 − 1.699z + 0.7273(5.2)

5.2.3 Design

In this section, two different ILC algorithms for the air mass flow system are designed. The firstdesign is based on Theorem 1.8 and is carried out in the frequency domain. The second designis a Q-ILC algorithm, which is defined in the time domain.

For the first design of the ILC system no filter is used, i.e. H(z) = 1, and L(z) is chosento be causal, so that Theorem 1.8 can be used as a design tool. The phase of zL(z)P (z) shouldbe between −90◦ and 90◦, but the minimum phase of zP (z) is −135◦. Therefore, a P-typelearning function cannot be used. A D-type learning function is able to keep the overall phasebetween the limits, but the resulting convergence is very slow. Instead, a lead-lag-type learningfunction is selected such that a good performance of the ILC system is obtained. A good choicefor the learning function is

L(z) =1

15z − 13.57

z + 0.4286(5.3)

which is based on the continuous-time lead-lag compensator 50 · (s + 10)/(s + 500). The bodeplot in Figure 5.2 shows that additional phase of the lead-lag compensator causes zL(z)P (z) tobe within the phase limits. Furthermore, the Nyquist plot in the same figure shows that theNyquist curve of F (z) = 1 − zL(z)P (z) lies within the unit circle and ‖F (z)‖∞ = 0.989 < 1.Therefore, AS and MC are achieved for this ILC system with a lead-lag-type learning function.

As a second design, Q-ILC is used with Q = R = I, which yields σ(F) ≈ 1 < 1 and thus AS andMC are achieved.

5.2.4 Experimental Results

The ILC for the air mass flow system is implemented on the engine test-bench and several exper-iments are carried out to assess both ILC designs. Unless otherwise mentioned, the experimentsare conducted at ωe = 2000 rpm with a total of 25 iterations. After the ILC is finished, the lastinput u25(k) is subsequently used for another ten experiments in order to explore the consistencyof the response of the physical system. The experimental results are compared to a simulation.To make the simulations better represent the situation at the engine test-bench, Gaussian whitenoise with a standard deviation of 0.015 g/s is added to the output yi. As mentioned in Sec-tion 3.4, this amount of noise is always present in steady-state conditions and is assumed to be

Page 56: Iterative Learning Control for Internal Combustion Engines

Chapter 5. Iterative Learning Control: Practice 44

Figure 5.2: Bode plot of learning function and plant dynamics and Nyquist plot of F (z).

uncorrelated. Therefore, it gives a good approximation of the value for the error reduction thatcan be achieved.

Firstly, the lead-lag-type ILC is tested. Figure 5.3 shows a detail of the desired reference trajec-tory yd(k) and measurements of the output of the system yi(k) for the first few iterations. Theoutput y1(k) of the first iteration is delayed due to the first-order lag dynamics of the system.In the subsequent iterations, the input of the system is changed, i.e. the reference is adjusted,and the output yi(k) is seen to "move" towards the desired trajectory. At the tenth iteration,the output seems to have converged, because y10(k) ≈ yd(k).

Figure 5.3: Detail of the desired trajectory yd(k) and the output of the system yi(k) at differentiterations.

Page 57: Iterative Learning Control for Internal Combustion Engines

Chapter 5. Iterative Learning Control: Practice 45

Figure 5.4 shows the results in terms of the logarithm of the error that is normalised by the errorof the first iteration. It can be observed that the ILC of both simulation and measurements areindeed converged after ten iterations. The measurements show that an error reduction of ap-proximately 95% is achieved, whereas the theoretical limit equals 98%. Furthermore, the actualrate of convergence is similar to that of the simulation. Both the higher steady-state error andthe slightly slower convergence are likely to be the result of model uncertainty and the fact thatthe amount of measurement noise might be larger in case of a dynamic trajectory, as opposed tosteady-state conditions.

Another observation is that the error of the ILC fluctuates much more in practice than it doesin theory. In order to find out if these fluctuations are caused by the learning algorithm, thelast input u25(k) is applied and ten more measurements are made. It can be seen in Figure 5.4that the fluctuations are still present, and thus they are not caused by the learning process. Thefluctuations were further investigated and the cause was found to be a mismatch between thedesired inlet valve lift uvvt and the actual position of the actuator uvvt,act. In all probabilitythis is due to the hysteresis of the control system of the actuator, as described in Section 3.4.Since it is unknown how the ECU and its systems are designed, there is no clear remedy for thefluctuations. One has to keep in mind, however, that these variations are very small and thatthe emphasis lies on stability and convergence of the ILC.

Figure 5.4: Performance of the lead-lag-type ILC at ωe = 2000 rpm.

The second design, Q-ILC, is also tested at 2000 rpm and with a total of 25 iterations, afterwhich the last input u25(k) is applied and ten additional measurements are made. The outputand behaviour of the ILC system are found to be very similar to the results in Figure 5.3. Alsothe logarithm of the error, as shown in Figure 5.5, looks almost identical to that of the lead-lag-type ILC. In fact, the same observations can be made, although some differences are visible.The converged error for Q-ILC is, on average, slightly lower than for the lead-lag-type ILC, buton the other hand the fluctuations are larger. These fluctuations are once again present in theadditional measurements with u25(k).

The response of the closed-loop system is designed to be virtually identical for all operatingpoints, which means that the ILC is expected to have the same performance. In order to find out

Page 58: Iterative Learning Control for Internal Combustion Engines

Chapter 5. Iterative Learning Control: Practice 46

Figure 5.5: Performance of the Q-ILC at ωe = 2000 rpm.

whether this is correct, the Q-ILC system is tested at two other rotational speeds and the resultsare compared. The performance of the Q-ILC at ωe = 1500, 2000 and 2500 rpm is shown inFigure 5.6. The convergence rate and average converged error are almost identical. Apparently,the rather large uncertainty in the time constant τ mentioned in Subsection 4.2.2 does not havea significant effect on the ILC.

Figure 5.6: Comparison of Q-ILC at different rotational speeds.

The above experiments showed that both the lead-lag type ILC and Q-ILC have good perfor-mance in terms of convergence rate and error reduction. Furthermore, the simulations corre-sponded very well to the practical ILC on the engine test-bench. Finally, the performance ofQ-ILC was found to be very similar at different rotational speeds.

Page 59: Iterative Learning Control for Internal Combustion Engines

Chapter 5. Iterative Learning Control: Practice 47

5.3 Air/Fuel Ratio

5.3.1 Reference Trajectory

The purpose of the air/fuel ratio control system is to keep λ close to 1 under the presence ofdisturbances. Thus, a logical choice for the desired reference trajectory is yd(k) = λd = 1 forall k and ILC is used to learn and counteract the disturbance. For the air/fuel ratio system, kdenotes the number of engine segments instead of the discrete time. The disturbance d is definedas follows. A base signal is defined as

d∗ =

+10%, if k ∈ [75, 149)

−10%, if k ∈ [225, 299)

0, otherwise

(5.4)

which coincides with (4.21) when ωe = 1500 rpm. The base signal d∗ is then smoothed usingthe MATLAB function filtfilt and a segment-based first order filter. The smoothed signal isused for the disturbance d, and a detail is shown in Figure 5.7.

Figure 5.7: Detail of the base signal d∗ and smoothed disturbance d that is used for the Q-ILC.

5.3.2 System Description

Since serial ILC is considered, the input ui(k) to the ILC system (1.1) is in fact the referencer in Figure 4.6, whereas the output yi(k) equals y. The closed-loop response of the discretizedsystem is equivalent to the general ILC system description (1.1):

y = T (z)︸︷︷︸

P (q)

r + S(z)P (z) d︸ ︷︷ ︸

d(k)

(5.5)

Notice that the repeating disturbance is captured in d(k). P (z) and S(z) are given by (4.18)and (4.20), respectively. Furthermore, xi(0) = 0 since the system is linearised around yd(0) = 1and it is assumed that yi(0) = yd(0) for all i. The plant P (z) for the ILC is taken directly from(4.19) but without the time delay:

P (z) =0.07996

z − 0.92(5.6)

Page 60: Iterative Learning Control for Internal Combustion Engines

Chapter 5. Iterative Learning Control: Practice 48

5.3.3 Design

The phase of zP (z) is already between −90◦ and 90◦, so a simple P-type learning filter can beused. Selecting the learning gain βP = 1 and setting H(z) = 1, both AS and MC are achievedsince ‖F (z)‖∞ = 0.958 < 1. As a second design, Q-ILC is used with Q = R = I, which yieldsσ(F) = 0.998 < 1 and thus AS and MC are achieved.

5.3.4 Experimental Results

The ILC for the air/fuel ratio system is implemented on the engine test-bench and several exper-iments are carried out to assess both ILC designs. Unless otherwise mentioned, the experimentsare conducted at ωe = 2000 rpm and mβ = 0.02 kg/s. A total of 50 iterations is used and theexperimental results are compared to a simulation. No artificial noise is added to the simulationoutput, because the noise of the air/fuel ratio system is not normally distributed. Furthermore,the amount and frequency content of the noise depend on the operating point of the engine.

Firstly, the results of the P-type learning function are discussed. The P-type ILC is found tobe unstable when tested on the engine, as can be seen in Figure 5.8, which shows the output ofthe system as the number of iterations increases. This could be caused by a mismatch between

Figure 5.8: Unstable output of the system using P-type ILC.

the actual and estimated time delay. On the one hand, the performance of the air/fuel ratiocontrol system is deteriorated, but the results in Section 4.4 did not show a significant amountof reduction in performance. On the other hand, the P-type ILC is, also in theory, sensitivityto a mismatch between Td and Td. In fact, the unstable ILC in practice can be approximatelyreproduced by a simulation in which the actual time delay is 25% higher than the estimated timedelay, i.e. Td = 1.25 · Td. This scenario is not unthinkable considering the rather large spreadof identified values in Figure 4.5. Several simulations have shown that an underestimation isgenerally worse than an overestimation of the time delay. In both cases the ILC will be unsta-ble, but if the time delay is overestimated, a considerable error reduction can often be achievedbefore the error increases again. Therefore, the P-type ILC is again tested on the engine, butthe estimation of the time delay is increased by 20%. This time the ILC is found to be stable,at least for the total number of iterations considered.

Page 61: Iterative Learning Control for Internal Combustion Engines

Chapter 5. Iterative Learning Control: Practice 49

The results for the unstable and stable P-type ILC in terms of the logarithm of the error areshown in Figure 5.9. The unstable ILC initially shows a small error reduction, followed by theonset of oscillations of the output yi(k) that then rapidly increase in amplitude, as shown inFigure 5.8. The experiment is aborted after the 20th iteration. The stable P-type ILC, for whichTd is increased by 20%, has a convergence rate that is very similar to that of the simulation.After 10 iterations, the noise becomes an important factor, i.e. the signal-to-noise ratio is signif-icantly decreased, which results in fluctuations in the logarithmic error. The ILC is convergedafter approximately 30 iterations and the error reduction is around 92%.

Figure 5.9: Performance of the unstable and stable (Td + 20%) P-type ILC.

The second design, Q-ILC, is tested at the same operating conditions, but no change in theestimated delay time is made. Figure 5.10 shows the logarithm of the error of the measurementsand a simulation for comparison. An error reduction of around 95% is achieved, and the conver-gence rate is almost identical to that of the simulation. Even more important is the observationthat the Q-ILC system is more robust to mismatches in the time delay. This is confirmed bysimulations, which have shown that a 25% increase or decrease of the estimated time delay doesnot have a significant effect on the performance of the ILC. The reason why Q-ILC has goodrobustness properties in case of an uncertainty in the time delay is still unclear.

The input ui(k) = λd and output yi(k) = λ of the Q-ILC system at various stages of the learningprocess is shown in Figure 5.11. The first output is the normal disturbance response of theair/fuel ratio system, as studied in Section 4.4. In the subsequent iterations, the reference λd

is adjusted and counteracts the disturbance. After roughly 30 iterations, the ILC system has"learned" the disturbance and λ ≈ 1.

Except for the time delay, the response of the closed-loop system is designed to be the same forall operating points, and thus the ILC is expected to have the same performance. In order toconfirm this, the Q-ILC system is tested at another operating point and the results are compared.Since Td and τ virtually only depend on the air mass flow, the same rotational speed is chosen,but a lower air mass flow of mβ = 0.01 kg/s is selected, where Td = 0.21 s. As mentionedin Section 4.4, the tuning parameter is selected such that the same closed-loop dynamics areobtained, and consequently σ = 0.875. Figure 5.12 shows the performance of the Q-ILC at two

Page 62: Iterative Learning Control for Internal Combustion Engines

Chapter 5. Iterative Learning Control: Practice 50

Figure 5.10: Performance of the Q-ILC at ωe = 2000 rpm and mβ = 0.02 kg/s.

Figure 5.11: Output (top) and input (bottom) of the Q-ILC system at different iterations.

Page 63: Iterative Learning Control for Internal Combustion Engines

Chapter 5. Iterative Learning Control: Practice 51

different air mass flows. The measurements of the ILC system at mβ = 0.01 kg/s show largerfluctuations of the error, whereas the average converged error is slightly lower. Compared tothe air mass flow system, the model uncertainties of the air/fuel ratio system are higher. Asa logical consequence, larger differences are expected for the ILC in practice. In spite of theseobservations, the overall convergence is found to be consistent. Therefore, the ILC is expectedto have the same performance at other operating points.

Figure 5.12: Comparison of Q-ILC at different air mass flows.

So far the convergence of the ILC system for the air/fuel ratio was rather slow. Another Q-ILCis designed that has a faster convergence rate and this ILC is tested on the engine. To this endthe tuning parameter of the error weight matrix is increased so that Q = 5 · I and R = I. Theresults of this Q-ILC are shown in Figure 5.13. It can be seen that the convergence is indeedfaster than for the Q-ILC with Q = I. A more important observation is that the ILC systemis still stable, even though the learning is much more aggressive. The converged input of theslow and fast Q-ILC is shown in Figure 5.14. It can be seen that the converged input of the

Figure 5.13: Comparison of the performance of the slow and fast Q-ILC.

Page 64: Iterative Learning Control for Internal Combustion Engines

Chapter 5. Iterative Learning Control: Practice 52

fast system contains more high frequency content, which comes from the noise that is amplifiedby the update law. As a consequence, also the converged output contains more noise and theerror reduction that can be achieved is therefore reduced. The question arises how fast, i.e. howa aggressive, the ILC can be made before it gets unstable and how it influences the maximumpossible error reduction. This could be a topic for further research.

Figure 5.14: Converged output of the slow and fast Q-ILC.

Until this point, an artificial disturbance was applied to the air/fuel ratio system. This has beenof great value in the aforementioned experiments, for it allowed the experimental results to becompared to the theory in the form of a simulation. In reality, however, the disturbance of theair/fuel ratio system comes from a changing air mass flow. An interesting question is if and howwell these disturbances can be learned. To this end, the air mass flow trajectory from Figure 5.1is used and the disturbance that occurs for the air/fuel ratio is learned with Q-ILC. The systemis tested on the engine at 2000 rpm and Figure 5.15 shows the input and output at differentiterations. It can be seen that the disturbance is successfully learned, because the deviationsfrom λ = 1 decrease as the number of iterations increases. However, the converged output signalstill contains some fluctuations. It is unclear why these deviations, which are significantly largerthan the normal noise, are not learned. A possible explanation is the fact that the air mass flowsystem runs at 10 ms and is therefore not synchronised with the engine segments. At 2000 rpm,the segment time is 20 ms, but small deviations in the rotational speed may increase or decreasethis time. Therefore it cannot be guaranteed that the same air mass flow is used for the sameengine segment. To find out if this really is the problem and to find a suitable solution are topicsfor further research. Figure 5.16 shows the results in terms of the logarithm of the error. Theconvergence is stable and comparable to the results of the previous experiments.

Page 65: Iterative Learning Control for Internal Combustion Engines

Chapter 5. Iterative Learning Control: Practice 53

Figure 5.15: Learning of the disturbances due to a changing mβ .

Figure 5.16: Learning of the disturbances due to a changing mβ .

Page 66: Iterative Learning Control for Internal Combustion Engines

Chapter 5. Iterative Learning Control: Practice 54

5.4 Conclusions

In this chapter, iterative learning control was successfully applied to the air mass flow systemand the air/fuel ratio system. For the former, a lead-lag-type ILC and Q-ILC algorithm weredesigned, whereas for the latter a P-type and Q-ILC update law were applied. The ILC algorithmwas implemented on the engine test-bench and several experiments were carried out to test ILCin practice. The following conclusions can be made.

• Both types of ILC for the air mass flow system were stable and achieved excellent perfor-mance in terms of the convergence rate and error reduction.

• The stability of the P-type ILC for the air/fuel ratio system was found to be sensitive toa mismatch between the actual and estimated time delay.

• The Q-ILC for the air/fuel ratio system showed excellent robustness and had good per-formance. A more aggressive form of Q-ILC resulted in a much faster convergence whileremaining stable.

• Q-ILC was used for the air/fuel ratio system to successfully learn a disturbance that wascaused by a changing air mass flow.

• The measurements of the ILC for both control systems corresponded very well to thetheoretical simulations. This proves that the theory can be conveniently used to designILC algorithms that are to be applied to engine systems.

• The ILC for both control systems performed virtually the same at different operating points.On the one hand, this proves that the engine systems were accurately identified. On theother hand, it shows that if the closed-loop dynamics are the same, also the ILC perfor-mance will be the same. Even though this is not surprising theoretically, it is importantto have demonstrated that this result is also obtained in practice.

Page 67: Iterative Learning Control for Internal Combustion Engines

Chapter 6

Conclusions and Outlook

6.1 Conclusions

The objective of this thesis was to design and implement iterative learning control for the airmass flow and air/fuel ratio control systems of an SI engine and to test the performance of ILCon the engine test-bench. An estimation model for the air mass flow was developed that provedto be very accurate. After the system dynamics were identified, a control system was designedand implemented on the engine test-bench. Gain scheduling was successfully used to obtainthe same closed-loop dynamics for the operating points of interest. Subsequently, the air/fuelratio system was modelled, the parameters were identified and a control system was designed.Apart from the time delay, the same closed-loop dynamics were obtained by using an internalmodel control structure and an appropriate choice of the tuning parameter. Several experimentsshowed that both control systems have good performance and robustness over a large range ofoperating points. In the last part of the thesis, several ILC algorithms were designed for bothcontrol systems and implemented on the engine test-bench. Numerous experiments were carriedout to assess the feasibility and performance of the ILC in practice. The following conclusionscan be made:

• Iterative learning control was successfully applied to both control systems. The stabilityand performance in terms of convergence rate and error reduction were found to be verygood.

• The behaviour of the iterative learning control for both control systems on the enginetest-bench corresponded very well to simulations. This proves that the theory can beconveniently used to design iterative learning control algorithms that are to be applied toengine systems.

• The iterative learning control for both control systems performed virtually the same atdifferent operating points. This demonstrated that the behaviour of both the controlsystems and the applied iterative learning control algorithms are consistent.

55

Page 68: Iterative Learning Control for Internal Combustion Engines

Chapter 6. Conclusions and Outlook 56

6.2 Outlook

The emphasis of this thesis was placed on the implementation of iterative learning control onan engine test-bench and to prove the feasibility of iterative learning control for two importantengine control systems. Valuable experience was gained in this process and several ideas forfurther research were collected. The most important ones are summarised below:

• In this thesis, only the serial ILC arrangement was analysed and tested, since it allows for astraightforward implementation. An interesting alternative is the parallel ILC arrangementas shown in Figure 1.2. In this architecture, the input to the plant is altered directlyby the ILC algorithm, and is essentially a learning feedforward controller. Therefore, theinformation that is gathered by this learning algorithm may be more intuitive. An exampleis the air/fuel ratio system, were it is more logical to improve the feedforward controllerthrough learning than to change the reference. Further research could be focussed on thedesign and implementation of parallel ILC. The feasibility and performance of this typeof ILC on some engine control systems could be investigated and the differences betweenserial and parallel ILC could be demonstrated.

• In this thesis, the model uncertainties, disturbances and measurement noise were not ex-plicitly taken into account in the theory and design of ILC. However, the experimentscarried out in this thesis showed that the various ILC algorithms have different robustnessproperties. For example, the P-type update law was found to be very sensitive to a mis-match between the estimated and actual time delay of the system, whereas the Q-ILC hadan excellent overall robustness. It is yet unclear how the model uncertainties and noise canbe formally included in the design of ILC and how the stability margins should be defined.This is another possible topic for further research.

• After an ILC algorithm has converged and the desired reference trajectory is learned, theconverged input trajectory u∞(k) contains valuable information about the system. In thecase of parallel ILC, for instance, the optimal feedforward signal is learned. The questionarises how to extract this information from the converged ILC output. In the literature,this is called knowledge transfer and several strategies are used, see e.g. [13]. A topic forfurther research could to investigate which type of knowledge transfer is particularly suitedfor engine systems and to put this theory into practice.

• In this thesis, the control systems were designed in such a way that the same closed-loopdynamics were obtained for a wide range of operating points. This greatly simplified thedesign of the ILC algorithms, because it required only one update law to be designed andimplemented. This was done to prove the consistency of both the control system and theILC algorithms in practice. However, the general idea of using ILC is to learn the dynamicsof the system through repetition, thereby substantially reducing the effort of modelling andidentifying the system. Therefore, the following scenario could be further investigated. Asingle and simplified model of the system is selected that describes the dynamics over alarge range of operating points reasonably well. Subsequently, a slow but very robustfeedback control system is designed. An ILC algorithm is then designed that has goodrobustness properties in order to cope with the rather large model uncertainties. Finally,this ILC can be implemented on an engine test-bench and used to learn the dynamics ofthe system over a large range of operating points. Obviously, this requires a thoroughunderstanding of robustness of ILC algorithms and therefore this would be the last topicfor further research.

Page 69: Iterative Learning Control for Internal Combustion Engines

Bibliography

[1] Khalid Abidi and Jian-Xin Xu. Iterative learning control for sampled-data systems: fromtheory to practice. IEEE Transactions on Industrial Electronics, 58(7):3002–3015, 2011.

[2] Hyo-Sung Ahn, Kevin L Moore, and YangQuan Chen. Iterative learning control: robustnessand monotonic convergence for interval systems. Springer, 2007.

[3] Notker Amann, David H Owens, and Eric Rogers. Iterative learning control for discrete-time systems with exponential rate of convergence. IEEE Proceedings-Control Theory andApplications, 143(2):217–224, 1996.

[4] Suguru Arimoto. A brief history of iterative learning control. In Iterative learning control,pages 3–7. Springer, 1998.

[5] Suguru Arimoto, Sadao Kawamura, and Fumio Miyazaki. Bettering operation of robots bylearning. Journal of Robotic systems, 1(2):123–140, 1984.

[6] Michael Baumann. Lambda feedback control of a turbocharged hybrid pneumatic engine.Bachelor’s thesis, ETH Zürich, 2010.

[7] Zeungnam Bien and Jian-Xin Xu. Iterative learning control: analysis, design, integrationand applications. Springer, 1998.

[8] Douglas A Bristow, Marina Tharayil, and Andrew G Alleyne. A survey of iterative learningcontrol. IEEE Control Systems Magazine, 26(3):96–114, 2006.

[9] Vinicius De Oliveira and Alireza Karimi. Robust smith predictor design for time-delaysystems with h infinity performance. In Proceedings of the IFAC Joint Conference, numberEPFL-CONF-169923, 2013.

[10] Dick De Roover and Okko H Bosgra. Synthesis of robust multivariable iterative learning con-trollers with application to a wafer stage motion system. International Journal of Control,73(10):968–979, 2000.

[11] Lino Guzzella. Digital control systems, lecture materials, ETH Zürich, 2013.

[12] Lino Guzzella and Christopher Onder. Introduction to modeling and control of internalcombustion engine systems. Springer, 2009.

[13] Michael Hamer, Markus Waibel, and Raffaello D’Andrea. Knowledge transfer for high-performance quadrocopter maneuvers. In 2013 IEEE/RSJ International Conference onIntelligent Robots and Systems (IROS), pages 1714–1719. IEEE, 2013.

[14] Joao P Hespanha. Linear systems theory. Princeton university press, 2009.

57

Page 70: Iterative Learning Control for Internal Combustion Engines

[15] Hongsheng Li, Yang Quan Chen, Jianhua Zhang, and Xiulan Wen. A tuning algorithmof pd-type iterative learning control. In 2010 Chinese Control and Decision Conference(CCDC), pages 1–6. IEEE, 2010.

[16] D Meng, Y Jia, J Du, and F Yu. Learning control for time-delay systems with iteration-varying uncertainty: a smith predictor-based approach. IET Control Theory & Applications,4(12):2707–2718, 2010.

[17] Julio E Normey-Rico. Control of dead-time processes. Springer, 2007.

[18] Mikael Norrlöf. On analysis and implementation of iterative learning control, 1998.

[19] Mikael Norrlöf. Iterative Learning Control–Analysis, Design, and Experiments. PhD thesis,Linköpings universitet, 2000.

[20] Mikael Norrlöf and Svante Gunnarsson. Time and frequency domain convergence propertiesin iterative learning control. International Journal of Control, 75(14):1114–1126, 2002.

[21] David H Owens and Jari Hätönen. Iterative learning control - an optimization paradigm.Annual Reviews in Control, 29(1):57–70, 2005.

[22] Francois Padieu and Renjeng Su. An h-infinity approach to learning control systems. In-ternational Journal of Adaptive Control and Signal Processing, 4(6):465–474, 1990.

[23] Minh Q Phan, Richard W Longman, and Kevin L Moore. Unified formulation of lineariterative learning control. Advances in the Astronautical Sciences, 105:93–111, 2000.

[24] Wilson J Rugh. Linear system theory, volume 2. Prentice-Hall, Inc., 1996.

[25] Daniel Rupp. Model-based adaptive air/fuel ratio control for an automotive gasoline engine.PhD thesis, ETH Zürich, 2009. Dissertation no. 18302.

[26] Sigurd Skogestad and Ian Postlethwaite. Multivariable feedback control: analysis and design,2nd edition. Wiley New York, 2007.

[27] Jian-Xin Xu, Qiuping Hu, Tong Heng Lee, and Shigehibo Yamamoto. Iterative learningcontrol with smith time delay compensator for batch processes. Journal of Process Control,11(3):321–328, 2001.

[28] Juan Yuz and Graham C Goodwin. Sampled-data models for linear and nonlinear systems.Springer, 2013.

Page 71: Iterative Learning Control for Internal Combustion Engines

Institute for Dynamic Systems and Control

Prof. Dr. R. D’Andrea, Prof. Dr. L. Guzzella

Title of work:

Iterative Learning Control for Internal Combustion Engines

Thesis type and date:

Master’s thesis, April 2015

Supervision:

Norbert ZsigaProf. Dr. Lino Guzzella

Student:

Name: Stijn van DoorenE-mail: [email protected].: 11-910-098Semester: 10

Statement regarding plagiarism:

By signing this statement, I affirm that I have read and signed the Declaration of Originality,independently produced this paper, and adhered to the general practice of source citation in thissubject-area.

Declaration of Originality:

http://www.ethz.ch/faculty/exams/plagiarism/confirmation_en.pdf

Zurich, 1. 5. 2015: