summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-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