mirror of
https://github.com/OPM/opm-simulators.git
synced 2025-02-25 18:55:30 -06:00
Adapt to changes in schedule interface
This commit is contained in:
@@ -109,7 +109,7 @@ try
|
||||
schedule.reset( new Schedule(deck,
|
||||
eclipseState->getInputGrid(),
|
||||
eclipseState->get3DProperties(),
|
||||
eclipseState->runspec().phases(),
|
||||
eclipseState->runspec(),
|
||||
parseContext));
|
||||
|
||||
|
||||
|
||||
@@ -119,7 +119,7 @@ try
|
||||
schedule.reset( new Schedule(deck,
|
||||
eclipseState->getInputGrid(),
|
||||
eclipseState->get3DProperties(),
|
||||
eclipseState->runspec().phases(),
|
||||
eclipseState->runspec(),
|
||||
parseContext));
|
||||
|
||||
// Grid init
|
||||
|
||||
@@ -107,7 +107,7 @@ try
|
||||
Opm::ParseContext parseContext({{ ParseContext::PARSE_RANDOM_SLASH , InputError::IGNORE }});
|
||||
deck.reset(new Deck(parser.parseFile(deck_filename , parseContext)));
|
||||
eclipseState.reset( new EclipseState(*deck , parseContext) );
|
||||
schedule.reset( new Schedule(*deck, eclipseState->getInputGrid(), eclipseState->get3DProperties(), eclipseState->runspec().phases(), parseContext ));
|
||||
schedule.reset( new Schedule(*deck, eclipseState->getInputGrid(), eclipseState->get3DProperties(), eclipseState->runspec(), parseContext ));
|
||||
// Grid init
|
||||
grid.reset(new GridManager(eclipseState->getInputGrid()));
|
||||
{
|
||||
|
||||
@@ -108,7 +108,7 @@ try
|
||||
deck.reset(new Deck(parser.parseFile(deck_filename , parseContext)));
|
||||
|
||||
eclipseState.reset(new Opm::EclipseState(*deck , parseContext));
|
||||
schedule.reset( new Opm::Schedule(*deck, eclipseState->getInputGrid(), eclipseState->get3DProperties(), eclipseState->runspec().phases(), parseContext));
|
||||
schedule.reset( new Opm::Schedule(*deck, eclipseState->getInputGrid(), eclipseState->get3DProperties(), eclipseState->runspec(), parseContext));
|
||||
// Grid init
|
||||
grid.reset(new GridManager(eclipseState->getInputGrid()));
|
||||
{
|
||||
|
||||
@@ -38,7 +38,7 @@ try
|
||||
Opm::Parser parser;
|
||||
Opm::Deck deck = parser.parseFile(file_name , parseContext);
|
||||
Opm::EclipseState eclipseState(deck , parseContext);
|
||||
Opm::Schedule schedule(deck, eclipseState.getInputGrid(), eclipseState.get3DProperties(), eclipseState.runspec().phases(), parseContext);
|
||||
Opm::Schedule schedule(deck, eclipseState.getInputGrid(), eclipseState.get3DProperties(), eclipseState.runspec(), parseContext);
|
||||
std::cout << "Done!" << std::endl;
|
||||
|
||||
// Setup grid
|
||||
|
||||
@@ -167,7 +167,7 @@ int main(int argc, char** argv)
|
||||
const auto& phases = runspec.phases();
|
||||
|
||||
std::shared_ptr<Opm::EclipseState> eclipseState = std::make_shared< Opm::EclipseState > ( *deck, parseContext );
|
||||
std::shared_ptr<Opm::Schedule> schedule = std::make_shared<Opm::Schedule>(*deck, eclipseState->getInputGrid(), eclipseState->get3DProperties(), phases, parseContext);
|
||||
std::shared_ptr<Opm::Schedule> schedule = std::make_shared<Opm::Schedule>(*deck, eclipseState->getInputGrid(), eclipseState->get3DProperties(), runspec, parseContext);
|
||||
std::shared_ptr<Opm::SummaryConfig> summary_config = std::make_shared<Opm::SummaryConfig>(*deck, *schedule, eclipseState->getTableManager(), parseContext);
|
||||
// Twophase cases
|
||||
if( phases.size() == 2 ) {
|
||||
|
||||
@@ -507,7 +507,7 @@ namespace Opm
|
||||
schedule_.reset(new Schedule(*deck_,
|
||||
eclipse_state_->getInputGrid(),
|
||||
eclipse_state_->get3DProperties(),
|
||||
eclipse_state_->runspec().phases(),
|
||||
eclipse_state_->runspec(),
|
||||
parseContext));
|
||||
summary_config_.reset(new SummaryConfig(*deck_,
|
||||
*schedule_,
|
||||
|
||||
@@ -214,7 +214,7 @@ public:
|
||||
|
||||
// Run a multiple steps of the solver depending on the time step control.
|
||||
solverTimer.start();
|
||||
|
||||
//ebosSimulator_.setEpisodeIndex(timer.reportStepNum());
|
||||
wellModel.beginReportStep(timer.currentStepNum());
|
||||
|
||||
auto solver = createSolver(wellModel, aquifer_model);
|
||||
|
||||
@@ -47,7 +47,8 @@ BOOST_AUTO_TEST_CASE(TestStoppedWells)
|
||||
const auto& grid = eclipseState.getInputGrid();
|
||||
const TableManager table ( deck );
|
||||
const Eclipse3DProperties eclipseProperties ( deck , table, grid);
|
||||
const Schedule sched(deck, grid, eclipseProperties, Phases(true, true, true), parseContext );
|
||||
const Opm::Runspec runspec (deck);
|
||||
const Schedule sched(deck, grid, eclipseProperties, runspec, parseContext );
|
||||
|
||||
|
||||
double target_surfacerate_inj;
|
||||
|
||||
@@ -45,7 +45,8 @@ BOOST_AUTO_TEST_CASE(AddWellsAndGroupToCollection) {
|
||||
const auto& grid = eclipseState.getInputGrid();
|
||||
const TableManager table ( deck );
|
||||
const Eclipse3DProperties eclipseProperties ( deck , table, grid);
|
||||
const Schedule sched(deck, grid, eclipseProperties, Phases(true, true, true), parseContext );
|
||||
const Runspec runspec(deck);
|
||||
const Schedule sched(deck, grid, eclipseProperties, runspec, parseContext );
|
||||
|
||||
|
||||
WellCollection collection;
|
||||
@@ -84,7 +85,8 @@ BOOST_AUTO_TEST_CASE(EfficiencyFactor) {
|
||||
const auto& grid = eclipseState.getInputGrid();
|
||||
const TableManager table ( deck );
|
||||
const Eclipse3DProperties eclipseProperties ( deck , table, grid);
|
||||
const Schedule sched(deck, grid, eclipseProperties, Phases(true, true, true), parseContext );
|
||||
const Runspec runspec(deck);
|
||||
const Schedule sched(deck, grid, eclipseProperties, runspec, parseContext );
|
||||
|
||||
size_t timestep = 2;
|
||||
WellCollection collection;
|
||||
|
||||
@@ -79,7 +79,8 @@ struct SetupTest {
|
||||
{
|
||||
const Opm::TableManager table ( deck );
|
||||
const Opm::Eclipse3DProperties eclipseProperties ( deck , table, ecl_state->getInputGrid());
|
||||
schedule.reset( new Opm::Schedule(deck, ecl_state->getInputGrid(), eclipseProperties, Opm::Phases(true, true, true), parse_context ));
|
||||
const Opm::Runspec runspec (deck);
|
||||
schedule.reset( new Opm::Schedule(deck, ecl_state->getInputGrid(), eclipseProperties, runspec, parse_context ));
|
||||
}
|
||||
|
||||
// Create grid.
|
||||
|
||||
@@ -52,7 +52,8 @@ BOOST_AUTO_TEST_CASE(ConstructGroupFromWell) {
|
||||
const auto& grid = eclipseState.getInputGrid();
|
||||
const TableManager table ( deck );
|
||||
const Eclipse3DProperties eclipseProperties ( deck , table, grid);
|
||||
const Schedule sched(deck, grid, eclipseProperties, Phases(true, true, true), parseContext );
|
||||
const Opm::Runspec runspec (deck);
|
||||
const Schedule sched(deck, grid, eclipseProperties, runspec, parseContext );
|
||||
|
||||
PhaseUsage pu = phaseUsageFromDeck(eclipseState);
|
||||
|
||||
@@ -91,7 +92,8 @@ BOOST_AUTO_TEST_CASE(ConstructGroupFromGroup) {
|
||||
const auto& grid = eclipseState.getInputGrid();
|
||||
const TableManager table ( deck );
|
||||
const Eclipse3DProperties eclipseProperties ( deck , table, grid);
|
||||
const Schedule sched(deck, grid, eclipseProperties, Phases(true, true, true), parseContext );
|
||||
const Opm::Runspec runspec (deck);
|
||||
const Schedule sched(deck, grid, eclipseProperties, runspec, parseContext );
|
||||
|
||||
|
||||
const auto& nodes = sched.getGroupTree(2);
|
||||
@@ -128,7 +130,8 @@ BOOST_AUTO_TEST_CASE(EfficiencyFactor) {
|
||||
const auto& grid = eclipseState.getInputGrid();
|
||||
const TableManager table ( deck );
|
||||
const Eclipse3DProperties eclipseProperties ( deck , table, grid);
|
||||
const Schedule sched(deck, grid, eclipseProperties, Phases(true, true, true), parseContext );
|
||||
const Opm::Runspec runspec (deck);
|
||||
const Schedule sched(deck, grid, eclipseProperties, runspec, parseContext );
|
||||
|
||||
|
||||
const auto& nodes = sched.getGroupTree(2);
|
||||
|
||||
@@ -184,7 +184,8 @@ BOOST_AUTO_TEST_CASE(New_Constructor_Works) {
|
||||
const auto& grid = eclipseState.getInputGrid();
|
||||
const Opm::TableManager table ( deck );
|
||||
const Opm::Eclipse3DProperties eclipseProperties ( deck , table, grid);
|
||||
const Opm::Schedule sched(deck, grid, eclipseProperties, Opm::Phases(true, true, true), parseContext );
|
||||
const Opm::Runspec runspec (deck);
|
||||
const Opm::Schedule sched(deck, grid, eclipseProperties, runspec, parseContext );
|
||||
|
||||
|
||||
{
|
||||
@@ -225,7 +226,8 @@ BOOST_AUTO_TEST_CASE(WellsEqual) {
|
||||
const auto& grid = eclipseState.getInputGrid();
|
||||
const Opm::TableManager table ( deck );
|
||||
const Opm::Eclipse3DProperties eclipseProperties ( deck , table, grid);
|
||||
const Opm::Schedule sched(deck, grid, eclipseProperties, Opm::Phases(true, true, true), parseContext );
|
||||
const Opm::Runspec runspec (deck);
|
||||
const Opm::Schedule sched(deck, grid, eclipseProperties, runspec, parseContext );
|
||||
|
||||
|
||||
Opm::WellsManager wellsManager0(eclipseState, sched, 0, *vanguard.c_grid());
|
||||
@@ -245,7 +247,8 @@ BOOST_AUTO_TEST_CASE(ControlsEqual) {
|
||||
const auto& grid = eclipseState.getInputGrid();
|
||||
const Opm::TableManager table ( deck );
|
||||
const Opm::Eclipse3DProperties eclipseProperties ( deck , table, grid);
|
||||
const Opm::Schedule sched(deck, grid, eclipseProperties, Opm::Phases(true, true, true), parseContext );
|
||||
const Opm::Runspec runspec (deck);
|
||||
const Opm::Schedule sched(deck, grid, eclipseProperties, runspec, parseContext );
|
||||
|
||||
|
||||
|
||||
@@ -273,7 +276,8 @@ BOOST_AUTO_TEST_CASE(WellShutOK) {
|
||||
const auto& grid = eclipseState.getInputGrid();
|
||||
const Opm::TableManager table ( deck );
|
||||
const Opm::Eclipse3DProperties eclipseProperties ( deck , table, grid);
|
||||
const Opm::Schedule sched(deck, grid, eclipseProperties, Opm::Phases(true, true, true), parseContext );
|
||||
const Opm::Runspec runspec (deck);
|
||||
const Opm::Schedule sched(deck, grid, eclipseProperties, runspec, parseContext );
|
||||
|
||||
|
||||
Opm::WellsManager wellsManager2(eclipseState, sched, 2, *vanguard.c_grid());
|
||||
@@ -294,7 +298,8 @@ BOOST_AUTO_TEST_CASE(WellSTOPOK) {
|
||||
const auto& grid = eclipseState.getInputGrid();
|
||||
const Opm::TableManager table ( deck );
|
||||
const Opm::Eclipse3DProperties eclipseProperties ( deck , table, grid);
|
||||
const Opm::Schedule sched(deck, grid, eclipseProperties, Opm::Phases(true, true, true), parseContext );
|
||||
const Opm::Runspec runspec (deck);
|
||||
const Opm::Schedule sched(deck, grid, eclipseProperties, runspec, parseContext );
|
||||
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user