0% found this document useful (0 votes)
9 views3 pages

PI Controller

The document discusses designing a PI controller for a plant using root locus analysis in MATLAB. It describes adding an integrator to the plant transfer function to achieve zero steady state error. The code plots the root locus, selects a PI controller zero location, and finds the gain K to satisfy design specifications of settling time less than 6.25s.

Uploaded by

Pablo Padilla
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
9 views3 pages

PI Controller

The document discusses designing a PI controller for a plant using root locus analysis in MATLAB. It describes adding an integrator to the plant transfer function to achieve zero steady state error. The code plots the root locus, selects a PI controller zero location, and finds the gain K to satisfy design specifications of settling time less than 6.25s.

Uploaded by

Pablo Padilla
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd

a.

Since the input reference is limited to step changes, but the plant transfer
function has no pole at the origin, an integrator must be added to achieve
zero steady state error. Since the system is already stable, a PI controller
can be used to meet the design specifications.
The following MATLAB code was used to plot the primitive root locus, select
the zero location for the PI controller, plot the new root locus for the
controlled system, and select a gain K that satisfies the design criteria
(settling time of less than 6.25s):

%%Design of PI controller using Root Locus

%Open-loop plant: s-domain polynomials


B = [16];
A = [1,6,8];
%Open-loop plant s-domain transfer function object
SYS = tf(B,A)

%Root locus for proportional controller


figure(1)
%[R, K] = rlocus(SYS, [0:1e-4:10]);
rlocus(SYS, [0:1e-4:10])
%rlocus(SYS)
sgrid

%PD controller zero location


z = -1.5;
% D parameter
I = -z;

%Open loop controlled system polynomials


Bc = conv(B,[1,I]);
Ac = [A,0];
SYSc = tf(Bc,Ac)

figure(2)
rlocus(SYSc, [0:1e-4:40])
%rlocus(SYSc)
sgrid

[Kp,r] = rlocfind(SYSc,[-0.8])

The zero location was chosen at s=−1.5, to ensure the existence of root locus
in the desired zone of the s-plane.
The last function in the code returns the value of K required to get a particular
root in the denominator of the closed loop transfer function, together with the values
of all the roots generated. Since 5 τ ≤ 6.25 s ⇒ σ ≤−0.8 , we could have chosen any root
with real part less than -0.8 if the rest of the roots were placed to its left. For this
design, we chose σ =−0.8 , obtaining the following gain Kp, roots and the final PI
controller transfer function:

Kp =

0.2743

r =

-2.6000 + 1.2118i
-2.6000 - 1.2118i
-0.8000 + 0.0000i

( 1s )
∴ G ( s )=0.2743 1+

You might also like