From cd9be1030a452d96e689dd8012755c3607378124 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Atgeirr=20Fl=C3=B8=20Rasmussen?= Date: Thu, 14 Jun 2012 14:26:29 +0200 Subject: [PATCH] Adapt to moved SimulatorTimer class, and use common SimulatorReport class. --- examples/polymer_reorder.cpp | 2 +- opm/polymer/SimulatorPolymer.cpp | 17 ++++++++--------- opm/polymer/SimulatorPolymer.hpp | 12 +----------- 3 files changed, 10 insertions(+), 21 deletions(-) diff --git a/examples/polymer_reorder.cpp b/examples/polymer_reorder.cpp index 28b62bb91..105542b66 100644 --- a/examples/polymer_reorder.cpp +++ b/examples/polymer_reorder.cpp @@ -31,7 +31,7 @@ #include #include #include -#include +#include #include #include #include diff --git a/opm/polymer/SimulatorPolymer.cpp b/opm/polymer/SimulatorPolymer.cpp index 7b5aff047..e7289ce39 100644 --- a/opm/polymer/SimulatorPolymer.cpp +++ b/opm/polymer/SimulatorPolymer.cpp @@ -32,7 +32,8 @@ #include #include -#include +#include +#include #include #include #include @@ -144,10 +145,9 @@ namespace Opm - SimulatorPolymer::SimulatorReport - SimulatorPolymer::run(SimulatorTimer& timer, - PolymerState& state, - WellState& well_state) + SimulatorReport SimulatorPolymer::run(SimulatorTimer& timer, + PolymerState& state, + WellState& well_state) { return pimpl_->run(timer, state, well_state); } @@ -231,10 +231,9 @@ namespace Opm - SimulatorPolymer::SimulatorReport - SimulatorPolymer::Impl::run(SimulatorTimer& timer, - PolymerState& state, - WellState& well_state) + SimulatorReport SimulatorPolymer::Impl::run(SimulatorTimer& timer, + PolymerState& state, + WellState& well_state) { std::vector transport_src; diff --git a/opm/polymer/SimulatorPolymer.hpp b/opm/polymer/SimulatorPolymer.hpp index 60313b953..af4c8bca4 100644 --- a/opm/polymer/SimulatorPolymer.hpp +++ b/opm/polymer/SimulatorPolymer.hpp @@ -37,6 +37,7 @@ namespace Opm class SimulatorTimer; class PolymerState; class WellState; + class SimulatorReport; /// Class collecting all necessary components for a two-phase simulation. class SimulatorPolymer @@ -77,17 +78,6 @@ namespace Opm LinearSolverInterface& linsolver, const double* gravity); - /// A struct for returning timing data to the client. - struct SimulatorReport - { - double pressure_time; - double transport_time; - double total_time; - SimulatorReport(); - void operator+=(const SimulatorReport& sr); - void report(std::ostream& os); - }; - /// Run the simulation. /// This will run succesive timesteps until timer.done() is true. It will /// modify the reservoir and well states.