# Root locus for an open loop transfer function?

The function, rlocus(), in MATLAB is used for closed loop system roots for variation in gain K. However, I am curious if there is a similar function for variation in parameter of open loop function. I have tried using the pzmap() function and iterating to vary RL & IL. Unfortunately, it doesn't plot enough points on the graph. Are there any functions that will allow me to plot an open loop transfer function? I am trying to plot the transfer function below:

$T(s)= \frac{(RL+sIL)(3s^3+12s^2+12s+4)}{8s^4IL+s^3(28IL+8RL+3)+4s^2(7IL+7RL+3)+4s(2IL+7RL+3)+8RL+4}$

Thank you for your help.

• Have you considered utilizing the tf() function and then doing rlocus()? For instance, let's call your transfer function above $T(s)$... so t=tf(your transfer function) and then rlocus(t). – user103380 Jun 23 '18 at 23:15
• The input to the root locus procedure is the open-loop TF. This is because the RL starts at the open-loop poles and ends at the open-loop zeros. The RL determines closed-loop performance from the open-loop TF, so your question is meaningless. – Chu Jun 24 '18 at 9:37
• Root locus is a plot of the closed-loop poles as the feedback gain changes. Poles of an open-loop system do not change position with open-loop gain. To say "pzmap doesn't plot enough points", or "root locus for open loop" are an indication of theoretical misconception. – Vicente Cunha Jun 24 '18 at 16:25
• @VicenteCunha the definition of Root locus you've stated it is incorrect. The thing you've stated it one of many root locus's cases but the common one. – CroCo Jun 26 '18 at 3:07
• @CroCo I'd be happy to delete my comment if you point out where I'm wrong. From the matlab documentation: "The root locus gives the closed-loop pole trajectories as a function of the feedback gain k (assuming negative feedback). Root loci are used to study the effects of varying feedback gains on closed-loop pole locations.". I understand possible variations of use for control design, but the same definition still fits for an augmented system. – Vicente Cunha Jun 26 '18 at 14:13

Ignoring the semantics of "root locus," you can certainly plot the roots of a polynomial as its coefficients change. The following script plots the set of poles of your system as $RL$ varies from 0 to 10000 with $IL$ fixed at 1:

IL = 1;
RLvec = linspace(0,10e3,1e5);
rts = zeros(1e5,4);
for k = 1:length(RLvec);
RL = RLvec(k);
D = [8*IL, 28*IL+8*RL+3, 4*(7*IL+7*RL+3), 4*(2*IL+7*RL+3), 8*RL+4];
r = roots(D);
rts(k,:) = r';
end;
figure
hold on;
for b = 1:4;
plot(real(rts(:,b)),imag(rts(:,b)));
end;
xlim([-5,0]); grid on;


It executes for me in under 5 seconds.

Admittedly, it does not show how the roots move as both parameters change, but that task is complicated by having a two-dimensional domain and a two-(real)-dimensional range.

• In case the roots don't come out 'sorted', the connecting lines may vary wildly. I couldn't find documentation that says that the roots returned will be in any particular order. [in.mathworks.com/matlabcentral/answers/… – AJN May 26 '20 at 12:53
• My solution to that problem would be to omit the "lines" Matlab interpolates between data points: plot(real(rts(:,b)),imag(rts(:,b)),'.'); – HermitianCrustacean Jun 7 '20 at 21:33