summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEugeniy Mikhailov <evgmik@gmail.com>2016-05-10 15:25:03 -0400
committerEugeniy Mikhailov <evgmik@gmail.com>2016-05-10 15:25:03 -0400
commit7e11108c16389dad055e7bc1353bb9f600c142c2 (patch)
tree04aa1bd04b0a4fd3b9d282134c80c7edd3308a13
parent5889aa228a5da15bdef692dec00096c83edad187 (diff)
downloadnoisy_eit_xmds-7e11108c16389dad055e7bc1353bb9f600c142c2.tar.gz
noisy_eit_xmds-7e11108c16389dad055e7bc1353bb9f600c142c2.zip
More efficient output form
-rw-r--r--MOR_5_levels_with_doppler_and_propagation/Nlevels_with_MOR.xmds13
-rw-r--r--MOR_5_levels_with_doppler_and_propagation/pp_Nlevels.m6
2 files changed, 13 insertions, 6 deletions
diff --git a/MOR_5_levels_with_doppler_and_propagation/Nlevels_with_MOR.xmds b/MOR_5_levels_with_doppler_and_propagation/Nlevels_with_MOR.xmds
index 1cd1bc6..0ab0051 100644
--- a/MOR_5_levels_with_doppler_and_propagation/Nlevels_with_MOR.xmds
+++ b/MOR_5_levels_with_doppler_and_propagation/Nlevels_with_MOR.xmds
@@ -371,16 +371,17 @@
<!-- The output to generate -->
- <output format="binary" filename="Nlevels_with_MOR.xsil">
+ <output format="hdf5" filename="Nlevels_with_MOR.xsil">
<group>
<sampling basis="t(1000) " initial_sample="yes">
<dependencies>E_field_avgd</dependencies>
- <moments>IdL_out IpL_out IdR_out IpR_out</moments>
+ <moments>EdLaR EdLaI EpLaR EpLaI EdRaR EdRaI EpRaR EpRaI</moments>
<![CDATA[
- IdL_out = mod2(EdLa);
- IpL_out = mod2(EpLa);
- IdR_out = mod2(EdRa);
- IpR_out = mod2(EpRa);
+ // _SAMPLE_COMPLEX is macro: _SAMPLE_COMPLEX(W) => WR = W.Re(); WI = W.Im();
+ _SAMPLE_COMPLEX(EdLa);
+ _SAMPLE_COMPLEX(EpLa);
+ _SAMPLE_COMPLEX(EdRa);
+ _SAMPLE_COMPLEX(EpRa);
]]>
</sampling>
</group>
diff --git a/MOR_5_levels_with_doppler_and_propagation/pp_Nlevels.m b/MOR_5_levels_with_doppler_and_propagation/pp_Nlevels.m
index 648cc09..f346fab 100644
--- a/MOR_5_levels_with_doppler_and_propagation/pp_Nlevels.m
+++ b/MOR_5_levels_with_doppler_and_propagation/pp_Nlevels.m
@@ -1,5 +1,11 @@
Nlevels_with_MOR
+%% output E fields to intensities
+IdL_out_1 = abs(EdLaR_1 +1i*EdLaI_1).^2;
+IdR_out_1 = abs(EdRaR_1 +1i*EdRaI_1).^2;
+IpL_out_1 = abs(EpLaR_1 +1i*EpLaI_1).^2;
+IpR_out_1 = abs(EpRaR_1 +1i*EpRaI_1).^2;
+
%% field propagation
z_1=z_1*100; % z in cm
t_1=t_1*1e6; % time now measured in uS