Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
P
pyLIAF
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Nicolas Nunez Barreto
pyLIAF
Commits
7fbd0d39
Commit
7fbd0d39
authored
Sep 03, 2021
by
Nicolas Nunez Barreto
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'master' of
https://code.df.uba.ar/nnunez/pyliaf
parents
7e58c522
5fc88b39
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
88 additions
and
0 deletions
+88
-0
trap_values.py
pyLIAF/utils/trap_values.py
+88
-0
No files found.
pyLIAF/utils/trap_values.py
0 → 100644
View file @
7fbd0d39
# reference: https://www1.udel.edu/atom/CaII.html
# TODO: typing annotations. Use ARTIQ's?
from
scipy.constants
import
c
,
pi
,
hbar
from
..common_values
import
nm
,
MHz
_all_transitions_keywds
=
[
'SP'
,
'DP'
,
'SP32'
,
'D32P32'
,
'D52P32'
]
_all_decays
=
{
'SP'
:
135.53
*
MHz
,
'DP'
:
9.45
*
MHz
,
'SP32'
:
139.23
*
MHz
,
'DP32'
:
0.9834
*
MHz
,
'D52P32'
:
8.752
*
MHz
}
_all_waveln
=
{
'SP'
:
396.959
*
nm
,
'DP'
:
866.452
*
nm
,
'SP32'
:
393.478
*
nm
,
'DP32'
:
850.036
*
nm
,
'D52P32'
:
854.444
*
nm
}
_all_branchratio
=
{
'SP'
:
0.93481
,
'DP'
:
0.06519
,
'SP32'
:
0.93465
,
'DP32'
:
0.006602
,
'D52P32'
:
0.05875
}
__doc__
=
"""Docstring for trap_value module
Transition | Keyword | Alt Keyword
S_{1/2}->P_{1/2} | SP | Doppler
D_{3/2}->P_{1/2} | DP | Repump
S_{1/2}->P_{3/2} | SP32 |
D_{3/2}->P_{3/2} | DP32 |
D_{5/2}->P_{3/2} | D52P32 | Quench
Possible extraction values:
\t
decay
\t
linewidth
\t
wavelength
\t
frequency
\t
branching_ratio
Example: trap_values.frequency("DP32") returns frequency of transition D_{3/2}->P_{3/2}
"""
def
help
():
print
(
__doc__
)
def
_preproc_names
(
fun_name
):
"""Decorator function to allow alt-keywords for transitions dict"""
def
changename
(
transition
):
outname
=
transition
if
outname
==
'Doppler'
:
outname
=
'SP'
elif
outname
==
'Repump'
:
outname
=
'DP'
elif
outname
==
'Quench'
:
outname
=
'D52P32'
elif
outname
not
in
_all_transitions_keywds
:
raise
KeyError
(
"No es una transicion valida"
)
return
fun_name
(
outname
)
return
changename
@
_preproc_names
def
decay
(
transition
):
"""Returns decay rate of transition"""
# OBS: This is the value corresponding to 2*pi*\omega_{transition}
return
_all_decays
[
transition
]
@
_preproc_names
def
wavelength
(
transition
):
"""Returns wavelength of transition"""
return
_all_waveln
[
transition
]
@
_preproc_names
def
frequency
(
transition
):
"""Returns frequency of transition"""
return
c
/
_all_waveln
[
transition
]
@
_preproc_names
def
branching_ratio
(
transition
):
"""Returns branching ratio of transition"""
return
_all_branchratio
[
transition
]
def
sat_from_power
(
powers
,
laser_diameter
,
transition
):
"""Return Saturation parameter from laser power"""
# Reference: https://www.quantenbit.physik.uni-mainz.de/files/2015/11/pub_phd_Poschinger2011.pdf
# Eq. (2.22)
# And then using the formula for intensity: I = 2*Power/area
# Aparentemente hay un error en la cuenta, ejemplo:
# Transicion doppler con un haz de ancho 40um y potencia de 250uW:
#
# trap_values.sat_from_power(250e-6, 40e-6, "SP") ---> 1375864.87...
#
# deberia dar del orden de 1 o algo asi
intensity
=
8
*
powers
/
(
pi
*
(
laser_diameter
**
2
))
prefactor
=
(
12
*
pi
*
c
*
c
)
/
(
hbar
*
(
decay
(
transition
)
/
(
2
*
pi
))
*
(
frequency
(
transition
)
**
3
))
return
prefactor
*
intensity
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment