All Classes Namespaces Files Functions Variables Typedefs Enumerator Pages
SimulatorPolymer.hpp
1 /*
2  Copyright 2012 SINTEF ICT, Applied Mathematics.
3 
4  This file is part of the Open Porous Media project (OPM).
5 
6  OPM is free software: you can redistribute it and/or modify
7  it under the terms of the GNU General Public License as published by
8  the Free Software Foundation, either version 3 of the License, or
9  (at your option) any later version.
10 
11  OPM is distributed in the hope that it will be useful,
12  but WITHOUT ANY WARRANTY; without even the implied warranty of
13  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14  GNU General Public License for more details.
15 
16  You should have received a copy of the GNU General Public License
17  along with OPM. If not, see <http://www.gnu.org/licenses/>.
18 */
19 
20 #ifndef OPM_SIMULATORPOLYMER_HEADER_INCLUDED
21 #define OPM_SIMULATORPOLYMER_HEADER_INCLUDED
22 
23 #include <opm/core/simulator/SimulatorReport.hpp>
24 #include <boost/shared_ptr.hpp>
25 #include <vector>
26 
27 struct UnstructuredGrid;
28 struct Wells;
29 struct FlowBoundaryConditions;
30 
31 namespace Opm
32 {
33  class ParameterGroup;
34  class IncompPropertiesInterface;
35  class PolymerProperties;
36  class RockCompressibility;
37  class WellsManager;
38  class PolymerInflowInterface;
39  class LinearSolverInterface;
40  class SimulatorTimer;
41  class PolymerState;
42  class WellState;
43  struct SimulatorReport;
44 
47  {
48  public:
75  SimulatorPolymer(const ParameterGroup& param,
76  const UnstructuredGrid& grid,
77  const IncompPropertiesInterface& props,
78  const PolymerProperties& poly_props,
79  const RockCompressibility* rock_comp_props,
80  WellsManager& wells_manager,
81  const PolymerInflowInterface& polymer_inflow,
82  const std::vector<double>& src,
83  const FlowBoundaryConditions* bcs,
84  LinearSolverInterface& linsolver,
85  const double* gravity);
86 
95  SimulatorReport run(SimulatorTimer& timer,
96  PolymerState& state,
97  WellState& well_state);
98 
103  const SimulatorReport& failureReport() const
104  { return failureReport_; }
105 
106  private:
107  class Impl;
108 
109  SimulatorReport failureReport_;
110 
111  // Using shared_ptr instead of scoped_ptr since scoped_ptr requires complete type for Impl.
112  boost::shared_ptr<Impl> pimpl_;
113  };
114 
115 } // namespace Opm
116 
117 #endif // OPM_SIMULATORPOLYMER_HEADER_INCLUDED
const SimulatorReport & failureReport() const
return the statistics if the nonlinearIteration() method failed.
Definition: SimulatorPolymer.hpp:103
Definition: PolymerProperties.hpp:43
Interface for classes encapsulating polymer inflow information.
Definition: PolymerInflow.hpp:38
Simulator state for a two-phase simulator with polymer.
Definition: PolymerState.hpp:32
SimulatorReport run(SimulatorTimer &timer, PolymerState &state, WellState &well_state)
Run the simulation.
Definition: SimulatorPolymer.cpp:169
Class collecting all necessary components for a two-phase simulation.
Definition: SimulatorPolymer.hpp:46
SimulatorPolymer(const ParameterGroup &param, const UnstructuredGrid &grid, const IncompPropertiesInterface &props, const PolymerProperties &poly_props, const RockCompressibility *rock_comp_props, WellsManager &wells_manager, const PolymerInflowInterface &polymer_inflow, const std::vector< double > &src, const FlowBoundaryConditions *bcs, LinearSolverInterface &linsolver, const double *gravity)
Initialise from parameters and objects to observe.
Definition: SimulatorPolymer.cpp:150
Definition: SimulatorTimer.hpp:34