Add freq analysis for active damping techniques
This commit is contained in:
parent
b2ed7cbd63
commit
afaefbd2f0
File diff suppressed because it is too large
Load Diff
@ -2199,25 +2199,22 @@ Inertial Control:
|
|||||||
#+CAPTION: Comparison of one off-diagonal plant for different damping technique applied ([[./figs/plant_comp_damping_coupling.png][png]], [[./figs/plant_comp_damping_coupling.pdf][pdf]])
|
#+CAPTION: Comparison of one off-diagonal plant for different damping technique applied ([[./figs/plant_comp_damping_coupling.png][png]], [[./figs/plant_comp_damping_coupling.pdf][pdf]])
|
||||||
[[file:figs/plant_comp_damping_coupling.png]]
|
[[file:figs/plant_comp_damping_coupling.png]]
|
||||||
** Tomography Experiment
|
** Tomography Experiment
|
||||||
|
*** Load the Simulation Data
|
||||||
#+begin_src matlab
|
#+begin_src matlab
|
||||||
load('./active_damping/mat/tomo_exp.mat', 'En', 'En_iff', 'En_dvf', 'En_ine');
|
load('./active_damping/mat/tomo_exp.mat', 'En', 'En_iff_hpf', 'En_dvf', 'En_ine');
|
||||||
|
En_iff = En_iff_hpf;
|
||||||
t = linspace(0, 3, length(En(:,1)));
|
t = linspace(0, 3, length(En(:,1)));
|
||||||
#+end_src
|
#+end_src
|
||||||
|
|
||||||
|
*** Frequency Domain Analysis
|
||||||
|
Window used for =pwelch= function.
|
||||||
#+begin_src matlab
|
#+begin_src matlab
|
||||||
rms(sqrt(En(:, 1).^2 + En(:, 2).^2 + En(:, 3).^2))
|
|
||||||
rms(sqrt(En_ine(:, 1).^2 + En_ine(:, 2).^2 + En_ine(:, 3).^2))
|
|
||||||
rms(sqrt(En_dvf(:, 1).^2 + En_dvf(:, 2).^2 + En_dvf(:, 3).^2))
|
|
||||||
rms(sqrt(En_iff(:, 1).^2 + En_iff(:, 2).^2 + En_iff(:, 3).^2))
|
|
||||||
#+end_src
|
|
||||||
|
|
||||||
*** Frequency Domain
|
|
||||||
#+begin_src matlab
|
|
||||||
Ts = t(2)-t(1); % Sample Time for the Data [s]
|
|
||||||
|
|
||||||
n_av = 8;
|
n_av = 8;
|
||||||
han_win = hanning(ceil(length(En(:, 1))/n_av));
|
han_win = hanning(ceil(length(En(:, 1))/n_av));
|
||||||
|
#+end_src
|
||||||
|
|
||||||
|
#+begin_src matlab :exports none
|
||||||
|
Ts = t(2)-t(1); % Sample Time for the Data [s]
|
||||||
|
|
||||||
[pxx, f] = pwelch(En(:, 1), han_win, [], [], 1/Ts);
|
[pxx, f] = pwelch(En(:, 1), han_win, [], [], 1/Ts);
|
||||||
[pxx_ine, ~] = pwelch(En_ine(:, 1), han_win, [], [], 1/Ts);
|
[pxx_ine, ~] = pwelch(En_ine(:, 1), han_win, [], [], 1/Ts);
|
||||||
@ -2250,22 +2247,7 @@ Inertial Control:
|
|||||||
[prz_iff, ~] = pwelch(En_iff(:, 6), han_win, [], [], 1/Ts);
|
[prz_iff, ~] = pwelch(En_iff(:, 6), han_win, [], [], 1/Ts);
|
||||||
#+end_src
|
#+end_src
|
||||||
|
|
||||||
#+begin_src matlab
|
#+begin_src matlab :exports none
|
||||||
figure;
|
|
||||||
hold on;
|
|
||||||
plot(f, prx_ine, 'DisplayName', 'Inertial')
|
|
||||||
plot(f, prx_dvf, 'DisplayName', 'DVF')
|
|
||||||
plot(f, prx_iff, 'DisplayName', 'IFF')
|
|
||||||
plot(f, prx, 'k--', 'DisplayName', 'Undamped')
|
|
||||||
hold off;
|
|
||||||
xlabel('Frequency [Hz]');
|
|
||||||
ylabel('Power Spectral Density [$m^2/Hz$]');
|
|
||||||
set(gca, 'xscale', 'log'); set(gca, 'yscale', 'log');
|
|
||||||
legend('location', 'northeast');
|
|
||||||
xlim([1, 500]);
|
|
||||||
#+end_src
|
|
||||||
|
|
||||||
#+begin_src matlab
|
|
||||||
figure;
|
figure;
|
||||||
hold on;
|
hold on;
|
||||||
plot(f, pxx_ine, 'DisplayName', 'Inertial')
|
plot(f, pxx_ine, 'DisplayName', 'Inertial')
|
||||||
@ -2277,9 +2259,90 @@ Inertial Control:
|
|||||||
ylabel('Power Spectral Density [$m^2/Hz$]');
|
ylabel('Power Spectral Density [$m^2/Hz$]');
|
||||||
set(gca, 'xscale', 'log'); set(gca, 'yscale', 'log');
|
set(gca, 'xscale', 'log'); set(gca, 'yscale', 'log');
|
||||||
legend('location', 'northeast');
|
legend('location', 'northeast');
|
||||||
xlim([1, 500]);
|
xlim([2, 500]);
|
||||||
#+end_src
|
#+end_src
|
||||||
|
|
||||||
|
#+HEADER: :tangle no :exports results :results none :noweb yes
|
||||||
|
#+begin_src matlab :var filepath="figs/act_damp_tomo_exp_comp_psd_trans.pdf" :var figsize="full-tall" :post pdf2svg(file=*this*, ext="png")
|
||||||
|
<<plt-matlab>>
|
||||||
|
#+end_src
|
||||||
|
|
||||||
|
#+NAME: fig:act_damp_tomo_exp_comp_psd_trans
|
||||||
|
#+CAPTION: PSD of the translation errors for applied Active Damping techniques ([[./figs/act_damp_tomo_exp_comp_psd_trans.png][png]], [[./figs/act_damp_tomo_exp_comp_psd_trans.pdf][pdf]])
|
||||||
|
[[file:figs/act_damp_tomo_exp_comp_psd_trans.png]]
|
||||||
|
|
||||||
|
#+begin_src matlab :exports none
|
||||||
|
figure;
|
||||||
|
hold on;
|
||||||
|
plot(f, prx_ine, 'DisplayName', 'Inertial')
|
||||||
|
plot(f, prx_dvf, 'DisplayName', 'DVF')
|
||||||
|
plot(f, prx_iff, 'DisplayName', 'IFF')
|
||||||
|
plot(f, prx, 'k--', 'DisplayName', 'Undamped')
|
||||||
|
hold off;
|
||||||
|
xlabel('Frequency [Hz]');
|
||||||
|
ylabel('Power Spectral Density [$m^2/Hz$]');
|
||||||
|
set(gca, 'xscale', 'log'); set(gca, 'yscale', 'log');
|
||||||
|
legend('location', 'northeast');
|
||||||
|
xlim([2, 500]);
|
||||||
|
#+end_src
|
||||||
|
|
||||||
|
#+HEADER: :tangle no :exports results :results none :noweb yes
|
||||||
|
#+begin_src matlab :var filepath="figs/act_damp_tomo_exp_comp_psd_rot.pdf" :var figsize="full-tall" :post pdf2svg(file=*this*, ext="png")
|
||||||
|
<<plt-matlab>>
|
||||||
|
#+end_src
|
||||||
|
|
||||||
|
#+NAME: fig:act_damp_tomo_exp_comp_psd_rot
|
||||||
|
#+CAPTION: PSD of the rotation errors for applied Active Damping techniques ([[./figs/act_damp_tomo_exp_comp_psd_rot.png][png]], [[./figs/act_damp_tomo_exp_comp_psd_rot.pdf][pdf]])
|
||||||
|
[[file:figs/act_damp_tomo_exp_comp_psd_rot.png]]
|
||||||
|
|
||||||
|
#+begin_src matlab :exports none
|
||||||
|
figure;
|
||||||
|
hold on;
|
||||||
|
plot(f, flip(-cumtrapz(flip(f), flip(pxx_ine))), 'DisplayName', 'Inertial')
|
||||||
|
plot(f, flip(-cumtrapz(flip(f), flip(pxx_dvf))), 'DisplayName', 'DVF')
|
||||||
|
plot(f, flip(-cumtrapz(flip(f), flip(pxx_iff))), 'DisplayName', 'IFF')
|
||||||
|
plot(f, flip(-cumtrapz(flip(f), flip(pxx))), 'k--', 'DisplayName', 'Undamped')
|
||||||
|
hold off;
|
||||||
|
xlabel('Frequency [Hz]');
|
||||||
|
ylabel('Power Spectral Density [$m^2/Hz$]');
|
||||||
|
set(gca, 'xscale', 'log'); set(gca, 'yscale', 'log');
|
||||||
|
legend('location', 'northeast');
|
||||||
|
xlim([2, 500]);
|
||||||
|
#+end_src
|
||||||
|
|
||||||
|
#+HEADER: :tangle no :exports results :results none :noweb yes
|
||||||
|
#+begin_src matlab :var filepath="figs/act_damp_tomo_exp_comp_cps_trans.pdf" :var figsize="full-tall" :post pdf2svg(file=*this*, ext="png")
|
||||||
|
<<plt-matlab>>
|
||||||
|
#+end_src
|
||||||
|
|
||||||
|
#+NAME: fig:act_damp_tomo_exp_comp_cps_trans
|
||||||
|
#+CAPTION: CPS of the translation errors for applied Active Damping techniques ([[./figs/act_damp_tomo_exp_comp_cps_trans.png][png]], [[./figs/act_damp_tomo_exp_comp_cps_trans.pdf][pdf]])
|
||||||
|
[[file:figs/act_damp_tomo_exp_comp_cps_trans.png]]
|
||||||
|
|
||||||
|
#+begin_src matlab :exports none
|
||||||
|
figure;
|
||||||
|
hold on;
|
||||||
|
plot(f, flip(-cumtrapz(flip(f), flip(prx_ine))), 'DisplayName', 'Inertial')
|
||||||
|
plot(f, flip(-cumtrapz(flip(f), flip(prx_dvf))), 'DisplayName', 'DVF')
|
||||||
|
plot(f, flip(-cumtrapz(flip(f), flip(prx_iff))), 'DisplayName', 'IFF')
|
||||||
|
plot(f, flip(-cumtrapz(flip(f), flip(prx))), 'k--', 'DisplayName', 'Undamped')
|
||||||
|
hold off;
|
||||||
|
xlabel('Frequency [Hz]');
|
||||||
|
ylabel('Power Spectral Density [$m^2/Hz$]');
|
||||||
|
set(gca, 'xscale', 'log'); set(gca, 'yscale', 'log');
|
||||||
|
legend('location', 'northeast');
|
||||||
|
xlim([2, 500]);
|
||||||
|
#+end_src
|
||||||
|
|
||||||
|
#+HEADER: :tangle no :exports results :results none :noweb yes
|
||||||
|
#+begin_src matlab :var filepath="figs/act_damp_tomo_exp_comp_cps_rot.pdf" :var figsize="full-tall" :post pdf2svg(file=*this*, ext="png")
|
||||||
|
<<plt-matlab>>
|
||||||
|
#+end_src
|
||||||
|
|
||||||
|
#+NAME: fig:act_damp_tomo_exp_comp_cps_rot
|
||||||
|
#+CAPTION: CPS of the rotation errors for applied Active Damping techniques ([[./figs/act_damp_tomo_exp_comp_cps_rot.png][png]], [[./figs/act_damp_tomo_exp_comp_cps_rot.pdf][pdf]])
|
||||||
|
[[file:figs/act_damp_tomo_exp_comp_cps_rot.png]]
|
||||||
|
|
||||||
* Useful Functions
|
* Useful Functions
|
||||||
** prepareTomographyExperiment
|
** prepareTomographyExperiment
|
||||||
:PROPERTIES:
|
:PROPERTIES:
|
||||||
|
Binary file not shown.
BIN
figs/act_damp_tomo_exp_comp_cps_rot.png
Normal file
BIN
figs/act_damp_tomo_exp_comp_cps_rot.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 98 KiB |
BIN
figs/act_damp_tomo_exp_comp_cps_trans.png
Normal file
BIN
figs/act_damp_tomo_exp_comp_cps_trans.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 164 KiB |
BIN
figs/act_damp_tomo_exp_comp_psd_rot.png
Normal file
BIN
figs/act_damp_tomo_exp_comp_psd_rot.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 113 KiB |
BIN
figs/act_damp_tomo_exp_comp_psd_trans.png
Normal file
BIN
figs/act_damp_tomo_exp_comp_psd_trans.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 187 KiB |
Loading…
Reference in New Issue
Block a user