You are on page 1of 41

Telemark University College Faculty of technology M.Sc.

Programme

Lab Report 2010

Candidates: Santosh Karki (103257) Rabin Bilas Pant (103258) Sayed Md. Rezaur Rahman (103524)

Title: State Estimation Lab (Lab I) SCE4206, Systems and Control Laboratory

Table of Contents
1 INTRODUCTION .........................................................................................................3
1.1 Tasks ............................................................................................................................................... 3

2 MODELING ..................................................................................................................4
2.1 Introduction .................................................................................................................................... 4 2.2 Tasks ............................................................................................................................................... 4 2.2.1 Task 1: Model parameter adjustment ..................................................................................... 4 2.2.2 Task 2: State space model........................................................................................................ 6 2.2.3 Task 3: Discretization .............................................................................................................. 8

3 KALMAN FILTER ..................................................................................................... 12


3.1 Introduction .................................................................................................................................. 12 3.1.1 Task 4: Kalman Filter ........................................................................................................... 12 3.2 Simulator/Model ........................................................................................................................... 13 3.2.1 Task 5: Steady state Kalman Gain ........................................................................................ 13 3.2.2 Task 6: Use of built-in Kalman filter in LabVIEW .............................................................. 16 3.2.3 Task 7: Implementation of our own Kalman Filter on the simulator ................................... 18 3.3 Real Process .................................................................................................................................. 20 3.3.1 Task 8: Kalman Filter on Real Process ................................................................................. 20

4 OBSERVER ................................................................................................................23
4.1 Introduction .................................................................................................................................. 23 4.1.1 Observer ................................................................................................................................ 23 4.2 Simulator / Model.......................................................................................................................... 25 4.2.1 Task 10: Observer Gain ........................................................................................................ 25 4.2.2 Task 11: Observer on the Simulator ..................................................................................... 27 4.2.3 Task 12: Comparing estimators ............................................................................................ 28 4.3 Real Process .................................................................................................................................. 30 4.3.1 Task 13: Observer on the Real Process ................................................................................. 30 5 CONTROL SYSTEM ...................................................................................................................... 32 5.1 Introduction .................................................................................................................................. 32 5.2 PI (D) Control (Feedback Control) ............................................................................................... 32

Summary ........................................................................................................................ 40 References....................................................................................................................... 41

1 INTRODUCTION

The lab report is about implementing state estimators of the outflow of a tank based on level measurement, and a level control system based on feedback control. Lab Equipments used: LM 900 Level Tank, also referred as Real Process. USB 6008 DAQ, a simple low cost and multifunction I/O device from the National Instruments which is used for interfacing between the computer and the outside world, the Real Process in our case. Software used: LabVIEW LabVIEW Control Design and Simulation Module LabVIEW PID and Fuzzy Logic Toolkit

1.1 Tasks

The lab consists of the following main tasks:

Task 1: Modelling Task 2: Kalman Filter Task 3: Observer Task 4: Control Systems

2 MODELING 2.1 Introduction

The LM-900 Level Tank equipment is used in this lab work. The simple (linear) model of the Level tank is as follows:

or, where, h (cm) is the level in the water tank u (V) is the pump control signal to the pump A (cm2) is the cross section area K ((cm3/s)/V) is the pump gain Fout (cm3/s) is the outflow through the valve

2.2 Tasks 2.2.1 Task 1: Model parameter adjustment

The model parameters, cross section area (A) and the pump gain (K) are to be determined on the real process. For this, we developed a simulation model of the real process. Then, we performed experiments on the real process in parallel with the simulated model. With lots of hit and trials, we concluded the proper values for A found to be 78 cm2 and the value of K to be 9 (cm3/s)/V. This is confirmed as the plot of the height of water from the simulated model almost overlaps with the plot of the height of water from the real process which can be clearly shown Figure 2 with these values of the parameters used for the simulated model. Real process and the simulated model are operated simultaneously for this experiment. We will use these values of the parameters in the subsequent tasks.

Simulation Model of the Level Tank

Real Process

Figure 1: Block diagram for operation of real process in parallel with the simulated model The outputs i.e. height of the water level is measured simultaneously from the simulation model and the real process then are plotted against each other.

Figure 2: Screen dump to show the result of trial and error adjustment of simulated model with the real process (Level Tank)

In order to make confirmation and conclude if the values of parameters A and K are correct, we tried to plot the heights of water level at different values of the control signal i.e. u(t) as seen in Figure 2. With different values of u(t) also, the plots of measured heights from the simulated model and real process almost overlaps with each other. This gives the strong confirmation that the selected values of A and K are correct.

2.2.2 Task 2: State space model

The simple (linear) model of the Level tank,

or, The linear model of the Level Tank is set up on the following continuous linear state space form:

we set, and We assume is constant i.e.

Modeling the linear model of the Level Tank into the continuous linear state space model, we get , =
A B

So,

Also

So,
6

Hence, the values for the matrices are calculated and found to be as follows: A=

B= C= D=

MathScript The continuous state space model is implemented in the MathScript and the values of the matrices are calculated as shown in Figure 3.

Calculation of values for the matrices of the continuous state space model

Figure 3: Screen dump to show the calculation of values of matrices for continuous linear state space model of the real process in MathScript

LabVIEW

The continuous state space model is implemented in the LabVIEW and the values of the matrices are calculated as shown in Figure 5.

Figure 4: Block diagram for calculation of continuous state space model in LabVIEW

Figure 5: Front panel for the calculation of continuous state space model in LabVIEW The continuous state space model and equation (see Figure 5) are generated with the block diagram as shown in Figure 4.

2.2.3 Task 3: Discretization

The simple (linear) model of the Level Tank, .(1) or, ..(2)

The linear model of the Level Tank is set up on the following discrete linear state space form: ..(3) .....(4)

From equation (2); ..(5) Euler Forward discretization method defines; .(6) From (5) and (6);

.(7) Also, we have,

So, ..(8) Now, putting (7) and (8) in discrete state space form;

For sampling time, Ts = 0.1 second, We get;

Also, for estimation of hk ; We get;

For estimation of We get;

So, the matrices for discrete state space form with T s = 0.1 second for estimation of hs becomes; A= B= C= So, the matrices for discrete state space form with T s = 0.1 second for estimation of becomes; A= B= C=

LabVIEW

Figure 6: Block diagram for calculation of discrete state space model and equation in LabVIEW

10

The block diagram (see Figure 6) converted continuous linear state space model into the discrete linear state space model as shown in Figure 7. The discrete state space equation is also generated. For the conversion, the sampling time is taken to be 0.1 second. So, the model is discretized with 0.1 second. We found the resulted values of the matrices to be exactly same as that calculated using the Euler Forward discretization method.

Figure 7: Front panel for the calculation of discrete state space model and equation in LabVIEW

MathScript The continuous state space model is converted to discrete state space model using the MathScript as shown in Figure 8. The dicretization sampling time is taken to be 0.1 second. We calculated the values of matrices to be same as calculated using the Euler Forward discretisation method.

Calculation of values for the matrices of the discrete state space model

Figure 8: Screen dump to show the calculation of values of matrices for discrete state space model in Mathscript
11

3 KALMAN FILTER 3.1 Introduction

The Kalman Filter is a commonly used method to estimate the values of state variables of a dynamic system which is excited by stochastic (random) disturbances and stochastic (random) measurement noise. In this task, we will estimate the process variable(s) using Kalman Filter. 3.1.1 Task 4: Kalman Filter Let us consider the discrete time system with process noise w and measurement noise v is defined by:

The corresponding block diagram is shown below

The block diagram for a Kalman Filter with physical process is given by:

12

The predictor equation is given by

The corrector equation is given by

This is the basic operation principle of the Kalman Filter. Kalman Filter which is a commonly used method to estimate the values of state variables of a dynamic system that is excited by stochastic (random) disturbances and stochastic (random) measurement noise. Such, state estimates may be useful for the purpose of supervision and control 3.2 Simulator/Model

We have used only the simulation model i.e. the simulator of the real process, in the subsequent tasks. 3.2.1 Task 5: Steady state Kalman Gain

In order to find the steady state Kalman gain, we need the following information as shown in the Figure 9: Transition matrix, A Process noise gain matrix, G Measurement gain matrix, C Process noise auto-covariance, Q Measurement noise auto- covariance, R

13

LabVIEW

Checks if the system is observable?

Calculates the steady state Kalman gain

Figure 9: Block diagram to calculate the steady state Kalman Gain and check for the observability in LabVIEW In the block diagram as shown in Figure 9, with the supplied values for matrices A, B, C, we have supplied the inputs for matrices G, Q, R. Matrices A, G, C, Q, R are the inputs necessary for calculation of Kalman gain. We have used the built-in function Steady State Kalman gain.vi to calculate the value of Kalman gain. We have also used the built in function, CD Observability Matrix.vi to check if the system is observable?

Figure 10: Screen dump of the Front Panel to calculate the steady state Kalman Gain and check for the obervability With the block diagram as in Figure 9, we calculated the values for Observability matrix and Steady State Kalman gain as shown by the red circles in the front panel. A necessary condition for the Kalman Filter to work correctly is that the system, for which the states are to be estimated, is observable. The green glowing of the button indicates that the system is observable. (see Figure 10).
14

MathScript A necessary condition for the Kalman Filter to work correctly is that the system, for which the states are to be estimated, is observable. We have numbers of states in the State space model which are height, (h) and outflow, (Fout) written as; = h and =Fout, i.e. number of states of the model is 2

So, for the system to work correctly, the rank of the observability matrix should be equal to the number of states in the state space model. Figure 10, shows the calculation of the rank of the observability matrix which is 2. So, it concludes that that the system is observable and works correctly. We calculated the Steady state Kalman gain using the lqe function in MathScript and found to be found to be . But we calculated the Steady state Kalman gain using the LabVIEW and . So, the result calculated in MathScript doesnt match with that of the result

calculated in LabVIEW. So, we also calculated the steady state Kalman gain in MATLAB (see Figure 11) also and found to be which is similar to that of the gain calculated in .

LabVIEW. So, we confirm that the Steady state Kalman gain is

Figure 10: Screen shot to show the calculation of rank and Kalman gain using MathScript

15

Matlab:

Figure 11 : Screen shot to show the calculation of Kalman gain using MATLAB

3.2.2 Task 6: Use of built-in Kalman filter in LabVIEW

We have used the built-in discrete Kalman Filter to plot the simulated results Vs estimated results in this task.
SubVi for the simulated model of the real process Built-in Kalman Filter

Figure 12: Block diagram to implement built-in Kalman Filter


16

Figure 13: Block diagram to show subsystem of the SubVi for the simulated model

Simulation plot Estimation plot

Figure 14: Block diagram to implement built-in Kalman Filter Built-in Kalman Filter is used to estimate the height, h and outflow, F out . For good estimation, the Process noise auto-covariance matrix, Q is selected to be matrix,Q, the Kalman gain matrix changes and becomes . With the change in the . The estimation result follows

the simulated values of Fout for different values of simulated Fout. It takes very little time to settle to the values of simulated Fout. The results of simulated height and the result of estimated height, almost overlaps with each other. This shows that the estimations from the built-in Kalman Filter is good and shows good response to its corresponding simulated results.

17

3.2.3 Task 7: Implementation of our own Kalman Filter on the simulator

For the estimation of outflow (Fout) and the height (h), we created our discrete steady state Kalman Filter in the formula node. Then the simulated model is implemented on our discrete steady state Kalman Filter. The steady state space model of the real process is used. The model is

We set, SubVI of the simulation model and

Kalman Filter in formula node

Figure 15: Block diagram to implement our own discrete steady state Kalman Filter for estimation of height and outflow,Fout

18

X1 estimation X2 estimation

Kalman gain

Figure 16: Implementation of the Kalman Filter equations in a Formula Node. The Kalman Filter developed in the formula node is based on the following algorithm: Pre Step: Finding of the steady state Kalman Gain K The Kalman Filter gain is fetched from the simulation loop in the Block diagram (see Figure 12) Initial state estimate: xp(0) = xinit Predicted measurement estimate: yp(k) = g [xp(k)] Innovation variable: e(k) = y(k) yp(k) Corrected (Aposteriori) state estimate: xc(k) = xp(k) +Ke(k) Predicted (Apriori) state estimate: xp(k + 1) = f[xc(k), u(k)

19

Simulation line

Estimation line

Figure 17: Screen dump of the Front Panel to show simulated vs estimated plots for height and outflow, Fout using our own steady state Kalman Filter Figure 17 shows the estimation Vs simulation plots for both height (h) and outflow (F out). In order to better the estimation for outflow (Fout), we have changed the value for element (i22) of Process noise auto-covariance matrix, Q and the new Q matrix is . The estimation is

done at constant value of control signal u(t). With the change in the value of elements for the Q matrix, we noticed the change in Kalman Filter gain (see red circle in Figure 17). The new Kalman gain matrix is .The plot of simulated Vs estimated height (h) is extremely

good. Both these lines almost overlap with each other. And the estimated Vs simulated plot for outflow (Fout) is fairly good. The estimated line follows the simulated line after some settling time and then settles with the quite similar values for different values of Fout for simulation line. This confirms for the good operation of the Kalman Filter created in the Formula node.

3.3 Real Process


We have used the real process in the following task.
3.3.1 Task 8: Kalman Filter on Real Process

We have used the estimators on the real process in order to accomplish this task. With the real process, we have used the built-in Kalman Filter and the Kalman Filter developed in the Formula node i.e. from the scratch. So, these two Kalman Filters are the estimators for this task.
20

Built-in Kalman Filter

Kalman Filter developed in Formula node

Low pass Filter

Figure 18: Block diagram to implement built-in Kalman Filter and Kalman Filter developed in Formula node for estimation of height and outflow, Fout on the real process

Low Pass Filter

Figure 19: Discrete low pass Filter The output from the sensor measured by the DAQ device always contains some measurement noise. The measurement noises are usually high frequency unwanted signals. The effect of the measurement noises can be minimized by using a low pass filter. Discrete first order filter or time constant filter is used for the purpose. The discrete low pass filter is developed inside the Formula node (see Figure 18) and is implemented in order to remove the unwanted noises from the measured value of the outflow (Fout).
21

The continuous-time transfer function of first order low pass filter is,

Where u is the filter input, and y is the filter output.

is the time-constant of the filter.

By using the Backward differentiation approximation, we get the discrete version of the low pass filter as,

with the filter parameter

Here,

is the time step.

Estimation from the developed Kalman Filter Estimation from the built-in Kalman Filter

Figure 20: Screen dump of the Front Panel to show simulated vs estimated plots for height and outflow, Fout using built-in Kalman Filter and our own Kalman Filter on the real process With the implementation of the discrete Kalman Filter, we were able to get the noiseless estimations of height (h) and outflow (F out) using both the build-in and developed Kalman Filters. The plot of real measurement of height of water level from the Level tank almost
22

resembles with the estimated height of it from the bult-in and developed Kalman Filter. We gave variations to the outflow (Fout) of the Level tank through the output valve provided in the equipment. At different positions of the handle of the output valve, the outflow (Fout) varies. And these variations are well estimated by both the built-in and developed Kalman Filters (see Figure 20). The good operation of the estimators is supported with the fact seen as when the Fout is increased then the corresponding height of water level decreases proportionally and vice versa. We experimented at different positions of the handle of the output valve and conclude that the estimators work well. Good estimations are possible with the better choice of values of elements for the Process noise auto-covariance matrix, Q which is .

4 OBSERVER
4.1 Introduction
An alternative to Kalman Filter are observers. Observers have the same structure as the Kalman Filter, but they are calculated from the specified estimator error dynamics or in other words how fast and stable we want the estimates to converge to the real values i.e. we specify the Eigen value of the system.

4.1.1 Observer

An observer is an algorithm for estimating the values of state variables of a dynamic system. Observers are calculated from specified estimator error dynamics, or in other words: how fast and stable you want the estimates to converge to the real values. The purpose of the observer is to estimate assumed unknown states in the process. Figure 21 shows a block diagram of a real system (process) with observer.

23

Figure 21 : Real System with the Observer The operating principle of the observer is that the mathematical model of the process is running or being simulated in parallel with the process. If the model is perfect, xe will be equal to the real states, x. But in practice there are model errors, so there will be a difference between x and xe. It is always assumed that at least one of the states are measured. If there is a difference between x and xe, there will also be a difference between the real measurement y and the estimated measurement ye. This difference is the error e of the measurement estimate ye (it is also denoted the innovation variable): e = y ye This error is used to update the estimate via the observer gain K. Thus, the correction of the estimates is error-driven which is the same principle as of a error-driven control loop. The numerical value of the observer gain determines the strength of the correction. An alternative to observers is the Kalman Filter which is an estimation algorithm based on stochastic theory. The Kalman Filter produces state estimates that contain a minimum amount of noise in the assumed presence of random process disturbances and random measurement noise. In observers however, such stochastic signals acting on the system is not in focus. The theory and implementation of observers are simpler than with Kalman Filters, and this is benefical. One particular drawback about observers is that they are not straightforward to design for systems having more than one measurement, while this is straightforward for Kalman Filters.

24

4.2 Simulator / Model


We have used the simulator / model of the real process in the subsequent tasks. 4.2.1 Task 10: Observer Gain

Based on the Eigen values we will find the Observer gain K that is used to update the estimates. We use a 2 order Butterworth Polynomial:

Where the parameter T is used to define the speed of the response accornig to ,

We have set, This gives,

and

So, the coefficients in the polynomial are as follows;


=

We have used the Polynomial Roots.vi in order to find the poles as specified in the Butterworth polynomial. CD Akerman.vi is used to find the Observer gain. The observer gain type is specified to be predictive.

25

Figure 22: Block diagram to calculate the Observer gain using the LabVIEW

Figure 16: Screen dump of the Front Panel to show the result of calculation of Observer gain using the LabVIEW So, using LabVIEW, the gain of the Observer is found to be polynomial as
=

with the Butterworth

. Also the system is confirmed to be observable with the green

glowing of the indicator.

26

Figure 22: Screen dump to show calculation of Observer gain using MathScript

Using MathScript, the gain of the Observable is calculated and found to be almost similar to the value of the observable gain calculated using LabVIEW.

which is

4.2.2 Task 11: Observer on the Simulator We have used the CD Continuous Observer.vi built-in Observer function to estimate the process variables i.e. the height (h) of the water level and the outflow (F out) on the simulated model of the process. SubVi for the simulation model model

CD Continuous Observer.vi, built-in Observer function Figure 23: Block diagram to estimate the process variables using Observer on the simulation model using the built-in function
27

Simulation result

Estimation result

Figure 23: Screen dump of the Front Panel to show estimations of process variables using Observer on the simulation model using built in function The plots shown in Figure 23 shows the simulated Vs estimated results of both the height(h) and outflow(Fout) using the built-in Observer function. The estimation results look good. We tried to estimate for the different simulated outflow (Fout) values. The estimations follow the simulated results at different values of Fout as well. We noticed a small settling time and then the results almost give the same values. In case of the estimations for height (h), the estimation is fairly better. The estimation and simulated result almost gives the same values and apparently looks to overlap with each other. The operation is done at constant control signal i.e. u(t).

4.2.3 Task 12: Comparing estimators

In order to compare the estimations from the Kalman Filter and Observer, we have used built-in functions of Kalman Filter and Observers i,e, Discrete Kalman Filter.vi and CD Continuous Observer.vi simultaneously in the simulation model of the real process.

28

SubVi for the simulation model built-in Observer funtion

built-in Kalman Filter

Figure 24: Block diagram to estimate the process variables using built-in Observer and Kalman Filter on the simulated model

Figure 25: Screen dump of the Front Panel to show estimations of process variables using builtin Observer and Kalman Filter on the simulation model

Estimations of process variables using the built-in Kalman Filter and observer is shown in Figure 25. In order to confirm for the better estimations, we have tried to estimate different values of the Fout and the result of estimations is quite similar. Estimations follow the simulated values of both
29

the process variables. We didnt notice many differences with the estimations from these estimators except the fact that observer shows slight overshoot before the estimation is settled to the final result. So, it is fairly difficult to state that which estimator gives better estimation as the result of the estimations looks similar. Kalman Filter needs to make good choice of noise matrices for better response and good estimations. In case of the observer, the Eigen values define the response time. So, one should be careful to select the good Eigen values for better Butterworth polynomial and good response. Kalman Filter needs some experiments in selecting the values for noise matrices as Q, R, G and is tedious. Operation of Kalman Filter is dependent upon the noise measurements. Whereas Observer response time is depended upon the Eigen values and is quite simpler and less tedious. In spite of the fact that they are much closer to the operation principle, estimation result are almost similar, Kalman filter looks slight difficult to implement as it deals with the noise measurement.

4.3 Real Process


In the following task, we have used the real process. We took the assistance of the USB=6008 DAQ for this task.
4.3.1 Task 13: Observer on the Real Process

In this task, we have used the built-in Observer function i.e. CD Continuous Observer .vi and the built-in Kalman Filter i.e. Discrete Kalman Filter.vi simultaneously to compare the results of estimations of process variables. This operation is performed on the real process. We have also used the low pass filter to remove any high frequency measurement noise is the process of estimating the process variables. Details about the low pass filter are presented in the section 3.3.1.

30

built- in Observer function, CD continuous observer.vi

Low pass filters built in Kalman Filter, Discrete Kalman Filter.vi

Figure 26: Block diagram to estimate the process variables using buitl-in Observer and Kalman Filter on the Real Process

Estimation result from the Kalman Filter

Estimation result from the Observer

Figure 27: Screen dump of the Front Panel to show estimations of process variables using builtin Observer and Kalman Filter on the Real Tank

31

Estimations of process variables using the built-in Kalman Filter and Observer on the real process is performed at constant control signal (u(t)). We changed the real outflow of the water with the provided outlet valve. The result of the estimations of outflow (F out ) from the built in Observer and Kalman Filter produces almost the same result. When the real outflow is decreased using the outlet valve, then the corresponding estimations from both the estimators decreases proportionally and vice versa. As the estimation of outflow is decreased, then the estimated height of the water level increases and shows the same result as that of the real height of the real process at that instant and vice versa. Both Kalman Filter and Observer show good estimations of the process variables as seen clearly in Figure 27. Response time of the Observer depends upon the Eigen values. We noticed slightly faster response of the estimations by the Kalman filter than that of Observer at the initial phases of the estimations. Then the estimations show almost similar results.

5 CONTROL SYSTEM 5.1 Introduction


We have used the standard PI (D) controller to control our control system.

5.2 PI (D) Control (Feedback Control)


5.2.1 Task 14: PI (D) on Simulator The built-in PI(D) controller is used to control the water level (h) in the simulated model of the water tank. We have the linear model of the water tank is as follows;

or,

.(1)

We set,

32

So, equation (1) becomes, ..(2) Equation (2) confirms that our process is the integrator without any time delay. Tuning method for PI (D) control system Generally, Skogestads method results in better tracking property of the control system (without the quite large overshoot in the response after a step in the set point which is typical with Ziegler-Nichols method), but the disturbance compensation may for some processes become more sluggish than with the Ziegler-Nichols method. This sluggish compensation can however be speeded up by selecting a smaller value of C. So, we have selected the Skogestad tuning method for control of level in the simulated model as well as real process. Skogestads PID tuning method is a model-based tuning method where the controller parameters are expressed as functions of the process model parameters. It is assumed that the control system has a transfer function block diagram as shown in Figure 28.

ysp(s)

Control error U(s) Hc(s) Controller Hp(s) Process yf(s)

Figure 28: Block diagram of the control system in PID tuning with Skogestads method The design principle of Skogestads method is as follows. The control system tracking transfer function T(s), which is the transfer function from the set point to the (filtered) process measurement, is specified as a first order transfer function with time delay.

33

where TC is the time-constant of the control system which the user must specify, and t is the process time delay which is given by the process model and it is zero for our case, as defined by the linear model of the real process . Also from the block diagram, the transfer function can be found as:

So, from (1) and (2);

Here, the only unknown is the controller transfer function, Hc(s). By making proper analysis to the time delay term, the controller becomes a PI controller for our process transfer function. We have the linear model of the water tank is as follows; where, or, is the gain of the process

.(1)

We set,

So, or, or, or, Hp(s) = ..(2) . (3)

So, the transfer function of our process is given by equation (5) and it is the integrator with no time delay.

34

We have Skogestads tuning formula for the integrator without time delay as follows: Process type; Hp(s) = , where K = , where K =

Proportional gain; Kp = so, Kp = A/TcKg

Hence, Kp = 10.833 for A =78, Kg = 9 and Tc selected to be 0.8sec.

Integral time; Ti = CTc = 1.4 * 0.8 = 1.12

for C selected to be 1.4.

Originally, Skogestad defined the factor C as 4. This gives good set point tracking. But the disturbance compensation becomes quite sluggish. To obtain faster disturbance compensation, we have used, C = 1.4 The drawback of such a reduction of C is that there is more overshoot

So, with these parameters selection for Skogestad tuning method for PI controller, we implemented the PI controller to control the level, (h) in the simulated model of water tank.

35

Built-in Advanced PI(D) controller

Figure 29: Block diagram to estimate the height, h of the simulated tank using the PI control system Advanced PI (D) controller, the built-in controller in LabVIEW is used to estimate the set point of water level in the simulated model.

Set point result

Estimation result

Figure 30: Screen dump of the Front Panel to show estimations of the height h of the simulated tank using the PI control system The plot in Figure 30 shows the tracking of the set point of water level with the estimation using the PI controller tuned with the values calculated from the Skogestad tuning principle. With the parameters selected, we achieved the very good tracking of the set point of water level with slight overshoot at the start with estimation result to settle with the set point of the water level. The response is quick and settles with the set point with small settling time. In order to track the
36

set point, we maintained a constant outflow of the water, i.e. Fout taken to be 4cm3/s in the above case which helped in the tracking of the set point with fast response. Also, we tried to track the different values of the set point and the tracking result was good. 5.2.2 Task 15: PI(D) on Real Process In this task, we have implemented the PI control system on the real process tuned with the Skogested principle.

built-in Advanced PI(D) controller Low pass filter

Figure 31: Block diagram to estimate the height, h of the Real Process using the PI control system

Low Pass Filter The output from the sensor i.e. water level in the water tank measured by the DAQ device always contains some measurement noise. The measurement noises are usually high frequency unwanted signals. The effect of the measurement noises can be minimized by using a low pass filter. Discrete first order filter or time constant filter is used for the purpose. Details about the low pass filter are explained in section 3.3.1.

37

Figure 32: Discrete Low pass filter The low pass filter used in the process to remove the measurement noises is shown in Figure 32.

Set point result

Estimation result

Figure 33: Screen dump of the Front Panel to show estimations of the height h of the Real Process using the PI(D) control system

For the better tracking of the set point of the water level, we fine tuned the parameters for PI controller. We selected Kp = 10.830 and Ti = 1.130 sec. With these parameters, the tracking of the set point gave good response. We noticed a slight larger settling time of estimator (tracker) than that with the simulated model to catch up with the set point. In this process, we had maintained a constant outflow manually with the outlet valve. We also tried with the different values of the set point of the water level and those set points were estimated with slight settling time delay. So, the tracking of the set point with the implementation of PI control system was
38

implemented with the simulated model as well as with the real system. The tracking was quick with slight overshoot and small time delay in case of the simulated model. We fine tuned the parameters and implemented the PI control system in the real process which worked well and the set point was tracked with larger time delay to that of simulated model.

39

Summary
This lab on the state estimation gave us in depth knowledge about the estimators. Kalman Filter and Observer were explained in detail, their operating principle and practical applications knowledge was broadened. Process variables estimations were done with different conditions. The knowledge about PI(D) control system is made much clearer. PI(D) control system are used for control of process variables and effectiveness of PI(D) control system was felt of much importance. We were able to learn many things sbout LabVIEW. Many aspects and applications of the LabVIEW were covered during this lab perioed. Overall, the lab season was a very good learning experience for all of us.

40

References
http://home.hit.no/~hansha/, Oct 2010 Finn Haugen, Oct 2009, Model-based PID tuning with Skogestads method PhD, David Di Ruscio, March, 2010, State estimation and the Kalman Filter PhD, David Di Ruscio, October, 2010Linear Polynomial Estimator: The State Observer

41

You might also like