%% Clear Workspace and Close figures clear; close all; clc; %% Intialize Laplace variable s = zpk('s'); addpath('./mat/'); % Load Data :noexport: load('huddle_test.mat', 't', 'y'); y = y - mean(y(1000:end)); % Time Domain Data figure; plot(t(1000:end), y(1000:end)) 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(1000:end), win, [], [], Fs); figure; plot(f, sqrt(pxx)); set(gca, 'XScale', 'log'); set(gca, 'YScale', 'log'); xlabel('Frequency [Hz]'); ylabel('ASD [$m/\sqrt{Hz}$]'); xlim([1, Fs/2]);