1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226
|
<?xml version="1.0" encoding="UTF-8"?>
<simulation xmds-version="2">
<testing>
<command_line>mpirun -n 1 ./mpi_highdimcrossprop</command_line>
<xsil_file name="mpi_highdimcrossprop.xsil" expected="../operators/highdimcrossprop_expected.xsil" absolute_tolerance="1e-5" relative_tolerance="1e-4" />
</testing>
<name>mpi_highdimcrossprop</name>
<features>
<benchmark />
<bing />
<globals>
<![CDATA[
const real pi=3.14159265358979;
const real g =2*pi*11.4005; // Sqrt(density)/Hz
const real sample_length = 0.2; //m
const real time_input =2.5e-6; // sec (5)
const real sigma=1e-6; // sec (2)
const real inp_hgt=1e3; //photonnum
const real gama=2*pi*5.6e6; //Hz
const real eta =2*pi*10e6/sample_length; //Hz/m (was 2*pi*10e6)
const real omc=2*pi*20e6; //Hz (was 2*pi*20e6)
const real gama0=0; //2*pi*2e3; //Hz
const real gamac=0; //2*pi*1e3; //Hz
const real c=3e8; // m/s
const real timeswitchz=10e-6; // sec (10)
const real N=1e18; // density
const real gNonc = g*N/c;
const real delta=2*pi*3e9; //Hz
const real width = 0.001; //m
const real k0 = 6.28 / (795e-9);
const real alpha=0.00; //m^2/s
]]>
</globals>
</features>
<driver name="distributed-mpi" />
<geometry>
<propagation_dimension> t </propagation_dimension>
<transverse_dimensions>
<dimension name="x" lattice="16" domain="(-0.004,0.004)" />
<dimension name="y" lattice="16" domain="(-0.003,0.003)" />
<dimension name="z" lattice="512" domain="(0,0.2)" />
</transverse_dimensions>
</geometry>
<vector name="main" initial_basis="z x y" type="complex">
<components>
alpha12
</components>
<initialisation>
<![CDATA[
alpha12 = 0.0;
]]>
</initialisation>
</vector>
<vector name="crossinitial" initial_basis="x y" type="complex">
<components>
beamprofile
</components>
<initialisation>
<![CDATA[
beamprofile=inp_hgt * (2*sqrt(2)*x/width) * exp(-x*x/(width*width)) * exp(-y*y/(width*width))* exp(-i*k0*(x*x+y*y)/0.5);
]]>
</initialisation>
</vector>
<vector name="cross1" initial_basis="x y z" type="complex">
<components>
E
</components>
</vector>
<sequence>
<integrate algorithm="RK4" interval="20e-8" steps="20" tolerance="1.0e-6">
<samples>2 1 2 2 1 1 1 1 1 1</samples>
<operators>
<operator kind="cross_propagation" algorithm="RK4" propagation_dimension="z">
<operator kind="ip" constant="yes">
<operator_names>Btt</operator_names>
<![CDATA[
Btt = 0; //i*(kx*kx + ky*ky)/(2*k0);
]]>
</operator>
<integration_vectors>cross1</integration_vectors>
<!-- You can have a dependencies tag in here -->
<dependencies>main</dependencies>
<boundary_condition kind="left">
<!-- You can also have a dependencies tag in here -->
<!-- like the one shown below, but none are needed -->
<!-- in this example -->
<dependencies>crossinitial</dependencies>
<![CDATA[
//E=inp_hgt*exp(-(t-time_input)*(t-time_input)/(sigma*sigma)) * exp(-x*x/(width*width))*exp(-y*y/(width*width));
E = exp(-(t-time_input)*(t-time_input)/(sigma*sigma)) * beamprofile;
]]>
</boundary_condition>
<![CDATA[
complex aalpha13 = (alpha12*omc+g*E)/delta;
dE_dz = i*gNonc*(aalpha13) + Btt[E];
]]>
</operator>
<operator kind="ip" constant="yes">
<operator_names>Ltt</operator_names>
<![CDATA[
Ltt = -alpha*(kz*kz+kx*kx+ky*ky);
]]>
</operator>
<integration_vectors>main</integration_vectors>
<![CDATA[
complex sw = -1.0; //( t<timeswitchz ? -1.0:1.0);
complex aalpha13 = (alpha12*omc+g*E)/(delta-i*(gamac/2+gama+gama0/2));
dalpha12_dt = ((-gama0 - gamac-i*(sw*eta*(z-sample_length/2) +(omc*omc)/delta))*alpha12+i*aalpha13*(omc)) + Ltt[alpha12];
]]>
</operators>
</integrate>
</sequence>
<output format="hdf5" filename="mpi_highdimcrossprop.xsil">
<group>
<sampling basis="z(128) x(16) y(16)" initial_sample="yes">
<moments>bprobereal bprobeimag</moments>
<dependencies>cross1</dependencies>
<![CDATA[
bprobereal = E.Re();
bprobeimag = E.Im();
]]>
</sampling>
</group>
<sampling_group basis="kx(16) ky(16) kz(128)" initial_sample="yes">
<moments>bproberealK bprobeimagK bintensityK</moments>
<dependencies>cross1</dependencies>
<![CDATA[
bproberealK = E.Re();
bprobeimagK = E.Im();
bintensityK = mod2(E);
]]>
</sampling_group>
<sampling_group basis="x(16) y(16) z(256)" initial_sample="yes">
<moments>balpreal12 balpimag12</moments>
<dependencies>main</dependencies>
<![CDATA[
balpreal12 = (alpha12).Re();
balpimag12 = (alpha12).Im();
]]>
</sampling_group>
<sampling_group basis="kx(2) ky(2) kz(256)" initial_sample="yes">
<moments>balpreal12K balpimag12K</moments>
<dependencies>main</dependencies>
<![CDATA[
balpreal12K = (alpha12).Re();
balpimag12K = (alpha12).Im();
]]>
</sampling_group>
<sampling_group basis="x(0) y(0) z(512)" initial_sample="yes">
<moments>bprobereal bprobeimag</moments>
<dependencies>cross1</dependencies>
<![CDATA[
bprobereal = E.Re();
bprobeimag = E.Im();
]]>
</sampling_group>
<sampling_group basis="x(0) y(16) z(0)" initial_sample="yes">
<moments>bprobereal bprobeimag</moments>
<dependencies>cross1</dependencies>
<![CDATA[
bprobereal = E.Re();
bprobeimag = E.Im();
]]>
</sampling_group>
<sampling_group basis="x(16) y(0) z(0)" initial_sample="yes">
<moments>bprobereal bprobeimag</moments>
<dependencies>cross1</dependencies>
<![CDATA[
bprobereal = E.Re();
bprobeimag = E.Im();
]]>
</sampling_group>
<sampling_group basis="x(0) y(0) z(512)" initial_sample="no">
<moments>balpreal12 balpimag12</moments>
<dependencies>main</dependencies>
<![CDATA[
balpreal12 = Re(alpha12);
balpimag12 = Im(alpha12);
]]>
</sampling_group>
<sampling_group basis="x(16) y(0) z(0)" initial_sample="no">
<moments>balpreal12 balpimag12</moments>
<dependencies>main</dependencies>
<![CDATA[
balpreal12 = Re(alpha12);
balpimag12 = Im(alpha12);
]]>
</sampling_group>
<sampling_group basis="x(0) y(16) z(0)" initial_sample="no">
<moments>balpreal12 balpimag12</moments>
<dependencies>main</dependencies>
<![CDATA[
balpreal12 = Re(alpha12);
balpimag12 = Im(alpha12);
]]>
</sampling_group>
</output>
</simulation>
|