Laboratory setup¶
Laboratory set-up for non-linear spectroscopy
This class controls calculations of non-linear optical spectra, and other experiments in which laboratory setting needs to be controlled. Examples are pulse polarization setting, pulse shapes and spectra in non-linear spectroscopy.
Class Details¶
-
class
quantarhei.spectroscopy.labsetup.
LabField
(labsetup, k)[source]¶ Class representing electric field of a laser pulse defined in LabSetup
Objects of this class are linked to their “mother” object of the LubSetup type. Their properties can be changed locally, with an effect on the LabSetup, or globally from the LabSetup with an effect on the EField objects.
Examples
Only the number of pulses has to be specified when LabSetup is created.
>>> lab = LabSetup(nopulses=3)
We can ask for a LabField object right away, even before field parameters are set.
>>> lf = LabField(lab, 1)
This object has all parameters “empty”
>>> lf.pol array([ 0., 0., 0.])
>>> lf.om 0.0
>>> lf.tc 0.0
>> lf.phi 0.0
The ‘field’ property, however, refuses to return values
>>> print(lf.field) Traceback (most recent call last): ... Exception: The property 'field' is not initialited.
Nor it can be set
>>> lf.field = 10.0 Traceback (most recent call last): ... Exception: The property 'field' is protected and cannot be set.
The LabField properties will be initialited through the LabSetup object. The only rule to follow is that arrival times of the pulses have to be specified before the pulse shape.
>>> lab.set_pulse_arrival_times([0.0, 0.0, 100.0])
>>> time = TimeAxis(-500.0, 1000, 1.0, atype="complete") >>> pulse2 = dict(ptype="Gaussian", FWHM=150, amplitude=1.0) >>> params = (pulse2, pulse2, pulse2) >>> lab.set_pulse_shapes(time, params)
Everything else can be set before we ask for the field’s time dependence. The LabField object can be created even
>>> lab.set_pulse_polarizations(pulse_polarizations=(X,X,X), ... detection_polarization=X) >>> lab.set_pulse_frequencies([1.0, 1.0, 1.0]) >>> lab.set_pulse_phases([0.0, 1.0, 0.0])
>>> lf = LabField(lab, 2) >>> print(lf.get_phase() == lab.phases[2]) True
>>> lf.set_phase(3.14) >>> print(lf.get_phase() == lab.phases[2]) True
>>> lab.phases[2] = 6.28 >>> print(lf.get_phase() == lab.phases[2]) True
>>> print(lf.get_center() == lab.pulse_centers[2]) True
>>> lf.set_center(12.0) >>> print(lab.pulse_centers[2]) 12.0
>>> print(lf.get_frequency() == lab.omega[2]) True
>>> lf.set_frequency(12.0) >>> print(lab.omega[2]) 12.0
>>> lf.get_polarization() array([ 1., 0., 0.])
>>> lab.e[2,:] = [0.0, 1.0, 0.0] >>> lf.get_polarization() array([ 0., 1., 0.])
>>> lf.set_polarization([0.0, 0.0, 1.0]) >>> lab.e[2,:] array([ 0., 0., 1.])
# we also have some quick access attributes
>>> print(lf.phi) 6.28
>>> lf.phi = 1.2 >>> lf.phi 1.2
>>> print(lf.phi == lab.phases[2]) True
>>> print(lf.tc) 12.0
>>> lf._center_changed False
>>> lf.tc = 10.0 >>> lf.tc 10.0
>> lf._center_changed True
>>> print(lf.tc == lab.pulse_centers[2]) True
>>> print(lf.om) 12.0
>>> lf.om = 10.0 >>> lf.om 10.0
>>> print(lf.om == lab.omega[2]) True
>>> lf.pol array([ 0., 0., 1.])
>>> lab.e[2,:] = [0.0, 1.0, 0.0] >>> lf.pol array([ 0., 1., 0.])
>>> lf.pol = [0.0, 0.0, 1.0] >>> lab.e[2,:] array([ 0., 0., 1.])
Most importantly, we can access the field values
>>> fld = lf.field >>> fld.shape (1000,)
and this property cannot be directly changed. >>> lf.field = 10.0 Traceback (most recent call last):
…Exception: The property ‘field’ is protected and cannot be set.
Attributes: - field
- field_m
- field_p
- om
- phi
- pol
- tc
Methods
get_field
([time, sign])Returns the electric field of the pulses get_center get_frequency get_phase get_polarization get_time_axis restore_rwa set_center set_frequency set_phase set_polarization set_rwa
-
class
quantarhei.spectroscopy.labsetup.
LabSetup
(nopulses=3)[source]¶ Laboratory set-up for non-linear spectroscopy
Class representing laboratory setup for non-linear spectroscopic experiments. It holds information about pulse shapes and polarizations.
Pulses can be set in time- and/or frequency-domain. Consistency between the domains is not checked nor enforced. Consistent conversion between domains is provided by convenience routines [TO BE IMPLEMENTED]
Parameters: nopulses (int) – Number of pulses in the experiment. Default is 3.
Attributes: - number_of_pulses
Methods
convert_to_frequency
()Converts pulse information from time domain to frequency domain convert_to_time
()Converts pulse information from frequency domain to time domain get_detection_polarization
()Returns detection polarizations get_labfields
()Retruns a list of EField objects for the lab’s pulses get_pulse_arrival_time
(k)Returns frequency of the pulse with index k get_pulse_arrival_times
()Returns frequency of the pulse with index k get_pulse_envelop
(k, t)Returns a numpy array with the pulse time-domain envelope get_pulse_frequency
(k)Returns frequency of the pulse with index k get_pulse_phase
(k)Returns frequency of the pulse with index k get_pulse_phases
()Returns frequency of the pulse with index k get_pulse_polarizations
()Returns polarizations of the laser pulses get_pulse_spectrum
(k, omega)Returns a numpy array with the pulse frequency-domain spectrum reset_pulse_shape
()Recalculates the pulse shapes set_pulse_arrival_times
(times)Sets the arrival time (i.e. set_pulse_frequencies
(omegas)Sets pulse frequencies set_pulse_phases
(phases)Sets the phases of the individual pulses set_pulse_polarizations
([…])Sets polarizations of the experimental pulses set_pulse_shapes
(axis, params)Sets the pulse properties get_labfield restore_rwa set_rwa -
convert_to_frequency
()[source]¶ Converts pulse information from time domain to frequency domain
Examples
>>> import quantarhei as qr >>> lab = LabSetup() >>> time = qr.TimeAxis(-100,200,1.0, atype="complete") >>> pulse = dict(ptype="Gaussian", FWHM=20, amplitude=1.0) >>> params = (pulse, pulse, pulse) >>> lab.set_pulse_arrival_times([0.0, 0.0, 0.0]) >>> lab.set_pulse_phases([0.0, 0.0, 0.0]) >>> lab.set_pulse_shapes(time, params) >>> lab.convert_to_frequency() >>> # plot the original and the FT pulses >>> pls_1f = lab.pulse_f[1] # doctest: +SKIP >>> plt.plot(pls_1f.axis.data, pls_1f.data) # doctest: +SKIP >>> pls_1t = lab.pulse_t[1] # doctest: +SKIP >>> plt.plot(pls_1t.axis.data, pls_1t.data) # doctest: +SKIP >>> plt.show() # doctest: +SKIP
(Source code, png, hires.png, pdf)
Situation in which excetions are thrown
>>> lab = LabSetup() >>> lab.convert_to_frequency() Traceback (most recent call last): ... Exception: Cannot convert to frequency domain: time domain not set
-
convert_to_time
()[source]¶ Converts pulse information from frequency domain to time domain
Examples
>>> import quantarhei as qr >>> import matplotlib.pyplot as plt >>> lab = LabSetup() >>> freq = qr.FrequencyAxis(-100, 200, 1.0) # atype="complete" is default >>> pulse = dict(ptype="Gaussian", FWHM=20, amplitude=1.0) >>> params = (pulse, pulse, pulse) >>> lab.set_pulse_arrival_times([0.0, 0.0, 0.0]) >>> lab.set_pulse_phases([0.0, 0.0, 0.0]) >>> lab.set_pulse_shapes(freq, params) >>> lab.convert_to_time() >>> # plot the original and the FT pulses >>> pls_1f = lab.pulse_f[1] # doctest: +SKIP >>> p1 = plt.plot(pls_1f.axis.data, pls_1f.data) # doctest: +SKIP >>> pls_1t = lab.pulse_t[1] # doctest: +SKIP >>> p2 = plt.plot(pls_1t.axis.data, pls_1t.data) # doctest: +SKIP >>> plt.show() # doctest: +SKIP
(Source code, png, hires.png, pdf)
Now we compare back and forth Fourier transform with the original
>>> import quantarhei as qr >>> import numpy >>> lab = LabSetup() >>> freq = qr.FrequencyAxis(-100,200,1.0) # atype="complete" is default >>> pulse = dict(ptype="Gaussian", FWHM=20, amplitude=1.0) >>> params = (pulse, pulse, pulse) >>> lab.set_pulse_arrival_times([0.0, 0.0, 0.0]) >>> lab.set_pulse_phases([0.0, 0.0, 0.0]) >>> lab.set_pulse_shapes(freq, params) >>> freq_vals_1 = lab.get_pulse_spectrum(2, freq.data) >>> lab.convert_to_time()
Here we override the original frequency domain definition
>>> lab.convert_to_frequency() >>> freq_vals_2 = lab.get_pulse_spectrum(2, freq.data) >>> numpy.allclose(freq_vals_2, freq_vals_1) True
and now the other way round
>>> import quantarhei as qr >>> import numpy >>> lab = LabSetup() >>> time = qr.TimeAxis(-100,200,1.0, atype="complete") >>> pulse = dict(ptype="Gaussian", FWHM=20, amplitude=1.0) >>> params = (pulse, pulse, pulse) >>> lab.set_pulse_arrival_times([0.0, 0.0, 0.0]) >>> lab.set_pulse_phases([0.0, 0.0, 0.0]) >>> lab.set_pulse_shapes(time, params) >>> time_vals_1 = lab.get_pulse_envelop(2, time.data) >>> lab.convert_to_frequency()
Here we override the original time domain definition
>>> lab.convert_to_time() >>> time_vals_2 = lab.get_pulse_envelop(2, freq.data) >>> numpy.allclose(time_vals_2, time_vals_1) True
Situation in which excetions are thrown
>>> lab = LabSetup() >>> lab.convert_to_time() Traceback (most recent call last): ... Exception: Cannot convert to time domain: frequency domain not set
-
get_detection_polarization
()[source]¶ Returns detection polarizations
Examples
>>> import quantarhei as qr >>> lab = LabSetup() >>> lab.set_pulse_polarizations(pulse_polarizations=(qr.utils.vectors.X, ... qr.utils.vectors.Y, ... qr.utils.vectors.Z)) >>> detpol = lab.get_detection_polarization() >>> print(detpol) [ 1. 0. 0.]
-
get_pulse_arrival_time
(k)[source]¶ Returns frequency of the pulse with index k
Parameters: k (int) – Pulse index Examples
>>> lab = LabSetup() >>> lab.set_pulse_arrival_times([1.0, 20.0, 100.0]) >>> print(lab.get_pulse_arrival_time(1)) 20.0
-
get_pulse_arrival_times
()[source]¶ Returns frequency of the pulse with index k
Examples
>>> lab = LabSetup() >>> lab.set_pulse_arrival_times([1.0, 20.0, 100.0]) >>> print(lab.get_pulse_arrival_times()) [1.0, 20.0, 100.0]
-
get_pulse_envelop
(k, t)[source]¶ Returns a numpy array with the pulse time-domain envelope
Parameters: - k (int) – Index of the pulse to be returned
- t (array like) – Array of time points at which the pulse is returned
Examples
>>> import quantarhei as qr >>> lab = LabSetup() >>> time = qr.TimeAxis(-100, 200, 1.0, atype="complete") >>> pulse2 = dict(ptype="Gaussian", FWHM=30.0, amplitude=1.0) >>> params = (pulse2, pulse2, pulse2) >>> lab.set_pulse_arrival_times([0.0, 0.0, 0.0]) >>> lab.set_pulse_phases([0.0, 0.0, 0.0]) >>> lab.set_pulse_shapes(time, params) >>> dfc = lab.get_pulse_envelop(1, [-50.0, -30.0, 2.0, 30.0]) >>> print(dfc) [ 1.41569209e-05 1.95716100e-03 3.09310662e-02 1.95716100e-03]
import quantarhei as qr import matplotlib.pyplot as plt lab = qr.LabSetup() time = qr.TimeAxis(-500.0, 1000, 1.0, atype="complete") pulse2 = dict(ptype="Gaussian", FWHM=150.0, amplitude=1.0) params = (pulse2, pulse2, pulse2) lab.set_pulse_arrival_times([0.0, 0.0, 0.0]) lab.set_pulse_phases([0.0, 0.0, 0.0]) lab.set_pulse_shapes(time, params) pls = lab.pulse_t[2] lab2 = qr.LabSetup() pulse1 = dict(ptype="numeric", function=pls) params = (pulse1, pulse1, pulse1) lab2.set_pulse_arrival_times([0.0, 0.0, 0.0]) lab2.set_pulse_phases([0.0, 0.0, 0.0]) lab2.set_pulse_shapes(time, params) dfc = lab2.get_pulse_envelop(1, time.data) pl = plt.plot(time.data, dfc) plt.show()
(Source code, png, hires.png, pdf)
-
get_pulse_frequency
(k)[source]¶ Returns frequency of the pulse with index k
Parameters: k (int) – Pulse index Examples
>>> lab = LabSetup() >>> lab.set_pulse_frequencies([1.0, 2.0, 1.0]) >>> print(lab.get_pulse_frequency(1)) 2.0
-
get_pulse_phase
(k)[source]¶ Returns frequency of the pulse with index k
Parameters: k (int) – Pulse index Examples
>>> lab = LabSetup() >>> lab.set_pulse_phases([1.0, 3.14, -1.0]) >>> print(lab.get_pulse_phase(1)) 3.14
-
get_pulse_phases
()[source]¶ Returns frequency of the pulse with index k
Examples
>>> lab = LabSetup() >>> lab.set_pulse_phases([1.0, 3.14, -1.0]) >>> print(lab.get_pulse_phases()) [1.0, 3.14, -1.0]
-
get_pulse_polarizations
()[source]¶ Returns polarizations of the laser pulses
Examples
>>> import quantarhei as qr >>> lab = LabSetup() >>> lab.set_pulse_polarizations(pulse_polarizations=(qr.utils.vectors.X, ... qr.utils.vectors.Y, ... qr.utils.vectors.Z)) >>> pols = lab.get_pulse_polarizations() >>> print(len(pols)) 3
-
get_pulse_spectrum
(k, omega)[source]¶ Returns a numpy array with the pulse frequency-domain spectrum
Parameters: - k (int) – Index of the pulse to be returned
- omega (array like) – Array of frequency points at which the pulse is returned
Examples
>>> import quantarhei as qr >>> lab = LabSetup() >>> freq = qr.FrequencyAxis(-2500, 1000, 5.0) >>> pulse2 = dict(ptype="Gaussian", FWHM=800.0, amplitude=1.0) >>> params = (pulse2, pulse2, pulse2) >>> lab.set_pulse_arrival_times([0.0, 0.0, 0.0]) >>> lab.set_pulse_phases([0.0, 0.0, 0.0]) >>> lab.set_pulse_shapes(freq, params) >>> dfc = lab.get_pulse_spectrum(1, [600.0, 700.0, 800.0, 900.0]) >>> print(dfc) [ 2.46865554e-04 1.40563844e-04 7.33935684e-05 3.51409609e-05]
Here is a complete example with setting, getting and plotting spectrum:
import quantarhei as qr import matplotlib.pyplot as plt lab = qr.LabSetup() freq = qr.FrequencyAxis(-2500, 1000, 5.0) pulse2 = dict(ptype="Gaussian", FWHM=800.0, amplitude=1.0) params = (pulse2, pulse2, pulse2) lab.set_pulse_arrival_times([0.0, 0.0, 0.0]) lab.set_pulse_phases([0.0, 0.0, 0.0]) lab.set_pulse_shapes(freq, params) pls = lab.pulse_f[2] lab2 = qr.LabSetup() pulse1 = dict(ptype="numeric", function=pls) params = (pulse1, pulse1, pulse1) lab2.set_pulse_arrival_times([0.0, 0.0, 0.0]) lab2.set_pulse_phases([0.0, 0.0, 0.0]) lab2.set_pulse_shapes(freq, params) dfc = lab2.get_pulse_spectrum(1, freq.data) pl = plt.plot(freq.data, dfc) plt.show()
(Source code, png, hires.png, pdf)
-
set_pulse_arrival_times
(times)[source]¶ Sets the arrival time (i.e. centers) of the pulses
Parameters: times (array of floats) – Arrival times (centers) of the pulses Examples
>>> lab = LabSetup() >>> lab.set_pulse_arrival_times([1.0, 20.0, 100.0]) >>> print(lab.pulse_centers) [1.0, 20.0, 100.0]
Situation which throws an exception
>>> lab = LabSetup() >>> lab.set_pulse_arrival_times([1.0, 2.0, 1.0, 6.0]) Traceback (most recent call last): ... Exception: Wrong number of arrival times: 3 required
-
set_pulse_frequencies
(omegas)[source]¶ Sets pulse frequencies
Parameters: omegas (array of floats) – Frequencies of pulses Examples
>>> lab = LabSetup() >>> lab.set_pulse_frequencies([1.0, 2.0, 1.0]) >>> print(lab.omega) [ 1. 2. 1.]
Situation which throws an exception
>>> lab = LabSetup() >>> lab.set_pulse_frequencies([1.0, 2.0, 1.0, 6.0]) Traceback (most recent call last): ... Exception: Wrong number of frequencies: 3 required
-
set_pulse_phases
(phases)[source]¶ Sets the phases of the individual pulses
Parameters: phases (array of floats) – Phases of the pulses Examples
>>> lab = LabSetup() >>> lab.set_pulse_phases([1.0, 3.14, -1.0]) >>> print(lab.phases) [1.0, 3.14, -1.0]
Situation which throws an exception
>>> lab = LabSetup() >>> lab.set_pulse_phases([1.0, 2.0, 1.0, 6.0]) Traceback (most recent call last): ... Exception: Wrong number of phases: 3 required
-
set_pulse_polarizations
(pulse_polarizations=((1.0, 0.0, 0.0), (1.0, 0.0, 0.0), (1.0, 0.0, 0.0)), detection_polarization=(1.0, 0.0, 0.0))[source]¶ Sets polarizations of the experimental pulses
Parameters: - pulse_polarization (tuple like) – Contains three vectors of polarization of the three pulses of the experiment. Currently we assume three pulse experiment per default.
- detection_polarization (array) – Vector of detection polarization
Examples
>>> import quantarhei as qr >>> lab = LabSetup() >>> lab.set_pulse_polarizations(pulse_polarizations=(qr.utils.vectors.X, ... qr.utils.vectors.Y, ... qr.utils.vectors.Z)) >>> print(lab.e[0,:]) [ 1. 0. 0.] >>> print(lab.e[3,:]) [ 1. 0. 0.] >>> print(lab.e[2,:]) [ 0. 0. 1.]
>>> lab.set_pulse_polarizations(pulse_polarizations=(qr.utils.vectors.X, ... qr.utils.vectors.Y)) Traceback (most recent call last): ... Exception: pulse_polarizations requires 3 values
-
set_pulse_shapes
(axis, params)[source]¶ Sets the pulse properties
Pulse shapes or spectra are set in this routine. If axis is of TimeAxis type, the parameters are understood as time domain, if axis is of FrequencyAxis type, they are understood as frequency domain.
Parameters: - axis (TimeAxis or FrequencyAxis) – Quantarhei time axis object, which specifies the values for which pulse properties are defined. If TimeAxis is specified, the parameters are understood as time domain, if FrequencyAxis is specified, they are understood as frequency domain.
- params (dictionary) –
Dictionary of pulse parameters. The parameters are the following: ptype is the pulse type with possible values Gaussian and numeric. Time domain pulses are specified with their center at t = 0.
Gaussian pulse has further parameters amplitude, FWHM, and frequency with obvious meanings. FWHM is speficied in fs, frequency is specified in energy units, while amplitude is in units of [energy]/[transition dipole moment]. The formula for the lineshape is
\[\rm{shape}(\omega) = \frac{2}{\Delta}\sqrt{\frac{4\ln(2)}{\pi}} \exp\left\{-\frac{4\ln(2)\omega^2}{\Delta^2}\right\}\]The same formulae are used for time- and frequency domain definitions. For time domain, \(t\) should be used in stead of \(\omega\).
numeric pulse is specified by a second parameters function which should be of DFunction type and specifies line shape around zero frequency.
Examples
>>> import quantarhei as qr >>> import matplotlib.pyplot as plt >>> lab = LabSetup() ... >>> # Time axis around 0 >>> time = qr.TimeAxis(-500.0, 1000, 1.0, atype="complete")
Gaussian pulse shape in time domain
>>> pulse2 = dict(ptype="Gaussian", FWHM=150, amplitude=1.0) >>> params = (pulse2, pulse2, pulse2) >>> lab.set_pulse_arrival_times([0.0, 0.0, 0.0]) >>> lab.set_pulse_phases([0.0, 0.0, 0.0]) # these settings are compulsory >>> lab.set_pulse_shapes(time, params)
Testing the pulse shape
>>> dfc = lab.get_pulse_envelop(1, time.data) # doctest: +SKIP >>> pl = plt.plot(time.data, dfc) # doctest: +SKIP >>> plt.show() # doctest: +SKIP
(Source code, png, hires.png, pdf)
numeric pulse shape in time domain
>>> # We take the DFunction for creation of `numeric`ly defined >>> # pulse shape from the previous example >>> pls = lab.pulse_t[2] >>> # new lab object >>> lab2 = LabSetup()
>>> pulse1 = dict(ptype="numeric", function=pls) >>> params = (pulse1, pulse1, pulse1) >>> lab2.set_pulse_arrival_times([0.0, 0.0, 0.0]) >>> lab2.set_pulse_phases([0.0, 0.0, 0.0]) >>> lab2.set_pulse_shapes(time, params)
Testing the pulse shape
>>> dfc = lab2.get_pulse_envelop(1, time.data) # doctest: +SKIP >>> pl = plt.plot(time.data, dfc) # doctest: +SKIP >>> plt.show() # we skip output here # doctest: +SKIP
Gaussian pulse shape in frequency domain
>>> lab = LabSetup() >>> # FrequencyAxis around 0 >>> freq = qr.FrequencyAxis(-2500, 1000, 5.0) ... >>> pulse2 = dict(ptype="Gaussian", FWHM=800, amplitude=1.0) >>> params = (pulse2, pulse2, pulse2) >>> lab.set_pulse_arrival_times([0.0, 0.0, 0.0]) >>> lab.set_pulse_phases([0.0, 0.0, 0.0]) >>> lab.set_pulse_shapes(freq, params)
Testing the pulse shape
>>> # getting differnt frequency axis >>> freq2 = qr.FrequencyAxis(-1003, 100, 20.0) >>> # and reading spectrum at two different sets of points >>> dfc1 = lab.get_pulse_spectrum(1, freq.data) >>> dfc2 = lab.get_pulse_spectrum(1, freq2.data) >>> pl1 = plt.plot(freq.data, dfc1) # doctest: +SKIP >>> pl2 = plt.plot(freq2.data, fdc2) # doctest: +SKIP >>> plt.show() # doctest: +SKIP
We plot in two different sets of points.
numeric pulse shape in frequency domain
>>> # We take the DFunction for creation of `numeric`ly defined >>> # pulse shape from the previous example >>> pls = lab.pulse_f[2] >>> # new lab object >>> lab2 = LabSetup()
>>> pulse1 = dict(ptype="numeric", function=pls) >>> params = (pulse1, pulse1, pulse1) >>> lab2.set_pulse_arrival_times([0.0, 0.0, 0.0]) >>> lab2.set_pulse_phases([0.0, 0.0, 0.0]) >>> lab2.set_pulse_shapes(freq, params)
Testing the pulse shape
>>> dfc = lab2.get_pulse_envelop(1, freq.data) # doctest: +SKIP >>> pl = plt.plot(freq.data, dfc) # doctest: +SKIP >>> plt.show() # we skip output here # doctest: +SKIP
Situations in which Exceptions are thrown
>>> pulse3 = dict(ptype="other", FWHM=10, amplitude=1.0) >>> params = (pulse3, pulse3, pulse3) >>> lab.set_pulse_shapes(time, params) Traceback (most recent call last): ... Exception: Unknown pulse type
>>> params = (pulse2, pulse2) >>> lab.set_pulse_shapes(time, params) Traceback (most recent call last): ... Exception: set_pulses requires 3 parameter sets
>>> params = (pulse2, pulse2) >>> lab.set_pulse_shapes(time.data, params) Traceback (most recent call last): ... Exception: Wrong axis paramater
>>> time = qr.TimeAxis(0.0, 1000, 1.0) >>> lab.set_pulse_shapes(time, params) Traceback (most recent call last): ... Exception: TimeAxis has to be of 'complete' type use atype='complete' as a parameter of TimeAxis
-
class
quantarhei.spectroscopy.labsetup.
labsetup
(nopulses=3)[source]¶ Attributes: - number_of_pulses
Methods
convert_to_frequency
()Converts pulse information from time domain to frequency domain convert_to_time
()Converts pulse information from frequency domain to time domain get_detection_polarization
()Returns detection polarizations get_labfields
()Retruns a list of EField objects for the lab’s pulses get_pulse_arrival_time
(k)Returns frequency of the pulse with index k get_pulse_arrival_times
()Returns frequency of the pulse with index k get_pulse_envelop
(k, t)Returns a numpy array with the pulse time-domain envelope get_pulse_frequency
(k)Returns frequency of the pulse with index k get_pulse_phase
(k)Returns frequency of the pulse with index k get_pulse_phases
()Returns frequency of the pulse with index k get_pulse_polarizations
()Returns polarizations of the laser pulses get_pulse_spectrum
(k, omega)Returns a numpy array with the pulse frequency-domain spectrum reset_pulse_shape
()Recalculates the pulse shapes set_pulse_arrival_times
(times)Sets the arrival time (i.e. set_pulse_frequencies
(omegas)Sets pulse frequencies set_pulse_phases
(phases)Sets the phases of the individual pulses set_pulse_polarizations
([…])Sets polarizations of the experimental pulses set_pulse_shapes
(axis, params)Sets the pulse properties get_labfield restore_rwa set_rwa