Effacer les filtres
Effacer les filtres

How to convert from rad/sec to Hz in bode plot, and what can i understand from the bode plot shown?

59 vues (au cours des 30 derniers jours)
%% These are the results i get after using genetic algorithm to maximize
%% the performance of a boost converter with input filter
Cc=0.01;
Cf = 1.0559e-9;
Lc = 1e-9;
Lf = 1.0182e-9;
Vo = 500;
R = 5;
DutyC=0.76;
s=tf('s');
dp = 1-DutyC;
w1 = -Lc;
w2 = dp*R;
u1 = Lc*Cc*R;
u2 = Lc;
u3 = (dp^2)*R;
x1 = Lf*Cf*(Lc^2)*dp*R*Cc;
x2 = (Lf+Lc*dp*R-(dp^2)*R*Lf*Cf)*Lc*Cc+(Lc^2)*Lf*Cf*dp*R;
x3 = (Lf+Lc*dp*R-(dp^2)*R*Lf*Cf)*Lc+Lf*Cf*Lc*(dp^3)*(R^2);
x4 = (Lf+Lc*dp*R-(dp^2)*R*Lf*Cf)*(dp^2)*R-(dp^2)*R*Lc;
x5 = -(dp^4)*(R^2);
y1 = Lc*Cc*Lf*Cf;
y2 = Lc*Cc + Lc*Lf*Cf;
y3 = Lc+Lf+Lf*Cf*(dp^2)*R;
y4 = R*(dp^2);
Gvd = (Vo*(s*w1 + w2)*((s^4)*x1+(s^3)*x2+(s^2)*x3+s*x4+x5))/(dp*((s^2)*u1+s*u2+u3)*((s^3)*y1+(s^2)*y2+s*y3+y4));
bode(Gvd)

Réponse acceptée

Paul
Paul le 9 Jan 2023
Modifié(e) : Paul le 10 Jan 2023
To plot in Hz, rather than rad/sec.
Option 1:
%[m,p,w] = bode(Gvd); % w - rad/sec
%f = w/2/pi; % f - Hz
%subplot(211);semilogx(f,db(squeeze(m)));
%subplot(212);semilogx(f,squeeze(p));
Option 2:
Use bodeplot with the appropriate bodeoptions input to specify frequency in Hz
If Gvd is a transfer function of a BIBO stable system (I didn't check it), then the Bode plot tells you the amplitude and phase of the steady state sinusoidal output of the system relative to a sinusoidal input at a given frequency. For example, for a sinusoidal input with frequency 10^5 rad/sec, the steady state output would be sinusoidal with output amplitude increased by ~60 dB and phase shifted by ~360 deg.
BTW, if Gvd represents an unstable, input-ouput system, its output in response to a sinusoidal input will still include a sinusoid at the same frequency as the input with relative amplitude and phase determined from the Bode plot, but the output will also contain other terms that grow towards infinity.
  2 commentaires
Salah
Salah le 9 Jan 2023
Modifié(e) : Salah le 9 Jan 2023
Thank you @Paul, it worked!
if it is okay for my second part of the question, why the phase looks like this, shouldn't it reach -180?
Paul
Paul le 9 Jan 2023
Think of the phase as an angle that identifies the location of point on the unit circle in the complex plane. 180 deg is the same as -180 deg. That is, the point at (-1,0) can written equally as exp(1j*deg2rad(180)) or exp(1j*deg2rad(-180))
format short e
exp(1j*deg2rad(180)) % not quite perfect because pi not exactly represented
ans =
-1.0000e+00 + 1.2246e-16i
exp(1j*deg2rad(-180))
ans =
-1.0000e+00 - 1.2246e-16i

Connectez-vous pour commenter.

Plus de réponses (0)

Catégories

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

Produits


Version

R2022b

Community Treasure Hunt

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

Start Hunting!

Translated by