AmplitudeTime
- class nexus.AmplitudeTime(experiment, time_length=200, time_step=0.2, electronic=False, fft_window='auto', id='')
Bases:
Measurement
Constructor for the
AmplitudeTime
class. Class to calculate the time-dependent scattering amplitudes of the experiment. Only possible for a properly set Jones Vector of theBeam
.- Parameters:
id (string) – User identifier.
experiment (
Experiment
) – Experiment.time_length (float) – Length of the calculation (nanoseconds).
time_step (float) – Step size of the calculation in (nanoseconds).
electronic (bool) – If True electronic scattering is also included.
fft_window (string) –
A window function that is applied during the Fourier transformation from energy to time. Options are
auto
(default) - no window, equal tonone
.Hann
Hamming
Sine
Welch
Kaiser2
- \(\alpha = 2\)Kaiser25
- \(\alpha = 2.5\)Kaiser3
- \(\alpha = 3\)none
Added in version 1.0.4.
- id
User identifier.
- Type:
string
- experiment
Experiment.
- Type:
- time_length
Length of the calculation (nanoseconds).
- Type:
float
- time_step
Step size of the calculation (nanoseconds).
- Type:
float
- electronic
If True electronic scattering is also included.
- Type:
bool
- fft_window
A window function that is applied during the Fourier transformation from energy to time. Options are
auto
(default) - no window, equal tonone
.Hann
Hamming
Sine
Welch
Kaiser2
- \(\alpha = 2\)Kaiser25
- \(\alpha = 2.5\)Kaiser3
- \(\alpha = 3\)none
Added in version 1.0.4.
- Type:
string
- result
List of Jones vectors in units of (\(\sqrt(\Gamma / ns)\).
- Type:
list
- Calculate()
Calculates the class method. Also callable via operator
()
.- Returns:
Time array of float values. ndarray: Amplitude array of Jones vectors.
- Return type:
ndarray
- Plot(sigma=True, pi=True, polar=False, unwrap=True, name=None)
Plot the
AmplitudeTime
.. versionadded:: 1.0.3
- Parameters:
sigma (bool) – Select if \(\sigma\) component should be plot.
pi (bool) – Select if \(\pi\) component should be plot.
phase (bool) – If
True
absolute and phase are plotted instead of real and imaginary parts.unwrap (bool) – Select if phase should be unwrapped.
name (string) –
If given, the plot is saved under this name.
Added in version 1.1.0.
- Velocity()
Returns the velocity detuning of the measurement in units of mm/s.
- Returns:
Velocity detuning (mm/s).
- Return type:
ndarray