The M3D-C1 code is designed to perform 3D nonlinear magnetohydrodynamics (MHD) calculations of a tokamak plasma that span the timescales associated with ideal and resistive stability as well as parallel and perpendicular transport. This requires a scalable fully implicit time advance where the time step is not limited by a Courant condition based on the MHD wave velocities or plasma flow but is chosen instead to accurately and efficiently resolve the physics. In order to accomplish this, we make use of several techniques to improve the effective condition number of the implicit matrix equation that is solved each time-step. The split time advance known as the differential approximation reduces the size of the matrix and improves its diagonal structure. A particular choice of velocity variables and annihilation operators approximately split the large matrix into 3 sub-matrices, each with a much improved condition number. A final block-Jacobi preconditioner further dramatically improves the condition number of the final matrix, allowing it to converge in a Krylov solver (GMRES) with a small number of iterations. As an illustration, we have performed transport timescale simulations of a tokamak plasma that periodically undergoes sawtooth oscillations. We specify the transport coefficients and apply a “current controller” that adjusts the boundary loop-voltage to keep the total plasma current fixed. The short-time plasma response depends on the initial conditions, but the long-time behavior depends only on the transport coefficients and the boundary conditions applied.
Back to Workshop II: Computational Challenges in Magnetized Plasma