|Version 1 (modified by xbai, 6 years ago) (diff)|
Wiki/Documentation/User Guide to Particles?/Grid Based Output
Grid-binned particle output is essentially the same as that for gas quantities. One example is given as below
<output1> out_fmt = ppm /* ppm image */ out = M1par /* particle x1-momentum */ id = M1par x2 = 1.0 dt = 1.0 /* time increment between outputs */
Here the variable M1par denotes the particle x1-momentum. All built-in quantities for output include dpar, M1par, M2par, M3par, V1par, V2par, V3par, which are grid-binned particle density, momentum and velocity respectively. The item pargrid is automatically set to 1 for these built-in outputs. By default, particle property selection function is set to "all", but the user is free to set their own property selection functions.
The built-in variables can be retrieved in the grid pG->Coup[k][j][i], where pG is the pointer to the grid, and Coup if of type GPCouple (see athena.h). It is mainly used for storing intermediate step gas quantities, but is also used in storing grid-binned particle quantities for output. Here its elements include grid_d (particle density), grid_v1, grid_v2, grid_v3 (particle momentum). The user can define their own particle-related output variables based on these grid-binned quantities in the same way for gas variables (see link), but in such cases pargrid must be set to 1 explicitly.
For binary/vtk/tab data dumps, they contain binned particle variables dpar, M1par, M2par and M3par with property selection function "all", which can not be changed.