24 lines
429 B
Mathematica
24 lines
429 B
Mathematica
|
% Load Data
|
||
|
|
||
|
load('./mat/huddle_test.mat', 't', 'u', 'y');
|
||
|
|
||
|
% Time Domain Data
|
||
|
|
||
|
figure;
|
||
|
plot(t, y)
|
||
|
ylabel('Output Displacement [m]'); xlabel('Time [s]');
|
||
|
|
||
|
% PSD of Measurement Noise
|
||
|
|
||
|
Ts = t(end)/(length(t)-1);
|
||
|
Fs = 1/Ts;
|
||
|
|
||
|
win = hanning(ceil(1*Fs));
|
||
|
|
||
|
[pxx, f] = pwelch(y, win, [], [], Fs);
|
||
|
|
||
|
figure;
|
||
|
plot(f, sqrt(pxx));
|
||
|
set(gca, 'XScale', 'log'); set(gca, 'YScale', 'log');
|
||
|
xlabel('Frequency [Hz]'); ylabel('ASD [$m/\sqrt{Hz}$]');
|