mirror of
https://github.com/OPM/opm-simulators.git
synced 2024-12-28 02:00:59 -06:00
Use plural for parameter class names.
This commit is contained in:
parent
270a7c59fb
commit
603b9657a1
@ -65,7 +65,7 @@ namespace Opm {
|
||||
typedef WellStateFullyImplicitBlackoil WellState;
|
||||
|
||||
/// Model-specific solver parameters.
|
||||
struct ModelParameter
|
||||
struct ModelParameters
|
||||
{
|
||||
double dp_max_rel_;
|
||||
double ds_max_;
|
||||
@ -75,8 +75,8 @@ namespace Opm {
|
||||
double tolerance_cnv_;
|
||||
double tolerance_wells_;
|
||||
|
||||
ModelParameter( const parameter::ParameterGroup& param );
|
||||
ModelParameter();
|
||||
explicit ModelParameters( const parameter::ParameterGroup& param );
|
||||
ModelParameters();
|
||||
|
||||
void reset();
|
||||
};
|
||||
@ -96,7 +96,7 @@ namespace Opm {
|
||||
/// \param[in] has_disgas turn on dissolved gas
|
||||
/// \param[in] has_vapoil turn on vaporized oil feature
|
||||
/// \param[in] terminal_output request output to cout/cerr
|
||||
BlackoilModel(const ModelParameter& param,
|
||||
BlackoilModel(const ModelParameters& param,
|
||||
const Grid& grid ,
|
||||
const BlackoilPropsAdInterface& fluid,
|
||||
const DerivedGeology& geo ,
|
||||
@ -241,7 +241,7 @@ namespace Opm {
|
||||
const bool has_disgas_;
|
||||
const bool has_vapoil_;
|
||||
|
||||
ModelParameter param_;
|
||||
ModelParameters param_;
|
||||
bool use_threshold_pressure_;
|
||||
V threshold_pressures_by_interior_face_;
|
||||
|
||||
|
@ -136,7 +136,7 @@ namespace detail {
|
||||
} // namespace detail
|
||||
|
||||
template <class Grid>
|
||||
void BlackoilModel<Grid>::ModelParameter::
|
||||
void BlackoilModel<Grid>::ModelParameters::
|
||||
reset()
|
||||
{
|
||||
// default values for the solver parameters
|
||||
@ -150,16 +150,16 @@ namespace detail {
|
||||
}
|
||||
|
||||
template <class Grid>
|
||||
BlackoilModel<Grid>::ModelParameter::
|
||||
ModelParameter()
|
||||
BlackoilModel<Grid>::ModelParameters::
|
||||
ModelParameters()
|
||||
{
|
||||
// set default values
|
||||
reset();
|
||||
}
|
||||
|
||||
template <class Grid>
|
||||
BlackoilModel<Grid>::ModelParameter::
|
||||
ModelParameter( const parameter::ParameterGroup& param )
|
||||
BlackoilModel<Grid>::ModelParameters::
|
||||
ModelParameters( const parameter::ParameterGroup& param )
|
||||
{
|
||||
// set default values
|
||||
reset();
|
||||
@ -177,7 +177,7 @@ namespace detail {
|
||||
|
||||
template <class Grid>
|
||||
BlackoilModel<Grid>::
|
||||
BlackoilModel(const ModelParameter& param,
|
||||
BlackoilModel(const ModelParameters& param,
|
||||
const Grid& grid ,
|
||||
const BlackoilPropsAdInterface& fluid,
|
||||
const DerivedGeology& geo ,
|
||||
|
@ -41,7 +41,7 @@ namespace Opm {
|
||||
enum RelaxType { DAMPEN, SOR };
|
||||
|
||||
// Solver parameters controlling nonlinear Newton process.
|
||||
struct SolverParameter
|
||||
struct SolverParameters
|
||||
{
|
||||
enum RelaxType relax_type_;
|
||||
double relax_max_;
|
||||
@ -50,8 +50,8 @@ namespace Opm {
|
||||
int max_iter_; // max newton iterations
|
||||
int min_iter_; // min newton iterations
|
||||
|
||||
SolverParameter( const parameter::ParameterGroup& param );
|
||||
SolverParameter();
|
||||
explicit SolverParameters( const parameter::ParameterGroup& param );
|
||||
SolverParameters();
|
||||
|
||||
void reset();
|
||||
};
|
||||
@ -65,7 +65,7 @@ namespace Opm {
|
||||
/// Construct solver for a given model.
|
||||
/// \param[in] param parameters controlling nonlinear Newton process
|
||||
/// \param[in, out] model physical simulation model
|
||||
explicit NewtonSolver(const SolverParameter& param,
|
||||
explicit NewtonSolver(const SolverParameters& param,
|
||||
PhysicalModel& model);
|
||||
|
||||
/// Take a single forward step, after which the states will be modified
|
||||
@ -87,7 +87,7 @@ namespace Opm {
|
||||
|
||||
private:
|
||||
// --------- Data members ---------
|
||||
SolverParameter param_;
|
||||
SolverParameters param_;
|
||||
PhysicalModel& model_;
|
||||
unsigned int newtonIterations_;
|
||||
unsigned int linearIterations_;
|
||||
|
@ -28,7 +28,7 @@
|
||||
namespace Opm
|
||||
{
|
||||
template <class PhysicalModel>
|
||||
NewtonSolver<PhysicalModel>::NewtonSolver(const SolverParameter& param,
|
||||
NewtonSolver<PhysicalModel>::NewtonSolver(const SolverParameters& param,
|
||||
PhysicalModel& model)
|
||||
: param_(param),
|
||||
model_(model),
|
||||
@ -131,7 +131,7 @@ namespace Opm
|
||||
|
||||
|
||||
template <class PhysicalModel>
|
||||
void NewtonSolver<PhysicalModel>::SolverParameter::
|
||||
void NewtonSolver<PhysicalModel>::SolverParameters::
|
||||
reset()
|
||||
{
|
||||
// default values for the solver parameters
|
||||
@ -144,16 +144,16 @@ namespace Opm
|
||||
}
|
||||
|
||||
template <class PhysicalModel>
|
||||
NewtonSolver<PhysicalModel>::SolverParameter::
|
||||
SolverParameter()
|
||||
NewtonSolver<PhysicalModel>::SolverParameters::
|
||||
SolverParameters()
|
||||
{
|
||||
// set default values
|
||||
reset();
|
||||
}
|
||||
|
||||
template <class PhysicalModel>
|
||||
NewtonSolver<PhysicalModel>::SolverParameter::
|
||||
SolverParameter( const parameter::ParameterGroup& param )
|
||||
NewtonSolver<PhysicalModel>::SolverParameters::
|
||||
SolverParameters( const parameter::ParameterGroup& param )
|
||||
{
|
||||
// set default values
|
||||
reset();
|
||||
|
@ -234,11 +234,11 @@ namespace Opm
|
||||
|
||||
typedef T Grid;
|
||||
typedef BlackoilModel<Grid> Model;
|
||||
typedef typename Model::ModelParameter ModelParam;
|
||||
ModelParam modelParam( param_ );
|
||||
typedef typename Model::ModelParameters ModelParams;
|
||||
ModelParams modelParams( param_ );
|
||||
typedef NewtonSolver<Model> Solver;
|
||||
typedef typename Solver::SolverParameter SolverParam;
|
||||
SolverParam solverParam( param_ );
|
||||
typedef typename Solver::SolverParameters SolverParams;
|
||||
SolverParams solverParams( param_ );
|
||||
|
||||
// adaptive time stepping
|
||||
std::unique_ptr< AdaptiveTimeStepping > adaptiveTimeStepping;
|
||||
@ -298,11 +298,11 @@ namespace Opm
|
||||
// Run a multiple steps of the solver depending on the time step control.
|
||||
solver_timer.start();
|
||||
|
||||
Model model(modelParam, grid_, props_, geo_, rock_comp_props_, wells, solver_, has_disgas_, has_vapoil_, terminal_output_);
|
||||
Model model(modelParams, grid_, props_, geo_, rock_comp_props_, wells, solver_, has_disgas_, has_vapoil_, terminal_output_);
|
||||
if (!threshold_pressures_by_face_.empty()) {
|
||||
model.setThresholdPressures(threshold_pressures_by_face_);
|
||||
}
|
||||
Solver solver(solverParam, model);
|
||||
Solver solver(solverParams, model);
|
||||
|
||||
// If sub stepping is enabled allow the solver to sub cycle
|
||||
// in case the report steps are to large for the solver to converge
|
||||
|
Loading…
Reference in New Issue
Block a user