PIC-1D Configuration Reference
This document describes how to construct a configuration file for the pic-1d solver, a 1D1V
electrostatic particle-in-cell solver.
PIC-1D shares its units, density, save, drivers, and mlflow blocks with
Vlasov-1D — the same normalization, the same density-profile
parameterization, and the same driver envelopes. Only grid and terms differ, because the
solver resolves velocity space with particles rather than a mesh. This page documents the blocks
that differ and links out for the rest.
Top-Level Structure
solver: pic-1d
units: ... # see Vlasov-1D
density: ... # see Vlasov-1D
grid: ... # PIC-specific, below
terms: ... # PIC-specific, below
drivers: ... # see Vlasov-1D
save: ... # see Vlasov-1D
mlflow: ...
diagnostics: {}
grid
Spatial/time grid plus the particle-resolution knobs.
Field |
Type |
Default |
Description |
|---|---|---|---|
|
float or string |
— |
Timestep |
|
int |
— |
Number of spatial grid cells (for the field solve and deposition) |
|
float or string |
|
Start time |
|
float or string |
— |
End time |
|
float or string |
— |
Domain minimum x |
|
float or string |
— |
Domain maximum x |
|
int |
|
Particles per cell. Total particle count is |
|
|
|
B-spline used for both charge deposition and field gather |
As with Vlasov-1D, dimensional inputs may be given as strings with units (e.g. xmax: 100um) and
are converted using the units block; plain numbers are taken to be in code units already.
ppc is the main accuracy/cost dial. PIC noise in the field falls off as roughly
\(1/\sqrt{N_{\text{particles}}}\), so a linear-response measurement such as Landau damping needs a
much larger ppc than a nonlinear saturation study — the example decks use ppc: 32768 for
damping measurements.
Example:
grid:
dt: 0.1
nx: 32
tmin: 0.0
tmax: 100.0
xmin: 0.0
xmax: 20.94
ppc: 32768
particle_shape: cubic
terms
Selects the field solver, the time integrator, and the particle species.
Field |
Type |
Default |
Description |
|---|---|---|---|
|
|
|
Field solver. Spectral Poisson is currently the only option. |
|
|
|
Symplectic integrator. |
|
list |
— |
Particle species (see below) |
species
Each entry defines one particle species. This mirrors terms.species in Vlasov-1D, but carries
PIC-specific loading fields in place of the velocity-grid fields (vmax, nv).
Field |
Type |
Default |
Description |
|---|---|---|---|
|
string |
|
Species name. Used as the key for per-species save blocks and output variables. |
|
float |
|
Species charge in units of \(e\) |
|
float |
|
Species mass in units of \(m_e\) |
|
list[string] |
|
Names of blocks in |
|
|
|
Particle loading scheme. |
|
float |
|
Velocity cutoff (in thermal velocities) for the inverse-CDF / rejection sampling used to draw particle velocities |
Species not listed here are treated as a static neutralizing background.
Example:
terms:
field: poisson
time: leapfrog
species:
- name: electron
charge: -1.0
mass: 1.0
loading: quiet
vmax_load: 8.0
Complete Example
A driven electron plasma wave, using the deck in configs/pic-1d/:
solver: pic-1d
units:
normalizing_temperature: 2000eV
normalizing_density: 1.5e21/cc
density:
quasineutrality: true
species-background:
noise_seed: 420
noise_type: gaussian
noise_val: 0.0
v0: 0.0
T0: 1.0
m: 2.0
basis: uniform
baseline: 1.0
bump_or_trough: bump
center: 0.0
rise: 25.0
bump_height: 0.0
width: 100000.0
grid:
dt: 0.1
nx: 32
tmin: 0.0
tmax: 100.0
xmin: 0.0
xmax: 20.94
ppc: 32768
particle_shape: cubic
terms:
field: poisson
time: leapfrog
species:
- name: electron
charge: -1.0
mass: 1.0
loading: quiet
vmax_load: 8.0
drivers:
ex:
'0':
params:
a0: 1.e-3
k0: 0.3
w0: 1.1598
dw0: 0.
envelope:
time: {center: 40.0, rise: 5.0, width: 30.0}
space: {center: 0.0, rise: 10.0, width: 4000000.0}
ey: {}
save:
fields:
t: {tmin: 0.0, tmax: 100.0, nt: 601}
electron:
main:
t: {tmin: 0.0, tmax: 100.0, nt: 11}
mlflow:
experiment: basic-epw-pic
run: leapfrog-cubic
diagnostics: {}
See the Overview for the equations and a discussion of the solver options.