Professional Documents
Culture Documents
Title:
Control System Modeling and Step Response
Objective:
(i) (ii) To design proportional-integral-derivative (PID) controller for closed loop control. To evaluate the performance of different controllers based on maximum overshoot, rise time, settling time and steady-state error.
Procedure:
(a)Open loop system 1) Firstly, a new m-file is created by clicking File -> New -> M-file in the MATLAB command window. A MATLAB editor/debugger window pops up. This is to view the open loop step response. In this window, the following codes is typed and saved as file. num = 1; den = [1 10 20]; step (num, den) num is denoted as the numerator polynomial coefficients in s; den is denoted as the denominator polynomial coefficients in s. Step is a MATLAB function. 3) The m-file is run by clicking Tools -> Run in the MATAB editor/debugger window. The following plot is obtained and shown in figure 1. The final value is checked using Final Value Theorem.
2)
4)
5)
From the response obtained, the maximum overshoot, rise time and settling time is found. (The steady-state error is calculated based on Final Value Theorem.)
(b)Proportional(P) control 1) The closed loop transfer function of the above system with a proportional controller is
The derivation of the closed loop transfer function is shown in table 1. 2) Let the proportional constant equal 300 and the m-file is changed to the following:
3) This m-file is run to obtain the step response plot as shown in figure 2. 4) The relevant entries in Tables 1 and 2 are completed.
(c)Proportional-Derivative(PD) control 1) The closed loop transfer function of the given system with a PD controller is derived and recorded in Table 2. 2) Let equal 300 and let equal 10. A new m-file is created, the necessary codes are typed and the m-file is run and the result is shown in figure 3. 3) The relevant entries are completed in Tables 1 and 2.
(d)Proportional-Integral(PI) control 1) The closed loop transfer function of the given system with a PI controller is derived and recorded in Table 1. 2) The Value is reduced to 30, and let equal to 70. A new file is created, the necessary codes are typed and the m-file is run and the results are shown below in figure 4. Note that the proportional constant have been reduced because the integral term also reduces the rise time and the overshoot is increased as the proportional term does (double effect). 3) The relevant entries are completed in Tables 1 and 2.
(e)Proportional-Integral-Derivative(PID) control 1) The closed loop transfer function of the given system with a PID controller is derived and recorded in Table 1. 2) Trial and error method is used to choose the parameters Four sets of values for are tried and the closed loop step responses are noted. One parameter is varied at one time, in order to see the effects of changing the parameter. These results are recorded in Table 2. The trial and errors are shown in figure 5(i), 5(ii), 5(iii), 5(iv), 5(v). 3) The method is repeated using 4) The relevant entries are completed in Tables 1 and 2. .
Results:
Table 1
(a) Open loop Transfer function: No. of finite zeros = 0 No. of poles = 2 System order= 2
Final value:
= = = (b) Proportional(P) control Transfer function Derivation: No. of finite zeros = 0 No. of poles = 2 System order= 2 ( )( )
= = ( )
( )
Final value:
= = ( )
( )
= =0.938 (d) ProportionalIntegral(PI) control Transfer Function Derivation: No. of finite zeros = 1 No. of poles = 3 System order= 3
= =
= Final value: = = ( )
= Final value: = = ( )
= =1
Table 2 Controller
Steadystate error
0.95 0.062 0.062 0 0 0 0 0 0
(a) Open loop (b) P (c) PD (d) PI (e) PID (i) (ii) (iii) (iv) (v)
Exercise:
1)
R + e
GC Controller u Plant Y
R + -
The equation in the denominator of the transfer function is used to find damping frequency. Where a = 1, b=20 and c=320 The answer obtained is -20 j28.6. Therefore the system is underdamped.
3) A system without any controller is an open loop system whereas systems with P, PD, PI and PID controllers are closed loop systems.
Conclusion:
Objectives of the experiment are achieved. All the different controllers are evaluated in terms of their performance. Using the PID controller we have made several trial and error using different values of KP, KI and KD and out of the combination of values we have tried with, KP = 400, KI = 400 and KD = 50 (as highlighted) gives the best results with zero maximum overshoot, zero steady state error and the lowest rise time and settling time.