S. Rominus Valsalam Control & Instrumentation Group
ABSTRACT
The Kalman Filter yields a minimum variance estimate of the states of dynamical systems which are contaminated by white Gaussian noises, with the help of real-time measurements obtained from the systems. This paper presents the theoretical characteristics of the Kalman filter and the problems that are encountered in attempting to apply it to practical problems. A broad coverage of applications that have been accomplished since the invention of the filter is briefly presented. The implementation of the filter in a number of industrial control applications is briefly discussed. These include optimization of main steam temperature control in Thermal Power Plants, estimation and prediction of unmeasurable variables in a steel mill soaking pit control system, on- line failure detection in Nuclear Power Plants and on- line estimation of microbial activity using virtual sensors in activated sludge systems. These applications underline the importance of the Kalman Filtering technique for solving complex control problems, which were once deemed to be unsolvable. The paper explores the applications of the technique to build state-of-the-art Artificial Intelligence Systems and Micro Electro Mechanical Systems whose operating environment is characterised by a high degree of randomness. Multi-dimensional computations involving teaching, learning and adaptation can be carried out at a very fast rate using the technique. Keywords: Kalman Filtering, Industrial Control, Optimal State Estimation, State Prediction, Artificial Intelligence
1. INTRODUCTION The main advantage of Kalman filter is that it doesnt expect the system model to be very perfect. Its parameters and implementation methodology can be completely described by the first two statistical moments. Since its inception in 1960, different architectures have been worked out for the filter. It is widely used to address the problems of optimal state estimation, filtering and prediction in different fields where systems are found to be stochastic in nature. The Extended Kalman Filter and its parallel architectures assume enormous significance in the context of control and guidance, weather forecasting and distributed parameter systems. The most successful applications of Kalman filtering have been in the areas of Thermal Power Plants, Process and Petrochemical industries, Aerospace industry, Metallurgical industries, Artificial Intelligence and Communication systems.
2 2. THE KALMAN FILTER Filtering is concerned with the extraction of signals from noise. If the signal and the noise spectra are non- overlapping, it is possible to design a filter that passes the desired signal but attenuates the unwanted noise component. The resulting filter would either be of a low-pass, band-pass or high-pass type, depending on the relative frequencies of the desired signal and noise; and such filters can be designed using standard procedures. When the signal and noise spectra are overlapping, the question arises as to what is the best filter characteristic to pass the signal while suppressing the noise. If the process and measurements and are modelled by linear stochastic equations in the state- space form, an optimal solution to the filtering and prediction problem can be obtained by the Kalman filter.
The Kalman filter developed most notably by Rudolph E. Kalman around 1960 is a computer algorithm for estimating the state variables in a stochastic process in an optimal and recursive fashion. The error variance algorithm of the Kalman filter differs for different applications and in general various forms of Kalman filter exist
The first step in the derivation of the filter algorithms is to obtain a stochastic state- space model for the process and measurement. This is achieved by adding white noise components {W(k)} and {V(k)} to the process and measurement models respectively. {W(k)} and {V(k)} are assumed to be stationary gaussian random processes with zero mean. {W(k)} is known as the process noise and {V(k)} is known as the measurement (observation) noise. The matrices W(k) and V(k) represent the process and measurement noises respectively. Thus, the stochastic state-space model for the system is derived in the form
X s (k) = s X s (k-1) + s U s (k-1) + W (k-1) with X s (0) = X s 0 (1) Y s (k) = CX s (k) + V(k) (2) where is a coefficient matrix. W(k) and V(k) are assumed to be independent of each other. Let Q represent the covariance matrix of process noise W(k) and R represent the covariance matrix of measurement noise V(k). Q and R are given by
E [W(k) W T (j)] = Q (k- j) for all k, j E [V(k) V T (j)] = R (k- j) for all k, j where E is the expected value and is the delta function. The cross covariance of W(k) and V(k) is zero and is given by
E [W(k) V T ( j )] = 0 for all k, j E [V(k) W T (j )] = 0 for all k, j
3 Let X s (k/k-1) = estimate of the state vector X s at time k before measurement (apriori estimate)
X s (k/k) = estimate of the state vector X s at time k after measurement (aposteriori estimate)
X s (k+N/k) = predicated estimate of X s at time k+ N from the measurement data available upto time k
P(k/k 1) = covariance matrix of error in the apriori estimate of the state vector X s at time k
P(k/k) = covariance matrix of error in the aposteriori estimate of the state vector X s at time k
P(k+N/k) = covariance matrix of error in the predicated estimate X s (k + N/k)
With the above definitions, the standard Kalman filter is constructed using the following algorithm:
(i) Extrapolation algorithm
X s (k/k1) = s X s (k1/k1) + s U s (k1) (3a) P(k/k1) = s P(k1/k1) s T + Q T (3b) (ii) Gain algorithm K(k) = P(k/k1) C T [CP(k/k1) C T + R ] -1 (3c)
(iii) Estimation algorithm X s (k/k) = X s (k/k1) + K(k) [Y s (k) CX s (k/k1)] (3d)
(iv) Error variance algorithm P(k/k ) = P (k/k1) K(k) CP(k/k1) (3e) 4 The equation (3) is simple to implement on a digital computer. When the Kalman filter is used to estimate the state of a physical process, the measurement data Y s (k) is provided as the output of specific transducers. Let us assume that only very little is known about the process initially. This being the case, the initial state estimate and the associated error covariance should be X s (0/-1) = 0 and P(0 /-1) = I where I is the Identity matrix and is a very large number. However, this is not permitted in the filter algorithm equation (3) because it leads to the indeterminant form / in the gain algorithm. Therefore, an alternative form of equation (3) is derived below to accommodate this situation:
The equations that describe the Kalman gain matrix K(k) and the error covariance matrix P(k/k) are written in a different form, which permits to assign the most pessimistic values for P(0/-1). An alternative form of the filter is derived to carry out this task. The computational sequence of this algorithm is described below:.
(i) Error variance algorithm P(k/k) = [P -1 (k/k 1) + C T R -1 C ] -1 (4a) (ii) Gain algorithm K(k) = P(k/k) C T R -1 (4b) (iii) Estimation algorithm X s (k/k) = X s (k/k1) + K(k) [Y s (k) CX s (k/k 1)] (4c) (iv) Prediction (Extrapolation ) algorithm X s (k/k1) = s X s (k1/ k1) + s U s (k1) (4d)
P(k/k1) = s P(k 1/ k 1) s T + Q T (4e)
This algorithm provides a means of starting the estimation procedure with infinite uncertainty if the physical situation under consideration so dictates. By the term infinite uncertainty we mean X s (0/ -1) = 0 and P(0/ -1) = I In the discrete Kalman Filter algorithm given by equation (4), there is a projection step where the aposteriori estimate X s (k/k) is projected ahead to yield an apriori estimate X s (k+1/k). This is the best estimate of X s at time k+1 given all the measurement data up to Y s (k). Thus, the filter algorithm corresponds to a one step predictor. Prediction of the state vector X s beyond the stage where measurements are not available, can be done by recursively using equations (4d) and (4e) and the necessary algorithms can be written in the following manner
5
X s (i+ 1/k) = s X s (i/ k ) + s U s (k) (5.) P(i+ 1 / k) = s P(i/ k) s
T + Q T (6) For i = k , k + 1 , k + 2 , k + 3,
where X s (k/k) is obtained from Equation (4). In order to predict N steps ahead and to obtain the predicted estimate X s (k+N/k) of X s , equations (5.) and (6) are recursively used N times with the time index i = k, k+1, k+2 k+N1. 3. APPLICATIONS In this section four applications are described briefly to illustrate the usefulness of the filter in industrial control: 3.1 Optimization of main steam temperature control in Thermal Power Plants
In a thermal power plant, the highest work efficiency can be achieved by maintaining highest possible steam temperatures that the metallurgy of the plant is capable of withstanding. Therefore, the steam temperature and its enthalpy has to be elevated to the highest possible values during the superheating process. For example, the maximum allowable superheater steam temperature for a 210 MW boiler is 540 o C at 176.8 kg/cm 2
pressure. If there exists a temperature deviation of + 10 o C in closed loop steam temperature control, the main steam temperature set point cannot be closer to the maximum allowable limit and is normally set at a value 10 o C less than the maximum allowable limit. Consequently, maximum plant efficiency is not achieved. On the other hand, if the steam temperature is controlled within + 2 o C through one of the advanced control techniques, we can fix the set point at 538 o C and thereby the efficiency of the boiler can be improved. Indeed, for every running thermal power plant, the main steam temperature control is a potential candidate for optimization and a lot of research has gone into the subject over the last 15 years. Therefore, all out efforts are being taken in almost all thermal power plants to optimize the main steam temperature control.
The characteristics of the main steam temperature control can be improved by computing the present value of the required spray to be applied from the present value of the steam temperature T s and the past history of the system . In this method, T s is predicted for a period less than or equal to the process lag period using a state estimator and the predicted value of T s is used as the measured variable for a conventional PID controller. The Kalman Filter is selected as the state estimator and predictor. 6
The development of the control system comprises four steps:
(i) State estimation using Kalman Filter (ii) Process identification (iii) N-step state prediction using Kalman filter (iv) Design of predictive controller
The above design steps are discussed below in detail.
3.1.1 State estimation using Kalman filter
Using the stochastic state space model of the SSH, and the measured value of T s , the most probable value of the state vector X s is estimated by the Kalman filter as per the state estimation algorithm presented above.
3.1.2 Process identification Recursive Least Squares system identification scheme is used for the identification of the SSH system. The identified system parameter matrices are denoted as s and s .
3.1.3 N-step state prediction using Kalman Filter Keeping the estimated value of the state vector X s (k/k) as the base, the state vector is predicted ahead N-steps. The state estimation and prediction algorithm is summarized as follows.
1. Enter the estimation loop with initial values of Apriori estimate of state vector and its error variance 2. Compute error variance of Aposteriori estimate of state vector 3. Compute Kalman gain 4. Compute Aposteriori estimate of state vector X(k/k) 5. Predict N steps ahead to obtain the estimate X(k+N/k) 6. Use the predicted steam temperature in place of measured variable in the PID steam temperature controller 7 7. During every sampling instant, update the system parameters in the predictor to account for process variations 8. During the next sampling instant continue from step 2.
In some of the modern thermal power stations, main steam temperature deviation has been reduced from +10 o C to +2 o C using the above control system.
3.2 ESTIMATION AND PREDICTION OF UNMEASURABLE VARIABLES IN THE STEEL MILL SOAKING PIT CONTROL SYSTEM
In one of the versions of the steel- making process, the steel ingots, before they may be rolled at the rolling mill, typically pass through the soaking pit operation. The purpose of this operation is to equalize the temperature throughout the ingot masses as some prespecified level. Accurate description of the ingot temperature distribution would require their knowledge of analytical space-temperature relationship of the temperature valued at many points along the ingot side, top, and bottom surfaces, as well as throughout its mass. Typically, the ingots (5-20 tons each, 5-15 ingots/pit) come from the stripping yard where they are stripped off their moulds. At this time the ingot surface and centre temperatures are usually within the range of 1300-1900 o F and 2000-2800 o F, respectively. Sometimes though the ingots may come from cold storage, in which case their temperature will be that of the ambient. To do the job, the control system (today it is done by the operator) has to continuously estimate the current ingot temperatures at least on the surface and at the center, and to stop the operation when these temperatures arrive at the prespecified levels (usually their level is same for both temperatures) Under heating of ingots results in poor rolling mill performance or in returning the ingots to the pit for additional heat up; overheating (which is often the case) results in a waste of energy . According to the industry estimates, up to 15-20 percent of the fuel saving could be realized in this energy- intensive operation if an efficient temperature estimation system is put in operation. Fig 1 depicts a typical soaking pit and Fig.2 presents its control system.
8
THERMOCOUPLE AIR INGOTS CONTROL FUEL BURNER LID WASTE GASES RECUPERATOR CONTROLLER SOAKING PIT ESTIMATOR Kalman Filter PREDICTOR Kalman Filter + Y ref Error E Control U System disturbance s Measurement noise X real X est, Y est X pred ,,Y pred State X = x 1 ingot surface Temp x 2 ingot center Temp x 3 pit wall Temp
Output Y = y 1 pit wall Temp y 2 waste gas Temp
Control U = u 1 fuel flow u 2 air flow Environment Fig 2. Control system structure Fig. 1 Schematic diagram of soaking pit Y measured 9 SOAKING PIT MODEL A simple lumped linear model is assumed .In matrix form, this is X k+1 =A.X k + B.U k Y k+1 = C.X k+1 Where X k , X k+1 = plant state vectors at the moments k and k+1, respectively; U k = control variables vector at the moment k; Y k+1 = output vector at the moment k+1; and k =time index, k=0,1,2,..
PREDICTOR Ready to-roll time may be defined in a number of ways. For example, it is the time moment t r at which the average ingot temperature (this may be an arithmetic average or an average of weighted components) enters some temperature corridor and stays there . Thus t r is a moment for which
X 1 , set d 1 < x 1 (tr) < X 1
,set +d 1
X 2
, set d 2 < X 2 (tr ) < X 2 set +d 2
Assuming that after entering their corridors, both temperatures stay there; here X 1 , set, X 2 , set are preset temperatures and d 1 , d 2 define the widths of the corridors. For example X 1set =X 2set =2400 o F , d 1 =50 o F,d 2 =100 o F
Fig. 3 demonstrates the performance of their predictor on the actual data, The horizontal axis in fig. 3 corresponds to real time and vertical axis to the ready- to-roll time t r predictions. For this example, from the operation records it is known that the actual ready to-roll time corresponded to t r =306 min (t=o is the beginning of the pit cycle). Required accuracy of the prediction is +15 min ; this time corridor is shown in the fig. in broken horizontal lines. Thus the ready-to-roll time is the moment when the prediction curve enters the 306+15 min corridor and stays there. Thus in our example t r =210 min ; that is the right prediction was given (306- 210)=104 min in advance before the ingots were ready. Initial conditions entered into the estimator in this example differed from the actual ones by amounts that are realistic
10
3.3 Software sensor for on-line estimation of the microbial activity in activated sludge systems
The lack of reliable sensors and the high cost of advanced instrumentation are significant problems in the monitoring and control of wastewater treatment plants. In order to overcome these inconveniences, estimation techniques issued from control and systems theory have been applied in the development of software sensors for on-line estimation of bio-process variables. Wastewater processing by means of activated sludge is the most widespread sewage biological treatment process and its efficiency depends, besides other factors, on the capacity of a sensitive community of micro-organisms. Thus the availability of on- line information about the microbial activity is of crucial importance for the monitoring and control of the process. Bioactivities in the activated sludge process are intimately related to the dissolved oxygen (DO) concentration. A critical element in the synthesis of a software sensor is the available knowledge of the process. An accurate process model generally expresses this knowledge. However it is normally impossible to obtain an exact process model, so that the estimation algorithm must be robust enough to deal with model errors. A schematic diagram of a software sensor is shown in Fig. 4
Predicted ready-to- roll time fuel 0 125 250 375 500 306 88 177 210 265 Current time , min Pr e di ct e d
ti m e , m in Fig. 3 Predictor performance 306 Actual Ready-to-roll time 11
Fig. 5 shows the closed match of the the DO estimate to the measured data using the software sensor
Measurements Available knowledge Mathematical model Prior knowledge.. State and/or Parameter estimates Fig. 4 Principle of a software sensor Fig. 5 Real and estimated DO concentration DO real DO estimate 12 Nuclear Power Plant
Measurements y 3.4 On-line failure detection in nuclear power plant instrumentation In nuclear power plants, it is important that instrument failures be detected and accommodated before significant performance degradation results .if such a detection cannot be made, total shutdown of the plant may be necessary, resulting in lost power production and lost revenues to the operating utility. Fig 6 shows the structure of the instrument failure detection system configured for a nuclear power plant with the help of a bank of Kalman Filters.
4. CONCLUSIONS In this paper, the Kalman filter has been briefly described and its application to different industrial processes has been analysed. It is observed that the filter provides optimal state estimates and predictions where conventional measurement and estimation techniques are difficult to apply. In recent years, the Kalman filter is increasingly used for training artificial neural networks at a very fast rate and to fine tune fuzzy membership functions. State of the art Micro Electro Mechanical Systems are being designed using the innovations sequence of the Kalman filter which contains useful information about model uncertainties and measurement noises. The extended Kalman filter and its associates are widely used in the case of non- linear systems. Fig. 6 Instrument failure detection system 13 References
1. Cheek C.N, Nobbs K. and Munro N. (1978) Estimation and prediction of ingot temperatures on a pilot scale soaking pit, IFAC proceedings, Helsinki. 2. John N. Wallace and Ray Clarke (1983) The application of Kalman fittering estimation techniques in Power Station Control Systems, IEEE Transactions on Automatic Control, Vol. AC 28, No.6. 3. Jube Matsumura, Nobuyoshi Uwazumi and Hiroshi Lida (1983) Recently Developed Features of Control Technology in Thermal Power Plants, Hitachi Review, Vol. 32, No. 6, pp. 315320. 4. Kalman R.E. (1960) A new approach to linear filtering and prediction problems, Trans. ASME, Journal of Basic Engineering, Series 82 D, pp. 3545. 5. Kalman R.E and Bucy R.S (1961) New results in filtering and prediction theory, Trans. ASME, Journal of Basic Engineering, Series 83 D, pp. 95108. 6. Litchfield R. J., Campbell K. S. and Locke A. (1979) The application of several Kalman Filters to the control of a Real Chemical Reactor, Trans. I Chem E, Vol. 57, pp. 113118. 7. Nomura M. and Ogura N. (1985) Steam Temperature Prediction Control for Thermal Power Plant, Proc. IEEE seminar on Distributed Computer Control and Monitoring Systems, New Delhi. 8. Robert Grover Brown (1983) Introduction to Random Signal Analysis and Kalman Filtering, John Wiley & Sons. 9. Vladmir J Lumelsky (1983) Estimation and prediction of unmeasurable variables in the steel mill soaking pit control system, IEEE Trans, Automatic Control, pp. 388 400. 10. Wismer D.A and Wells C.H. (1972) A modern approach to Industrial Process Control, Automatica, Vol. 8, pp. 117125. 11. Oscar A.Z Sotomayor, Song Won Park, Claudio Garcia (2002) Software sensor for Online Estimation of the Microbial activity in activated sludge systems, ISA Transactions, pp. 127-143. 12. J. Louis Tylee (1983) On-Line failure detection in Nuclear Power plant Instrumentation, IEEE Trans. Automatic control, AC- 18 pp. 406-415.