Plot Root Locus for PD-Controller
23 次查看(过去 30 天)
显示 更早的评论
Hi!
I'm looking to plot the Root Locus for my system.
With G =
G = tf([2],[1 2 1 0]);
G =
2
---------------
s^3 + 2 s^2 + s
Continuous-time transfer function.
I want to apply a D-regulator, i.e
.
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/378176/image.png)
How do I use the rlocus plot to draw with respect to
as my parameter and not a P-regulator which is standard?
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/378181/image.png)
Muchos gracias
0 个评论
回答(1 个)
Jon
2020-10-12
编辑:Jon
2020-10-12
I don't think you can do it directly with the rlocus command which is just for a variable overall open loop gain.
One way to do it is to make your own loop something like this (here I just put in some numerical values to give you the idea you will have to adapt to the details of your situation)
% proportional gain
kp = 3
% derivative filter constant
tauf = 20
% desired range of derivative gain
kd = linspace(0,30,100); % put your range in here
% define plant transfer function
G = tf([2],[1 2 1 0])
% loop to find poles (root locus) as a function of derivative gain
numPoints = length(kd) % number of points to evaluate on root locus
for k = 1:numPoints
% form open loop transfer function for plant and controller
Gol = (kp + kd(k)*s/(tauf*s + 1))*G;
% find poles and zeros
p = pole(Gol);
z = zero(Gol);
% plot the root locus points, need to add appropriate labels etc
hold on
plot(real(z),imag(z),'o')
plot(real(p),imag(p),'*')
end
hold off
4 个评论
Jon
2020-10-13
From what I can determine from the documentation for rlocus can only be used when you can factor out the parameter of interest so that it can be applied as a multiplicative constant (overall loop gain). Otherwise you will have to make your own plot, for example as I show in my script above. It sounds like you already know how to do this though. If this answers your question please mark it as answered so others will know.
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Classical Control Design 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!