SAMappingBinLocal

order local indices from the rank's support into n consecutive groups or "bins" (some possibly empty) according to which of the n image indices they are mapped to on this rank. The groups are concatenated and returned as a single array. See SAMappingBinSplitLocal() if separate bin output is desired. Since SAMapping is potentially multivalued, the same index can appear in multiple bins. The binning is done on the indices of the selected type(I or J); the other indices and weights, if any, are moved to the appropriate bin together with the selected indices.

Synopsis

#include "petscsa.h"  
PetscErrorCode SAMappingBinLocal(SAMapping map, SA array, SAIndex index, SA bins)

Not collective

Input Parameters

map - mapping of indices
array - SA with indices to bin
index - selection of the index to bin on (SA_I or SA_J; PETSC_NULL is equivalent to SA_I)

Output Parameters

bins -SA containing concatenated binned indices; the number of bins is the same as the result of ISGetImageSizeLocal().

See Also

SAMappingGetSupport(), SAMappingGetImage(), SAMappingGetSupportSizeLocal(), SAMappingGetImageSizeLocal(),
SAMappingBin(), SAMappingMapLocal(), SAMappingMapLocal(), SAMappingBinSplitLocal()

Level:advanced
Location:
src/dm/sa/interface/sa.c
Index of all DM routines
Table of Contents for all manual pages
Index of all manual pages