Photon-Plasma: a modern high-order particle-in-cell code
We present the Photon-Plasma code, a modern high order charge conserving particle-in-cell code for simulating relativistic plasmas. The code is using a high order implicit field solver and a novel high order charge conserving interpolation scheme for particle-to-cell interpolation and charge deposition. It includes powerful diagnostics tools with on-the-fly particle tracking, synthetic spectra integration, 2D volume slicing, and a new method to correctly account for radiative cooling in the simulations. A robust technique for imposing (time-dependent) particle and field fluxes on the boundaries is also presented. Using a hybrid OpenMP and MPI approach the code scales efficiently from 8 to more than 250.000 cores with almost linear weak scaling on a range of architectures. The code is tested with the classical benchmarks particle heating, cold beam instability, and two-stream instability. We also present particle-in-cell simulations of the Kelvin-Helmholtz instability, and new results on radiative collisionless shocks.
💡 Research Summary
The paper introduces Photon‑Plasma, a modern high‑order particle‑in‑cell (PIC) code designed for relativistic plasma simulations. The authors combine several advanced numerical techniques to achieve high accuracy, physical fidelity, and excellent scalability. First, the electromagnetic field solver is implicit and high‑order, allowing time steps far larger than the Courant‑Friedrichs‑Lewy limit of explicit solvers while preserving stability in strongly nonlinear regimes. This enables long‑duration simulations of dense or high‑voltage plasmas without prohibitive computational cost. Second, the code implements a novel charge‑conserving interpolation and deposition scheme based on high‑order B‑splines. Both particle‑to‑grid interpolation and charge deposition are performed at fourth‑order or higher, dramatically reducing spurious charge errors and numerical electric‑field divergence. The scheme guarantees exact charge conservation at the discrete level, which is essential for correctly capturing fine current structures and wave‑particle interactions. Third, a new method for radiative cooling is integrated directly into the particle update. The radiative power of each particle is computed each sub‑step, subtracted from its kinetic energy, and the lost energy is deposited back into the electromagnetic field to maintain total energy balance. This on‑the‑fly treatment of radiation reaction allows realistic modeling of astrophysical scenarios where synchrotron or inverse‑Compton cooling is significant. The authors also present a robust technique for imposing time‑dependent particle and field fluxes at domain boundaries, enabling realistic injection of beams, currents, or external drives without resorting to artificial reflective or absorbing layers.
From a computational standpoint, Photon‑Plasma adopts a hybrid OpenMP‑MPI parallelization. Within a node, shared‑memory threading exploits multi‑core CPUs, while inter‑node communication is handled by MPI. Benchmarks on a variety of supercomputing architectures (Intel, AMD, ARM) demonstrate near‑linear weak scaling from 8 cores up to more than 250 000 cores, with efficient memory usage and minimal communication overhead.
The code is validated against classic PIC benchmarks: particle heating, cold‑beam instability, and two‑stream instability. In each case, growth rates, energy exchange, and field structures match analytical predictions, confirming both the high‑order accuracy and the charge‑conserving properties. Beyond benchmarks, the authors apply the code to two physically demanding problems. In a Kelvin‑Helmholtz instability simulation, the high‑order interpolation resolves the development of fine‑scale vortices and associated electromagnetic fluctuations, demonstrating the code’s capability to capture complex shear‑driven turbulence. In simulations of radiative, collisionless shocks, the integrated cooling model shows how radiative losses modify shock speed, downstream temperature, and particle spectra, providing new insight into astrophysical shock environments where radiation cannot be neglected.
Overall, Photon‑Plasma represents a significant step forward in PIC methodology. By uniting implicit high‑order field solving, charge‑conserving high‑order particle operations, realistic radiative cooling, flexible boundary driving, and massive parallel scalability, the code offers a versatile platform for a wide range of plasma physics research, from laboratory laser‑plasma interactions to high‑energy astrophysical phenomena. The presented results suggest that the code is ready for production‑level studies and can serve as a foundation for future extensions that incorporate additional physics such as quantum electrodynamics effects or multi‑fluid coupling.