A minimal pNbody object consists of a set of 4 numarray vectors :
- pos: positions of particles (
float32 Numeric array)
- vel: velocities of particles (
float32 Numeric array)
- mass: mass of particles (
Float Numeric array)(default=None)
- num: identifier of particles (
Int Numeric array)(default=None)
and a set of default associated variables :
- npart: number of particles of each type (List), for the current node.
- nbody: number of particles for the current node (sum of npart)
- npart_tot: number of particles of each type (List), summing over all nodes.
- nbody_tot: total number of particles (sum of npart_tot)
- mass_tot: total mass of the system
The variable npart gives the list of particles of each type. For example
>>> nb.npart
array([10, 20, 0, 10])
means that there are 4 particle types,
10 particles belongs to the first type,
20 to the second,
0 to the third
and 10 to the fourth.
The value of the following variables are automatically set during intitialisation (using
the values of npart,nbody and nb.mass),
even if they are defined before (during the reading process) :
- nbody :
- npart_tot : get_npart_tot()
- nbody_tot : get_nbody_tot()
- mass_tot : get_mass_tot()
The user is free, when reading a specific file format, to add specific variables (for example, the time of
the snapshot) and specific numarray vectors (density, specific energy, etc.).
See the formats section for more details.
Release 4.0, documentation updated on February 2008.
See About this document... for information on suggesting changes.