Adds possibility of having a well not stored on a grid partitioning.

In a parallel run each process only knows a part of the grid. Nevertheless
it does hold the complete well information. To resolve this the WellsManager
must be able to handle this case.

With this commit its constructor gets a flag indicating whether this is
a parallel run. If it is, then it does not throw if a well has cells that
are not present on the local part of the grid. Nevertheless it will check
that either all or none of the cells of a well are stored in the local part
of the grid.

Wells with no perforated cells on the local will still be present but set to SHUT.
This commit is contained in:
Markus Blatt
2015-05-08 16:29:05 +02:00
parent a87b46a037
commit 2b4ebb94cc
3 changed files with 54 additions and 21 deletions

View File

@@ -308,13 +308,13 @@ namespace Opm
/// Default constructor.
WellsManager::WellsManager()
: w_(0)
: w_(0), is_parallel_run_()
{
}
/// Construct from existing wells object.
WellsManager::WellsManager(struct Wells* W)
: w_(clone_wells(W))
: w_(clone_wells(W)), is_parallel_run_()
{
}
@@ -323,7 +323,7 @@ namespace Opm
const size_t timeStep,
const UnstructuredGrid& grid,
const double* permeability)
: w_(0)
: w_(0), is_parallel_run_()
{
init(eclipseState, timeStep, UgGridHelpers::numCells(grid),
UgGridHelpers::globalCell(grid), UgGridHelpers::cartDims(grid),