On 1/19/19 1:09 PM, Daniel wrote:
> 
> After compiling I get the following behavior:
> 
> bash-3.2$ mpirun -np 4 ./step-18
> 
> fem group size: 3 comm:3
> 
> fem group size: 3 comm:3
> 
> fem group size: 3 comm:3
> 
> fem group size: 3 comm:32766

The problem here is that only 3 of the processes participate in the 
communicator. But you ask the question of the group size on all processes:
   MPI_Comm_size( FEM_Comm ,&size_fem_comm);
Here, FEM_Comm is a communicator object that is really only initialized on the 
three participating processes, whereas it is uninitialized on the fourth and 
consequently you are getting pointless answers there.

You have the same problem again at the end of the same block, where every 
process creates a TopLevel object using FEM_Comm, but really only on three of 
the processes is this object valid.

After creating the subset communicator, you need to have an if statement of 
the form
   if (this process is participating in the subset communicator)
     {
        do everything else
     }

Best
  W.

-- 
------------------------------------------------------------------------
Wolfgang Bangerth          email:                 [email protected]
                            www: http://www.math.colostate.edu/~bangerth/

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to