mpi_grp_constructor Function

private function mpi_grp_constructor(comm) result(mpi_grp)

Contructor for mpi_grp_t class.

This sets the communicator of the group and gets the size of the group and rank of current process. If no communicator is provided, it will use the default defined when calling mpi_mod_init.

Note that when the undefined communicator is used, the group size is 1 and the rank to 0, such that the code can work in serial mode.

Arguments

Type IntentOptional Attributes Name
integer, intent(in), optional :: comm

MPI communicator

Return Value type(mpi_grp_t)