Make sure that updateWellControls is called on each process.

The new WellSwitchingLogger within updateWellControls uses
collective communication with all processes. Therefore all
of them need to enter the function as other flow_mpi will deadlock.
Therefore this commit calls the method even with non local wells
active.
This commit is contained in:
Markus Blatt
2016-10-05 23:53:43 +02:00
parent 2a1388d124
commit 3e6b1949ea

View File

@@ -1077,8 +1077,11 @@ namespace detail {
const Eigen::VectorXd& dx = solver.solve(total_residual_v.matrix());
assert(dx.size() == total_residual_v.size());
asImpl().wellModel().updateWellState(dx.array(), dpMaxRel(), well_state);
asImpl().wellModel().updateWellControls(well_state);
}
// We have to update the well controls regardless whether there are local
// wells active or not as parallel logging will take place that needs to
// communicate with all processes.
asImpl().wellModel().updateWellControls(well_state);
} while (it < 15);
if (converged) {