Graph Information Functions



next up previous contents
Next: Low-level Graph Functions Up: Graph Topology Functions Previous: Graph Inquiry Functions

Graph Information Functions

The functions in this section provide information about the structure of the graph topology. All calls are local.

MPI_Graph_neighbors_count(MPI_Comm comm, int rank, int *nneighbors)

MPI_GRAPH_NEIGHBORS_COUNT(COMM, RANK, NNEIGHBORS, IERROR)INTEGER COMM, RANK, NNEIGHBORS, IERROR

MPI_GRAPH_NEIGHBORS_COUNT returns the number of neighbors for the process signified by rank. It can be used by MPI_GRAPH_NEIGHBORS to give an array of correct size for neighbors. Using Example gif with rank = 3 would give nneighbors = 2.

MPI_Graph_neighbors(MPI_Comm comm, int rank, int maxneighbors, int *neighbors)

MPI_GRAPH_NEIGHBORS(COMM, RANK, MAXNEIGHBORS, NEIGHBORS, IERROR)INTEGER COMM, RANK, MAXNEIGHBORS, NEIGHBORS(*), IERROR

MPI_GRAPH_NEIGHBORS returns the part of the edges array associated with process rank. Using Example gif, rank = 3 would return neighbors = 0, 2. Another use is given in Example gif.



Jack Dongarra
Fri Sep 1 06:16:55 EDT 1995