Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
A
artiq_experiments
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
artiq_experiments
Commits
2c74777d
Commit
2c74777d
authored
Dec 19, 2023
by
Nicolas Nunez Barreto
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
para muri
parent
21e4723d
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
54 additions
and
2 deletions
+54
-2
CPT_plotter_20220615.py
.../20220615_CPTvariandocompensacion/CPT_plotter_20220615.py
+50
-0
CPT_plotter_20231214.py
...0231214_CPTconmicromocioncristals/CPT_plotter_20231214.py
+4
-2
No files found.
analisis/plots/20220615_CPTvariandocompensacion/CPT_plotter_20220615.py
View file @
2c74777d
...
@@ -260,6 +260,56 @@ plt.xlabel('Detuning (MHz)')
...
@@ -260,6 +260,56 @@ plt.xlabel('Detuning (MHz)')
plt
.
ylabel
(
'Counts'
)
plt
.
ylabel
(
'Counts'
)
plt
.
grid
()
plt
.
grid
()
#%%
"""
Ahora repito el fit pero con un super ajuste
"""
FreqsDR
=
Freqs
[
10
]
CountsDR
=
Counts
[
10
]
def
FitEIT_MM_SA
(
Freqs
,
offset
,
DetDoppler
,
SG
,
SP
,
SCALE1
,
SCALE2
,
OFFSET
,
BETA1
,
BETA2
,
TEMP
,
U
,
plot
=
False
):
#def FitEIT_MM(freqs, SG, SP, SCALE1, OFFSET, BETA1):
#BETA = 1.8
# SG = 0.6
# SP = 8.1
# TEMP = 0.2e-3
freqs
=
[
2
*
f
*
1e-6
-
offset
for
f
in
Freqs
]
Detunings
,
Fluorescence1
=
PerformExperiment_8levels_MM
(
SG
,
SP
,
gPS
,
gPD
,
DetDoppler
,
U
,
DopplerLaserLinewidth
,
ProbeLaserLinewidth
,
TEMP
,
alpha
,
phidoppler
,
titadoppler
,
phiprobe
,
titaprobe
,
BETA1
,
drivefreq
,
min
(
freqs
),
max
(
freqs
)
+
(
freqs
[
1
]
-
freqs
[
0
]),
freqs
[
1
]
-
freqs
[
0
],
circularityprobe
=
CircPr
,
plot
=
False
,
solvemode
=
1
,
detpvec
=
None
)
Detunings
,
Fluorescence2
=
PerformExperiment_8levels_MM
(
SG
,
SP
,
gPS
,
gPD
,
DetDoppler
,
U
,
DopplerLaserLinewidth
,
ProbeLaserLinewidth
,
TEMP
,
alpha
,
phidoppler
,
titadoppler
,
phiprobe
,
titaprobe
,
BETA2
,
drivefreq
,
min
(
freqs
),
max
(
freqs
)
+
(
freqs
[
1
]
-
freqs
[
0
]),
freqs
[
1
]
-
freqs
[
0
],
circularityprobe
=
CircPr
,
plot
=
False
,
solvemode
=
1
,
detpvec
=
None
)
ScaledFluo1
=
np
.
array
([
f
*
SCALE1
+
OFFSET
for
f
in
Fluorescence1
])
ScaledFluo2
=
np
.
array
([
f
*
SCALE2
+
OFFSET
for
f
in
Fluorescence2
])
if
plot
:
return
ScaledFluo1
+
ScaledFluo2
,
Detunings
else
:
return
ScaledFluo1
+
ScaledFluo2
#return ScaledFluo1
popt_SA
,
pcov_SA
=
curve_fit
(
FitEIT_MM_SA
,
FreqsDR
,
CountsDR
,
p0
=
[
425
,
-
13
,
0.9
,
7.5
,
4e3
,
5e3
,
4000
,
3.8
,
0.8
,
0.2e-3
,
32e6
],
bounds
=
((
0
,
-
50
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
28e6
),
(
1000
,
0
,
2
,
20
,
5e6
,
5e6
,
1e4
,
10
,
10
,
20e-3
,
40e6
)))
FittedEITpi_short_SA
,
Detunings_short_SA
=
FitEIT_MM_SA
(
FreqsDR
,
*
popt_SA
,
plot
=
True
)
freqslong
=
np
.
arange
(
min
(
FreqsDR
),
max
(
FreqsDR
)
+
FreqsDR
[
1
]
-
FreqsDR
[
0
],
0.1
*
(
FreqsDR
[
1
]
-
FreqsDR
[
0
]))
FittedEITpi_long_SA
,
Detunings_long_SA
=
FitEIT_MM_SA
(
freqslong
,
*
popt_SA
,
plot
=
True
)
plt
.
figure
()
plt
.
errorbar
(
Detunings_short_SA
,
CountsDR
,
yerr
=
2
*
np
.
sqrt
(
CountsDR
),
fmt
=
'o'
,
color
=
'darkgreen'
,
alpha
=
0.5
,
capsize
=
2
,
markersize
=
2
)
plt
.
plot
(
Detunings_long_SA
,
FittedEITpi_long_SA
,
color
=
'darkolivegreen'
,
linewidth
=
3
)
plt
.
title
(
'2 ion model'
)
plt
.
xlabel
(
'Detuning (MHz)'
)
plt
.
ylabel
(
'Counts'
)
#plt.legend(loc='upper left', fontsize=20)
plt
.
grid
()
#%%
#%%
"""
"""
Vemos la contribucion de cada ion
Vemos la contribucion de cada ion
...
...
analisis/plots/20231214_CPTconmicromocioncristals/CPT_plotter_20231214.py
View file @
2c74777d
...
@@ -413,14 +413,16 @@ for selectedcurve in selectedcurvevec:
...
@@ -413,14 +413,16 @@ for selectedcurve in selectedcurvevec:
return
ScaledFluo1
+
ScaledFluo2
return
ScaledFluo1
+
ScaledFluo2
#return ScaledFluo1
#return ScaledFluo1
def
FitEIT_MM_1ion
(
Freqs
,
offset
,
DetDoppler
,
SG
,
SP
,
SCALE1
,
OFFSET
,
BETA1
,
TEMP
,
plot
=
False
):
def
FitEIT_MM_1ion
(
Freqs
,
offset1
,
offset2
,
DetDoppler
,
SG
,
SP
,
SCALE1
,
OFFSET
,
BETA1
,
TEMP
,
plot
=
False
):
#def FitEIT_MM(freqs, SG, SP, SCALE1, OFFSET, BETA1):
#def FitEIT_MM(freqs, SG, SP, SCALE1, OFFSET, BETA1):
#BETA = 1.8
#BETA = 1.8
# SG = 0.6
# SG = 0.6
# SP = 8.1
# SP = 8.1
# TEMP = 0.2e-3
# TEMP = 0.2e-3
freqs
=
[
2
*
f
*
1e-6
-
offset
for
f
in
Freqs
]
freqs
=
[
2
*
f
*
1e-6
-
offset
1
for
f
in
Freqs
]
Detunings
,
Fluorescence1
=
PerformExperiment_8levels_MM
(
SG
,
SP
,
gPS
,
gPD
,
DetDoppler
,
u
,
DopplerLaserLinewidth
,
ProbeLaserLinewidth
,
TEMP
,
alpha
,
phidoppler
,
titadoppler
,
phiprobe
,
titaprobe
,
BETA1
,
drivefreq
,
min
(
freqs
),
max
(
freqs
)
+
(
freqs
[
1
]
-
freqs
[
0
]),
freqs
[
1
]
-
freqs
[
0
],
circularityprobe
=
CircPr
,
plot
=
False
,
solvemode
=
1
,
detpvec
=
None
)
Detunings
,
Fluorescence1
=
PerformExperiment_8levels_MM
(
SG
,
SP
,
gPS
,
gPD
,
DetDoppler
,
u
,
DopplerLaserLinewidth
,
ProbeLaserLinewidth
,
TEMP
,
alpha
,
phidoppler
,
titadoppler
,
phiprobe
,
titaprobe
,
BETA1
,
drivefreq
,
min
(
freqs
),
max
(
freqs
)
+
(
freqs
[
1
]
-
freqs
[
0
]),
freqs
[
1
]
-
freqs
[
0
],
circularityprobe
=
CircPr
,
plot
=
False
,
solvemode
=
1
,
detpvec
=
None
)
#Detunings, Fluorescence2 = PerformExperiment_8levels_MM(SG, SP, gPS, gPD, DetDoppler, u, DopplerLaserLinewidth, ProbeLaserLinewidth, TEMP, alpha, phidoppler, titadoppler, phiprobe, titaprobe, BETA2, drivefreq, min(freqs), max(freqs)+(freqs[1]-freqs[0]), freqs[1]-freqs[0], circularityprobe=CircPr, plot=False, solvemode=1, detpvec=None)
#Detunings, Fluorescence2 = PerformExperiment_8levels_MM(SG, SP, gPS, gPD, DetDoppler, u, DopplerLaserLinewidth, ProbeLaserLinewidth, TEMP, alpha, phidoppler, titadoppler, phiprobe, titaprobe, BETA2, drivefreq, min(freqs), max(freqs)+(freqs[1]-freqs[0]), freqs[1]-freqs[0], circularityprobe=CircPr, plot=False, solvemode=1, detpvec=None)
...
...
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