phase angle v/s frequency ratio of a damped Sdof system under harmonic force
Mostra commenti meno recenti
clear all;clc
q=1;
for zeta=[0.05,0.15,.375,1];
p=1;
for r=0:0.001:5
phi(p)=atan((2*zeta*r)/(1-(r^2)));
R(p)=r;
p=p+1;
end
plot(R,phi,'color',rand(1,3),'linewidth',2)
pause(1) %just to see it being draw
hold on;
q=q+1;
end
grid on
% This is my code for plotting phase angle v/s frequency ratio of a damped Sdof system under harmonic force
% But the graph obtaining is wrong
% Error starts from r=1
% The graph i expect is attached with this mail.
% Pls help me in correcting the error...
% This is the graph am Expecting......

4 Commenti
KSSV
il 11 Set 2017
YOu need not to use a loop and make code such complex: Check this code:
% zeta = [0.05,0.15,.375,1] ;
zeta = linspace(0.01,1,10) ;
r=0:0.001:5 ;
phi = zeros(length(zeta),length(r)) ;
for i = 1:length(zeta)
phi(i,:)=atan((2*zeta(i)*r)./(1-(r.^2)));
end
plot(r,phi)
grid on
I am suspecting the formula....show us your reference.
Bilal Ahmad
il 14 Gen 2020
Modificato: Bilal Ahmad
il 14 Gen 2020

from ( 0 to 1 ) graph is correct but from ( 1 to 5) graph scroll down and start from -1.5 which is not correct
Giuseppe Carbone
il 15 Mag 2020
Hi. I have a question: is it possibly to plot a legend for each value of the angle?
David Goodmanson
il 11 Set 2022
Modificato: David Goodmanson
il 11 Set 2022
If in KSSV's code you replace the atan line with
phi(i,:)=atan2((2*zeta(i)*r),(1-(r.^2)));
then the plot looks good. Compared to atan, atan2 keeps track of which quadrant to be in.
Risposte (1)
Shan Min Hii
il 19 Mag 2021
0 voti
clear all;close all;clc
for zeta=[0:0.2:1]
r=[0:0.1:3];
theta= atand((2*zeta*r)./(1-r.^2));
for j=1:31
if theta(j)<0
theta(j)=theta(j)+180;
end
end
plot(r,theta)
hold on
end
grid on
legend('\zeta=0','\zeta=0.2','\zeta=0.4','\zeta=0.6','\zeta=0.8','\zeta=1',"Location","southeast")
xlabel('w/w0')
ylabel('Phase Angle (\theta)')
title('Phase Angle')
This might help you.
2 Commenti
Charbell
il 10 Set 2022
good
william thomas
il 10 Ott 2022
what about amplitude or (whirl vector) vs. frequency ratio. should look like this..

Categorie
Scopri di più su Vibration Analysis in Centro assistenza e File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!