synchronous_phases module
Define various functions to compute the synchronous phase.
- phi_s_legacy(integrated_field, *args, **kwargs)[source]
Compute the cavity parameters with phi_s historical definition.
- Parameters:
integrated_field (
complex|None) – Complex electric field felt by the synchronous particle. It is None if the cavity is failed.- Return type:
- Returns:
v_cav_mv – Accelerating voltage in \(\mathrm{MV}\). It is
np.nanifintegrated_fieldis None.phi_s – Synchronous phase of the cavity in \(\mathrm{rad}\). It is
np.nanifintegrated_fieldis None.
- phi_s_lagniel(simulation_output, *args, **kwargs)[source]
Compute cavity parameters with new phi_s model [Lag21].
- phi_s_from_tracewin_file(simulation_output, *args, **kwargs)[source]
Get the synchronous phase from a TraceWin output file.
It is up to you to edit the
tracewin.inifile in order to have the synchronous phase that you want.
- PHI_S_FUNC_T
A function that takes in the output of a transfer matrix function wrapper, and returns the accelerating field and the synchronous phase.