Within the EM algorithm, this routine switches the behavior of the EM code between the electrostatic algorithm and the electromagnetic algorithm. At the fundamental level, this involves adjusting the time step size and the number of electron subcycling steps, and setting an indicator flag in the sml class to indicate to other parts of the code whether to use the ES or EM method. If the indicator is set to ES, the Ampere solver and pullback transform are skipped, the Poisson equation is set up with the adiabatic response term on the RHS, and the electron background distribution function will contain the adiabatic response (used in the weight update).
- Parameters
-
[in,out] | sml | Class with simulation parameters |
[in] | perturbed_B_field | Class with parameters for RMP field |