mirror of
https://github.com/OPM/opm-simulators.git
synced 2026-10-12 17:02:02 -05:00
flow: use eclipseState.simulatorConfig().isThermal() to determine whether energy ought to be conserved
this is the new and hip way to query this information from the ECL parser.
This commit is contained in:
1 parent
7896c2f334
commit
bf602c621b
1 file changed
+7
-1
+7
-1
@@ -167,6 +167,12 @@ int main(int argc, char** argv)
|
|||||||
const auto& phases = runspec.phases();
|
const auto& phases = runspec.phases();
|
||||||
|
|
||||||
std::shared_ptr<Opm::EclipseState> eclipseState = std::make_shared< Opm::EclipseState > ( *deck, parseContext );
|
std::shared_ptr<Opm::EclipseState> eclipseState = std::make_shared< Opm::EclipseState > ( *deck, parseContext );
|
||||||
|
|
||||||
|
// run the actual simulator
|
||||||
|
//
|
||||||
|
// TODO: make sure that no illegal combinations like thermal and twophase are
|
||||||
|
// requested.
|
||||||
|
|
||||||
// Twophase cases
|
// Twophase cases
|
||||||
if( phases.size() == 2 ) {
|
if( phases.size() == 2 ) {
|
||||||
// oil-gas
|
// oil-gas
|
||||||
@@ -211,7 +217,7 @@ int main(int argc, char** argv)
|
|||||||
return Opm::flowEbosSolventMain(argc, argv);
|
return Opm::flowEbosSolventMain(argc, argv);
|
||||||
}
|
}
|
||||||
// Energy case
|
// Energy case
|
||||||
else if ( phases.active( Opm::Phase::ENERGY ) ) {
|
else if (eclipseState->getSimulationConfig().isThermal()) {
|
||||||
Opm::flowEbosEnergySetDeck(*deck, *eclipseState);
|
Opm::flowEbosEnergySetDeck(*deck, *eclipseState);
|
||||||
return Opm::flowEbosEnergyMain(argc, argv);
|
return Opm::flowEbosEnergyMain(argc, argv);
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in new issue
Block a user