Skip to content
Snippets Groups Projects
Commit eada967c authored by Jade Mackay's avatar Jade Mackay
Browse files

Fixed problem in which grid refinement on partition domains (parallel) kept

hanging  because refinement criterion satisfied on one partition but not
another.
Fixed by including appropriate MPI collect in setEstMax() and setEstSum()
methods. So satisfaction of criterion is global not local.
parent 63e8fc19
No related branches found
No related tags found
No related merge requests found
......@@ -389,12 +389,24 @@ namespace AMDiS {
/// Sets \ref est_sum.
inline void setEstSum(double e, int index)
{
#ifdef HAVE_PARALLEL_DOMAIN_AMDIS
double send_est_sum = e;
double est_sum = 0.0;
MPI::COMM_WORLD.Allreduce(&send_est_sum, &est_sum, 1, MPI_DOUBLE, MPI_SUM);
e = est_sum;
#endif
scalContents[index]->est_sum = e;
}
/// Sets \ref est_max.
inline void setEstMax(double e, int index)
{
#ifdef HAVE_PARALLEL_DOMAIN_AMDIS
double send_est_max = e;
double est_max = 0.0;
MPI::COMM_WORLD.Allreduce(&send_est_max, &est_max, 1, MPI_DOUBLE, MPI_MAX);
e = est_max;
#endif
scalContents[index]->est_max = e;
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment