Beam model

The beam is modeled by macro-particles. Each beam macro-particle is characterized by its longitudinal position \(\xi_b\), transverse position \(r_b\) or (\(x, y\)), three components of momentum \(\vec{p}_b\), charge \(q_b\), and mass \(m_b\). Equations of motion for the macro-particles are

\begin{gather} \frac{d r_b}{d t} = v_{br}, \qquad \frac{d \xi_b}{d t} = v_{bz} - 1, \\ \frac{d \vec{p}_b}{d t} = q_b \vec{E} + q_b \left[ \vec v_b \times \vec B \right], \qquad \vec{v}_b = \frac{\vec{p}_b}{\sqrt{m_b^2 + p_b^2}}. \end{gather}

These equations are solved with the modified Euler’s method (midpoint method). The fields acting on the macro-particle are linearly interpolated to the predicted macro-particle location at the half time step. If a particle has a small longitudinal momentum and thus a high frequency of betatron oscillations, then the time step for this particle is automatically reduced.

With no external magnetic field (\(B_0=0\)), the angular momentum of beam particles must conserve, so the azimuthal component of the momentum \(p_{b\varphi}\) is not changed, and reconstructed from the condition \(r_b p_{b\varphi} = const\).