at.physics.revolution#

Functions

get_mcf(ring[, dp, keep_lattice])

Compute the momentum compaction factor \(\alpha\)

get_slip_factor(ring, **kwargs)

Compute the slip factor \(\eta\)

get_revolution_frequency(ring[, dp, dct, df])

Compute the revolution frequency of the full ring [Hz]

set_rf_frequency(ring[, frequency, dp, dct, df])

Set the RF frequency

get_mcf(ring, dp=0.0, keep_lattice=False, **kwargs)[source]#

Compute the momentum compaction factor \(\alpha\)

Parameters:
  • ring (Lattice) – Lattice description (ring.is_6d must be False)

  • dp (Optional[float]) – Momentum deviation. Defaults to None

  • keep_lattice (bool) – Assume no lattice change since the previous tracking. Default: False

Keyword Arguments:

DPStep (Optional[float]) – Momentum step size. Default: DConstant.DPStep

Returns:

mcf (float) – Momentum compaction factor \(\alpha\)

get_revolution_frequency(ring, dp=None, dct=None, df=None)[source]#

Compute the revolution frequency of the full ring [Hz]

Parameters:
Returns:

frev – Revolution frequency [Hz]

get_slip_factor(ring, **kwargs)[source]#

Compute the slip factor \(\eta\)

Parameters:

ring (Lattice) – Lattice description (ring.is_6d must be False)

Keyword Arguments:
Returns:

eta (float) – Slip factor \(\eta\)

set_rf_frequency(ring, frequency=None, dp=None, dct=None, df=None, **kwargs)[source]#

Set the RF frequency

Parameters:
Keyword Arguments:
  • cavpts (Optional[Refpts]) – If None, look for ring.cavpts, or otherwise take all cavities.

  • array (Optional[bool]) –

    If False (default), frequency is applied to the selected cavities with the lowest frequency. The frequency of all the other selected cavities is scaled by the same ratio.

    If True, directly apply frequency to the selected cavities. The value must be broadcastable to the number of cavities.

  • copy (Optional[bool]) – If True, returns a shallow copy of ring with new cavity elements. Otherwise (default), modify ring in-place