@Daniel:

- n_vertices() only gives you the number of vertices for one process, not 
> the global one. In particular, you can't rely on the fact that this is the 
> same for all processes. Furthermore, you (probably) don't initialize all 
> the values of your struct. This might be the reason for the large numbers 
> you are observing.
>

Exactly. I fixed the large numbers by setting all entries initially 0. I 
also had that in mind, but assumed that we already initialize everything 
the moment we assign its size.

Here the solution for whom it may be interesting. 

int disp_size = triangulation.n_vertices();

struct
{
double value* = 0*;
int rank *= 0*;
} in[disp_size], out[disp_size];

Surprisingly, n_vertices() gives me exactly the number of the total 
vertices. I checked it. Is it not always like this? And what would be the 
command to obtain the global one?

@ Jean-Paul: Ah, ok. I assumed there are special MPI_Send functions 
implemented in deal.II which I could use such as Utilities::MPI::max() for 
instance.

BR,
Seyed Ali

-- 
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 dealii+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to