Add few curves
This commit is contained in:
parent
7aa568e55d
commit
ec07f0b91e
@ -18,6 +18,8 @@
|
|||||||
#+PROPERTY: header-args:matlab+ :output-dir figs
|
#+PROPERTY: header-args:matlab+ :output-dir figs
|
||||||
:END:
|
:END:
|
||||||
|
|
||||||
|
* Experimental Setup
|
||||||
|
|
||||||
* Signal Processing
|
* Signal Processing
|
||||||
** Matlab Init :noexport:ignore:
|
** Matlab Init :noexport:ignore:
|
||||||
#+begin_src matlab :exports none :results silent :noweb yes
|
#+begin_src matlab :exports none :results silent :noweb yes
|
||||||
@ -33,19 +35,6 @@ Measurement =data_001.mat= corresponds to a measurement where the spindle is not
|
|||||||
data2 = load('mat/data_002.mat', 't', 'x1', 'x2');
|
data2 = load('mat/data_002.mat', 't', 'x1', 'x2');
|
||||||
#+end_src
|
#+end_src
|
||||||
|
|
||||||
** Pre-processing
|
|
||||||
#+begin_src matlab :results none
|
|
||||||
imax = min([length(data1.t), length(data2.t)]);
|
|
||||||
|
|
||||||
data1.t = data1.t(1:imax);
|
|
||||||
data1.x1 = data1.x1(1:imax);
|
|
||||||
data1.x2 = data1.x2(1:imax);
|
|
||||||
|
|
||||||
data2.t = data2.t(1:imax);
|
|
||||||
data2.x1 = data2.x1(1:imax);
|
|
||||||
data2.x2 = data2.x2(1:imax);
|
|
||||||
#+end_src
|
|
||||||
|
|
||||||
** Time domain Data
|
** Time domain Data
|
||||||
#+begin_src matlab :results none
|
#+begin_src matlab :results none
|
||||||
figure;
|
figure;
|
||||||
@ -67,17 +56,19 @@ Measurement =data_001.mat= corresponds to a measurement where the spindle is not
|
|||||||
#+begin_src matlab :results none
|
#+begin_src matlab :results none
|
||||||
dt = data1.t(2) - data1.t(1);
|
dt = data1.t(2) - data1.t(1);
|
||||||
Fs = 1/dt;
|
Fs = 1/dt;
|
||||||
windows_psd = hanning(ceil(10/dt));
|
|
||||||
|
windows_psd = hanning(ceil(10*Fs));
|
||||||
#+end_src
|
#+end_src
|
||||||
|
|
||||||
#+begin_src matlab :results none
|
#+begin_src matlab :results none
|
||||||
[pxx1m, f] = pwelch(data1.x1, windows_psd, [], [], Fs);
|
[pxx1m, f] = pwelch(data1.x1, windows_psd, [], [], Fs); f(1) = []; pxx1m(1) = [];
|
||||||
[pxx1h, ~] = pwelch(data1.x2, windows_psd, [], [], Fs);
|
[pxx1h, ~] = pwelch(data1.x2, windows_psd, [], [], Fs); pxx1h(1) = [];
|
||||||
|
|
||||||
[pxx2m, ~] = pwelch(data2.x1, windows_psd, [], [], Fs);
|
[pxx2m, ~] = pwelch(data2.x1, windows_psd, [], [], Fs); pxx2m(1) = [];
|
||||||
[pxx2h, ~] = pwelch(data2.x2, windows_psd, [], [], Fs);
|
[pxx2h, ~] = pwelch(data2.x2, windows_psd, [], [], Fs); pxx2h(1) = [];
|
||||||
#+end_src
|
#+end_src
|
||||||
|
|
||||||
|
** Some plots
|
||||||
#+begin_src matlab :results none
|
#+begin_src matlab :results none
|
||||||
figure;
|
figure;
|
||||||
hold on;
|
hold on;
|
||||||
@ -120,3 +111,86 @@ Measurement =data_001.mat= corresponds to a measurement where the spindle is not
|
|||||||
set(gca, 'XScale', 'log');
|
set(gca, 'XScale', 'log');
|
||||||
xlabel('Frequency [Hz]'); ylabel('CAS [m]')
|
xlabel('Frequency [Hz]'); ylabel('CAS [m]')
|
||||||
#+end_src
|
#+end_src
|
||||||
|
|
||||||
|
** Scaling to take into account the sensibility of the geophone and the voltage amplifier
|
||||||
|
The Geophone used are L22. Their sensibility is shown on figure [[fig:geophone_sensibility]].
|
||||||
|
|
||||||
|
#+begin_src matlab :results none
|
||||||
|
S0 = 88; % Sensitivity [V/(m/s)]
|
||||||
|
f0 = 2; % Cut-off frequnecy [Hz]
|
||||||
|
|
||||||
|
S = S0*(s/2/pi/f0)/(1+s/2/pi/f0);
|
||||||
|
#+end_src
|
||||||
|
|
||||||
|
We also take into account the gain of the electronics which is here set to be $60dB$.
|
||||||
|
|
||||||
|
#+begin_src matlab :results none
|
||||||
|
G0_db = 60; % [dB]
|
||||||
|
|
||||||
|
G0 = 10^(60/G0_db); % [abs]
|
||||||
|
#+end_src
|
||||||
|
|
||||||
|
We divide the ASD measured (in $\text{V}/\sqrt{\text{Hz}}$) by the gain of the voltage amplifier to obtain the ASD of the voltage across the geophone.
|
||||||
|
We further divide the result by the sensibility of the Geophone to obtain the ASD of the velocity in $m/s/\sqrt{Hz}$.
|
||||||
|
|
||||||
|
#+begin_src matlab :results none
|
||||||
|
scaling = 1./squeeze(abs(freqresp(G0*S, f, 'Hz'))); scaling(1) = 0;
|
||||||
|
#+end_src
|
||||||
|
|
||||||
|
** Computation of the ASD of the velocity
|
||||||
|
#+begin_src matlab :results none
|
||||||
|
figure;
|
||||||
|
hold on;
|
||||||
|
plot(f, sqrt(pxx1h).*scaling);
|
||||||
|
plot(f, sqrt(pxx2h).*scaling);
|
||||||
|
hold off;
|
||||||
|
set(gca, 'xscale', 'log');
|
||||||
|
set(gca, 'yscale', 'log');
|
||||||
|
xlabel('Frequency [Hz]'); ylabel('ASD of the measured Velocity $\left[\frac{m/s}{\sqrt{Hz}}\right]$')
|
||||||
|
xlim([0.1, 500]);
|
||||||
|
#+end_src
|
||||||
|
|
||||||
|
#+begin_src matlab :results none
|
||||||
|
figure;
|
||||||
|
hold on;
|
||||||
|
plot(f, (sqrt(pxx1).*scaling)./(2*pi*f));
|
||||||
|
plot(f, (sqrt(pxx2).*scaling)./(2*pi*f));
|
||||||
|
hold off;
|
||||||
|
set(gca, 'xscale', 'log'); set(gca, 'yscale', 'log');
|
||||||
|
xlabel('Frequency [Hz]'); ylabel('ASD of the displacement $\left[\frac{m}{\sqrt{Hz}}\right]$')
|
||||||
|
xlim([0.1, 500]);
|
||||||
|
#+end_src
|
||||||
|
|
||||||
|
** RMS value of the difference between the two geophones
|
||||||
|
We also compute the Power Spectral Density of the difference between the two geophones. This is done in order to estimate the relative displacement of the sample with respect to the granite.
|
||||||
|
#+begin_src matlab :results none
|
||||||
|
[pxxd1, ~] = pwelch(data1.x2-data1.x1, windows_psd, [], [], Fs); pxxd1(1) = [];
|
||||||
|
[pxxd2, ~] = pwelch(data2.x2-data2.x1, windows_psd, [], [], Fs); pxxd2(1) = [];
|
||||||
|
#+end_src
|
||||||
|
|
||||||
|
#+begin_src matlab :results none
|
||||||
|
figure;
|
||||||
|
hold on;
|
||||||
|
plot(f, (sqrt(pxxd1).*scaling)./(2*pi*f));
|
||||||
|
plot(f, (sqrt(pxxd2).*scaling)./(2*pi*f));
|
||||||
|
hold off;
|
||||||
|
set(gca, 'xscale', 'log'); set(gca, 'yscale', 'log');
|
||||||
|
xlabel('Frequency [Hz]'); ylabel('ASD of the displacement $\left[\frac{m}{\sqrt{Hz}}\right]$')
|
||||||
|
xlim([0.1, 500]);
|
||||||
|
#+end_src
|
||||||
|
|
||||||
|
#+begin_src matlab :results none
|
||||||
|
psd_d1 = ((sqrt(pxxd1).*scaling)./(2*pi*f)).^2;
|
||||||
|
psd_d2 = ((sqrt(pxxd2).*scaling)./(2*pi*f)).^2;
|
||||||
|
|
||||||
|
df = f(2) - f(1);
|
||||||
|
|
||||||
|
figure;
|
||||||
|
hold on;
|
||||||
|
plot(f, sqrt(cumsum(df.*psd_d1, 'reverse')));
|
||||||
|
plot(f, sqrt(cumsum(df.*psd_d2, 'reverse')));
|
||||||
|
hold off;
|
||||||
|
set(gca, 'xscale', 'log'); set(gca, 'yscale', 'log');
|
||||||
|
xlabel('Frequency [Hz]'); ylabel('CAS $\left[m\right]$')
|
||||||
|
xlim([0.1, 500]);
|
||||||
|
#+end_src
|
||||||
|
3
slip-ring-test/figs/.gitignore
vendored
Normal file
3
slip-ring-test/figs/.gitignore
vendored
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
*.tex
|
||||||
|
*.pdf
|
||||||
|
*.svg
|
BIN
slip-ring-test/figs/psd_noise.png
Normal file
BIN
slip-ring-test/figs/psd_noise.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 105 KiB |
@ -3,7 +3,7 @@
|
|||||||
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
||||||
<html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en">
|
<html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en">
|
||||||
<head>
|
<head>
|
||||||
<!-- 2019-05-02 jeu. 14:12 -->
|
<!-- 2019-05-03 ven. 14:39 -->
|
||||||
<meta http-equiv="Content-Type" content="text/html;charset=utf-8" />
|
<meta http-equiv="Content-Type" content="text/html;charset=utf-8" />
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1" />
|
<meta name="viewport" content="width=device-width, initial-scale=1" />
|
||||||
<title>Effect of the rotation of the Slip-Ring</title>
|
<title>Effect of the rotation of the Slip-Ring</title>
|
||||||
@ -254,16 +254,16 @@ for the JavaScript code in this tag.
|
|||||||
<h2>Table of Contents</h2>
|
<h2>Table of Contents</h2>
|
||||||
<div id="text-table-of-contents">
|
<div id="text-table-of-contents">
|
||||||
<ul>
|
<ul>
|
||||||
<li><a href="#org4210b03">1. Measurement Description</a></li>
|
<li><a href="#orgfad781f">1. Measurement Description</a></li>
|
||||||
<li><a href="#org28261aa">2. Load data</a></li>
|
<li><a href="#org15aab25">2. Load data</a></li>
|
||||||
<li><a href="#org79cb6de">3. Analysis</a></li>
|
<li><a href="#orgf84fddf">3. Analysis</a></li>
|
||||||
<li><a href="#org30f1cc1">4. Conclusion</a></li>
|
<li><a href="#org072e1d4">4. Conclusion</a></li>
|
||||||
</ul>
|
</ul>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="outline-container-org4210b03" class="outline-2">
|
<div id="outline-container-orgfad781f" class="outline-2">
|
||||||
<h2 id="org4210b03"><span class="section-number-2">1</span> Measurement Description</h2>
|
<h2 id="orgfad781f"><span class="section-number-2">1</span> Measurement Description</h2>
|
||||||
<div class="outline-text-2" id="text-1">
|
<div class="outline-text-2" id="text-1">
|
||||||
<p>
|
<p>
|
||||||
Random Signal is generated by one DAC of the SpeedGoat.
|
Random Signal is generated by one DAC of the SpeedGoat.
|
||||||
@ -352,8 +352,8 @@ Here, the rotation speed of the Slip-Ring is set to 1rpm.
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="outline-container-org28261aa" class="outline-2">
|
<div id="outline-container-org15aab25" class="outline-2">
|
||||||
<h2 id="org28261aa"><span class="section-number-2">2</span> Load data</h2>
|
<h2 id="org15aab25"><span class="section-number-2">2</span> Load data</h2>
|
||||||
<div class="outline-text-2" id="text-2">
|
<div class="outline-text-2" id="text-2">
|
||||||
<p>
|
<p>
|
||||||
We load the data of the z axis of two geophones.
|
We load the data of the z axis of two geophones.
|
||||||
@ -366,11 +366,11 @@ sr_on = load<span class="org-rainbow-delimiters-depth-1">(</span><span class="o
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="outline-container-org79cb6de" class="outline-2">
|
<div id="outline-container-orgf84fddf" class="outline-2">
|
||||||
<h2 id="org79cb6de"><span class="section-number-2">3</span> Analysis</h2>
|
<h2 id="orgf84fddf"><span class="section-number-2">3</span> Analysis</h2>
|
||||||
<div class="outline-text-2" id="text-3">
|
<div class="outline-text-2" id="text-3">
|
||||||
<p>
|
<p>
|
||||||
Let's first look at the signal produced by the DAC (figure <a href="#orgf3a4e2b">1</a>).
|
Let's first look at the signal produced by the DAC (figure <a href="#org36eec0a">1</a>).
|
||||||
</p>
|
</p>
|
||||||
|
|
||||||
<div class="org-src-container">
|
<div class="org-src-container">
|
||||||
@ -384,20 +384,20 @@ xlim<span class="org-rainbow-delimiters-depth-1">(</span><span class="org-rainbo
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|
||||||
<div id="orgf3a4e2b" class="figure">
|
<div id="org36eec0a" class="figure">
|
||||||
<p><img src="figs/random_signal.png" alt="random_signal.png" />
|
<p><img src="figs/random_signal.png" alt="random_signal.png" />
|
||||||
</p>
|
</p>
|
||||||
<p><span class="figure-number">Figure 1: </span>Random signal produced by the DAC</p>
|
<p><span class="figure-number">Figure 1: </span>Random signal produced by the DAC</p>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<p>
|
<p>
|
||||||
We now look at the difference between the signal directly measured by the ADC and the signal that goes through the slip-ring (figure <a href="#org07de8c8">2</a>).
|
We now look at the difference between the signal directly measured by the ADC and the signal that goes through the slip-ring (figure <a href="#orga6ca37c">2</a>).
|
||||||
</p>
|
</p>
|
||||||
|
|
||||||
<div class="org-src-container">
|
<div class="org-src-container">
|
||||||
<pre class="src src-matlab"><span class="org-type">figure</span>;
|
<pre class="src src-matlab"><span class="org-type">figure</span>;
|
||||||
hold on;
|
hold on;
|
||||||
plot<span class="org-rainbow-delimiters-depth-1">(</span>sr_on.t, sr_on.x1 <span class="org-type">-</span> sr_on.x2, <span class="org-string">'DisplayName', '</span>Slip<span class="org-type">-</span>Ring <span class="org-type">-</span> $<span class="org-type">\</span>omega = <span class="org-highlight-numbers-number">1rpm$</span>'<span class="org-rainbow-delimiters-depth-1">)</span>;
|
plot<span class="org-rainbow-delimiters-depth-1">(</span>sr_on.t, sr_on.x1 <span class="org-type">-</span> sr_on.x2, <span class="org-string">'DisplayName', '</span>Slip<span class="org-type">-</span>Ring <span class="org-type">-</span> $<span class="org-type">\</span>omega = <span class="org-highlight-numbers-number">1rpm$</span>'<span class="org-rainbow-delimiters-depth-1">)</span>;
|
||||||
plot<span class="org-rainbow-delimiters-depth-1">(</span>sr_off.t, sr_off.x1 <span class="org-type">-</span> sr_off.x2,<span class="org-string">'DisplayName', 'Slip-Ring off'</span><span class="org-rainbow-delimiters-depth-1">)</span>;
|
plot<span class="org-rainbow-delimiters-depth-1">(</span>sr_off.t, sr_off.x1 <span class="org-type">-</span> sr_off.x2,<span class="org-string">'DisplayName', 'Slip-Ring off'</span><span class="org-rainbow-delimiters-depth-1">)</span>;
|
||||||
hold off;
|
hold off;
|
||||||
xlabel<span class="org-rainbow-delimiters-depth-1">(</span><span class="org-string">'Time </span><span class="org-string"><span class="org-rainbow-delimiters-depth-2">[</span></span><span class="org-string">s</span><span class="org-string"><span class="org-rainbow-delimiters-depth-2">]</span></span><span class="org-string">'</span><span class="org-string"><span class="org-rainbow-delimiters-depth-1">)</span></span><span class="org-string">; ylabel</span><span class="org-string"><span class="org-rainbow-delimiters-depth-1">(</span></span><span class="org-string">'Voltage </span><span class="org-string"><span class="org-rainbow-delimiters-depth-2">[</span></span><span class="org-string">V</span><span class="org-string"><span class="org-rainbow-delimiters-depth-2">]</span></span><span class="org-string">'</span><span class="org-rainbow-delimiters-depth-1">)</span>;
|
xlabel<span class="org-rainbow-delimiters-depth-1">(</span><span class="org-string">'Time </span><span class="org-string"><span class="org-rainbow-delimiters-depth-2">[</span></span><span class="org-string">s</span><span class="org-string"><span class="org-rainbow-delimiters-depth-2">]</span></span><span class="org-string">'</span><span class="org-string"><span class="org-rainbow-delimiters-depth-1">)</span></span><span class="org-string">; ylabel</span><span class="org-string"><span class="org-rainbow-delimiters-depth-1">(</span></span><span class="org-string">'Voltage </span><span class="org-string"><span class="org-rainbow-delimiters-depth-2">[</span></span><span class="org-string">V</span><span class="org-string"><span class="org-rainbow-delimiters-depth-2">]</span></span><span class="org-string">'</span><span class="org-rainbow-delimiters-depth-1">)</span>;
|
||||||
@ -407,16 +407,37 @@ legend<span class="org-rainbow-delimiters-depth-1">(</span><span class="org-stri
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|
||||||
<div id="org07de8c8" class="figure">
|
<div id="orga6ca37c" class="figure">
|
||||||
<p><img src="figs/slipring_comp_signals.png" alt="slipring_comp_signals.png" />
|
<p><img src="figs/slipring_comp_signals.png" alt="slipring_comp_signals.png" />
|
||||||
</p>
|
</p>
|
||||||
<p><span class="figure-number">Figure 2: </span>Alteration of the signal when the slip-ring is turning</p>
|
<p><span class="figure-number">Figure 2: </span>Alteration of the signal when the slip-ring is turning</p>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
<div class="org-src-container">
|
||||||
|
<pre class="src src-matlab">dt = sr_on.t<span class="org-rainbow-delimiters-depth-1">(</span><span class="org-highlight-numbers-number">2</span><span class="org-rainbow-delimiters-depth-1">)</span> <span class="org-type">-</span> sr_on.t<span class="org-rainbow-delimiters-depth-1">(</span><span class="org-highlight-numbers-number">1</span><span class="org-rainbow-delimiters-depth-1">)</span>;
|
||||||
|
Fs = <span class="org-highlight-numbers-number">1</span><span class="org-type">/</span>dt; <span class="org-comment">% [Hz]</span>
|
||||||
|
|
||||||
|
win = hanning<span class="org-rainbow-delimiters-depth-1">(</span>ceil<span class="org-rainbow-delimiters-depth-2">(</span><span class="org-highlight-numbers-number">1</span><span class="org-type">*</span>Fs<span class="org-rainbow-delimiters-depth-2">)</span><span class="org-rainbow-delimiters-depth-1">)</span>;
|
||||||
|
</pre>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="org-src-container">
|
||||||
|
<pre class="src src-matlab"><span class="org-rainbow-delimiters-depth-1">[</span>pxx_on, f<span class="org-rainbow-delimiters-depth-1">]</span> = pwelch<span class="org-rainbow-delimiters-depth-1">(</span>sr_on.x1 <span class="org-type">-</span> sr_on.x2, win, <span class="org-rainbow-delimiters-depth-2">[]</span>, <span class="org-rainbow-delimiters-depth-2">[]</span>, Fs<span class="org-rainbow-delimiters-depth-1">)</span>;
|
||||||
|
<span class="org-rainbow-delimiters-depth-1">[</span>pxx_off, <span class="org-type">~</span><span class="org-rainbow-delimiters-depth-1">]</span> = pwelch<span class="org-rainbow-delimiters-depth-1">(</span>sr_off.x1 <span class="org-type">-</span> sr_off.x2, win, <span class="org-rainbow-delimiters-depth-2">[]</span>, <span class="org-rainbow-delimiters-depth-2">[]</span>, Fs<span class="org-rainbow-delimiters-depth-1">)</span>;
|
||||||
|
</pre>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
<div id="orgc50d568" class="figure">
|
||||||
|
<p><img src="figs/psd_noise.png" alt="psd_noise.png" />
|
||||||
|
</p>
|
||||||
|
<p><span class="figure-number">Figure 3: </span>ASD of the measured noise</p>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="outline-container-org30f1cc1" class="outline-2">
|
<div id="outline-container-org072e1d4" class="outline-2">
|
||||||
<h2 id="org30f1cc1"><span class="section-number-2">4</span> Conclusion</h2>
|
<h2 id="org072e1d4"><span class="section-number-2">4</span> Conclusion</h2>
|
||||||
<div class="outline-text-2" id="text-4">
|
<div class="outline-text-2" id="text-4">
|
||||||
<div class="note">
|
<div class="note">
|
||||||
<p>
|
<p>
|
||||||
@ -433,7 +454,7 @@ legend<span class="org-rainbow-delimiters-depth-1">(</span><span class="org-stri
|
|||||||
</div>
|
</div>
|
||||||
<div id="postamble" class="status">
|
<div id="postamble" class="status">
|
||||||
<p class="author">Author: Thomas Dehaeze</p>
|
<p class="author">Author: Thomas Dehaeze</p>
|
||||||
<p class="date">Created: 2019-05-02 jeu. 14:12</p>
|
<p class="date">Created: 2019-05-03 ven. 14:39</p>
|
||||||
<p class="validation"><a href="http://validator.w3.org/check?uri=referer">Validate</a></p>
|
<p class="validation"><a href="http://validator.w3.org/check?uri=referer">Validate</a></p>
|
||||||
</div>
|
</div>
|
||||||
</body>
|
</body>
|
||||||
|
@ -82,7 +82,7 @@ We now look at the difference between the signal directly measured by the ADC an
|
|||||||
#+begin_src matlab :results none
|
#+begin_src matlab :results none
|
||||||
figure;
|
figure;
|
||||||
hold on;
|
hold on;
|
||||||
plot(sr_on.t, sr_on.x1 - sr_on.x2, 'DisplayName', 'Slip-Ring - $\omega = 1rpm$');
|
plot(sr_on.t, sr_on.x1 - sr_on.x2, 'DisplayName', 'Slip-Ring - $\omega = 1rpm$');
|
||||||
plot(sr_off.t, sr_off.x1 - sr_off.x2,'DisplayName', 'Slip-Ring off');
|
plot(sr_off.t, sr_off.x1 - sr_off.x2,'DisplayName', 'Slip-Ring off');
|
||||||
hold off;
|
hold off;
|
||||||
xlabel('Time [s]'); ylabel('Voltage [V]');
|
xlabel('Time [s]'); ylabel('Voltage [V]');
|
||||||
@ -101,6 +101,41 @@ We now look at the difference between the signal directly measured by the ADC an
|
|||||||
#+RESULTS: fig:slipring_comp_signals
|
#+RESULTS: fig:slipring_comp_signals
|
||||||
[[file:figs/slipring_comp_signals.png]]
|
[[file:figs/slipring_comp_signals.png]]
|
||||||
|
|
||||||
|
#+begin_src matlab :results none
|
||||||
|
dt = sr_on.t(2) - sr_on.t(1);
|
||||||
|
Fs = 1/dt; % [Hz]
|
||||||
|
|
||||||
|
win = hanning(ceil(1*Fs));
|
||||||
|
#+end_src
|
||||||
|
|
||||||
|
#+begin_src matlab :results none
|
||||||
|
[pxx_on, f] = pwelch(sr_on.x1 - sr_on.x2, win, [], [], Fs);
|
||||||
|
[pxx_off, ~] = pwelch(sr_off.x1 - sr_off.x2, win, [], [], Fs);
|
||||||
|
#+end_src
|
||||||
|
|
||||||
|
#+begin_src matlab :results none :exports none
|
||||||
|
figure;
|
||||||
|
hold on;
|
||||||
|
plot(f, sqrt(pxx_on), 'DisplayName', 'Slip-Ring - $\omega = 1rpm$');
|
||||||
|
plot(f, sqrt(pxx_off),'DisplayName', 'Slip-Ring off');
|
||||||
|
hold off;
|
||||||
|
set(gca, 'xscale', 'log'); set(gca, 'yscale', 'log');
|
||||||
|
xlabel('Frequency [Hz]'); ylabel('PSD $\left[\frac{V}{\sqrt{Hz}}\right]$');
|
||||||
|
legend('Location', 'northeast');
|
||||||
|
xlim([1, 500]);
|
||||||
|
#+end_src
|
||||||
|
|
||||||
|
#+NAME: fig:psd_noise
|
||||||
|
#+HEADER: :tangle no :exports results :results value raw replace :noweb yes
|
||||||
|
#+begin_src matlab :var filepath="figs/psd_noise.pdf" :var figsize="wide-tall" :post pdf2svg(file=*this*, ext="png")
|
||||||
|
<<plt-matlab>>
|
||||||
|
#+end_src
|
||||||
|
|
||||||
|
#+NAME: fig:psd_noise
|
||||||
|
#+CAPTION: ASD of the measured noise
|
||||||
|
#+RESULTS: fig:psd_noise
|
||||||
|
[[file:figs/psd_noise.png]]
|
||||||
|
|
||||||
* Conclusion
|
* Conclusion
|
||||||
#+begin_note
|
#+begin_note
|
||||||
*Remaining questions*:
|
*Remaining questions*:
|
||||||
|
Loading…
x
Reference in New Issue
Block a user