summaryrefslogtreecommitdiff
path: root/test.m
diff options
context:
space:
mode:
authorEugeniy Mikhailov <evgmik@gmail.com>2009-12-15 22:02:18 +0000
committerEugeniy Mikhailov <evgmik@gmail.com>2009-12-15 22:02:18 +0000
commitf765eba5a1cdad219d47c0ae6bbac6739bd84215 (patch)
tree5ea5d2ce112e1c03866a03535d7b4ace1cdeae35 /test.m
parente5b9a01f36acaa186b462feae2cff4da62d5491a (diff)
downloadmulti_mode_eit-f765eba5a1cdad219d47c0ae6bbac6739bd84215.tar.gz
multi_mode_eit-f765eba5a1cdad219d47c0ae6bbac6739bd84215.zip
hard coded test case
Diffstat (limited to 'test.m')
-rw-r--r--test.m113
1 files changed, 104 insertions, 9 deletions
diff --git a/test.m b/test.m
index b6b829e..5c8de4c 100644
--- a/test.m
+++ b/test.m
@@ -11,14 +11,91 @@ useful_functions;
useful_constants;
% load atom energy levels and decay description
-four_levels;
-%three_levels;
-%two_levels;
+%four_levels;
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+Nlevels=4;
+w1=1e9;
+w2=0;
+w_hpf=6800;
+w3=w_hpf;
+w4=w_hpf+.1; % separation of levels |3> and |4> somewhat like Zeeman splitting
+w12=w1-w2;
+w13=w1-w3;
+
+%
+% ----------- |1>
+% / \
+% E_d / \
+% / \ E_p
+% / \
+% -------- |3> \
+% -------- |4> \
+% \
+% ___________ |2>
+
+
+% unperturbed Hamiltonian energy levels
+levels_energy=[ w1, 0, w3, w4];
+levels_energy=levels_energy*hbar;
+H0=zeros(Nlevels);
+H0=diag(levels_energy);
+%for i=1:Nlevels
+ %H0(i,i)=levels_energy(i);
+%endfor
+
+% decay matrix g(i,j) correspnds to decay from i-->j
+gamma=6;
+gamma_23=.001;
+g_decay=zeros(Nlevels);
+g_decay(1,2)=gamma; %upper level decay
+g_decay(1,3)=gamma; %upper level decay
+g_decay(1,4)=gamma; %upper level decay
+g_decay(3,2)=gamma_23; % lower levels mixing
+g_decay(2,3)=gamma_23; % lower levels mixing
+g_decay(4,2)=gamma_23; % lower levels mixing
+g_decay(2,4)=gamma_23; % lower levels mixing
+
+%defasing matris
+g_deph=0;
+g_dephasing=zeros(Nlevels);
+g_dephasing(1,2)=g_deph;
+g_dephasing(2,1)=g_dephasing(1,2);
+g_dephasing(1,3)=g_deph;
+g_dephasing(3,1)=g_dephasing(1,3);
+g_dephasing(1,4)=g_deph;
+g_dephasing(4,1)=g_dephasing(4,1);
+
+
+
+% dipole matrix
+dipole_elements=zeros(Nlevels);
+dipole_elements(1,2)=1;
+dipole_elements(2,1)=dipole_elements(1,2);
+dipole_elements(1,3)=1;
+dipole_elements(3,1)=dipole_elements(1,3);
+dipole_elements(1,4)=1;
+dipole_elements(4,1)=dipole_elements(1,4);
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+
+%EM field definition
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+Ep=0.01; %probe
+Epc=conj(Ep);
+Ed=.1; %drive
+Edc=conj(Ed);
+Em=-Ep; % opposite sideband (resulting from EOM modulation of drive)
+Emc=conj(Em);
+%wd=w13;
+%wp=w12;
+%wm=wd-(wp-wd);
+%modulation_freq=[0, wp, wd, wm, -wp, -wd, -wm, wp-wd, wd-wp];
+E_field =[0, Ep, Ed, Em, Epc, Edc, Emc, 0, 0 ];
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-% load EM field description
-field_description;
-Nfreq=length(modulation_freq);
+%Nfreq=length(modulation_freq);
@@ -31,7 +108,10 @@ detuning_freq=zeros(1,N_detun_steps+1);
kappa_p =zeros(1,N_detun_steps+1);
kappa_m =zeros(1,N_detun_steps+1);
-wp0=w12;
+w_pf1=1e9;
+w_hpf_ground=6800;
+wd=w_pf1-w_hpf_ground;
+wp0=w_pf1;
wp=wp0+detuning_p_min;
wm=wd-(wp-wd);
%modulation_freq=[0, wp, wd, wm, -wp, -wd, -wm, wp-wd, wd-wp];
@@ -44,6 +124,16 @@ Nfreq=length(modulation_freq);
[N, rhoLiouville_w, rhoLiouville_r, rhoLiouville_c]=unfold_density_matrix(Nlevels,Nfreq);
rhoLiouville=zeros(N,1);
+dipoles=dipole_elements;
+Efld=E_field;
+clear dipole_elements;
+dipole_elements.right=dipoles;
+dipole_elements.left=dipoles;
+dipole_elements.linear=dipoles;
+clear E_field;
+E_field.right=Efld;
+E_field.left=Efld;
+E_field.linear=Efld;
% calculate E_field independent properties of athe atom
% to be used as sub matrix templates for Liouville operator matrix
[L0m, polarizability_m]=L0_and_polarization_submatrices( ...
@@ -73,8 +163,13 @@ L_new=L;
rhoLiouville_new=rhoLiouville;
% uncomment to update reference file
-% save 'L_and_rhoL_referenced.mat' L
+%save 'L_and_rhoL_referenced.mat' L rhoLiouville
+
+clear L rhoLiouville;
+
+load 'L_and_rhoL_referenced.mat'
+diff_with_reference_L=sum(sum(abs(L_new-L)))
-diff_with_reference=sum(sum(abs(L_new-L)))
+diff_with_reference_rhoL=(sum(abs(rhoLiouville_new -rhoLiouville)))
elapsed_time = etime (clock (), t0)