How to create a FRF graph of the real and imaginary parts of a signal
84 ビュー (過去 30 日間)
古いコメントを表示
Hello,
I ran a hammer test on a structure that gave me acceleration and force data. I know MATLAB has an inbuilt function, modalfrf, that outputs a FRF in terms of magnitude and phase, but I'm trying to get FRF plots in terms of the real and imaginary parts of the data. Does anyone know how I would go about getting this?
As a bonus question, I know from the modalfrf plot that I can pick out natural frequencies. Is there a way for me to get matlab to calculate the damping ratio of the specific natural frequencies I want?
Thank you so much for your time!
0 件のコメント
採用された回答
Star Strider
2023 年 10 月 31 日
It appears that is its default behaviour if you request outputs —
load modaldata
figure
subplot(2,1,1)
plot(thammer,Xhammer(:))
ylabel('Force (N)')
subplot(2,1,2)
plot(thammer,Yhammer(:))
ylabel('Displacement (m)')
xlabel('Time (s)')
winlen = size(Xhammer,1);
figure
modalfrf(Xhammer(:),Yhammer(:),fs,winlen,'Sensor','dis')
[frf,f] = modalfrf(Xhammer(:),Yhammer(:),fs,winlen,'Sensor','dis');
figure
semilogy(f, real(frf), 'DisplayName','Real')
hold on
plot(f, imag(frf), 'DisplayName','Imag')
plot(f, abs(frf), 'DisplayName','Magnitude')
hold off
grid
legend('Location','best')
2 件のコメント
Star Strider
2023 年 11 月 1 日
Thank you! As always, my pleasure!
I completely understand. I debated on that, and finally decided on a logarithmic axis because I used an example from the documentation, and the default modalfrf plot it produces uses a logarithmic magnitude scale. (I used the logarithmic y-axis here to demonstrate that it produced the same plot.)
その他の回答 (0 件)
参考
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!