7.9 Selection of particles

selectc( c)
Return an Nbody object that contains only particles where the corresponding value in c is not zero. c is a $n\times 1$ Numeric array.

selectp( [lst],[file])
Return an Nbody object that contains only particles with indexes.

The list of indexes is given either by lst ($n\times 1$ Int Numeric array) or by the name (file) of a file containing the list of id's.

sub( [n1],[n2])
Return an Nbody object that have particles with indexes in the range [n1,n2].

reduc( n)
Return an Nbody object that contains a fraction 1/n of particles. Only particles that have an index equal to a multiple of n are conserved.

select( type)
Return an Nbody object that contain only particles of type type. This function depends on the object format.

getindex( num)
Return an array of index of a particle from its specific number id. The array is empty if no particle corresponds to the specific number id. num : Id of the particle

See About this document... for information on suggesting changes.