Two-Stage Engine Mapping for the Calibration of Carbon Monoxide Emission

The calibration of a model’s parameters due to desired objectives is the main definition of model-based calibration. The calibration of a diesel engine’s two-stage model to get minimum carbon monoxide (CO) emission is described in this paper. The data used in this study is collected in an engine test bench which can measure CO emission of the engine for different cam angle, engine speed and torque values. The different two-stage models are created by different local and global model functions. The best model among these models is chosen by statistical parameters. Afterwards, this model is used for the calibration. The optimization of cam angle to minimize CO emissions is described. At the end of the calibration, the look-up table can be filled up with optimum cam angle values to be used in an electronic control unit of a diesel engine (ECU).


Introduction
Engine mapping is the process of modelling engine behaviour as a function of adjustable engine parameters.A primary application of engine mapping is the calibration of electronic engine controllers used to optimize the fuel efficiency of the engine subject to legislative limits on the emission of exhaust gases (Holliday T., Lawrence A.J., Davis T.P., 1998).
Engine maps consisting of three-dimensional contour plots of engine performance parameters such as break specific fuel consumption (bsfc) in the engine speed-break mean effective pressure (bmep) plane give a large amount of information in a very concise manner (Darda M., Sable A., Sastry G.V.J.).
The objective of this study is calibrating the diesel engine's cam angle for different operating conditions to get minimum CO emission by using the engine mappings created by two-stage modelling method with the help of model-based calibration toolbox which is supported by MATLAB.The cam angle term is used as the start of fuel injection according to the position of No:1 piston in the cylinder.
Model-based calibration refers to the process of using modern design of experiments, statistical modelling and optimization techniques and tools to define a methodology for efficiently producing high quality calibrations for complex engine applications, and model-based calibration provides a way to break down the calibration process into manageable subtasks (Sampson D.J.M., Sheridan L.A.D.).Including these advantages, the model-based calibration toolbox in MATLAB allows extracting calibrations directly from the models, and makes analysis possible without taking extra time (Maloney P., 2003).

Two-Stage Modelling
Using large polynomials for engine modelling causes the interpretation of the fitted model (Holliday T. 1995), and the number of parameters is too much which increases both the time and the cost for the tests, and it is also not so easy to extend the model, because of the difficulty to figure out how to add extra parameters (Esenturk E., 2004).
These problems started a new approach to engine modelling which is called two-stage modelling because of the nature of data collecting.This new approach improves the accuracy of the model, takes account of variability in the data, and easily identifies the outliers (Sameer M.P., Maloney P., 2003) ( Dr.Morton T.M. 2004).The previous studies about two-stage modelling are described in details in reference (Kazan R., Taymaz I., Gokce M.).
The cam angle is swept from maximum to minimum values for two-stage modelling, while the engine speed, torque, and vs. are fixed within each test group and CO emission is recorded for each test group after enough time is given for the stabilization of the diesel engine.The specification of the diesel engine, which is used for this study, is presented at Table -1.The local models are formed independently for each test group, and then global model is constructed by these local models.That is why this approach of modelling is called two-stage modelling.Once the global model has been estimated it can be used to calculate the local models' parameters for any engine speed and torque.
There are different functions for both local and global model in the model-based calibration toolbox, which can be chosen by the user.
The algorithm of two-stage modelling in the toolbox is presented in Fig. 1.In this figure, ' S (degree)' stands for cam angle which is the local input, and 'T (Nm)' stands for torque and ' N (rpm) is engine speed which are the global inputs in this figure.Since the cam is swept from minimum to maximum within each test group, it shall be chosen as local input whereas engine torque and engine speed shall be global inputs, because they are fixed within each test group.It is not possible to choose the local and global inputs other than these parameters because of the capability of test facility.
The linear least square method is used to form both local and global models in the toolbox.It is assumed that the error follows a normal distribution with zero mean and constant variance.To clarify the modelling procedures in the toolbox, quadratic function for both local and global model is chosen and examined.The number of the local models is equal to the number of measured test groups, which is 89 for this study.The fitted quadratic function that belongs to test group number 3 is displayed in Fig. 2. The points in this figure show the measured CO emission for each cam angle while the curve is the fitted quadratic function.
After the coefficients of each local model are estimated, the next step will be to express these coefficients in terms of global inputs, which is the second stage of two-stage modelling.The coefficients of global model in terms of engine speed and torque are shown below The matrix solution of equation (3) by using linear least square method is displayed below;

(
) ( ) where, The best-chosen model's surface response is displayed in Fig- 5.This figure can be used just for general idea about the model, it does not provide any cam angle value corresponding to engine speed and torque.
RMSE is the basic parameter to figure out how close the model is fitted, and it estimates the average mismatch between each test, whereas PRESS RMSE measures the predictive of each point in the data if it was not included in modelling process.
The model fit is getting better as RMSE is getting closer to zero.On the other hand, considering RMSE as the only measure for the model fit can cause skipping overfit problem.That is why PRESS RMSE shall be also considered for deciding the model fit.If PRESS RMSE is much bigger than RMSE, then there is an over fitting problem.

Calibration
After the models are built up, the second step is the calibration of the models in order to get minimum CO emission by using 'CAGE' browser of the model-based calibration toolbox.
After CO emission model is imported to 'CAGE' browser, the size and the parameters of the look-up table are chosen.The x-axis of the look up table is engine speed whereas the y-axis is torque.The inside of the look-up table will be filled by the cam angle, which satisfies the minimum CO emission.The size of the look-up table is up to the engineer; however the axes of the look-up table must be the global inputs of the two-stage model.
The combination of engine speed and torque values depends on the size of the look-up table.CO emission for each combination is calculated for the cam angle sweep by using the global model equation evaluated during modelling, and displayed as graph in the toolbox as shown in Fig- 6.Once the graph is drawn, the engineer can easily choose the minimum cam angle for CO emission.It can be easily observed in Fig- 6 that the cam angle for minimum CO emission shall be -4.44 ο for 1193 rpm and 1213 Nm.The CO emission at this cam angle is evaluated as 8.40 ppm.The optimal cam angle for CO emission can be found for random 4 or 5 combinations, and the rest of the table can be extrapolated.But as it is stated in the toolbox manual [10], the result of extrapolation cannot always satisfy the desired value for each combination.That is why each point must be checked manually, which consumes time depending on the size of the look-up table.

Results and Discussions
The model-based calibration is performed for a diesel engine by using real data to minimize CO emission.The calibration process consists of mainly two steps.The first step is creating engine mapping of the diesel engine by two-stage modelling, and the second step is importing this model into 'CAGE' browser to find the optimum cam angle for minimum CO emission.
One of the experienced advantages of model-based calibration toolbox is the ability to observe and remove away the outliers in modelling stage to improve the model.The calibration is very fast, simple, and needs no statistical information after the models are created which are the advantages of 'CAGE' browser.On the other hand, the results must be always checked after the calibration to be sure about it.Because it is experienced that the extrapolation does not always give the correct values.
The original cam angle of the diesel engine used in this study is -10 ο .The measured CO emission at this cam angle is 75 ppm for 1198 rpm and 1202 Nm.However the CO emission value evaluated after modelling is approximately 85 ppm for 1193rpm and 1213 Nm at this cam angle as shown Fig- 6.
Even though there is 10% percent error between the measured and modelled CO emission values, the decrease of CO emission can be easily observed by changing only the cam angle from -10 ο from -4.44 ο for the same engine speed and torque as presented in Fig- 6 It will be very helpful to consider also specific fuel consumption during the calibration of exhaust emissions for a diesel engine for further studies.

1XY
: calculated coefficients for each local model 1 in equation (6) is identical for the other coefficients of global model.The predicted versus observed values for 1 _ beta are plotted in Fig-3.In this figure, the points in circle are the outliers and these points can be removed to improve the model.Once these coefficients are found it is very easy and simple to find CO emission of the engine for any combination of engine speed and torque.During the modelling, five different combinations of local and global models for CO emission are investigated, and it is decided that the combination of 'cubic' as local model and 'multiquadratic radial basis function (RBF)' as global model is the best model for CO emission by comparing two-stage root mean squared error (RMSE) and predicted sum of squares (PRESS) RMSE values of the models.The RMSE and PRESS RMSE values of the examined models are displayed in Table-2.The fitted curve for test group number 3 after two-stage modelling is shown in Fig-4.The curve with empty circles present fitted two-stage model, whereas the curve with dots is the fitted curve for local model.
It is always necessary to consider both RMSE and PRESS RMSE values at the same time during the selection of best model.As it is observed, model 'D' has the smallest two-stage RMSE value, but there is a big difference between the model's two-stage RMSE and PRESS RMSE values.That is why model 'E' is chosen as the best model instead of model 'D'.

Figure 4 .
Figure 4. Two-stage modelling of test no: 3 Figure 5.The response surface of the best-chosen model Figure 6.The calibration for CO emission The mathematical definition of quadratic local model is presented below; CO : CO emission, S : cam angle,

Table 1 .
The specification of the diesel engine

Table Caption Table 1 .
The specification of the diesel engine Table2.The statistics of the investigated models