Week 14 pid may 24 2016 pe 3032

57
Closed Loop Systems Professor CHARLTON S. INAO Control System Design, PE -3032 Defence Engineering College Bishoftu, Ethiopia Controller s 1

Transcript of Week 14 pid may 24 2016 pe 3032

Page 1: Week  14 pid  may 24 2016 pe 3032

Closed Loop Systems

Professor CHARLTON S. INAOControl System Design, PE -3032Defence Engineering College

Bishoftu, Ethiopia

Controllers

1

Page 2: Week  14 pid  may 24 2016 pe 3032

Topics

• Proportional Mode• Derivative Mode• Integral Mode• PID Controller

2

Page 3: Week  14 pid  may 24 2016 pe 3032

Continuous controllers

Now in the continuous controller’s theory, there are three basic modes on which the whole control action takes place and these modes are written below. We will use the combination of these modes in order to have a desired and accurate output.

• Proportional controllers.• Integral controllers.• Derivative controllers.

Page 4: Week  14 pid  may 24 2016 pe 3032

Combinations of these three controllers are written below:

• Proportional and integral controllers.(PI)• Proportional and derivative controllers.

(PD)• Proportional ,integral and derivative

controllers(PID)

Page 5: Week  14 pid  may 24 2016 pe 3032

Proportional controlProportional control, the controller output is proportional to the error signal,Proportional controllers there are two conditions and these are written below:

• Deviation should not be large, it means there should be less deviation between the input and output.

• Deviation should not be sudden.Now we are in a condition to discuss proportional controllers, as the name suggests in a proportional controller the output (also called the actuating signal) is directly proportional to the error signal.

This can be analyzed (proportional controller) mathematically.

As we know in proportional controller output is directly proportional to error signal, writing this mathematically we have,

Page 6: Week  14 pid  may 24 2016 pe 3032

Proportional control

Removing the sign of proportionality we have,

Where Kp is proportional constant also known as controller gain. It is recommended that Kp should be kept greater than unity. If the value of Kp is greater than unity, then it will amplify the error signal and thus the amplified error signal can be detected easily.

Page 7: Week  14 pid  may 24 2016 pe 3032

Advantages of Proportional Controller Now let us discuss some advantages of proportional

controller. Proportional controller helps in reducing the steady state error, thus makes the system more stable.

Slow response of the over damped system can be made faster with the help of these controllers.

Disadvantages of Proportional Controller Now there are some serious disadvantages of these

controllers and these are written as follows: Due to presence of these controllers we some offsets in the system.

Proportional controllers also increase the maximum overshoot of the system.

Proportional control

Page 8: Week  14 pid  may 24 2016 pe 3032

Steady-state error

Page 9: Week  14 pid  may 24 2016 pe 3032

Integral Controllers

As the name suggests in integral controllers the output (also called the actuating signal) is directly proportional to the integral of the error signal. Now let us analyze integral controller mathematically. As we know in an integral controller output is directly proportional to the integration of the error signal, writing this mathematically we have,

Page 10: Week  14 pid  may 24 2016 pe 3032

Integral Controllers

Removing the sign of proportionality we have,

Where Ki is integral constant also known as controller gain. Integral controller is also known as reset controller.

Advantages of Integral ControllerDue to their unique ability they can return the

controlled variable back to the exact set point following a disturbance that’s why these are known as reset controllers.

Disadvantages of Integral ControllerIt tends to make the system unstable because it

responds slowly towards the produced error.

Page 11: Week  14 pid  may 24 2016 pe 3032

Derivative Controllers

We never use derivative controllers alone. It should be used in combinations with other modes of controllers because of its few disadvantages which are written below: It never improves the steady state error.It produces saturation effects and also amplifies the noise signals produced in the systemNow, as the name suggests in a derivative controller the output (also called the actuating signal) is directly proportional to the derivative of the error signal. Now let us analyze derivative controller mathematically. As we know in a derivative controller output is directly proportional to the derivative of the error signal, writing this mathematically we have,

Page 12: Week  14 pid  may 24 2016 pe 3032

Derivative Controllers

Removing the sign of proportionality we have,

Where Kd is proportional constant also known as controller gain. Derivative controller is also known as rate controller.

Advantages of Derivative ControllerThe major advantage of derivative controller is that it

improves the transient response of the system

Page 13: Week  14 pid  may 24 2016 pe 3032

Proportional and Integral Controller

As the name suggests it is a combination of proportional and an integral controller the output (also called the actuating signal) is equal to the summation of proportional and integral of the error signal. Now let us analyze proportional and integral controller mathematically. As we know in a proportional and integral controller output is directly proportional to the summation of proportional of error and integration of the error signal, writing this mathematically we have,

Page 14: Week  14 pid  may 24 2016 pe 3032

Proportional and Derivative Controller

As the name suggests it is a combination of proportional and a derivative controller the output (also called the actuating signal) is equals to the summation of proportional and derivative of the error signal. Now let us analyze proportional and derivative controller mathematically. As we know in a proportional and derivative controller output is directly proportional to summation of proportional of error and differentiation of the error signal, writing this mathematically we have,

Page 15: Week  14 pid  may 24 2016 pe 3032

PID controllerThe PID controller is the most widely used type of process controller. When combined into a single control loop the proportional, integral and derivative modes complement each other to reduce the system error to zero faster than any other controller.

Page 16: Week  14 pid  may 24 2016 pe 3032

PID control

Page 17: Week  14 pid  may 24 2016 pe 3032

PID control• PID control is a feedback control method that

combines proportional, integral, and derivative actions.

• The proportional action provides smooth control without hunting.

• The integral action automatically corrects offset.

• The derivative action responds quickly to large external disturbances.

Page 18: Week  14 pid  may 24 2016 pe 3032

Hunting

Page 19: Week  14 pid  may 24 2016 pe 3032

PID Action

Page 20: Week  14 pid  may 24 2016 pe 3032

PID Output Graph

Page 21: Week  14 pid  may 24 2016 pe 3032

What is tuning?

• Tuning is adjustment of control parameters to the optimum values for the desired control response. Stability is a basic requirement. However, different systems have different behaviour, different applications have different requirements, and requirements may conflict with one another.

Page 22: Week  14 pid  may 24 2016 pe 3032

Manual Tuning

• The operator estimates the tuning parameters required to give the desired controller response.

• The proportional, integral, and derivative terms must be adjusted, or tuned, individually to a particular system using a trial-and-error method

Page 23: Week  14 pid  may 24 2016 pe 3032

Semiautomatic or Autotune

• The controller takes care of calculating and setting PID parameters.

• Measures sensor output• Calculates error, sum of error, rate of change

of error• Calculates desired power with PID equations• Updates control output

Page 24: Week  14 pid  may 24 2016 pe 3032

PID Tuning Software

• PID Tuning Software: There is some prepared software that they can easily calculate the gain parameter. Any kind of theoretical methods can be selected in some these methods.

Some Examples:• MATLAB Simulink PID Controller Tuning, • BESTune, Exper Tune etc.

Page 25: Week  14 pid  may 24 2016 pe 3032

Ziegler-Nichols Rules for Tuning PID Controllers- Ziegler and Nichols proposed rules for determining values of

the proportional gain Kp, integral time Ti, and derivative time Td based on the transient response characteristics of a given plant.

- Such determination of the parameters of PID controllers or tuning of PID controllers can be made by engineers on-site by experiments on the plant.

- Such rules suggest a set of values of Kp, Ti, and Td that will give a stable operation of the system. However, the resulting system may exhibit a large maximum overshoot in the step response, which is unacceptable.

- We need series of fine tunings until an acceptable result is obtained.

Page 26: Week  14 pid  may 24 2016 pe 3032

Ziegler-Nichols 1st Method of Tuning Rule- We obtain experimentally the response of the plant to a unit-step input, as shown in Figure 10-2.- The plant involves neither integrator(s) nor dominant complex-

conjugate poles.- This method applies if the response to a step input exhibits an

S-shaped curve.- Such step-response curves may be generated experimentally or from a dynamic simulation of the plant.

Figure 10-2 Unit-step response of a plant.

Page 27: Week  14 pid  may 24 2016 pe 3032

Figure 10-3 S-shaped response curve.

L = delay timeT = time constant

Page 28: Week  14 pid  may 24 2016 pe 3032

Transfer function:

Table 8-1 Ziegler–Nichols Tuning Rule Based on Step Response of Plant (First Method)

Page 29: Week  14 pid  may 24 2016 pe 3032

Instructional Objectives

• At the end of the chapter, the students should be able to1) Understand the parameters of P, I,D and PID control mode.

2) Explain t he concept of proportional band and proportional gain.

3) Solve practical process and control problems related to the closed cloop control modes.

29

Page 30: Week  14 pid  may 24 2016 pe 3032

Proportional Control

Error0

Con

trolle

r Out

put

Proportional Band

Slope Kp

Proportional Gain=Kp=100/PB

Output=Kp e

Transfer function for the controllerGc(s)=Kp

30

Page 31: Week  14 pid  may 24 2016 pe 3032

System with Proportional controlC

ontro

ller O

utpu

t

Time0

Err

or

Time0

Kp=100/PBIout= Kpe + Io

Change in output(s) =KpE(s)Transfer Function= change

in output(s)/E(s)= Kp

31

Page 32: Week  14 pid  may 24 2016 pe 3032

Proportional ControlKpeSetpoifromOutputControllerinChange nt

errorinchangeKpSetpoifromOutputControllerinoChange 00

00 nt

BandoportionalKp Pr/100

)(

)(

sE

KpsoutputinChangeFunctionTransfer

IoKpeIout

32

Page 33: Week  14 pid  may 24 2016 pe 3032

Proportional Control Problems(Process)• A proportional controller

has Kp of 20 and a set point of 50% output. Its output is to have a which at the set point allows a flow of 2.0 m3/s. the valves change its output in direct proportion to the controller output. What will be the controller output and the offset error when the flow has to be changed to 2.5m3/sec?

50%

62.5%I0 2.0 m3/s

Solution:

By proportion:a) Controller Output at the new flow rate

50%/2.0m3/s =x%/2.5m3/s = 62.5%Iout = 62.5%

2.5 m3/sIout

b) The offset errorKp= change in output/EE= change in output/Kp = (62.5%-50%)/20 = 0.625%=0.63%

New Output

33

Page 34: Week  14 pid  may 24 2016 pe 3032

Proportional Control Problems• A pneumatic proportional

controller is used to control temperature within the range of 60 °C to 100 °C . The controller is adjusted so that the output pressure goes from 3 psi(valve to fully open) to 15 psi(valve to fully closed) as the measured temperature goes from 71 °C to 75 °C with the set point held constant. Find the gain and the proportional band.

• Answer a) Gain= 3psi/ °C b) PB= 10 %

Solution:

)s(E

Kp)s(outputinChangeFunctionTransfer

b)PB=75-71/ 100-60=0.1x 100%=10%

a)15psi-3psi/75-71C=3psi/C

34

Page 35: Week  14 pid  may 24 2016 pe 3032

Proportional Control Problem• .Consider the proportional mode

level controller system in the figure below. Valve A is a linear with a flow scale factor of 10 m3/hr per percent controller output.

• The controller output is nominally 50% with a proportional gain Kp=10%.A load change occurs when flow through valve B changes from 500 m3/hr to 600 m3/hr .Calculate the new controller output and the offset error.

Figure

35

Page 36: Week  14 pid  may 24 2016 pe 3032

Solution

36

Page 37: Week  14 pid  may 24 2016 pe 3032

Derivative Controllers

• Derivative Control- the change in controller output from the set point value is proportional to the rate of change with time of the error signal.

dtde

KdIoIout

Transfer Function by Laplace Transform

)())(( ssEKsIoIout D

Where Io = the setpoint output value Iout=the output value that will occur when the error e is changing at the rate de/dt KD = the constant of proportionality and is commonly referred to as the derivative time since it has units of time KDs = transfer function

37

Page 38: Week  14 pid  may 24 2016 pe 3032

Derivative ControllersE

rror

Con

trolle

r Out

put Time

Time

0

0

With derivative control, as soon as the error signal begins to change there can be quite a large controller output since it is proportional to the rate of change of the error signal and not its value. The controller output is constant because the rate of change is constant and occurs immediately as the deviation occurs.Derivative controllers do not respond to steady state error signals, since with steady error the rate of change of error with time is zero. Because of this the derivative control is often combined with proportional control.

Constant rate of change of error signal with time

38

Page 39: Week  14 pid  may 24 2016 pe 3032

Sample 1: Derivative Control-Problem

A derivative controller has a set point of 50% and derivative constant KD= 0f 0.4 s. What will be the controller output when the error a) changes at 1%/s, b) is constant at 4%?

Solution:

dtdeKdIoIout

Iout= Kd de/dt + Io

= 0.4s (1%/s) + 50% = 50.4%

a)

b) With de/dt = zero, then Iout=Io that is 50%. The output only differs from the setpoint value when the error is changing.Error is constant at 4%. Derivative of a constant is zero(0). Iout=50% 39

Page 40: Week  14 pid  may 24 2016 pe 3032

Integral Control

dtIKt

Io)(Iout0

e

Integral control – is one where the rate of change of the control output is proportional to the input error signal e.

d /dt=KIeI

I

IK is the constant of proportionality and, when the controller output is expressed as a percentage and the error as a percentage, has units of s -1 (per second). The reciprocal of KI is called the integral time TI and is in seconds. Integrating the above equation gives:

teI dIKt

d0

Iout

Io Io is the controller output at

zero timeIout= is the output at time t

40

Page 41: Week  14 pid  may 24 2016 pe 3032

• The transfer function is obtained by taking Laplace transform. Thus

Integral Control

(s)EKs1s)Io)(Iout I (

Transfer function = IKs1

41

Page 42: Week  14 pid  may 24 2016 pe 3032

Integral ControlC

ontro

ller O

utpu

t

Time0

The figure illustrates the action of an integral controller when there is a constant error input to the controller. We can consider the graph in two ways. When the controller output is constant, that is , dP/dt is zero, the error is zero.When the controller output varies at constant rate, that is dP/dt is constant, the error must have a constant value

Contro

ller

outpu

t

varie

s at

cons

tant

rate

Err

or

Time0

Constant percent error value

IoArea under the error graph between t=0 and t

edtt

0

42

Page 43: Week  14 pid  may 24 2016 pe 3032

Thus up to the time when the error occurs, the value of the integral is zero. Hence Iout=Io. When the error occurs it maintains a constant value.

Thus the area under the graph is increasing as time increases. Since the area increases at a constant rate, the controller output increases at a constant rate.

Integral Control

43

Page 44: Week  14 pid  may 24 2016 pe 3032

Integral Control-ProblemConsider an integral controller

with a value of KI =0.1/s and an output of 40% at the set point. What will be the output after times a)1 s b)2 s, if there is a sudden change to a constant error of 20%.

Given

KI = 0.1/s Io=40%E=error(constant)=20%

Required:a) Iout @ t=1sb) Iout @ t=2s

edtKIoIout I

t

0

)(When the error does not vary with time, the equation becomes

IoetKIoutetKIoIout

I

I

)(

a)t=1s; Iout=0.1x20x1 + 40= 42% b)t=2s; Iout=0.1x20x2 + 40= 44% 44

Page 45: Week  14 pid  may 24 2016 pe 3032

Integral Control Problem

An integral controller is used for speed control with a set point of 12 rpm with a range of 10 to 15 rpm. The controller output is 22% initially. The integral constant KI=-0.15% controler output per second per percentage error. If the speed jumps to 13.5% rpm, calculate the out put after a) 2 seconds

b)4 seconds c)6 seconds for a constant ep.

45

Page 46: Week  14 pid  may 24 2016 pe 3032

Solution

Iout=p=-0.15/s x -30 %x 6 sec + 22= 49%

Iout=p=-0.15/s x -30 %x 4 sec + 22= 40%

46

Page 47: Week  14 pid  may 24 2016 pe 3032

PID Controller Combining all three modes of

control(proportional, integral and derivative) enables a controller to be produced which has no offset error and reduces the tendency for oscillations. Such a controller is known as three mode controller or PID controller. The equation describing its action is:

Io)dtdeKedtKKp(eIout DI

t

0

47

Page 48: Week  14 pid  may 24 2016 pe 3032

PID Controller

)(sEsK(s)EKpKs1 (s)KpE(s)Io) -(Iout DI

Transfer function by Laplace Transform

)DI sKKs1 (1Kp Function Transfer

Problem: What will the controller output of a three mode controller having Kp as 4, KI as 0.6/s, Kd as 0.5s, a set point output of 50% and subject to error change show in the figure below, a) immediately the change starts to occur from t=0 sec, and b) 2 s after it starts.

1E

rror

(%)

1 2Time ,s

48

Page 49: Week  14 pid  may 24 2016 pe 3032

PID Controller Problem

Io)dtdeKedtKKp(eIout DI

t

0

Solution:a) For (a) e=0; de/dt= 1/s and

edtt

00

Thus: Iout= 4(0 + 0 + 0.5x 1) + 50 = 52 %

b) For (b) we have , at 2 sec, e=1%

1

Err

or(%

)

1 2

Figure

Time ,s

edtt

0

1.5 s , since the integral is the area under the error-time graph up to 2 s, only 1.5 sec because of the half area covered in square 1and de/dt= 0, for constant error rate change of 1 %

Iout=4( 1 + 0.6x 1.5 + 0) + 50= 57.6%49

Page 50: Week  14 pid  may 24 2016 pe 3032

Summary of the Characteristics of the Most Commonly Used Controller Modes

1. Two Position:Inexpensive.Extremely simple.

2. Proportional:Simple.Inherently stable when properly tuned.Easy to tune.Experiences offset at steady state. (OK for level control)

3. Proportional plus integral:No offset.Better dynamic response than reset alone.Possibilities exist for instability due to lag introduced.

4. Proportional plus derivative:Stable.Less offset than proportional alone (use of higher gain possible).Reduces lags, i.e., more rapid response.

5. Proportional plus integral plus derivative:Most complexRapid responseNo offset.Best control if properly tuned.

50

Page 51: Week  14 pid  may 24 2016 pe 3032

PID Controllers Summary

• Proportional gain increases response speed, to much gain causes system to ring.

• Integral gain kills steady-state error, wind-up and/or too much gain can cause system to go unstable.

• Derivative gain adds damping and stability, but is sensitive to jitter and noise.

51

Page 52: Week  14 pid  may 24 2016 pe 3032

52

PID Controllers Summary• Proportional term responds immediately to the

current tracking error; it cannot achieve the desired set point accuracy without an unacceptably large gain. Needs the other terms.

• Derivative action reduces transient errors.• Integral term yields zero steady-state error in

tracking a constant setpoint. It also rejects constant disturbances.

Proportional-Integral-Derivative (PID) control provides an efficient solution to many real-world control problems

Page 53: Week  14 pid  may 24 2016 pe 3032

Assignment/Homework to be graded as Project Report

PROBLEMS:

1)A proportional controller has Kp of 20 and a set point of 50% allows a flow of 8.0 m3/s . The valve changes its output in direct proportion to the controller output. What will be the controller output and the offset error when the flow has to be changed to 10 m3/s.

2) A derivative controller has a set point of 50% and a derivative constant Kd of 0.5s. The error starts at zero

and then changes at 2%/s for 3 s before becoming constant for 2 s, after which it decreases at 1%/sec to zero. What will be the controller output at

a) 0 s b) 1 s c) 4 s d) 6 s 3) An integral controller has a set point of 50% and a value of KI of 0.1/s. the error starts at zero and changes at

4%/s for 2 s before becoming constant for 3 s. What will be the output after times times of a) 1 s b) 3 s? 4) A three mode (PID) controller has Kp as 2, KI as 0.1/s, Kd as 1.0s, and a set point output of 50%. The error

starts at zero and changes at 5% for 2 s before becoming constant for 3s. It then decreases at 2%/s to zero and remains at zero. What will be the controller output at

a) 0 s b) 3 s c) 7 s d) 11 s?

53

Page 54: Week  14 pid  may 24 2016 pe 3032

Assignment-Project No. 3

• A proportional controller is used to control the height of water in a tank where the water level can vary from zero(0) to 4.0 meters. The required height of water is 3.5m and the controller is fully close a valve when the water rises to 3.9 m and fully open it when the water falls to 3.1m. What proportional band and transfer function will be required? Ans. a) PB=20% b) Kp=Transfer function=5

54

Page 55: Week  14 pid  may 24 2016 pe 3032

Assignment 2: Derivative Control-Problem

• A derivative controller has a set point of 50% and derivative constant of Kd 0.5s. The error starts at zero and then changes at 2%/s for 3 seconds before becoming constant for 2 seconds, after which it decreases at 1%/s to zero. What will be the controller output a t

a) 0 s and b)1s c)4s d)6s

55

Page 56: Week  14 pid  may 24 2016 pe 3032

Assignment 3 Problem Integral Control

• An integral controller has a set point of 50% and a value of Ki of 0.1/s. The error starts at zero and changes at 4%/s for 2 s before becoming costant at 3 s, what will be the ouput after times of a) 1 s b) 5s

56

Page 57: Week  14 pid  may 24 2016 pe 3032

Assignment 4. Problem PID Controller

A three mode (PID) controller has Kp as 2, KI as 0.1/s, Kd as 1.0s, and a set point output of 50%. The error starts at zero and changes at 5% for 2 s before becoming constant for 3s. It then decreases at 2%/s to zero and remains at zero. What will be the controller output at a) 0 s b) 3 s c) 7 s d) 10 s?

57