Additional Attributes for Particle Simulations

In some types of particle simulations, a user may want to add one or two additional Grid block attributes, both of which affect the number of guard cells.

maxIntDepHalfWidth

In particle simulations in which you use higher-order particle depositors or interpolators, you should invoke the maxIntDepHalfWidth parameter with a value no less than (int)(particleOrder/2)+1. This is because higher order particle depositors will spread a particle’s charge over more than just the nearest neighbor grid nodes.

maxCellXings/maxcellxings

It is not recommended to allow particles to move more than a cell in a single time step. By skipping over more than a single cell, particles will not be accelerated in a completely self-consistent way (since they will experience slightly non-local fields), which will introduce inaccuracies in the simulation.

However, if there are a few fast-moving particles at the top end of a speed distribution which are unimportant to the overall physics of the simulation, it would be inconvenient to have to set a time step short enough to keep these fast particles from crossing more than a cell per time step.

The maxCellXings attribute in the grid block combined with the maxcellxings (note the difference in case) attribute in the species block can be used in such a situation. Both of these attributes should be set to the same value. These two attributes must be set appropriately if particles are able to travel more than a cell in a time step.

The maxCellXings attribute in the grid block will (along with the maxIntDepHalfWidth attribute, see Guard Cell Calculation and Setting Overlap in Fields below) sets the number of “guard cells” around the simulation domain which absorb particles leaving the simulation. By default, there is one guard cell surrounding the simulation domain. If particles can travel more than a cell per time step, they can skip over this absorber and cause a segmentation fault when they ask for the field values from outside the simulation domain. For example, a setting of maxCellXings = 3 will set a layer of three guard cells around the simulation grid.

The maxcellxings attribute in the species block will impose a speed limit on each component of the velocity, independently. So, if maxcellxings = 3 in a simulation, then the speed limit for the x-component of velocity will be \(3*DX/DT\), the speed limit for the y-component will be \(3*DY/DT\), and the speed limit in z will be \(3*DZ/DT\). Any particles with a velocity component larger than the limits will have the speed reduced to the speed limit for each velocity component in violation of it’s respective speed limit. This will likely result in the modification of both the magnitude and direction of the velocity of particles in an unphysical way. For simulations in which a significant number of particles have their speeds limited, you should lower the time step for the simulation.

To see the effect of the speed limit, set the verbosity level to “NOTICE.” This will print out the numbers of particles with limited speeds in the run log. Additionally, the phase space plot can be checked. If there are a significant number of particles piled up along a vertical or horizontal line in the plot, reduce the time step.

Guard Cell Calculation and Setting Overlap in Fields

The number of guard cells is determined based on the preceding parameters. Each field in the multiField block should include a two-component vector attribute, overlap, which is set according to the following.

For a non-dep field:

  • overlap[0]=maxIntDepHalfWidth + (maxCellXings - 1)
  • overlap[1]=maxIntDepHalfWidth + (maxCellXings - 1)

This defaults to overlap = [1 1]

For a dep field:

  • overlap[0]=maxIntDepHalfWidth + (maxCellXings - 1)
  • overlap[1]=maxIntDepHalfWidth + (maxCellXings - 1) + 1

This defaults to overlap = [1 2]

Please see Field for more details on manually overriding the number of guard cells for an individual field.

See also