cellSpecies

cellSpecies (deprecated in 8.0)

Along with interpolation, acceleration, and deposition implementations, cellSpecies provides another particle data structure that improves performance of particle-dominated plasma simulations. Simulations that feature regions with high particles-per-cell counts will benefit from using cellSpecies.

By maximizing data reuse on a per-cell basis, cellSpecies simulation performance improves on that of simulations using analogous Basic Dynamic Species with the standard particle data infrastructure. When used under the conditions listed below, cellSpecies implementation-specific kinds accelerate simulations. For example, the performance benefit of using the cellSpecies kind = cell instead of the Basic Dynamic Species kind = relBoris can be significant.

For electrostatic simulations, Tech-X recommends setting the value of .maxcellxing to 1. Defining maxcellxing = 1 ensures that particle velocities will always be less than the velocity required to cross more than one cell boundary at a time. Use of cellSpecies in electrostatic simulations without maxcellxing is allowed, but may cause undesirable results – the program may encounter an error if a particle gains sufficient velocity such that it moves more than one cell in any direction in a single time step.

When to Use cellSpecies Kinds

The use of cellSpecies kinds to achieve improved performance depends on the types of other features also used in the simulation. cellSpecies supports:

  • All particle sinks described in ParticleSink
  • All Monte Carlo interactions described in MonteCarloInteractions
  • Moving window simulations (available via the top-level simulation parameter downShiftDir)

cellSpecies does not support:

  • comboEmFields
  • Segmented moves

Note

Because cellSpecies does not have a sorting function, it is a good idea to disable particle sorting (for example, by using the –ns flag on the command line). Otherwise, use of the ptclSort flag will cause MPI-related program crashes on some systems.

Using the cell kind, parameters specific to cellSpecies

A new input file syntax can be used with cellSpecies where the kind of the species block is always cell. Different options for the species are determined by additional parameters:

kind (string)

This parameter is set to cell (as opposed to sortSpecies).

pusher (string)

Determines the kind of pusher to use to advance the particle positions and velocities.

relBoris

Relativistic Boris push.

nonRelBoris

Non-relativistic Boris push.

nonRelEs

Non-relativistic electrostatic push.

freeRel

Free streaming particles with relativistic velocities.

ballisticX

Push particles in the x direction only, with no acceleration.

pulseLaunch

Use this pusher to launch a laser pulse from a moving plane. The particles must be set up on a plane perpendicular to the direction of propagation of the laser pulse. The shape of the laser pulse is set by a functional field which is referred to in the fields parameter. Two additional parameters must be used with this pusher:

vmax

Maximum velocity reached by the particle, typically a small fraction of the speed of light

Emax

Maximum amplitude of the electric field applied to the species
stencil (string)

Interpolation method to use in charge density and current deposition.

spline1stOrder

Use linear interpolation.

spline2ndOrder

Use piecewise parabolic interpolation.
variableWeightParticle (integer)

Whether to use variable weight particles (as opposed to constant weight).

taggedParticle (integer)

Whether to use tagged particles.

ptclSubGroupCapacity

Represents the size (in number of particles) of the fundamental particle data structure per cell. The default value is 64. Although this parameter is strongly simulation-dependent, the basic rule for determining the value for this parameter is to set ptclSubGroupCapacity equal to 150% of the typical value of particles-per-cell. This flag can have a large impact on the performance of the cellSpecies algorithms; unless the simulation domain is exceedingly large, using too large a value for ptclSubGroupCapacity is preferable to using too small a value. The default value 64 is well-suited to plasmas with an average number of macroparticles per cell on the order of 40.

Example cellSpecies Block

<Species electrons>

  kind = cell
  pusher = nonRelES
  stencil = spline1stOrder
  charge = -1.6022e-1
  mass = 9.109e-31
  emField = myEmField
  ptclSubGroupCapacity = 64

  maxcellxing=1

  nominalDensity = 3e+22
  nomPtclsPerCell = 40.

  ...

</Species>

See also