The Grad-Shafranov (GS) equation describes the force balance in a toroidally axisymmetric magnetic confinement device, such as a tokamak. It admits a rich variety of equilibrium solutions that are routinely used in stability analysis, device design and validation, and plasma optimisation. For the accurate study of global MHD instabilities, it is critical to begin with a precise equilibrium solution—preferably computed on the same mesh that will be used in the subsequent simulations.

The challenge
Solving the GS equation in realistic tokamak geometries is non-trivial due to its inherent nonlinearity—the source terms depend on the solution itself. This necessitates a complex iterative approach involving:
- Determination of external coil currents.
- Localisation of the plasma region.
- Enforcement of plasma confinement.
- Robust handling of non-uniqueness, since multiple equilibria may exist for a given coil configuration.
To ensure convergence to a unique, physically meaningful solution, additional constraints and stabilisation strategies must be imposed.
The research
We have developed a robust, accurate, and efficient free-boundary GS solver in a Cartesian frame with adaptive mesh refinement (AMR) capabilities.
- The solver is built on the AMReX framework and employs a geometric multigrid strategy for solving the linearised systems.
- A level-set method implicitly defines the reactor vessel geometry, enabling enforcement of plasma confinement during the solution process.
- Toroidal rotation is incorporated to capture spatial variation in velocity.
- An efficient fast marching algorithm is used to compute the plasma mask required by the solver.
- Vertical stabilisation techniques are applied to ensure robust solution of the forward Grad-Shafranov problem.
Publications
Farmakalides A, Nikiforakis N, Millmore S, Romanelli M, Buxton PF. CRATOS-GS: A free-boundary, hierarchical adaptive mesh refinement Grad–Shafranov solver. AIP Advances. 2025 Sep 1;15(9).
https://doi.org/10.1063/5.0285053
Work in progress

Figure 1: Illustration of AMR grids for a three level mesh with an ST40 limited plasma equilibrium solution. The red contour depicts the reactor vessel, the green contour depicts the plasma boundary, while the black contour lines represent the magnetic flux from the plasma core to the LCFS.

Figure 2: Numerical solution for Ψ for the MAST (left) and ITER (right) diverted equilibrium test cases. The red contour in each plot represents the limiter geometry, while the light-blue contour represents the plasma boundary and LCFS. White squares correspond to the coil locations, while blue and red points correspond to the magnetic axis and X-points, respectively.

Figure 3: Numerical solution for the ST40 limited equilibrium test case. Results are displayed for Ψ with an overlaid black contour of the LCFS, a light-blue contour of the plasma boundary , and a red contour of the reactor vessel. Also shown is the refined mesh for levels 1 and 2. On the right, a magnified close-up of the X-point and vessel is depicted.

Figure 4: Numerical results for the ST40 equilibrium with different central Mach number M0 values. The contour field for the pressure is shown, along with contour lines for Ψ within the LCFS (clipped to the limiter geometry), a green contour of the plasma boundary, and a yellow contour of the reactor vessel.