15
Control of batch product quality by trajectory manipulation using latent variable models Jesus Flores-Cerrillo, John F. MacGregor * Department of Chemical Engineering, McMaster University, Hamilton, Ontario, Canada L8S4L7 Received 25 June 2003; received in revised form 22 September 2003; accepted 22 September 2003 Abstract A novel inferential strategy for controlling end-product quality properties by adjusting the complete trajectories of the ma- nipulated variables is presented. Control through complete trajectory manipulation using empirical models is possible by controlling the process in the reduce space (scores) of a latent variable model rather than in the real space of the manipulated variables. Model inversion and trajectory reconstruction is achieved by exploiting the correlation structure in the manipulated variable trajectories captured by a partial least squares model. The approach is illustrated with a condensation polymerisation example for the pro- duction of nylon and with data gathered from an industrial emulsion polymerisation process. The data requirements for building the model are shown to be modest. Ó 2003 Elsevier Ltd. All rights reserved. Keywords: Product quality; Partial least squares; Reduced space control 1. Introduction Batch/semi-batch processes are commonly used be- cause their flexibility to manage many different grades and types of products. In these processes, it is necessary to achieve tight final quality specifications. However, this is not easily achieved because batch operations suffer from constant changes in raw material properties, variations in start-up initialisation, and in operating conditions, all of which introduce disturbances in the final product quality. Moreover, compensating for these disturbances is difficult due to the non-linear behaviour of the chemical reactors and to the fact that robust on- line sensors for monitoring quality variables are rarely available. Control of product quality usually requires the on- line adjustment of several manipulated variable trajec- tories (MVTs) such as the pressure and temperature trajectories. Several approaches based on detailed theoretical models have been presented. These can generally be divided into two groups, the first based on non-linear differential geometric control, and the second based on on-line optimization. The differential geometric approaches [1–3] use the non-linear model to perform a feedback transformation that linearizes the system and then linear control theory can be applied. Examples in the literature include the control of final latex properties such as instantaneous copolymer composition, conversion and weight average molecular weight common in the emulsion polymerisa- tion of styrene–butadiene [1], and the control of co- polymer composition and weight average molecular weight for the free radical polymerisation of vinyl ace- tate/methyl methacrylate reaction [2]. In on-line optimization, optimal trajectories are pe- riodically recomputed at various instances throughout the batch to optimize some final quality and/or perfor- mance measure. Some examples include Crowley and Choi [4] for the on-line control of molecular weight distribution and conversion on the free radical poly- merisation of methyl methacrylate, and Ruppen et al. [5] for on-line batch time minimization and conversion control in an experimental set-up. In both approaches control action was obtained using sequential quadratic programming methods at several time intervals. In spite of the significant literature addressing the trajectory control of batch processes, many of these * Corresponding author. Tel.: +1-905-525-9140x24951; fax: +1-905- 521-1350. E-mail address: [email protected] (J.F. MacGregor). 0959-1524/$ - see front matter Ó 2003 Elsevier Ltd. All rights reserved. doi:10.1016/j.jprocont.2003.09.008 Journal of Process Control 14 (2004) 539–553 www.elsevier.com/locate/jprocont

Control of batch product quality by trajectory manipulation using latent variable models

Embed Size (px)

DESCRIPTION

 

Citation preview

Page 1: Control of batch product quality by trajectory manipulation using latent variable models

Journal of Process Control 14 (2004) 539–553

www.elsevier.com/locate/jprocont

Control of batch product quality by trajectory manipulationusing latent variable models

Jesus Flores-Cerrillo, John F. MacGregor *

Department of Chemical Engineering, McMaster University, Hamilton, Ontario, Canada L8S4L7

Received 25 June 2003; received in revised form 22 September 2003; accepted 22 September 2003

Abstract

A novel inferential strategy for controlling end-product quality properties by adjusting the complete trajectories of the ma-

nipulated variables is presented. Control through complete trajectory manipulation using empirical models is possible by controlling

the process in the reduce space (scores) of a latent variable model rather than in the real space of the manipulated variables. Model

inversion and trajectory reconstruction is achieved by exploiting the correlation structure in the manipulated variable trajectories

captured by a partial least squares model. The approach is illustrated with a condensation polymerisation example for the pro-

duction of nylon and with data gathered from an industrial emulsion polymerisation process. The data requirements for building the

model are shown to be modest.

� 2003 Elsevier Ltd. All rights reserved.

Keywords: Product quality; Partial least squares; Reduced space control

1. Introduction

Batch/semi-batch processes are commonly used be-cause their flexibility to manage many different grades

and types of products. In these processes, it is necessary

to achieve tight final quality specifications. However,

this is not easily achieved because batch operations

suffer from constant changes in raw material properties,

variations in start-up initialisation, and in operating

conditions, all of which introduce disturbances in the

final product quality. Moreover, compensating for thesedisturbances is difficult due to the non-linear behaviour

of the chemical reactors and to the fact that robust on-

line sensors for monitoring quality variables are rarely

available.

Control of product quality usually requires the on-

line adjustment of several manipulated variable trajec-

tories (MVTs) such as the pressure and temperature

trajectories. Several approaches based on detailedtheoretical models have been presented. These can

generally be divided into two groups, the first based on

*Corresponding author. Tel.: +1-905-525-9140x24951; fax: +1-905-

521-1350.

E-mail address: [email protected] (J.F. MacGregor).

0959-1524/$ - see front matter � 2003 Elsevier Ltd. All rights reserved.

doi:10.1016/j.jprocont.2003.09.008

non-linear differential geometric control, and the second

based on on-line optimization.

The differential geometric approaches [1–3] use thenon-linear model to perform a feedback transformation

that linearizes the system and then linear control theory

can be applied. Examples in the literature include the

control of final latex properties such as instantaneous

copolymer composition, conversion and weight average

molecular weight common in the emulsion polymerisa-

tion of styrene–butadiene [1], and the control of co-

polymer composition and weight average molecularweight for the free radical polymerisation of vinyl ace-

tate/methyl methacrylate reaction [2].

In on-line optimization, optimal trajectories are pe-

riodically recomputed at various instances throughout

the batch to optimize some final quality and/or perfor-

mance measure. Some examples include Crowley and

Choi [4] for the on-line control of molecular weight

distribution and conversion on the free radical poly-merisation of methyl methacrylate, and Ruppen et al. [5]

for on-line batch time minimization and conversion

control in an experimental set-up. In both approaches

control action was obtained using sequential quadratic

programming methods at several time intervals.

In spite of the significant literature addressing the

trajectory control of batch processes, many of these

Page 2: Control of batch product quality by trajectory manipulation using latent variable models

Nomenclature

A number of principal components

E residual matrix

f number of on-line measurements for the jthvariable

F residual matrix

g number of off-line analysis for the sth variable

K number of batches

l number of trajectories for the on-line vari-ables

M number of quality properties

n number of trajectories for the manipulated

variables

PT loading matrix

pT loading vector

Q1 weighting matrix in the controlled scores

Q2 score suppression movement matrixQT projection matrix from PLS

r number of the off-line variables

s2 variance of a score

T score matrix

t score vector

tpresent vector of estimated scores

uc vector of manipulated variables trajectories

uc;future vector of future control actions (hi 6 h6 hf )uc;implemented vector of implemented control actions

(06 h6 hi�1)

w number of segments for the mth manipulated

variable

W projection matrix

x regressor vector that includes on-line and off-

line measurements, and control actions

X unfolded regressor matrix of process trajec-

tories (MVTs and measurements)

v three-dimensional array

xm vector of total measurements (on-line and

off-line)

xm;future vector of unmeasured variables at timehi (hiþ1 6 h6 hf )

xm;measured vector of measured variables at time hi(06 h6 hi)

xoff vector of off-line measurements

xon vector of on-line trajectory measurements

Y matrix of quality properties

y vector of quality variables

y vector of estimated quality variables

Greek symbols

k weighting factor

h decision times

d de-tuning factor

a proportionality vector

b coefficients for the PLS inner relation

Index

a latent variable index

i time index

j,s,m variable index

k batch indexf final batch time

540 J. Flores-Cerrillo, J.F. MacGregor / Journal of Process Control 14 (2004) 539–553

strategies are difficult to implement because they are

computationally intensive and/or require substantial

model knowledge. Recently, Bonvin and co-workers

[6–8], recognizing that the use of detailed theoretical

models for the control and optimization of batch pro-

cesses is unrealistic in industry, introduce a strategy in

which the optimal structure of the parameterised inputs

is determined using, for example an approximate modeland then measurements (off-line and/or off-line) are

employed to refine (update) them.

Empirical modelling, on the other hand, has the ad-

vantage of ease in model building. Yabuki and Mac-

Gregor [9,10], and Flores-Cerrillo and MacGregor

[11,12] among others used empirical models for the

control of product quality-properties, but in these ap-

proaches the control action was restricted to only a fewmovements in the manipulated variables (injection of

additional reactants) because, in these cases, these few

adjustments were enough to reject the disturbances and

to achieve the desired end-qualities. However, if the

operation calls for adjustments to MVTs through most

of the duration of the process, another approach needs

to be taken. The approach often used in these cases is to

segment the MVTs into a small number of intervals (e.g.

5–10) and force the behaviour of the MVTs over the

duration of each interval to follow a zero or first order

hold. Control is then accomplished by manipulating the

slope or the level (stair-case parameterisation) at the

start of each interval (decision points). Studies involving

this type of parameterisation can be found in [13,14]among others. However, in many batch processes such a

staircase parameterisation of the MVTs, just for con-

venience of the control engineers, may not be accept-

able. The operation of the batch may require, or

historically be based on, smooth MVTs, and converting

them to stair-case approximations might represent a

radical departure from normal practice, with the impli-

cation that control schemes based on them will never beimplemented. Moreover, model inversion in the control

algorithm would be usually difficult with this approach

because a large number of highly correlated control

actions need to be determined at every decision point.

A solution to this problem comes from recognizing

that within the range of normal process operation all the

Page 3: Control of batch product quality by trajectory manipulation using latent variable models

J. Flores-Cerrillo, J.F. MacGregor / Journal of Process Control 14 (2004) 539–553 541

process variable trajectories (both MVTs and measured

variables) are very highly correlated with one another,

both contemporaneously (i.e. at the same time period)

and temporally (over the time history of the batch). Thisimplies that their behaviour can be represented in a

much lower dimensional space using latent variable

models based on principal component analysis (PCA) or

partial least squares (PLS). This concept has been

powerfully exploited for the analysis and monitoring of

batch processes [15–17] where the entire time histories of

all the process and MVTs can usually be summarized by

only a few (2 or 3) latent variables. Therefore, in thispaper we show that by projecting all the process variable

trajectory data into low dimensional latent variable

spaces, all control decisions can be performed on the

latent variables, and the entire MVTs for the remainder

of the batch then reconstructed from the latent variable

models. In this reduced dimensional space, the data re-

quirements for modelling and for model parameter

estimation are much less demanding, the control com-putation is easier, and the computed MVTs are smooth

and consistent with past operation of the process. In

spite of these inherent advantages in controlling the

MVTs of batch processes in a latent variable space, no

literature has yet addressed this issue. Reduced dimen-

sion controllers for continuous processes (a binary dis-

tillation column simulator and the Tennessee Eastman

process) based on PCA have been proposed [18–20]which express the control objective in the score space of

a PCA model, but the dimension of the manipulated

variable space is still small since no trajectories need to

be computed.

The purpose of this paper is to introduce an infer-

ential control strategy that allows a much finer charac-

terisation and smoother reconstruction of optimal

MVTs than those obtained using staircase parameteri-

Fig. 1. Unfolding of databa

sation, and one that reduces the complexity and number

of identification experiments needed for model building.

These objectives are made possible by formulating the

control strategy in the reduced dimensional space of alatent variable model, and then inverting the model to

obtain the solution for the MVTs. The outline of the

paper is as follows: in Section 2 the methodology is in-

troduced; in Section 3, the control approach is illus-

trated with a condensation polymerisation case study

for the production of nylon and preliminary results are

shown for an industrial emulsion polymerisation pro-

cess.

2. Control methodology

2.1. Model building

The proposed methodology uses historical databasesand a few complementary identification experiments for

model building. The empirical model is obtained using

PLS. However, other projection methods such as prin-

cipal component regression may also be applied.

The database from which the PLS model is identified

is shown in Fig. 1. It consists of a (K �M) response

matrix Y and an originally three-dimensional array v,

which after unfolding [17,22] would yield a (K � N ) re-gressor matrix X where K is the number of batches. Each

row vector of Y denoted as yT, contains M quality

properties measured at the end of each batch. Each row

vector of X, denoted as xT, is composed of:

xT ¼ xTon xT

off uTc� �

where xTon ¼ ½ xT

on;1 xTon;2 � � � xT

on;l � is a vector of the

trajectories of l on-line process variables such as tem-

perature and pressure obtained from on-line sensors;

se for model building.

Page 4: Control of batch product quality by trajectory manipulation using latent variable models

542 J. Flores-Cerrillo, J.F. MacGregor / Journal of Process Control 14 (2004) 539–553

xToff ¼ ½ xT

off ;1 xToff ;2 � � � xT

off ;r � is the set of any off-line

measurements collected occasionally on r variables

during the batch, and uTc ¼ ½ uTc;1 uTc;2 � � � uTc;n � is a

vector of the trajectories of n manipulated variables. Ascan be seen in Fig. 1, xT

on;j ¼ ½xon;1; . . . xon;f �j and xToff ;s ¼

½xoff ;1; . . . ; xoff ;g�s denotes, respectively, the row vector of

observations obtained from on-line measurements on

the jth variable, and from off-line measurements on the

sth variable over the course of the batch, while uTc;m ¼½ uc;1; � � � uc;w �m denotes the trajectory of the mthmanipulated variable (MV). Here, f , g and w are, re-

spectively, the number of on-line measurements, off-lineanalysis and MV segments for the corresponding vari-

able in each category. Therefore the regressor matrix is

of dimension (K � N ) where N ¼ flþ gr þ wn. In the

following text xTon and xT

off are combined into a single

row vector xTm ¼ ½ xT

on xToff �, and then xT ¼ ½ xT

m uTc �.Full MVTs are obtained through trajectory segmen-

tation as illustrated in Fig. 2. The MVTs are segmented

into a (possibly) large number of intervals ðwÞ andcontrol decision points (hi; i ¼ 1; 2; . . .) are selected. At

each decision point (hi), final properties (y) are predictedand the adjustments to the remaining MVTs (after this

decision point) are computed if the predicted final

properties are not within desired specifications. Notice

that the segment size is not necessarily uniform and that

decisions points may be chosen arbitrarily but are as-

sumed to be the same for each batch. (The decisionpoints will usually be selected using prior process

knowledge.) In the limit, control action can be taken at

every segment (i.e. every segment would represent a

decision point), but this is almost never necessary, as a

very small number is usually adequate. The fineness of

the trajectory segmentation will largely depend on how

fine the shape of the trajectories needs to be recon-

structed. The control methodology presented in thepaper is essentially independent of this.

The data-set used for model building consists of

representative operating data from past batches in order

to capture information on most of the disturbances and

operating policies normally encountered in the batch

Fig. 2. Fine segmentation of MVTs and decision points.

operation. In addition, data in which some changes in

the MVTs are performed at each decision point are re-

quired in order to establish causal relationship between

these MVT changes and the other measured processvariable trajectories and the final product qualities.

Rebuilding the model by adding new batch data col-

lected after implementing the control scheme can also be

done in order to further improve the causal relationship

and expand the information on the effect of disturbances

on the trajectories. The data requirements are further

discussed in the examples. Linear PLS regression is then

performed by projecting the scaled (unit variance) data(expressed as deviations from their nominal conditions)

onto lower dimensional subspaces:

X ¼ TPT þ E

Y ¼ TQT þ Fð1Þ

where the columns of T are values of new latent vari-

ables (T ¼ XW) that capture most of the variability inthe data, P and Q are the loading matrices for X and Y

respectively, and E and F are residual matrices. Non-

linear PLS regression can also be used as will be shown

at the end of Section 3.1. However, for simplicity, in the

following discussion linear models are assumed.

The control methodology used in this work consists

of two stages: at predetermined decision times (hi,i ¼ 1; 2; . . .) an inferential end-quality prediction usingon-line and possible off-line process measurements (xm)

and MVTs (uc) available up to that time is performed to

determine whether or not the controlled end-qualities (y)

fall outside a pre-determined ‘‘no-control’’ region, and

then if needed, control action is computed in the latent

variable space followed by model inversion to obtain the

modified MVTs for the remainder of the batch that will

yield the desired final qualities. This two-stage proce-dure is repeated at every decision point (hi) using all

available measurements on the process variable and

MVTs available up to that time. The novelty of the

proposed approach is that the control and the model

inversion stage is performed in the reduced dimensional

space (latent variable or score space) of a PLS model

rather than in the real space of the MVTs. Due to the

high correlation of measurements and control actions,the true dimensionality of the process, determined by the

score variable space (ta; a ¼ 1; 2; . . . ;A) of the PLS

model, is generally much smaller than the number of

manipulated variable points obtained from the MVT

segmentation (uc). Therefore, the control computation

performed in the reduced latent variable space (t) is

much simpler than the one performed in the real space.

In the following, the control methodology is describedfor one control decision point (hi) during the batch. This

is simply repeated at each future decision point. Notice

that although the method is illustrated with an example

in which the decision points are defined at fixed clock

Page 5: Control of batch product quality by trajectory manipulation using latent variable models

J. Flores-Cerrillo, J.F. MacGregor / Journal of Process Control 14 (2004) 539–553 543

times (hi; i ¼ 1; 2; . . .), these decision points could easily

be based on measured variables other than time, such as

specified values of conversion or energy production.

This would be an advantage on batches that do not havethe same duration (due to, for example, seasonal vari-

ations in cooling capacity and varying row material

properties), since the process trajectories can then be

aligned using such indicator variables [21,15,22–24].

2.2. Prediction

For on-line end-quality estimation (y), when a new

batch k is being processed, at every decision point

(hi; i ¼ 1; 2; . . .) 06 hi 6 hf , there exists a regressor rowvector xT composed of at least the following variables:

xT ¼ xTm uTc

� �¼ xm;measured;hTi

xTm;future uc;implemented;hTi

; uTc;future

h ið2Þ

The regressor vector x consists of: all measured variables

(xm;measured) available up to time hi (06 h6 hi); unmea-sured variables (xm;future) not available at hi, but that willbe available in the future (hiþ1 6 h6 hf ); implemented

control actions uc;implemented (06 h6 hi�1); and future

control actions uc;future, (hi 6 h6 hf ) which will be de-

termined through the control algorithm. Note that at

the model building stage, the xm;future and uc;future vectors

are available for each batch.

To estimate whether or not the final quality propertiesfor a new batch will lie within an acceptable region, the

prediction is performed considering uc;future ¼ uc;nominal

(i.e. assuming that the remaining MVTs will be kept at

their nominal conditions) using the PLS model:

tTpresent¼�xTm uTc

�W

¼hxTm;measured;hi

; xTm;future uTc;implemented;hi

; uTc;nominal

iW

ð3ÞyT ¼ tTpresentQ

T ð4Þ

W and Q are projection matrices obtained from the PLS

model building stage. The vector of scores, tpresent, for

the new batch is the projection of the x vector onto the

reduced dimension space of the latent variable model at

time hi, and y is the vector of predicted end-quality

properties. From the above equations, it can be noticed

that changes in batch operation detected by measure-

ments of the process variable trajectories (xm;measured;hi ) orproduced by changes in the MVTs (uc;implemented;hi) would

produce changes in the scores (tpresent) and therefore in

the end-quality properties (i.e. changes in the end-

qualities can be detected through changes in the scores).

From Eq. (3), it can also be noticed that in order to

compute tpresent and y, it is necessary to have an estimate

of the unknown future measurements (xm;future) from

(hiþ1 6 h6 hf ). These can be imputed from the PLS

model for the batch process using efficient missing data

algorithms available in the literature [25,26]. Alterna-

tively, a multi-model approach in which different PLSmodels are identified at every decision point can be used

[14] or a recursive Kalman filter approach as shown in

[14] taken. In this paper a single PLS model is used for

prediction and control, and the estimation of unknown

future measurements is performed using the PLS model

and a missing data algorithm. Missing data imputation

based on, for example, conditional expectation or ex-

pectation/maximisation (EM) have been shown to pro-vide very powerful time-varying model predictive

forecast of the remaining portions of the batch trajec-

tories [27]. Such efficient predictions are possible because

the latent variable models based on PLS (or PCA)

capture the time varying covariance structure of the data

over the entire batch trajectory. These predictions will

be much better than those provided by fixed time series

or Kalman filter models [27].The ‘‘no-control region’’ can be determined in several

ways, such as one that takes into account the uncer-

tainty of the model for prediction [9], using product

specifications, or with quality data under normal (‘‘in-

control’’) operating conditions [12]. In this work a

simple control region based on product quality specifi-

cations will be used (Section 3). The issue of whether or

not to use a ‘‘no-control’’ region is at the discretion ofthe user, and is not essential to the control methodology

presented in this paper.

If the quality prediction is outside the ‘‘no-control’’

region, then a control action, and model inversion to

obtain the MVTs for the remainder of the batch uTc;futureis needed. Obtaining the full MVTs consist of two

stages: (1) computation of the adjustments required in

the latent variable scores Dt, followed by (2) model in-version of the PLS model to obtain the real MVTs for

the remainder of the batch. These two stages are ex-

plained in the following sections.

2.3. Score adjustment computation

At every decision point (hi), the change in the scores

(Dt) needed to track the end-qualities closer to their set-

points (ysp) can be obtained by solving the quadratic

objective:

min|{z}DtðhiÞ

ðy� yspÞTQ1ðy� yspÞ þ DtTQ2Dtþ kT 2

st yT ¼ ðDtþ tpresentÞTQT

T 2 ¼XAa¼1

ðDtþ tpresentÞ2as2a

Dtmin 6Dt6Dtmax

ð5Þ

where DtT ¼ tT � tTpresent, Q1 is a diagonal weighting

matrix defining the relative importance of the variables

Page 6: Control of batch product quality by trajectory manipulation using latent variable models

544 J. Flores-Cerrillo, J.F. MacGregor / Journal of Process Control 14 (2004) 539–553

y’s, Q2 is a diagonal movement suppression matrix that

is used as a tuning matrix to moderate the aggressiveness

of the control, T 2 is the Hotelling’s statistic, s2a is the

variance of the score ta, and k is a weighting factor whichdetermines how tightly the solution is to be constrained

to the region of the score space defined by past opera-

tion. Russell et al. [14] used a similar constraint on T 2.

Hard constraints in the adjustment to the scores

(Dtmin 6Dt6Dtmax) are problem dependent and may or

not need to be included. Soft constraints on Dt are

contained in the quadratic objective function. The soft

constraint on the score magnitudes through, Hotelling’sT 2 statistic, is intended to constrain the solution in the

region where the model is valid.

Eq. (5) is a quadratic programming problem that can

be restated as:

min|{z}DtðhiÞ

1

2DtTHDtþ fTDt ð6Þ

where

H ¼ QTQ1QþQ2 þQ3

fT ¼ ðQtpresent � yspÞTQ1Qþ tTpresentQ3

Q3 ¼ diag½k=s2a�Dtmin 6Dt6Dtmax

ð7Þ

In the case of no hard constraints, the solution is easily

obtained as:

DtT ¼ �fTH�1 ð8Þ

The aim of Eq. (8) is to obtain the change in the scores

(Dt) that would drive the final quality variables closer to

their desired set-points (ysp). Due to the movement

suppression matrix (Q2) and/or k, the computed (Dt)may not drive the process all the way to their set-points.

Choosing Q1 ¼ I, Q2 ¼ 0 and k ¼ 0, gives the mini-

mum variance controller, which, at each decision point

would force the predicted qualities (y) to be equal to

their set-points (y ¼ ysp) at the end of the batch:

min|{z}DtðhiÞ

ðy� yspÞTQ1ðy� yspÞ

st yT ¼ ðDtþ tpresentÞTQT

ð9Þ

Three situations arise (for the unconstrained case) in

finding a solution to (9) depending on the statistical

dimensions of ysp and (Dt):

1. dimðDtÞ ¼ dimðyspÞIn this situation a unique solution exists that can be

directly obtained from (9):

DtT ¼ yTspðQTÞ�1 � tTpresent ð10Þ

2. dimðDtÞ < dimðyspÞIn this case a least square solution is needed:

DtT ¼ ðyTsp � tTpresentQTÞQðQTQÞ�1 ð11Þ

3. dimðDtÞ > dimðyspÞThis case is a common situation. Although the number

of variables to be used in the control algorithm has been

reduced to A latent variables, a projection from a lowerto higher space is still required. In this situation Eq. (9)

has an infinite number of solutions. Therefore, a natu-

ral choice is to select the DtðhiÞ having the minimum

norm-2:

min|{z}DtðhiÞ

DtTDt

st yTsp ¼ ðDtþ tpresentÞTQT

ð12Þ

and whose solution can be easily obtained as:

DtT ¼ ðyTsp � tTpresentQTÞðQQTÞ�1

Q ð13Þ

A detuning factor (06 d6 1) may be included for this

reduced space controller in order to moderate the

aggressiveness of the control moves:

DtT ¼ dðyTsp � tTpresentQTÞðQQTÞ�1

Q ð14Þ

This is a simple alternative to using the quadratic term

DtTQ2Dt in the general linear quadratic control objective

(5). A Dt vector is computed at every decision point (hi).Eqs. (10), (11) and (13) are consistent with the PLS

model inversion results found in [28].Notice that in this last situation (Eq. (14)), the matrix

QQT has dimension m� m (m being the number of

quality properties). Therefore, in order to avoid ill-

conditioned matrix inversion, the quality properties

should not be highly correlated. This poses no problem

since one can always perform a PCA on the Y quality

matrix to obtain a set of orthogonal variables (s) thatcan be used as new controlled variables. Alternatively, ifit is decided to retain an independent set of physical yvariables, selective PCA [28] can be performed on the Y

matrix to determine that subset of quality variables

which best defines the Y space.

2.4. Inversion of PLS model to obtain the MVTs

Once the low dimensional (A� 1) vector Dt is com-

puted via one of the control algorithms described in

the last section, it remains to reconstruct from tT ¼DtT þ tTpresent, estimates for the high dimensional trajec-tories for the future process variables (xm;future) and for

the future manipulated variables (uc;future) over the re-

mainder of the batch. These future trajectories can be

computed from the PLS model (1) in such a way that

their covariance structure is consistent with past oper-

ation. If there were no restrictions on the trajectories,

such as might be the case for a control action at h ¼ 0,

Page 7: Control of batch product quality by trajectory manipulation using latent variable models

J. Flores-Cerrillo, J.F. MacGregor / Journal of Process Control 14 (2004) 539–553 545

then the model for the X-space can be used directly to

compute the x vector trajectory (xT ¼ ½ xTm uTc �) for the

entire batch [28] as:

xT ¼ tTPT ð15Þ

However for control intervals at times hi > 0 the x

vector trajectory (xT ¼ ½xTm;measuredð0:hiÞ u

Tc;implementedð0:hiÞ

xTm;futureðhi:hf Þ u

Tc;futureðhi:hf Þ�) is composed of measured pro-

cess variables (xTm;measuredð0:hiÞ) for the interval 06 h < hi,

and for the already implemented manipulated variables

(uTc;implementedð0:hiÞ) that must be respected when computing

the trajectories for the remainder of the batch (hi 6h < hf ). Denote xT

1 ¼ ½ xTm;measuredð0:hiÞ uTc;implementedð0:hiÞ �

the known trajectories over the time interval (0 : hi) thatmust be respected, xT

2 ¼ ½ xTm;futureðhi:hf Þ uTc;futureðhi:hf Þ � the

remaining trajectories to be computed, and PT1 and

PT2 their corresponding loading matrices. At times

hi > 0, if x is directly reconstructed using (15) as xT ¼tTPT then

xT1 xT

2

� �¼ tTPT

1 tTPT2

� �ð16Þ

However, the computed tTPT1 will not be equal to

the actually observed trajectories at time hi xT1 ¼

½ xTm;measuredð0:hiÞ uTc;implementedð0:hiÞ �. Therefore, simply se-

lecting xT2 ¼ tTPT

2 would not be correct as it does not

account for what has actually been observed for xT1 in

the first part of batch.Therefore, assume that the remaining trajectories

(future manipulated variables and measurements) are:

xT2 ¼ ðtT þ aTÞPT

2 ð17Þ

where aTPT2 is an adjustment to xT

2 that accounts for theeffects of discrepancy between tTPT

1 and xT1 during the

first part of the batch. (Selection of such a relationship

will also ensure that the correlation structure of the PLS

model is kept.) However, we still wish to achieve the

computed value in score space t that will satisfy the

overall PLS model. Therefore, we must have:

tT ¼ xT1 xT

2

� � W1

W2

� �¼ xT

1W1 þ xT2W2 ð18Þ

then

xT2W2 ¼ tT � xT

1W1 ð19Þ

Substituting xT2 ¼ ðtT þ aTÞPT

2 in (19):

ðtT þ aTÞPT2W2 ¼ tT � xT

1W1

Therefore

ðtT þ aTÞ ¼ ðtT � xT1W1ÞðPT

2W2Þ�1 ð20ÞAnd by substituting (20) in (17) the remaining MVTs to

be implemented are obtained (hi 6 h < hf ):

xT2 ¼ ðtT � xT

1W1ÞðPT2W2Þ�1

PT2 ð21Þ

It is easy shown that this equation reduces to the rela-

tionship in (15) when hi ¼ 0 where there are no existing

trajectory measurements or manipulated variables. The

(A� A) matrix PT2W2 is nearly always well conditioned,

and so there is no problem with performing the inver-

sion [29]. This inferential control algorithm is then re-

peated at every decision point (hi) until completion of

the batch.

3. Case studies

3.1. Case study 1. Condensation polymerisation

In the batch condensation polymerisation of nylon

6,6 the end product properties are mainly affected by

disturbances in the water content of the feed. In plantoperation, feed water content disturbances occur be-

cause a single evaporator usually feeds several reactors

[30]. The non-linear mechanistic model of nylon 6,6

batch polymerisation used in this work for data gener-

ation and model performance evaluation was developed

in [30]. The complete description of the model and

model parameters can be found in the original publi-

cation.This system was studied in [14,30], where several

control strategies including conventional control (PID

and gain scheduled PID), non-linear model based con-

trol and empirical control based on linear state-space

models were evaluated. In the databased approach [14],

control of the system was achieved by reactor and jacket

pressure manipulation. These two manipulated variables

were segmented and characterised by slope and level(stair-case parameterisation) leading to 10 control vari-

ables. A total of 7 intervals (decision points) were used.

An empirical state space model was identified from 69

batches arising from an experimental design in the 10

manipulated variables. Several differences between the

control strategy proposed here and the one used in [14]

can be noticed, the most important being: (i) the control

is computed in the reduce latent variable space ratherthan in the real space of the MVTs, (ii) only two decision

points are needed to achieve good control; thereby

simplifying the implementation and decreasing the

number of identification experiments needed to build a

model, and (iii) a much finer MVT reconstruction is

achieved.

Control objectives and trajectory segmentation: The

control objective is to maintain the end-amine concen-tration (NH2) and the number average molecular weight

(MWN) at their set-points to produce nylon 6,6 when

the system is affected by changes in the initial water

content (W). The MVTs used to control the end-quali-

ties are the jacket and reactor pressure trajectories.

These MVTs are finely segmented every 5 min starting at

35 min from the beginning of the reaction until 30 min

Page 8: Control of batch product quality by trajectory manipulation using latent variable models

Fig. 3. Predictions of the missing measurements made at the first de-

cision point (35 min) using different missing data imputation methods:

(-·-) expectation-maximisation (EM), (-h-) iterative-imputation

(IMP), (� � �) single component projection (SCP), (-�-) projection to the

plane using PLS (PTP) and (––) actual value.

546 J. Flores-Cerrillo, J.F. MacGregor / Journal of Process Control 14 (2004) 539–553

before the completion of the batch (total reaction time

200 min), giving trajectories defined at 40 discrete time

points in the interval (356 h6 170). The trajectories for

the first 35 min and the last 30 min were fixed for allbatches. Two control decision points at 35 and 75 min

were found to be sufficient for good control for the

conditions used in this example. In order to predict NH2

and MWN, on-line measurements of the reactor tem-

perature (Tr) and venting (v) are considered available

every two minutes.

Data generation: A PLS model with five latent vari-

ables (determined by cross-validation) was built from adata set consisting of 45 batches in which the initial

water content (W ) was randomly varied. In 30 of the

batches some movement in the MVT (at the two deci-

sion points) was performed (some of these batches

would normally be available from historical data). The

effect that the number batches used for identification of

the PLS model has on control performance is discussed

at the end of this section and in [29].Prediction: The first step is to evaluate the perfor-

mance of the PLSmodel prediction with different missing

data algorithms at each decision point. Several missing

data algorithms were tested and as an illustration some

results are shown in Figs. 3 and 4. The predicted trajec-

tories, made using the available data up to the first de-

cision point (hi ¼ 35 min), for venting (v) and reactor

temperature (Tr) when the process is affected by a dis-turbance of )10% (mass) in the initial water content are

shown in Fig. 3. Each predicted trajectory is obtained

using: (-·-) expectation–maximisation (EM), (-h-) iter-

ative-imputation (IMP), (� � �) single component projec-

tion (SCP), and (-�-) projection to the plane using PLS

(PTP) method [26,27]. As judged from this example and

many similar simulations, all the missing data algorithms

provide reasonable estimates of the trajectories, exceptperhaps the SCP method. In Fig. 4 predictions of the

final qualities made at the first decision point (hi ¼ 35

min) using the IMP approach are shown when the initial

water content randomly varies for 15 batches in the

range of ±10% (mass). As can be seen in this figure, the

predicted final quality properties (at h ¼ 200 min) made

using the PLS model at the first decision point (hi ¼ 35

min) are in good agreement with the observed values (�).Slight improvement in the predictions at high MWN

and NH2 values can be obtained with a non-linear

quadratic PLS model [29]. However, the linear PLS

model is very good in the target region (mid-values) and

adequate in the extremes. Moreover, the control per-

formance obtained using linear PLS model and that

obtained using a non-linear quadratic PLS model, for

the conditions used in this example, were found to bequite similar [29].

Estimation and model prediction assessment: One of

the advantages of using PLS models for control, it is

that it provides a powerful way to asses the validity of

the PLS model for trajectory estimation of the missingmeasurements, and for quality prediction, and it enables

one to detect sensor failures, etc. because, unlike normal

regression and neural network methods, it provides a

model for the regressor space (x) as well as giving a

prediction of the final qualities [31]. Therefore, prior to

computing new control trajectories, the square predic-

tion error (SPE) of the new vector of measurements

should be computed at each decision point. This SPEprovides a measure of any inconsistency between the

measurements and imputed missing values for the new

batch and the behaviour of the set of measurements used

to develop the PLS model [15]. If the SPE is larger than

a statistically determined limit [16], the quality predic-

tion and the control computation from the PLS model

should be considered to be unreliable. In this situation,

it might be preferable not to recompute the MVTs at the

Page 9: Control of batch product quality by trajectory manipulation using latent variable models

1.325 1.33 1.335 1.34 1.345 1.35 1.355 1.36 1.365 1.37 1.375

x 104

45

46

47

48

49

50

51

52

53

541

1

22

33

4 4

5 5

6

7

8

9

10

111213

1415

Number Average Molecular Weight (MWN)

End

Am

ine

Con

cent

ratio

n (N

H2)

Prediction Results

Fig. 4. Observed (�) and predicted (h) end-quality properties using

PLS model.

J. Flores-Cerrillo, J.F. MacGregor / Journal of Process Control 14 (2004) 539–553 547

current decision point, but simply continue to apply

those from the last decision point.

Control

Regulatory control: At each decision time (hi) a pre-

diction of the final quality is made. If it is determined

that control action is needed any of the control algo-

rithms given by Eqs. (5)–(14) can be used to compute a

correction, Dt, in the latent variable score space, andthen the new MVTs for the remainder of the batch can

be reconstructed from Eq. (21). The performance of the

linear minimum variance controller algorithm (Eqs. (14)

and (21) with d ¼ 1:0) is shown in Fig. 5. The final

quality properties of the 15 batches shown in Fig. 4 that

are affected by disturbances in the initial water concen-

tration are shown with and without control. An ‘‘in-

1.325 1.33 1.335 1.34 1.345 1.35 1.355 1.36 1.365 1.37

x 104

45

46

47

48

49

50

51

52

53

54

15

1211

Control Results

End

Am

ine

Con

cent

ratio

n (N

H2)

Number Average Molecular Weight (MWN)

7

6

54

32

1

1413

10

9

Fig. 5. Control results: end-quality properties without control (�);

after control is taken (h) and set-point ( ).

control’’ region (dotted lines) was defined considering

that the final product is acceptable if their predicted

values lay in the specified ranges 48 6 NH2 6 50.6 and

13,463 6 MWN 6 13,590. In Fig. 5, the o’s show whathappens if no control action is taken and the h’s show

the end qualities obtained after control is performed.

The final qualities (h’s) were obtained by rerunning the

non-linear simulation model with the MVTs computed

by the controller. As can be seen in this figure, the

proposed control scheme corrects all batches and brings

the final quality into the acceptable region. Fig. 6 shows

the jacket and reactor pressure MVTs for runs 1 and 15together with their nominal conditions. In this figure,

(––) represents the MVTs computed to reject a distur-

bance of )10% in the initial mass of water, and (- – -)

that needed to reject a disturbance of +10%. Their nom-

inal conditions of the MVTs are indicated with (- - -).

Fig. 6. MVTs: (- - -) nominal conditions, (––) when the disturbance is

)10% mass in W, and (- – -) when disturbance is +10% in W.

Page 10: Control of batch product quality by trajectory manipulation using latent variable models

Fig. 8. MVTs for set point change: the number indicates the set-point

change shown in Fig. 7, and (- - -) the nominal MVT.

548 J. Flores-Cerrillo, J.F. MacGregor / Journal of Process Control 14 (2004) 539–553

Note that the controller computes new MVTs that are

very smooth and consistent with their behaviour during

past operations. This consistency with past operation is,

of course, forced to be true through use of the PLSmodel for MVT reconstruction (Eqs. (17) and (21)).

Set-point change or new product design: In this section

the performance of the control algorithm is shown in the

case that a set-point change (or new product design) is

desired within the region of validity of the PLS model.

No disturbances in W are included in this example, but,

if present, the on-line control algorithm will easily reject

them as illustrated above. The desired quality properties(�) and those obtained by using Eqs. (14) and (21) with

d ¼ 1 (h) are shown in Fig. 7 for three different set-

points. In Fig. 8 the MVTs needed to achieve such set-

points are shown. It can be seen that the performance of

the algorithm in achieving the desired final quality set-

points is very good (Fig. 7), and that the MVTs com-

puted by the controller are smooth and very consistent

with the shape of the trajectories from past operation.

Discussion

Several practical issues may affect (to some extent)

the performance of the proposed control algorithm.Some of them are briefly discussed here and more details

are given in [29].

The number of latent variables is generally decided by

cross-validation methods at the model building stage. It

was observed that too large a number of components

(with respect to that obtained by cross-validation) might

promote an ill-conditioned P2W2 inversion at the second

decision point. This problem can be easily overcome byusing a pseudo-inverse procedure based on singular

value decomposition as detailed in [29]. For the simu-

lation system studied no significant degradation in per-

1.29 1.3 1.31 1.32 1.33 1.34 1.35 1.36 1.37 1.38 1.39

x 104

42

44

46

48

50

52

54 1

2

3

Set-Point Change Results

End

Am

ine

Con

cent

ratio

n (N

H2)

Number Average Molecular Weight (MWN)

Fig. 7. Set-point change: (�) desired, (h) achieved qualities using the

control algorithm (Eq. (14) and (21)) and ( ) nominal operating point.

formance is obtained by using a different number of PLS

components.

The influence of using different missing data impu-tation algorithms was also studied. All the algorithms

give adequate control performance. Those based on

EM, IMP and PTP perform slightly better than the one

in which SCP was used.

In the previous examples, a total of 45 batches (30

with a movement in the MVTs at the two decision

points) were used for model identification. However,

adequate control performance (all test batches fallinginside the ‘‘in-control’’ region of Fig. 5) was achieved

using as few as 15 batches (10 in which some experiment

in the MVTs was performed). This illustrates that the

data requirements for PLS model building are modest.

However, if the model has been identified using very

limited or uninformative batch data-sets (as those aris-

ing from only historical data), batch-to-batch model

parameter updating can be performed at the end of eachnew completed batch to improve the quality of the

Page 11: Control of batch product quality by trajectory manipulation using latent variable models

J. Flores-Cerrillo, J.F. MacGregor / Journal of Process Control 14 (2004) 539–553 549

model parameter estimates, prediction and control for

the upcoming batch [12,29].

To assess the impact of measurement noise on the

performance of the algorithm, different levels of randomnoise were added to the on-line measurements of reactor

temperature (Tr) and venting (v). It was found that ad-

equate control performance (test batches falling inside

the ‘‘in-control’’ region of Fig. 5) was achieved with

noise levels up to 35% in the temperature and venting

rate. The noise level here represents the percentage of

the noise variance over the true variations of the tem-

perature and venting rate changes observed in the train-ing set. The 35% noise level approximately represents

one standard deviation in temperature of 2 K and vent-

ing rate of 42 g/s (see [29] for details). For larger levels of

noise (50%, for example) the control performance is de-

graded to some extent because the random error added

to the measurements becomes quite large when com-

pared with the true variations in the MVs. A no-control

region that reflects the impact of these measurementnoises may be obtained by propagating such measure-

ment errors with the PLS model as suggested in [9]. This

would prevent control actions from being implemented

based solely on the uncertainty arising from noise.

Finally, the control methodology outlined in Section

2 can be easily extended to cases in which a non-linear

PLS model and control is needed. This is achieved by

simply modifying Eq. (12) (case 3, dimðDtÞ > dimðyspÞ)to take into account the non-linear nature of the PLS

algorithm. For example, in the case of a quadratic PLS

model, Eq. (12) can be restated as:

min|{z}DtðhiÞ

DtTDt

st yTsp ¼ uTQT

ð22Þ

where uT ¼ b1 þ b2ðDtþ tpresentÞT þ b3ðDtT þ tTpresentÞ2.

Fig. 9. (a) Original process variable trajectories (every interval represe

This equation can be easily solved for Dt using qua-

dratic programming (or non-linear least squares in

the case of no constraints), and the MVTs can be re-

constructed in the same way as described in Section 2.4.From the simulation study, the control performance

of the quadratic PLS model is quite similar to that

obtained using the linear PLS model [29] (and there-

fore results are not shown). This is not surprising be-

cause, in the region under study, the process is only

slightly non-linear. However, if larger disturbances af-

fect the process a non-linear PLS approach may be

better suited.

3.2. Case study 2. Feasibility study on industrial data for

an emulsion polymerisation process

Data: In this feasibility case study, industrial data for

an emulsion polymerisation processes is used. The ori-

ginal data set consists of 53 batches obtained from an

experimental design in which the initial conditions and/or process variable trajectories were altered. No inter-

mediate quality measurements were available during the

reaction. However, final product physical properties

(FP) and final product quality properties (FQ) are

available at the end-of the process for most of the bat-

ches. Fig. 9(a) shows the actual process variable trajec-

tories that comprise the training data set (X), while Fig.

9(b) shows the 6 quality properties (Y matrix), corre-sponding to these batches. In Fig. 9(a), it can be noticed

that (i) since the batches in the process were of unequal

duration, alignment of the trajectories was accomplished

using the reaction extent as an indicator variable [15,21]

(every interval represents a 0.5% increase in the reaction

extent), and that (ii) some of the trajectories contain a

noticeable level of noise. It was decided not to perform

nts 0.5% of reaction extent), and (b) original quality properties.

Page 12: Control of batch product quality by trajectory manipulation using latent variable models

550 J. Flores-Cerrillo, J.F. MacGregor / Journal of Process Control 14 (2004) 539–553

any pre-treatment such as filtering or smoothing on the

process trajectories in order to test the performance of

the prediction and control algorithm under this situa-

tion. It can also be seen in Fig. 9(a) that FP-1 and FP-2are highly correlated therefore, to avoid an ill condition

matrix inversion in the control computation stage, FP-2

was removed and only five end quality properties con-

trolled. Removing FP-2 poses no problem since by

controlling FP-1 and the other quality variables we are

controlling FP-2 indirectly. Alternatively, we can per-

form PCA on the quality property matrix (Y) and

control the corresponding principal components insteadof the actual properties. For property reasons no further

details will be given here regarding the nature of the

process trajectories, initial conditions or product speci-

fications.

From the original data, 49 batches were used as a

training data set, while four batches were used as testing

set. These four batches were selected to span different

regions of the space far from the origin as can be seen inFig. 10. In this figure the projection of all batches in the

first two PLS dimensions (t1–t2) is shown. Batches 6, 12,16 and 46 were removed from the dataset and used as

test data. The 8 process variable trajectories are ma-

nipulated variables and each one of them is segmented

in 200 intervals (every interval represents 0.5% of reac-

tion extent). Therefore the data matrix used for model

building consists of segmented MVTs [X] and initialconditions [Z] (regressor matrices), and the matrix of

five physical and quality properties [Y]. The identified

PLS model consists of five latent variables (obtained by

cross-validation) that fits 76.8% of the X space and

69.9% of the Y space. Based on cross-validation, 51.7%

of the Y space can be predicted.

Control objectives: The batch data in this study was

the result of open-loop batch runs collected under dif-ferent initial conditions and different MVTs. There was

no possibility of implementing the resulting controller

on the batches. Therefore, this data is simply used to test

the feasibility of the prediction and control algorithms.

-40

-20

0

20

40

60

-60 -50 -40 -30 -20 -10 0 10 20 30 40 50 60

t [2]

t [1]

1

2

3

4

5 67

8

9

10

11

1213

14

151617

18

19 20

21

22232425 26

27 28

29

303132

33

34

3536 3738 3940

41424344454647 484950

51

5253

Fig. 10. t1 � t2 PLS space for the batches used in the training data set.

Batches 6, 12, 16, and 46 were removed from the original data set and

used as test data.

One of the existing batch runs is taken as the nominal

conditions and the final physical and quality variables

(y) measured from it selected as the targets (set-points).

Others batch runs with different initial conditions anddifferent MVTs are then selected as initial disturbance

conditions for a new batch. If no corrective action is

taken to adjust the MVTs then the batch will follow the

actual MVTs implemented throughout its duration, and

the final quality (y) will be the measured values for that

batch. Control is to be applied after a batch has reached

10% of completion (based on reaction extent).

Direct evaluation of the controller is not possible, butindirect validation can be obtained by comparing how

close the recomputed MVTs follow the nominal MVTs

from 10% of reaction extent until the end of the batch.

Since the first 10% of the history of the new batch is

different from the nominal MVTs, then to achieve the

desired final qualities (qualities of the nominal batch),

one should not expect the recomputed MVTs to exactly

follow those for the nominal batch, but they should beclose to them. Notice that if the control algorithm is

actually implemented, it would pose no problem to re-

compute the MVTs at several decision points and not

only at one as shown here.

Prediction: To evaluate the performance of the PLS

missing data algorithms, the total percent relative

RMSE for all the qualities properties (5 in this study) is

shown in Table 1 over the k ¼ 4 batches that composethe testing data set:

%RMSE ¼ 1

5

X5i¼1

1

k

ffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiXkj¼1

yij � yijyij

!2vuut0

@1A� 100

where yij is the i observed end-quality property for the jbatch and yij its predicted value.As an illustration of the

missing measurement reconstruction (at 10% of reactionextent using the EM approach), Fig. 11 is shown for

batch 12, where it can be noticed that the trajectory

estimation is satisfactory in spite of the high level of

noise.

Control: As an illustration of the control performance

using the proposed scheme (Eqs. (10) and (21) with

d¼ 1.0), results for one testing batch (batch 12) are

shown. Fig. 12 shows the measured final values of the yvariables (�) for the batch when no control was taken,

their predicted values at 10% of completion if no control

were taken ( ), the target values (h), and the expected

quality properties obtained if control action were per-

formed ( ). Since a minimum variance strategy was used

Table 1

Performance of missing data algorithms for prediction: total percent

relative RMSE for all five end quality properties

Algorithm EM IMP SCP PTP–PLS

%RMSE 8.0 7.3 9.8 6.8

Page 13: Control of batch product quality by trajectory manipulation using latent variable models

Fig. 11. Performance of the missing data algorithm for reconstruction of process measurements. The prediction is performed at 10% of reaction

extent (every interval represents 0.5% of reaction extent): (� � �) estimated trajectory using the EM algorithm and (––) observed trajectories (scaled

units).

0 1 24

5

6

7

8

9

0 1 20.4

0.6

0.8

1

1.2

1.4

0 1 26

7

8

9

10

11

0 1 20.55

0.6

0.65

0.7

0.75

0 1 22

2.5

3

3.5

4x 105

Qua

lity

Pro

perty

Valu

e

FQ-1 FQ-2 FQ-3

FP-1 FP-3

Fig. 12. Control results (control action taken at 10% of completion of the batch). Target (h), predicted qualities ( ), observed values if no control

action is taken (�) and expected quality properties if control action were performed ( ).

J. Flores-Cerrillo, J.F. MacGregor / Journal of Process Control 14 (2004) 539–553 551

(Eq. (10) and (21)), the values of the expected end

quality properties resulting from the control algorithm

will match their targets ( ), (since these values were

computed using simply the PLS model with the imputed

MVT adjustments obtained from model inversion using

the same PLS model.) A better way to evaluate the

reasonableness of the control is to inspect the MVTs

obtained from the control algorithm. Fig. 13 shows

Page 14: Control of batch product quality by trajectory manipulation using latent variable models

Fig. 13. MVTs (computed at 10% of reaction extent from the beginning of the process): (� � �) nominal conditions; (- - -) current trajectories that would

give ‘‘out-of-control’’ qualities and (––) MVTs obtained from the control algorithm (equation (10) and (21), with d ¼ 1:0).

552 J. Flores-Cerrillo, J.F. MacGregor / Journal of Process Control 14 (2004) 539–553

nominal trajectories (� � �), the current trajectories that

would give ‘‘out-of-control’’ qualities (- - -) and theMVTs obtained from the control algorithm (––) (at 10%

of reaction extent) that would drive the predicted

physical and quality properties to the desired targets. In

this figure, notice that MVTs obtained from the control

algorithm after 10% of completion are quite close to

their nominal conditions and exhibit the desired shapes.

It seems reasonable to assume that if these new trajec-

tories were to be implemented, they would drive theprocess closer to the desired end-quality values, simply

because the new MVTs are much closer to the nominal

conditions than those when no control is performed.

Note that they should not match the nominal trajecto-

ries exactly because they must also compensate for the

first 10% of the batch being run at the wrong conditions.

Furthermore, since the trajectories are highly correlated

with one another, there are various trade-off among theMVTs that might give quite similar final quality values.

In summary, although the control could not actually be

tested, these results indicate that the controller is be-

having very much as one might expect and are providing

the incentive for its implementation.

4. Conclusions

A novel control strategy for final product quality

control in batch and semi-batch processes is proposed

that recomputes, on-line, the entire remaining trajecto-

ries for the MVs at several decision points. In spite of thefact that the resulting controller solves for the high di-

mensional MVTs, the control algorithm involves solving

for only a small number of latent variables in the reduced

dimensional space of a PLSmodel. The high dimensional

MVTs are then solved by inverting the PLS model. The

only requirement of this approach (as with any other

control algorithm that recomputes the MVTs) is that the

lower level control scheme can accept and track thecomputed modified trajectories. The strategy uses em-

pirical PLS models identified from historical data and a

few complementary experiments. The algorithm is illus-

trated using a simulated condensation polymerisation

process and data obtained from an industrial emulsion

polymerisation setting. Since smooth and continuous

MVTs can be obtained, the approach seems well suited

for use in processes and mechanical systems (robotics)where such smooth changes in the MVs are desirable.

The methodology would also be well suited to the control

of transitions of continuous processes.

Acknowledgements

J. Flores-Cerrillo thanks McMaster University and

SEP for financial support and to Dr. Russell S. A. for

kindly providing us with his condensation polymerisa-

tion simulator.

Page 15: Control of batch product quality by trajectory manipulation using latent variable models

J. Flores-Cerrillo, J.F. MacGregor / Journal of Process Control 14 (2004) 539–553 553

References

[1] D.J. Kozub, J.F. MacGregor, Feedback control of polymer

quality on semi-batch copolymerization reactors, Chem. Eng. Sci.

47 (4) (1992) 929–942.

[2] C. Kravaris, M. Soroush, Synthesis of multivariate nonlinear

controllers by input/output linearization, AIChE J. 36 (1990) 249–

264.

[3] C. Kravaris, R.A. Wright, J.F. Carrier, Nonlinear controllers for

trajectory tracking in batch processes, Comp. Chem. Eng. 13

(1989) 73–82.

[4] T.J. Crowley, K.Y. Choi, Experimental studies on optimal

molecular weight control in a batch-free radical polymerisation

process, Chem. Eng. Sci. 53 (15) (1998) 2769–2790.

[5] D. Ruppen, D. Bonvin, D.W.T. Rippin, Implementation of

adaptive optimal operation for a semi-batch reaction system,

Comp. Chem. Eng. 22 (1/2) (1997) 185–199.

[6] D. Bonvin, B. Srinivasan, D. Ruppen, Dynamic optimization in

the batch chemical industry, in: Proceedings of the CPC-VI

Conference, AIChE Symp. Ser. 326 (98) (2002) 255–273.

[7] B. Srinivasan, S. Palanki, D. Bonvin, Dynamic optimization of

batch processes: I. Characterization of the nominal solution,

Comp. Chem. Eng. 27 (1) (2003) 1–26.

[8] B. Srinivasan, D. Bonvin, E. Visser, S. Palanki, Dynamic

optimization of batch processes: II. Role of measurements in

handling uncertainty, Comp. Chem. Eng. 27 (1) (2003) 27–44.

[9] Y. Yabuki, J.F. MacGregor, Product quality control in semibatch

reactors using midcourse correction policies, Ind. Eng. Chem.

Res. 36 (1997) 1268–1275.

[10] Y. Yabuki, T. Nagasawa, J.F. MacGregor, An industrial expe-

rience with product quality control in semi-batch processes,

Comp. Chem. Eng. 24 (2000) 585–590.

[11] J. Flores-Cerrillo, J.F. MacGregor, Control of particle size

distributions in emulsion semi-batch polymerization using mid-

course correction policies, Ind. Eng. Chem. Res. 41 (2002) 1805–

1814.

[12] J. Flores-Cerrillo, J.F. MacGregor, Within-batch and batch-to-

batch inferential-adaptive control of batch reactors: A PLS

approach, Ind. Eng. Chem. Res. 42 (2003) 3334–3345.

[13] S.I. Chin, S.K. Lee, J.H. Lee, A technique for integrated quality

control, profile control, and constraint handling for batch

processes, Ind. Eng. Chem. Res. 39 (2000) 693–705.

[14] S.A. Russell, P. Kesavan, J.H. Lee, B.A. Ogunnaike, Recursive

data-based prediction and control of batch product quality,

AIChE J. 44 (1998) 2442–2458.

[15] P. Nomikos, J.F. MacGregor, Multivariate SPC charts for

monitoring batch processes, Technometrics 37 (1) (1995) 41–59.

[16] P. Nomikos, J.F. MacGregor, Monitoring batch processes using

multiway principal component analysis, AIChE J. 40 (8) (1994)

1361–1375.

[17] P. Nomikos, J.F. MacGregor, Multi-way partial least squares in

monitoring batch processes, Chemometr. Intell. Lab. Syst. 30

(1995) 97–108.

[18] G. Chen, T.J. McAvoy, Process control utilizing data based

multivariate statistical models, Can. J. Chem. Eng. 74 (1996)

1010–1024.

[19] G. Chen, T.J. McAvoy, M.J. Piovoso, A multivariate statistical

controller for on-line quality improvement, J. Proc. Cont. 8 (2)

(1998) 139–149.

[20] T.J. McAvoy, Model predictive statistical process control of

chemical plants, in: Proceedings of the 15th IFAC World

Congress, Barcelona, Spain, 2002.

[21] A. Kassidas, J.F. MacGregor, P.A. Taylor, Synchronization of

batch trajectories using dynamic time warping, AIChE J. 44

(1998) 864–875.

[22] T. Kourti, P. Nomikos, J.F. MacGregor, Analysis, monitoring

and fault diagnosis of batch processes using multi-block and

multiway PLS, J. Process Control 5 (1995) 277–284.

[23] T. Kourti, J. Lee, J.F. MacGregor, Experiences with industrial

applications of projection methods for multivariate statistical

process control, Comp. Chem. Eng. 20 (1996) S745–S750.

[24] D. Neogi, C.E. Schlags, Multivariate statistical analysis of an

emulsion batch process, Ind. Eng. Chem.Res. 37 (1998) 3971–3979.

[25] P. Nelson, J.F. MacGregor, P.A. Taylor, Missing data methods in

PCA and PLS: score calculations with incomplete observations,

Chemometr. Intell. Lab. Syst. 35 (1996) 45–65.

[26] F. Arteaga, A. Ferrer, Dealing with missing data in MSPC:

several methods, different interpretations, some examples, J.

Chemometr. 16 (2002) 408–418.

[27] S. Garc�ıa Mu~noz, J.F. MacGregor, T. Kourti, Model predictive

monitoring of batch processes, Ind. Eng. Chem. Res., submitted

for publication.

[28] J.M. Jaeckle, J.F. MacGregor, Product design through multivar-

iate statistical analysis of process data, AIChE J. 44 (1998) 1105–

1118.

[29] J. Flores-Cerrillo, Quality control for batch processes using

multivariate latent variable methods, Ph.D. thesis, McMaster

University, Hamilton, ON, Canada, 2003.

[30] S.A. Russell, D.G. Robertson, J.H. Lee, B.A. Ogunnaike, Control

of product quality for batch nylon 6, 6 autoclaves, Chem. Eng.

Sci. 53 (1998) 3685–3702.

[31] A. Burnham, R. Viveros, J.F. MacGregor, Latent variable

multivariate regression modeling, Chemometr. Intell. Lab. Syst.

48 (2) (1999) 167–180.