MPI_GRAPH_NEIGHBORS_COUNT, MPI_Graph_neighbors_count Purpose Returns the number of neighbors of the given task. C synopsis #include MPI_Graph_neighbors_count(MPI_Comm comm,int rank, int *neighbors); C++ synopsis #include mpi.h int MPI::Graphcomm::Get_neighbors_count(int rank) const; FORTRAN synopsis include 'mpif.h' or use mpi MPI_GRAPH_NEIGHBORS_COUNT(INTEGER COMM,INTEGER RANK, INTEGER NEIGHBORS(*),INTEGER IERROR) Parameters comm is a communicator with graph topology (handle) (IN) rank is the rank of a task within comm (integer) (IN) neighbors is the number of neighbors of the specified task (integer) (OUT) IERROR is the FORTRAN return code. It is always the last argument. Description This subroutine returns the number of neighbors of the given task. Errors Invalid rank rank < 0 or rank > = groupsize MPI not initialized MPI already finalized Invalid communicator No graph topology associated with communicator Invalid topology type Related information MPI_GRAPH_CREATE