Unknown input observer design for fault detection and diagnosis in a continuous stirred-tank reactor

: Early and accurate fault detection and diagnosis (FDD) minimises downtime, increases the safety and reliability of plant operation, and reduces manufacturing costs. This paper presents a robust FDD strategy for a nonlinear system using a bank of unknown input observers (UIO). The approach is based on structure residual generation that provides not only decoupling of faults from model uncertainties and unknown input disturbance but also decoupling the effect of a fault from the effects of other faults. The generated residual was evaluated through the statistical threshold to avoid fault missing or false alarm. The performance of the robust FDD scheme was assessed by some sensor fault scenarios created in a continuous stirred-tank reactor (CSTR). The simulation result showed the effectiveness of the proposed approach.


Introduction
Fault detection and diagnosis (FDD) is an important task for improving the reliability and safety of process industries. Chemical process plants are susceptible to many common failures such as sensor faults, actuator faults, process faults, noise, and unexpected disturbances. These failures can cause product quality degradation, high operational costs, damage to equipment and instrumentation, and fatal accidents such as explosion, release of harmful materials, and fire that may cause harm to humans and the environment unless the failures are detected and diagnosed early.
FDD has become a significant aspect of the early warning system and control system design [1]. The conventional method is hardware redundancy, which involves additional implementation and maintenance costs, as well as occupies more space. The recent methods used are analytical redundancy methods, which only rely on the knowledge of the process model to generate fault features. Analytical redundancy methods reduce the cost, weight, and size of a system, and fault detection of not only the sensor (or the actuator) but also inside the system compared to hardware redundancy. However, it is more challenging due to equipment and process noises, the complexity of the system, and unavoidable modelling uncertainties [2].
In chemical engineering, a valuable classification scheme was presented in a three-part survey paper [3]. FDD methods are classified into three groups: data-driven, qualitative model-based, and quantitative model-based methods. Data-driven methods rely on the availability of huge historical data and higher-level user expertise [4]. Qualitative modelbased methods basically rely on physical laws using qualitative rule relationships. These methods generate a large number of hypotheses, which cause poor and spurious solutions [3]. Qualitative model-based methods that rely on explicit mathematical and first principle models have received considerable attention in recent years [5]. The techniques of parameter estimation, state estimation, and parity relations have received more attention to improve their application in chemical processes [3]. Among the quantitative-based models, unknown input observer (UIO) approach is considered as the most popular technique for decoupling of state estimation error from modelling uncertainties and unknown disturbances. This makes the residuals insensitive to unknown disturbances but sensitive to faults [2]. The development of a UIO for a linear chemical process has been applied in [6], where most studies deal with the theoretical development or numerical application on nonlinear systems [7].
The objective of this work is to detect and diagnose faults for a nonlinear process using a bank of well-designed UIOs. An exothermic continuous stirred-tank reactor (CSTR) model was used to evaluate the robustness of UIO by considering some sensor fault scenarios.

Unknown input observer design
The state space representation of the dynamic system can be written as a linear time-invariant (LTI) system with an additive unknown disturbance term: Where ( ) ∈ 5 , ( ) ∈ 7 , and ( ) ∈ 9 are the state vector, output vector, and input vector, respectively. ( ) ∈ ; is an unknown input disturbance vector for the <= sample, and , , are constant coefficient matrices, which are assumed to be known.
is an unknown input distribution matrix. The structure of the UIO has the following form: 5 is the state vector of the UIO, D( ) is the estimated state vector, and , , and are the matrices to be designed to achieve decoupling of the state estimation errors ( K = ( ) − D( )) from unmeasured disturbances. The dynamic state estimation error is defined by Equation 3: Therefore, abnormal behaviour results from any significant change will appear in this error.
The generated residual can be described as: To design an unknown input filter, these relationships must hold: The necessary conditions for the observer (Equation (3)) to be a UIO for the described system in Equation 1 are: (i) rank ( ) = rank ( ) and (ii) ( N , C) is an observable pair. To achieve these conditions, the number of independent measurements should be more or equal to the number of disturbances to be decoupled. Since N represents the free matrix of parameters in the design of a UIO, the matrix of the dynamic process needs to be stabilised by correctly identifying N using the pole placement routine available in the MATLAB Control System Toolbox. If ( N , C) is not observable, an observable canonical decomposition should be applied to the pair. A set of structured residuals is designed to facilitate fault isolation. Each residual is sensitive to all other faults but insensitive to its own fault [8].
When the system is only subjected to sensor faults and all actuators are fault-free, the output vector can be expressed as: Where ; ∈ 7 is an immeasurable vector considered as an additive bias resulting from sensor fault, X ∈ R NK5 is the j th row of the matrix , X ∈ R (7eN)K5 is obtained from the matrix C by deleting the j th row X , y X is the j th component of y, and X ∈ R 7eN is obtained from the vector by deleting the j th component y X . Based on this description, the generated residual of a bank of UIOs can be constructed as: Each residual is driven by all inputs and outputs except the j th sensor output. Moreover, it should be noted that the necessary conditions of the existence of decoupled residual generator satisfy the following equations in order to design UIOs: X = (( X ) i ( X )) eN ( X ) i , X = ( − X X ), N = X for = 1,2, … . X = N − N X X , Q X = X X , X = N X + Q X The FDD using residuals has two main steps: residual generation and residual evaluation. Residual generation is the core element of fault detection based on an observer. The residuals are generated using the difference between the real measured and the estimated output ( ( ) = ( ) − D( )). A well-designed residual is defined such that it is equal or approach to zero in the fault-free case and it deviates from zero when the system is faulty. The generated structure residual is evaluated in terms of the likelihood of a fault, and a logical decision-making rule is then applied to avoid a wrong decision, such as a missed fault or a false alarm. Either a fixed or adaptive threshold j is used on a residual evaluation function l ( )m [9]. The fault size is computed from the observer output state estimation as follows: ( ( )) ≤ j ( = 0) − (7) ( ( )) ≥ j ( ≠ 0) A nonlinear exothermic CSTR model adopted from [6] is considered and it can be viewed as a good prototype of various process industries for investigating the robustness of the FDD scheme and evaluating its performance. The exothermic CSTR system is used to produce an explosive organic compound (nitroamine), which is widely used in military applications. It is known as Research Department Formula X (RDX or hexogen), which is a highly energetic explosive. Besides, this explosive contains some toxic hazards during its manufacture [10]. Thus, RDX is produced from the reaction of hexamine with nitric acid. The details of operational conditions and the set of parameters at a steady state are illustrated in [6]. The reaction rate is expressed as:

Case study
The model is described by the following nonlinear ordinary differential equations: Possible safety issues may take place due to energy accumulation. This overheating may result from malfunction of the reactor or cooling system temperature sensors. Furthermore, the concentration of reactant A must achieve the process constraints. It is important to design a fault diagnosis scheme that can monitor and track the faults that seriously affect the steady state and closed-loop

Results and discussion
An exothermic CSTR, as a nonlinear model, was simulated in MATLAB by a set of ordinary differential equations (ODEs). The 4 th order Runge-Kutta method was used with sampling discrete time of 1 s. In order to construct the UIO, firstly, the observer gains need to be calculated and the observer existence needs to be checked. Appropriate observer gains were chosen based on the stability of the error dynamics of the system (Equation (3)), which can be solved using the Riccati equation. For this purpose, the condition ( ) was first verified, where rank ( ) = rank ( ) = 3. Next, the matrices H, T, and A1 were computed as: A bank of UIOs was designed to detect and diagnose sensor faults. Each designed UIO is able to generate structure residual insensitive to its own fault. Once a fault occurs, all the UIOs will be affected except the UIO that is insensitive to that fault and this will assist in detecting and isolating the fault, and later identifying the size of the fault. When the system has a fault-free condition, the generated residuals are identically equal to zero. The simulation results in Figure 1 show that all residuals are zero as long as no fault occurs in the system. These residuals can be used to obtain predefined threshold coefficients that will be applied for fault detection and isolation purposes.

Scenario 1
The robustness and performance of the proposed scheme were evaluated through three different sensor fault scenarios conducted on the system. In scenario 1, an abrupt fault was created in the concentration of component CA sensor with 0.2 mol L -1 as a drift from its  Figure 2(a), where the generated residuals were all affected except J(rs1) that was insensitive, and it had a value near zero, which clearly indicates the fault occurred in sensor 1. The fault was perfectly detected and isolated with a magnitude estimated using the observer estimated state D( ) of the insensitive observer as illustrated in Figure 2(b).

Scenario 2
In scenario 2, an abrupt fault was introduced at the reactor temperature Tr sensor with 10 K as a drift from its nominal value (occurred at t = 1,500 s). The simulation results in Figure  3(a) show that the generated residuals of the first and third sensors were affected whereas the generated residual of the second sensor J(rs2) was kept close to zero. Hence, fault detection has been successfully achieved from the residual features calculated from Equation 6, and the decision is made by comparing the value of these residuals with its threshold using Equation 7. Based on the principles of decoupling of a bank of UIOs and the sensitivity, the fault isolation is achieved to locate or determine the faulty sensor. Since the residual of reactor temperature sensor J(rs2) is insensitive to this fault, this indicates that the fault occurred in sensor 2. The fault magnitude is illustrated in Figure 3(b), which is estimated from the observer estimated state D( ) of the insensitive UIO.

Scenario 3
In scenario 3, an abrupt fault was introduced at the jacket temperature Tj sensor with 10 K as a drift from its nominal value (occurred at t = 1,500 s). The simulation results in Figure  4(a) show that the generated residuals of the first and second sensors were affected whereas the generated residual of the third sensor J(rs3) was insensitive. This means that a fault has occurred in sensor 3. The fault magnitude was estimated using the observer estimated state D( ) of the insensitive observer as illustrated in Figure 4(b).

Conclusion
In this paper, an FDD scheme for a nonlinear system was implemented. A bank of welldesigned UIOs was used to generate structured residual. These residuals are sensitive to the faults and insensitive to unknown inputs and modelling uncertainties. The performance and robustness of the proposed scheme were assessed in a nonlinear exothermic CSTR using three different fault scenarios of the sensor in the system. Satisfactory results were obtained. The faulty sensor was quickly detected and isolated by residual evaluation technique and the fault magnitude was directly estimated from the observer estimated state.