diff options
author | Eugeniy Mikhailov <evgmik@gmail.com> | 2009-12-21 22:48:07 +0000 |
---|---|---|
committer | Eugeniy Mikhailov <evgmik@gmail.com> | 2009-12-21 22:48:07 +0000 |
commit | c680b440e6963ab1f507ca0fcefdc3ce982db8af (patch) | |
tree | 935b6b2c62f5eaefa4fc407e4e343a05e3319916 /useful_functions.m | |
parent | 9e39b7b6b7a74414551a70ea8ccdb11a98023ef5 (diff) | |
download | multi_mode_eit-c680b440e6963ab1f507ca0fcefdc3ce982db8af.tar.gz multi_mode_eit-c680b440e6963ab1f507ca0fcefdc3ce982db8af.zip |
calculation of total absorption is added
Diffstat (limited to 'useful_functions.m')
-rw-r--r-- | useful_functions.m | 40 |
1 files changed, 40 insertions, 0 deletions
diff --git a/useful_functions.m b/useful_functions.m index 22c54be..f799f90 100644 --- a/useful_functions.m +++ b/useful_functions.m @@ -258,4 +258,44 @@ function [xi_linear, xi_left, xi_right]=susceptibility_steady_state_at_freq( ato xi_left = xi.left; endfunction +function [dEdz_coef_linear, dEdz_coef_left, dEdz_coef_right] =dEdz_at_freq(wi, rhoLiouville, dipole_elements, E_field) +% complex absorption coefficient +% at given E_field frequency component + Nlevels=( size(dipole_elements.linear)(1) ); + rho=rhoOfFreq(rhoLiouville, wi, Nlevels); + + dEdz_coef_linear = sum( sum( transpose(dipole_elements.linear) .* rho ) ); + dEdz_coef_left = sum( sum( transpose(dipole_elements.left) .* rho ) ); + dEdz_coef_right = sum( sum( transpose(dipole_elements.right) .* rho ) ); + +endfunction + +function [dEdz_linear, dEdz_left, dEdz_right]=dEdz( atom_field_problem) +% complex absorption coefficient for each field + global atom_properties; + L0m = atom_properties.L0m ; + polarizability_m = atom_properties.polarizability_m ; + dipole_elements = atom_properties.dipole_elements ; + + E_field = atom_field_problem.E_field ; + modulation_freq = atom_field_problem.modulation_freq ; + Nfreq=length(modulation_freq); + + rhoLiouville=rhoLiouville_steady_state(L0m, polarizability_m, E_field, modulation_freq); + for wi=1:Nfreq + [dEdz_linear(wi), dEdz_left(wi), dEdz_right(wi)] = dEdz_at_freq(wi, rhoLiouville, dipole_elements, E_field); + endfor +endfunction + +function total_absorption=total_field_absorption(atom_field_problem) +% summed across all frequencies field absorption coefficient + global atom_properties; + [dEdz_linear, dEdz_left, dEdz_right]=dEdz( atom_field_problem); + dEdz_total= dEdz_linear .* conj(dEdz_linear) ... + +dEdz_left .* conj(dEdz_left) ... + +dEdz_right .* conj(dEdz_right); + total_absorption = sum(dEdz_total); +endfunction + + % vim: ts=2:sw=2:fdm=indent |