mirror of
https://github.com/OPM/opm-simulators.git
synced 2025-02-25 18:55:30 -06:00
parallel running for flow_mutlisegment
SPE9 can be run in parallel now.
This commit is contained in:
parent
4c73f3c01c
commit
38a9dbd9ff
@ -78,6 +78,7 @@ list (APPEND TEST_DATA_FILES
|
||||
list (APPEND EXAMPLE_SOURCE_FILES
|
||||
examples/find_zero.cpp
|
||||
examples/flow.cpp
|
||||
examples/flow_multisegment_mpi.cpp
|
||||
examples/flow_multisegment.cpp
|
||||
examples/flow_solvent.cpp
|
||||
examples/sim_2p_incomp_ad.cpp
|
||||
|
2
examples/flow_multisegment_mpi.cpp
Normal file
2
examples/flow_multisegment_mpi.cpp
Normal file
@ -0,0 +1,2 @@
|
||||
#define WANT_DUNE_CORNERPOINTGRID 1
|
||||
#include "flow_multisegment.cpp"
|
@ -119,7 +119,20 @@ namespace Opm
|
||||
if (wells_ecl[i]->getStatus(timer.currentStepNum()) == WellCommon::SHUT) {
|
||||
continue;
|
||||
}
|
||||
wells_multisegment.push_back(std::make_shared<WellMultiSegment>(wells_ecl[i], timer.currentStepNum(), wells));
|
||||
// checking if the well can be found in the wells
|
||||
const std::string& well_name = wells_ecl[i]->name();
|
||||
// number of wells in wells
|
||||
const int nw_wells = wells->number_of_wells;
|
||||
int index_well;
|
||||
for (index_well = 0; index_well < nw_wells; ++index_well) {
|
||||
if (well_name == std::string(wells->name[index_well])) {
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
if (index_well != nw_wells) { // found in the wells
|
||||
wells_multisegment.push_back(std::make_shared<WellMultiSegment>(wells_ecl[i], timer.currentStepNum(), wells));
|
||||
}
|
||||
}
|
||||
|
||||
well_state.init(wells_multisegment, state, prev_well_state);
|
||||
|
Loading…
Reference in New Issue
Block a user