mirror of
https://github.com/OPM/opm-simulators.git
synced 2025-02-25 18:55:30 -06:00
make assemble method return IterationReport.
This commit is contained in:
parent
baeab02bd6
commit
e6930df28c
@ -147,12 +147,12 @@ namespace Opm {
|
||||
|
||||
|
||||
|
||||
|
||||
void assemble(const ReservoirState& reservoir_state,
|
||||
WellState& well_state,
|
||||
const bool initial_assembly)
|
||||
IterationReport
|
||||
assemble(const ReservoirState& reservoir_state,
|
||||
WellState& well_state,
|
||||
const bool initial_assembly)
|
||||
{
|
||||
Base::assemble(reservoir_state, well_state, initial_assembly);
|
||||
IterationReport iter_report = Base::assemble(reservoir_state, well_state, initial_assembly);
|
||||
|
||||
if (initial_assembly) {
|
||||
}
|
||||
@ -184,6 +184,7 @@ namespace Opm {
|
||||
assert(int(well_state.perfRates().size()) == wflux.size());
|
||||
std::copy_n(wflux.data(), wflux.size(), well_state.perfRates().begin());
|
||||
}
|
||||
return iter_report;
|
||||
}
|
||||
|
||||
|
||||
|
@ -82,10 +82,10 @@ namespace Opm {
|
||||
asImpl().makeConstantState(state0_);
|
||||
}
|
||||
|
||||
|
||||
void assemble(const ReservoirState& reservoir_state,
|
||||
WellState& well_state,
|
||||
const bool initial_assembly)
|
||||
IterationReport
|
||||
assemble(const ReservoirState& reservoir_state,
|
||||
WellState& well_state,
|
||||
const bool initial_assembly)
|
||||
{
|
||||
|
||||
using namespace Opm::AutoDiffGrid;
|
||||
@ -124,9 +124,9 @@ namespace Opm {
|
||||
asImpl().assembleMassBalanceEq(state);
|
||||
|
||||
// -------- Well equations ----------
|
||||
|
||||
IterationReport iter_report = {false, false, 0, 0};
|
||||
if ( ! wellsActive() ) {
|
||||
return;
|
||||
return iter_report;
|
||||
}
|
||||
|
||||
std::vector<ADB> mob_perfcells;
|
||||
@ -134,7 +134,7 @@ namespace Opm {
|
||||
asImpl().wellModel().extractWellPerfProperties(state, rq_, mob_perfcells, b_perfcells);
|
||||
if (param_.solve_welleq_initially_ && initial_assembly) {
|
||||
// solve the well equations as a pre-processing step
|
||||
asImpl().solveWellEq(mob_perfcells, b_perfcells, state, well_state);
|
||||
iter_report = asImpl().solveWellEq(mob_perfcells, b_perfcells, state, well_state);
|
||||
}
|
||||
V aliveWells;
|
||||
std::vector<ADB> cq_s;
|
||||
@ -153,6 +153,7 @@ namespace Opm {
|
||||
asImpl().makeConstantState(state0);
|
||||
asImpl().wellModel().computeWellPotentials(mob_perfcells, b_perfcells, state0, well_state);
|
||||
}
|
||||
return iter_report;
|
||||
}
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user