How to choose the grid size for a PIC simulation
Updated · Scientifically reviewed by Dinkar Mishra, PhD on
Short answer
Resolve the smallest physical length that matters. In explicit electrostatic PIC, keep Δx ≲ λD (the Debye length) to avoid numerical heating; in electromagnetic plasma problems resolve the skin depth c/ωp with about 10 cells or more; in laser–plasma runs use roughly 20–30 cells per laser wavelength (more for harmonics or dense targets). The time step then follows from the CFL condition. Confirm with a convergence test.
Who this is for
Researchers setting up electrostatic or electromagnetic PIC simulations who need a defensible cell size and time step.
How it works
The grid must resolve every length scale that affects the physics you report. Compute the candidate scales first. The Debye length calculator and plasma skin depth calculator give them in one step:
Then apply the rule that matches your problem.
| Problem type | Constraint on Δx | Reason |
|---|---|---|
| Explicit electrostatic PIC (thermal plasma, sheaths, discharges) | (often ) | Avoid finite-grid instability and numerical heating |
| Electromagnetic plasma (no laser) | and comparable to where thermal effects matter | Resolve current sheets, Weibel and whistler physics |
| Laser–plasma, Yee solver | – along the laser, and | Control numerical dispersion; resolve plasma response |
| Dense targets (solid density) | Set by , often far smaller than | The skin depth of over-dense plasma is tens of nanometres |
| Spectral (PSATD) solvers | Can be coarser for the same dispersion error | Dispersion-free vacuum propagation |
The smallest required value wins. If it makes the run unaffordable, use reduced dimensionality (2D, quasi-cylindrical), a moving window, mesh refinement, or energy-conserving or implicit schemes that relax the Debye constraint.
The time step follows
For the explicit Yee scheme, the Courant–Friedrichs–Lewy condition is
and all codes also need to resolve plasma oscillations. Electrostatic codes additionally require that thermal particles move less than a cell per step. The CFL time step calculator computes both.
Worked example
A laser wakefield run at and :
- nm;
- , so nm;
- longitudinal nm is set by the laser. A transverse of about 100–200 nm may resolve the bubble and the laser spot, which you would check by convergence.
The PIC Simulation Planner performs this reasoning automatically and estimates cells, memory and core-hours.
Testing your choice
Run the same case at , and (time step refined with it), and compare the quantities you report. If they converge, your grid is adequate for those quantities. The procedure is in PIC convergence testing. Warning signs of under-resolution: steady temperature growth in a plasma that should be stationary, unphysical high-frequency noise, and numerical Cherenkov radiation from relativistic beams.
Assumptions and limitations
- The constraints are rules of thumb for standard explicit, second-order PIC. Higher-order shapes, filtering, energy-conserving and implicit methods change them.
- “Cells per wavelength” for Yee solvers depends on the propagation distance you need with acceptable phase error.
- The worked example illustrates the calculation, not a validated setup for a specific experiment.
Frequently asked questions
Why must the cell resolve the Debye length?+
In standard momentum-conserving explicit PIC, cells much larger than λD cause aliasing that feeds energy into the particles (finite-grid instability). The plasma heats until λD grows to about the cell size. Energy-conserving and implicit schemes relax this constraint.
How many cells per laser wavelength do I need?+
20–30 cells per wavelength along the laser direction is a common baseline for Yee solvers to control numerical dispersion. Long propagation distances, harmonic generation and dense plasmas often need more. Spectral solvers can use coarser grids for the same dispersion error.
Can the transverse cell size be larger than the longitudinal one?+
Often yes in laser wakefield simulations, where transverse structures (laser spot, bubble radius) are larger than the laser wavelength. But the CFL time step depends on all cell sizes, and the transverse resolution must still resolve the structures and the skin depth.
Does a smaller grid always give a better answer?+
It reduces discretisation error, but cost rises steeply (in 3D, halving Δx and Δt costs about 16× more) and particle noise per cell rises unless you keep particles per cell fixed. Refine until your reported quantities converge, then stop.
References
- Birdsall & Langdon, Plasma Physics via Computer Simulation (CRC Press) · Standard textbook
- Yee, Numerical solution of initial boundary value problems involving Maxwell's equations, IEEE Trans. Antennas Propag. 14, 302 (1966) · Peer-reviewed article
- Arber et al., Contemporary particle-in-cell approach to laser-plasma modelling, PPCF 57, 113001 (2015) · Peer-reviewed article
- NRL Plasma Formulary · U.S. Naval Research Laboratory
Need help applying this?
Our physicists turn concepts into working, verified simulations for research groups and companies.
Services listed on this page are available today. Products marked “early access” or “in development” on our platform page are not yet generally available.
Spotted an error or an outdated command? Tell us. We correct verified issues promptly.