Skip to main content
`Ctrl`+`K`

# PetscPartitionerMultistageSetStages

Sets stages for the partitioning

## Synopsis

    #include "petscpartitioner.h"
    PetscErrorCode PetscPartitionerMultistageSetStages(PetscPartitioner part, PetscInt levels, MPI_Group lgroup[])

Collective

## Input Parameters

- part - the `PetscPartitioner` object.

- levels - the number of stages.

- lgroup - array of `MPI_Group`s for each stage.

## Notes

`MPI_Comm_create(comm, lgroup[l], &lcomm)` is used to compute the communicator for the stage partitioner at level `l`. The groups must be specified in the process numbering of the partitioner communicator. `lgroup[0]` must be collectively specified and it must represent a proper subset of the communicator associated with the original partitioner. For each level, ranks can be listed in one group only (but they can be listed on different levels)

## See Also

`PetscPartitionerSetType()`, `PetscPartitionerDestroy()`, `PETSCPARTITIONERMULTISTAGE`

## Level

advanced

## Location

src/dm/partitioner/impls/multistage/mspart.c

Index of all MatGraphOperations routines
Table of Contents for all manual pages
Index of all manual pages