Atomic Structure¶
This module contains all the information about the atoms.
This includes classes to describe atomic states, transitions, and the atoms themselves. Routines to calculate hyperfine decay rates, and electric dipole matrix elements are included.
Here is the ground state of Cesium.
>>> State("Cs", 133, 6, 0, 1/Integer(2))
133Cs 6S_1/2
References¶
[SteckRb85] | (1, 2, 3) Daniel A. Steck, “Rubidium 85 D Line Data,” available online at http://steck.us/alkalidata (revision 2.1.5, 19 September 2012). |
[SteckRb87] | (1, 2, 3, 4) Daniel A. Steck, “Rubidium 87 D Line Data,” available online at http://steck.us/alkalidata (revision 2.1.5, 19 September 2012). |
[SteckCs] | (1, 2, 3) Daniel A. Steck, “Cesium D Line Data,” available online at http://steck.us/alkalidata (revision 2.1.4, 23 December 2010). |
-
class
fast.atomic_structure.
Atom
(element, isotope=None)¶ This class implements specific atoms and their properties.
The atoms can be identified by element and optionally by isotope.
>>> atom=Atom("Rb") >>> print atom Rb
-
find_decays
(fine_state)¶ Find all possible decays from a given fine state.
This function finds all the states to which a given fine structure state can decay (through electric dipole selection rules).
>>> atom=Atom("Cs",133) >>> e=State("Cs",133,6,"P",3/Integer(2)) >>> atom.find_decays(e) [133Cs 6P_3/2, 133Cs 6S_1/2]
>>> s=State("Cs",133,6,"D",5/Integer(2)) >>> atom.find_decays(s) [133Cs 6D_5/2, 133Cs 6P_3/2, 133Cs 7P_3/2, 133Cs 6S_1/2, 133Cs 5D_3/2, 133Cs 5D_5/2, 133Cs 7S_1/2, 133Cs 6P_1/2]
-
states
(Nmax=50, omega_min=None, omega_max=None, return_missing=False)¶ Find all states of available in an atom.
This function returns all available states up to the fine structure (ordered by energy) such that the principal quantum number is N<=Nmax. Nmax is 50 by default.
>>> atom=Atom("Rb",85) >>> states=atom.states() >>> print states [85Rb 5S_1/2, 85Rb 5P_1/2, 85Rb 5P_3/2, 85Rb 4D_5/2, 85Rb 4D_3/2, 85Rb 6S_1/2, 85Rb 6P_1/2, 85Rb 6P_3/2, 85Rb 5D_3/2, 85Rb 5D_5/2, 85Rb 7S_1/2, 85Rb 7P_1/2, 85Rb 7P_3/2, 85Rb 6D_3/2, 85Rb 7D_3/2, 85Rb 14S_1/2, 85Rb 15S_1/2, 85Rb 16S_1/2, 85Rb 17S_1/2, 85Rb 18S_1/2, 85Rb 19S_1/2, 85Rb 20S_1/2, 85Rb 21S_1/2, 85Rb 22S_1/2, 85Rb 23S_1/2, 85Rb 24S_1/2, 85Rb 25S_1/2, 85Rb 26S_1/2, 85Rb 27S_1/2, 85Rb 28S_1/2, 85Rb 29S_1/2, 85Rb 30S_1/2, 85Rb 31S_1/2, 85Rb 32S_1/2, 85Rb 33S_1/2, 85Rb 34S_1/2, 85Rb 35S_1/2, 85Rb 36S_1/2, 85Rb 37S_1/2, 85Rb 38S_1/2, 85Rb 39S_1/2, 85Rb 40S_1/2, 85Rb 41S_1/2, 85Rb 42S_1/2, 85Rb 43S_1/2, 85Rb 44S_1/2, 85Rb 45S_1/2, 85Rb 46S_1/2, 85Rb 47S_1/2, 85Rb 48S_1/2, 85Rb 49S_1/2, 85Rb 50S_1/2]
If an omega_max is provided any state with an energy higher than hbar*omega will not be returned. If an omega_min is provided any state with an energy lower than hbar*omega will not be returned.
>>> atom.states(omega_min=1.00845e15*2*pi, omega_max=1.0086e+15*2*pi) [85Rb 49S_1/2, 85Rb 50S_1/2]
If return_missing=True then the function will return a 2-tuple composed by a list of the states available, and a list of the valid states not available.
>>> available,not_available=atom.states(Nmax=5,return_missing=True) >>> print available [85Rb 5S_1/2, 85Rb 5P_1/2, 85Rb 5P_3/2, 85Rb 4D_5/2, 85Rb 4D_3/2, 85Rb 5D_3/2, 85Rb 5D_5/2] >>> print not_available [('Rb', 85, 1, 0, 1/2), ('Rb', 85, 2, 0, 1/2), ('Rb', 85, 2, 1, 1/2), ('Rb', 85, 2, 1, 3/2), ('Rb', 85, 3, 0, 1/2), ('Rb', 85, 3, 1, 1/2), ('Rb', 85, 3, 1, 3/2), ('Rb', 85, 3, 2, 3/2), ('Rb', 85, 3, 2, 5/2), ('Rb', 85, 4, 0, 1/2), ('Rb', 85, 4, 1, 1/2), ('Rb', 85, 4, 1, 3/2), ('Rb', 85, 4, 3, 5/2), ('Rb', 85, 4, 3, 7/2), ('Rb', 85, 5, 3, 5/2), ('Rb', 85, 5, 3, 7/2), ('Rb', 85, 5, 4, 7/2), ('Rb', 85, 5, 4, 9/2)]
-
transitions
(omega_min=None, omega_max=None)¶ Find all allowed transitions.
This function finds all allowed transitions (by electric-dipole selection rules) in the atom.
>>> atom=Atom("Rb",85) >>> transitions=atom.transitions() >>> print len(transitions) 270
Arguments omega_min and omega_max can be used to make filter out the results.
>>> from scipy.constants import c >>> wavelength_min=770e-9 >>> wavelength_max=790e-9 >>> omega_min=2*pi*c/wavelength_max >>> omega_max=2*pi*c/wavelength_min
>>> easy_transitions=atom.transitions(omega_min=omega_min, ... omega_max=omega_max) >>> for ti in easy_transitions: ... print abs(ti.wavelength)*1e9, ti 780.241476935 85Rb 5S_1/2 -----> 85Rb 5P_3/2 776.157015322 85Rb 5P_3/2 -----> 85Rb 5D_3/2 775.978619616 85Rb 5P_3/2 -----> 85Rb 5D_5/2
-
-
class
fast.atomic_structure.
State
(element, isotope, n, l=None, j=None, f=None, m=None)¶ This class implements specific eigenstates of the atomic hamiltonian.
The states must be identified by element, isotope and quantum numbers in one of these forms:
1 .- \(|n, l, j\rangle\)
>>> State("Rb",85,5,0,1/Integer(2)) 85Rb 5S_1/2
2 .- \(|n, l, j, f>\)
>>> State("Cs", 133, 6, 0, 1/Integer(2), 3) 133Cs 6S_1/2^3
3 .- \(|n, l, j, f, m>\)
>>> State("Rb", 87, 5, 0, 1/Integer(2), 2, -1) 87Rb 5S_1/2^2,-1
States have many useful properties:
>>> g2=State("Cs", 133, 6, 0, 1/Integer(2), 4, 4) >>> e =State("Cs", 133, 6, 1, 3/Integer(2), 5, 5)
The defining properties of the state:
>>> g2.element, g2.isotope, g2.n, g2.l, g2.j, g2.f, g2.m ('Cs', 133, 6, 0, 1/2, 4, 4)
The atomic number of the element:
>>> g2.Z 55
The number of neutrons:
>>> g2.neutrons 78
The mass of the atom (in kilograms):
>>> print g2.mass 2.2069469161e-25
The absolute frequency of the state relative to the groundstate energy (in Hz):
>>> print g2.nu 4021776399.38
The angular frequency of the state (in rad/s):
>>> print g2.omega 25269566381.3
The hyperfine constants Ahfs, Bhfs, Chfs:
>>> print e.Ahfs, e.Bhfs, e.Chfs 50288250.0 -494000.0 560.0
A latex representation:
>>> print g2._latex_() ^{133}\mathrm{Cs}\ 6S_{1/2}^{4,4}
-
class
fast.atomic_structure.
Transition
(e1, e2)¶ This class describes a transition between different atomic states.
For instance, the transition between the hyperfine ground states of cesium used in the definition of the second.
>>> g1 = State("Cs", 133, 6, 0, 1/Integer(2),3) >>> g2 = State("Cs", 133, 6, 0, 1/Integer(2),4) >>> clock =Transition(g2,g1) >>> clock 133Cs 6S_1/2^4 --/--> 133Cs 6S_1/2^3
By this definition, the exact frequency of this transition is
>>> clock.nu 9192631770.0
-
fast.atomic_structure.
calculate_boundaries
(fine_states, full_magnetic_states)¶ Calculate the boundary indices within a list of magnetic states.
This function calculates the boundary indices of each fine state and each hyperfine state within a list of magnetic states. The output is a list of tuples (a,b) with a the starting index of a state and b it’s ending index.
>>> g=State("Rb", 87, 5, 0, 1/Integer(2)) >>> full_magnetic_states=make_list_of_states([g],"magnetic") >>> calculate_boundaries([g], full_magnetic_states) ([(0, 8)], [(0, 3), (3, 8)])
-
fast.atomic_structure.
calculate_gamma_matrix
(magnetic_states, Omega=1)¶ Calculate the matrix of decay between states.
This function calculates the matrix \(\gamma_{ij}\) of decay rates between states \(|i\rangle\) and \(|j\rangle\) (in the units specified by the Omega argument).
>>> g=State("Rb",87,5,0,1/Integer(2)) >>> e=State("Rb",87,5,1,3/Integer(2)) >>> magnetic_states=make_list_of_states([g,e],"magnetic")
To return the rates in rad/s:
>>> print calculate_gamma_matrix(magnetic_states) [[0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, -12702506.296014734, -15878132.870018415, -15878132.870018415, -0.0, -19053759.4440221, -9526879.72201105, -3175626.5740036834, -0.0, -0.0, -0.0, -0.0, -0.0, -0.0, -0.0, -0.0, -0.0], [0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, -12702506.296014734, -15878132.870018415, -0.0, -15878132.870018415, -0.0, -9526879.72201105, -12702506.296014734, -9526879.72201105, -0.0, -0.0, -0.0, -0.0, -0.0, -0.0, -0.0, -0.0], [0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, -12702506.296014734, -0.0, -15878132.870018415, -15878132.870018415, -0.0, -0.0, -3175626.5740036834, -9526879.72201105, -19053759.4440221, -0.0, -0.0, -0.0, -0.0, -0.0, -0.0, -0.0], [0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, -0.0, -3810751.8888044204, -0.0, -0.0, -12702506.296014734, -6351253.148007367, -0.0, -0.0, -0.0, -38107518.8880442, -12702506.296014734, -2540501.2592029474, -0.0, -0.0, -0.0, -0.0], [0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, -0.0, -1905375.9444022102, -1905375.9444022102, -0.0, -6351253.148007367, -3175626.5740036834, -9526879.72201105, -0.0, -0.0, -0.0, -25405012.592029467, -20324010.07362358, -7621503.77760884, -0.0, -0.0, -0.0], [0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, -0.0, -635125.3148007367, -2540501.259202947, -635125.3148007367, -0.0, -9526879.72201105, -0.0, -9526879.72201105, -0.0, -0.0, -0.0, -15243007.55521768, -22864511.33282652, -15243007.55521768, -0.0, -0.0], [0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, -0.0, -0.0, -1905375.9444022102, -1905375.9444022102, -0.0, -0.0, -9526879.72201105, -3175626.5740036834, -6351253.148007367, -0.0, -0.0, -0.0, -7621503.77760884, -20324010.07362358, -25405012.592029467, -0.0], [0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, -0.0, -0.0, -0.0, -3810751.8888044204, -0.0, -0.0, -0.0, -6351253.148007367, -12702506.296014734, -0.0, -0.0, -0.0, -0.0, -2540501.2592029474, -12702506.296014734, -38107518.8880442], [12702506.296014734, 12702506.296014734, 12702506.296014734, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0], [15878132.870018415, 15878132.870018415, 0.0, 3810751.8888044204, 1905375.9444022102, 635125.3148007367, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0], [15878132.870018415, 0.0, 15878132.870018415, 0.0, 1905375.9444022102, 2540501.259202947, 1905375.9444022102, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0], [0.0, 15878132.870018415, 15878132.870018415, 0.0, 0.0, 635125.3148007367, 1905375.9444022102, 3810751.8888044204, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0], [19053759.4440221, 0.0, 0.0, 12702506.296014734, 6351253.148007367, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0], [9526879.72201105, 9526879.72201105, 0.0, 6351253.148007367, 3175626.5740036834, 9526879.72201105, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0], [3175626.5740036834, 12702506.296014734, 3175626.5740036834, 0.0, 9526879.72201105, 0.0, 9526879.72201105, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0], [0.0, 9526879.72201105, 9526879.72201105, 0.0, 0.0, 9526879.72201105, 3175626.5740036834, 6351253.148007367, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0], [0.0, 0.0, 19053759.4440221, 0.0, 0.0, 0.0, 6351253.148007367, 12702506.296014734, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0], [0.0, 0.0, 0.0, 38107518.8880442, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0], [0.0, 0.0, 0.0, 12702506.296014734, 25405012.592029467, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0], [0.0, 0.0, 0.0, 2540501.2592029474, 20324010.07362358, 15243007.55521768, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0], [0.0, 0.0, 0.0, 0.0, 7621503.77760884, 22864511.33282652, 7621503.77760884, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0], [0.0, 0.0, 0.0, 0.0, 0.0, 15243007.55521768, 20324010.07362358, 2540501.2592029474, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0], [0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 25405012.592029467, 12702506.296014734, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0], [0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 38107518.8880442, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0]]
To return the rates in 10^6 rad /s:
>>> gamma = calculate_gamma_matrix(magnetic_states,Omega=1e6) >>> gamma [[0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, -12.702506296014734, -15.878132870018417, -15.878132870018417, -0.0, -19.053759444022102, -9.526879722011051, -3.1756265740036835, -0.0, -0.0, -0.0, -0.0, -0.0, -0.0, -0.0, -0.0, -0.0], [0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, -12.702506296014734, -15.878132870018417, -0.0, -15.878132870018417, -0.0, -9.526879722011051, -12.702506296014734, -9.526879722011051, -0.0, -0.0, -0.0, -0.0, -0.0, -0.0, -0.0, -0.0], [0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, -12.702506296014734, -0.0, -15.878132870018417, -15.878132870018417, -0.0, -0.0, -3.1756265740036835, -9.526879722011051, -19.053759444022102, -0.0, -0.0, -0.0, -0.0, -0.0, -0.0, -0.0], [0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, -0.0, -3.8107518888044205, -0.0, -0.0, -12.702506296014734, -6.351253148007367, -0.0, -0.0, -0.0, -38.107518888044204, -12.702506296014734, -2.5405012592029474, -0.0, -0.0, -0.0, -0.0], [0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, -0.0, -1.9053759444022103, -1.9053759444022103, -0.0, -6.351253148007367, -3.1756265740036835, -9.526879722011051, -0.0, -0.0, -0.0, -25.40501259202947, -20.32401007362358, -7.62150377760884, -0.0, -0.0, -0.0], [0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, -0.0, -0.6351253148007368, -2.540501259202947, -0.6351253148007368, -0.0, -9.526879722011051, -0.0, -9.526879722011051, -0.0, -0.0, -0.0, -15.24300755521768, -22.86451133282652, -15.24300755521768, -0.0, -0.0], [0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, -0.0, -0.0, -1.9053759444022103, -1.9053759444022103, -0.0, -0.0, -9.526879722011051, -3.1756265740036835, -6.351253148007367, -0.0, -0.0, -0.0, -7.62150377760884, -20.32401007362358, -25.40501259202947, -0.0], [0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, -0.0, -0.0, -0.0, -3.8107518888044205, -0.0, -0.0, -0.0, -6.351253148007367, -12.702506296014734, -0.0, -0.0, -0.0, -0.0, -2.5405012592029474, -12.702506296014734, -38.107518888044204], [12.702506296014734, 12.702506296014734, 12.702506296014734, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0], [15.878132870018417, 15.878132870018417, 0.0, 3.8107518888044205, 1.9053759444022103, 0.6351253148007368, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0], [15.878132870018417, 0.0, 15.878132870018417, 0.0, 1.9053759444022103, 2.540501259202947, 1.9053759444022103, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0], [0.0, 15.878132870018417, 15.878132870018417, 0.0, 0.0, 0.6351253148007368, 1.9053759444022103, 3.8107518888044205, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0], [19.053759444022102, 0.0, 0.0, 12.702506296014734, 6.351253148007367, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0], [9.526879722011051, 9.526879722011051, 0.0, 6.351253148007367, 3.1756265740036835, 9.526879722011051, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0], [3.1756265740036835, 12.702506296014734, 3.1756265740036835, 0.0, 9.526879722011051, 0.0, 9.526879722011051, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0], [0.0, 9.526879722011051, 9.526879722011051, 0.0, 0.0, 9.526879722011051, 3.1756265740036835, 6.351253148007367, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0], [0.0, 0.0, 19.053759444022102, 0.0, 0.0, 0.0, 6.351253148007367, 12.702506296014734, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0], [0.0, 0.0, 0.0, 38.107518888044204, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0], [0.0, 0.0, 0.0, 12.702506296014734, 25.40501259202947, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0], [0.0, 0.0, 0.0, 2.5405012592029474, 20.32401007362358, 15.24300755521768, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0], [0.0, 0.0, 0.0, 0.0, 7.62150377760884, 22.86451133282652, 7.62150377760884, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0], [0.0, 0.0, 0.0, 0.0, 0.0, 15.24300755521768, 20.32401007362358, 2.5405012592029474, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0], [0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 25.40501259202947, 12.702506296014734, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0], [0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 38.107518888044204, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0]]
Let us test if all D2 lines decay at the expected rate (6.065 MHz):
>>> Gamma =[ sum([ gamma[i][j] for j in range(i)])/2/pi for i in range(len(magnetic_states))][8:] >>> for Gammai in Gamma: print Gammai 6.065 6.065 6.065 6.065 6.065 6.065 6.065 6.065 6.065 6.065 6.065 6.065 6.065 6.065 6.065 6.065
-
fast.atomic_structure.
calculate_matrices
(states, Omega=1)¶ Calculate the matrices omega_ij, gamma_ij, r_pij.
This function calculates the matrices omega_ij, gamma_ij and r_pij given a list of atomic states. The states can be arbitrarily in their fine, hyperfine or magnetic detail.
-
fast.atomic_structure.
calculate_omega_matrix
(states, Omega=1)¶ Calculate the matrix of transition frequencies.
This function recieves a list of states and returns the corresponding omega_ij matrix, rescaled to units of Omega. These are understood to be absolute frequencies (as opposed angular frequencies).
-
fast.atomic_structure.
calculate_reduced_matrix_elements
(fine_states, convention=1)¶ Calculate the reduced matrix elements for a list of fine states.
This function calculates the reduced matrix elments
\[\langle N,L,J||T^1(r)||N',L',J'\rangle\]given a list of fine states.
We calculate the reduced matrix elements found in [SteckRb87] for the D1 and D2 lines in rubidium.
>>> g=State("Rb",87,5,0,1/Integer(2)) >>> e1=State("Rb",87,5,1,1/Integer(2)) >>> e2=State("Rb",87,5,1,3/Integer(2)) >>> red=calculate_reduced_matrix_elements([g, e1, e2], convention=2) >>> print red[0][1] 2.99207750426 >>> print red[0][2] 4.22698361868
-
fast.atomic_structure.
collision_rate
(Temperature, element, isotope)¶ This function recieves the temperature of an atomic vapour (in Kelvin), the element, and the isotope of the atoms, and returns the angular frequency rate of collisions (in rad/s) in a vapour assuming a Maxwell-Boltzmann velocity distribution, and taking the cross section of the collision to be
\[\sigma = \pi (2r)^2\]where r is the atomic radius. colission rate returned is
\[\gamma_{col}=2 \pi ( \sigma v n )\]where v is the average velocity of the distribution, and n is the number density of the vapour.
A few examples (in Hz):
>>> print collision_rate(25 + 273.15, "Cs", 133)/2/pi 9.0607260277
For cesium collisions become important for temperatures above 120 Celsius.
>>> print collision_rate(120 + 273.15, "Cs", 133)/2/pi 10519.235289
-
fast.atomic_structure.
matrix_element
(ji, fi, mi, jj, fj, mj, q, II, reduced_matrix_element, numeric=True, convention=1)¶ Calculate a matrix element of the electric dipole.
-
fast.atomic_structure.
reduced_matrix_element
(fine_statei, fine_statej, convention=1)¶ Return the reduced matrix element of the position operator in Bohrradii.
We have two available conventions for this
\[\begin{split}\langle \gamma_i, J_i, M_i| \hat{T}^k_q| \gamma_j, J_j, M_j\rangle \ = (-1)^{J_i-M_i} \ \left(\begin{matrix}J_i & k & J_j\\-M_i & q & M_j\end{matrix}\right) \ \langle \gamma_i, J_i|| \hat{T}^k|| \gamma_j, J_j \ \rangle_\mathrm{Racah}\end{split}\]2.- [Brink_Satchler]
\[\begin{split}\langle \gamma_i, J_i, M_i| \hat{T}^k_q| \gamma_j, J_j, M_j\rangle \ = (-1)^{J_i-M_i} \sqrt{2J_i+1} \ \left(\begin{matrix}J_i & k & J_j\\-M_i & q & M_j\end{matrix}\right) \ \langle \gamma_i, J_i|| \hat{T}^k|| \gamma_j, J_j\rangle \ _\mathrm{Brink}\end{split}\]These two definitions of the reduced matrix element are related by
\[\langle \gamma_i, J_i|| \hat{T}^k|| \gamma_j, J_j \ \rangle_\mathrm{Racah} = \sqrt{2J_i+1} \ \langle \gamma_i, J_i|| \hat{T}^k|| \gamma_j, J_j\rangle \ _\mathrm{Brink}\]With the Racah element being symetric under argument exchange apart from asign:
\[\langle \gamma_j, J_j|| (\hat{T}^k)^\dagger|| \gamma_i, J_i\rangle \ _\mathrm{Racah} = (-1)^{J_j-J_i}\ \langle \gamma_i, J_i|| \hat{T}^k|| \gamma_j, J_j\rangle \ _\mathrm{Racah}\]And the Brink element being asymetric under argument exchange:
\[\langle \gamma_j, J_j|| \hat{T}^k|| \gamma_i, J_i\rangle \ _\mathrm{Brink} = (-1)^{J_j-J_i}\ \frac{\sqrt{2J_i +1}}{\sqrt{2J_j +1}}\ \langle \gamma_i, J_i|| \hat{T}^k|| \gamma_j, J_j\rangle \ _\mathrm{Brink}\]References:
[Brink_Satchler] Brink, D. M. and G. R. Satchler: 1994. “AngularMomentum”. Oxford: Oxford University Press, 3rd edn., 182 pages. [Racah] Racah, G.: 1942. “Theory of complex spectra II”. Phys. Rev., 62 438-462. [Edmonds] Racah, G.: 1942. “Theory of complex spectra II”. Phys. Rev., 62 438-462. >>> g = State("Rb", 87, 5, 0, 1/Integer(2)) >>> e = State("Rb", 87, 5, 1, 3/Integer(2)) >>> print reduced_matrix_element(g, e) 5.97785756147 >>> print reduced_matrix_element(e, g) -5.97785756146761 >>> print reduced_matrix_element(g, e, convention=2) 4.22698361868 >>> print reduced_matrix_element(e, g, convention=2) -2.11349180934051
-
fast.atomic_structure.
speed_average
(Temperature, element, isotope)¶ This function calculates the average speed (in meters per second) of an atom in a vapour assuming a Maxwell-Boltzmann velocity distribution. This is simply \(\sqrt{8 k_B T/m/\pi}\)
where \(k_B\) is Boltzmann’s constant, T is the temperature (in Kelvins) and m is the mass of the atom (in kilograms).
>>> print speed_average(25+273.15,"Rb",85) 272.65940782
>>> print speed_average(25+273.15,"Cs",133) 217.938062809
-
fast.atomic_structure.
speed_likely
(Temperature, element, isotope)¶ This function calculates the most likely speed (in meters per second) of an atom in a vapour assuming a Maxwell-Boltzmann velocity distribution. This is simply \(\sqrt{2 k_B T/m}\)
where \(k_B\) is Boltzmann’s constant, T is the temperature (in Kelvins) and m is the mass of the atom (in kilograms).
>>> print speed_likely(25+273.15,"Rb",85) 241.638108688
>>> print speed_likely(25+273.15,"Cs",133) 193.142579342
-
fast.atomic_structure.
speed_rms
(Temperature, element, isotope)¶ This function calculates the root mean squared speed (in meters per second) of an atom in a vapour assuming a Maxwell-Boltzmann velocity distribution. This is simply \(\sqrt{8k_B T/m/\pi}\)
where \(k_B\) is Boltzmann’s constant, T is the temperature (in Kelvins) and m is the mass of the atom (in kilograms).
>>> print speed_rms(25+273.15,"Rb",85) 295.945034349
>>> print speed_rms(25+273.15,"Cs",133) 236.550383496
-
fast.atomic_structure.
vapour_density
(Temperature, element, isotope=None)¶ This function returns the density in a rubidium or cesium vapour in kg/m^-3. It receives as input the temperature in Kelvins, the name of the element, and optionally the isotope. If no isotope is specified, the density of a vapour with the natural abundances will be returned.
This is calculated using the formulas in [SteckRb85], [SteckRb87], [SteckCs].
>>> print vapour_density(90.0 + 273.15,"Cs",133) 1.85318869181e-06
If no isotope is specified, the natural abundances are used to calculate the density.
>>> print vapour_density(25.0 + 273.15,"Rb") 1.83339788085e-09
-
fast.atomic_structure.
vapour_number_density
(Temperature, element)¶ Return the number of atoms in a rubidium or cesium vapour in m^-3.
It receives as input the temperature in Kelvins and the name of the element.
This is calculated using the formulas in [SteckRb85], [SteckRb87], [SteckCs].
>>> print vapour_number_density(90.0 + 273.15,"Cs") 8.39706962725e+18
-
fast.atomic_structure.
vapour_pressure
(Temperature, element)¶ Return the vapour pressure of rubidium or cesium in Pascals.
This function receives as input the temperature in Kelvins and the name of the element.
This is calculated using the formulas in [SteckRb85], [SteckRb87], [SteckCs].
>>> print vapour_pressure(25.0 + 273.15,"Rb") 5.31769896107e-05 >>> print vapour_pressure(39.3 + 273.15,"Rb") 0.000244249795696 >>> print vapour_pressure(90.0 + 273.15,"Rb") 0.0155963687128 >>> print vapour_pressure(25.0 + 273.15,"Cs") 0.000201461144963 >>> print vapour_pressure(28.5 + 273.15,"Cs") 0.000297898928349 >>> print vapour_pressure(90.0 + 273.15,"Cs") 0.0421014384667
The element must be in the database.
>>> print vapour_pressure(90.0 + 273.15,"Ca") Traceback (most recent call last): ... ValueError: Ca is not an element in the database for this function.