Effacer les filtres
Effacer les filtres

Bode form of a transfer function

45 vues (au cours des 30 derniers jours)
Dale
Dale le 27 Juin 2013
Suppose I have the transfer function k*(s-z1)/((s - p1)*(s - p2)), i.e., in the form that comes from the zpk() function. This form is convenient in that I can see immediately the location of the poles and zeros, but in order to obtain the gain at s=0, I need to compute k*(-z1)*(-p1)*(-p2). Is there a way to instead have the transfer function displayed in Bode form: k2*(-s/z1 + 1)/((-s/p1 + 1)*(-s/p2 + 1)), so that k2 = (-z1)*(-p1)*(-p2), and this represents the gain at s=0? I find this much nicer because I can see the poles, zeros, and the gain at s=0 without having to do any calculations in my head.
Thanks, Luke

Réponse acceptée

Arkadiy Turevskiy
Arkadiy Turevskiy le 27 Juin 2013
Yes, as descsribed in zpk doc.
>> sys=zpk(1,[2 3],4)
sys =
4 (s-1)
-----------
(s-2) (s-3)
Continuous-time zero/pole/gain model.
>> sys.DisplayFormat='frequency';
>> sys
sys =
-0.66667 (1-s)
---------------
(1-s/2) (1-s/3)
Continuous-time zero/pole/gain model.
  1 commentaire
Dale
Dale le 27 Juin 2013
Excellent! I knew Matlab must have this capability, thank you for finding it.

Connectez-vous pour commenter.

Plus de réponses (1)

David Sanchez
David Sanchez le 27 Juin 2013
s=tf('s');
% dummy values for the parameters
k=1;
z1=1;
p1=1;
p2=1;
H=k*(s-z1)/((s - p1)*(s - p2));
k2= (-z1)*(-p1)*(-p2);
H2=k2*(-s/z1 + 1)/((-s/p1 + 1)*(-s/p2 + 1));
bode(H);
figure;
bode(H2);
  1 commentaire
Dale
Dale le 27 Juin 2013
Modifié(e) : Dale le 27 Juin 2013
My question is not about how to make a Bode plot. It is about how to print the transfer function as it would be written mathematically.
Is there a single function built into Matlab that already implements the code you have written? I can write the function to do this myself for an arbitrary transfer function, but I figured since they already have tf() and zpk(), which put things in the other two common forms of a transfer function, they might have a Bode form of the transfer function as well. If they do have it, I can't find it anywhere in the documentation.

Connectez-vous pour commenter.

Catégories

En savoir plus sur Get Started with Control System Toolbox dans Help Center et File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by