mirror of
https://github.com/OPM/opm-simulators.git
synced 2025-02-25 18:55:30 -06:00
Rename FullyImplicitSolver -> NewtonSolver.
This commit is contained in:
parent
82827f56c0
commit
f89297255f
@ -107,11 +107,11 @@ list (APPEND PUBLIC_HEADER_FILES
|
||||
opm/autodiff/ImpesTPFAAD.hpp
|
||||
opm/autodiff/FullyImplicitBlackoilSolver.hpp
|
||||
opm/autodiff/FullyImplicitBlackoilSolver_impl.hpp
|
||||
opm/autodiff/FullyImplicitSolver.hpp
|
||||
opm/autodiff/FullyImplicitSolver_impl.hpp
|
||||
opm/autodiff/NewtonIterationBlackoilCPR.hpp
|
||||
opm/autodiff/NewtonIterationBlackoilInterface.hpp
|
||||
opm/autodiff/NewtonIterationBlackoilSimple.hpp
|
||||
opm/autodiff/NewtonSolver.hpp
|
||||
opm/autodiff/NewtonSolver_impl.hpp
|
||||
opm/autodiff/LinearisedBlackoilResidual.hpp
|
||||
opm/autodiff/RateConverter.hpp
|
||||
opm/autodiff/RedistributeDataHandles.hpp
|
||||
|
@ -18,8 +18,8 @@
|
||||
along with OPM. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
#ifndef OPM_FULLYIMPLICITSOLVER_HEADER_INCLUDED
|
||||
#define OPM_FULLYIMPLICITSOLVER_HEADER_INCLUDED
|
||||
#ifndef OPM_NEWTONSOLVER_HEADER_INCLUDED
|
||||
#define OPM_NEWTONSOLVER_HEADER_INCLUDED
|
||||
|
||||
#include <opm/autodiff/AutoDiffBlock.hpp>
|
||||
#include <opm/core/utility/parameters/ParameterGroup.hpp>
|
||||
@ -27,9 +27,9 @@
|
||||
namespace Opm {
|
||||
|
||||
|
||||
/// A fully implicit solver class suitable for general models.
|
||||
/// A Newton solver class suitable for general fully-implicit models.
|
||||
template <class PhysicalModel>
|
||||
class FullyImplicitSolver
|
||||
class NewtonSolver
|
||||
{
|
||||
public:
|
||||
// --------- Types and enums ---------
|
||||
@ -65,8 +65,8 @@ namespace Opm {
|
||||
/// Construct solver for a given model.
|
||||
/// \param[in] param parameters controlling nonlinear Newton process
|
||||
/// \param[in, out] model physical simulation model
|
||||
explicit FullyImplicitSolver(const SolverParameter& param,
|
||||
PhysicalModel& model);
|
||||
explicit NewtonSolver(const SolverParameter& param,
|
||||
PhysicalModel& model);
|
||||
|
||||
/// Take a single forward step, after which the states will be modified
|
||||
/// according to the physical model.
|
||||
@ -106,6 +106,6 @@ namespace Opm {
|
||||
};
|
||||
} // namespace Opm
|
||||
|
||||
#include "FullyImplicitSolver_impl.hpp"
|
||||
#include "NewtonSolver_impl.hpp"
|
||||
|
||||
#endif // OPM_FULLYIMPLICITSOLVER_HEADER_INCLUDED
|
||||
#endif // OPM_NEWTONSOLVER_HEADER_INCLUDED
|
@ -20,16 +20,16 @@
|
||||
along with OPM. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
#ifndef OPM_FULLYIMPLICITSOLVER_IMPL_HEADER_INCLUDED
|
||||
#define OPM_FULLYIMPLICITSOLVER_IMPL_HEADER_INCLUDED
|
||||
#ifndef OPM_NEWTONSOLVER_IMPL_HEADER_INCLUDED
|
||||
#define OPM_NEWTONSOLVER_IMPL_HEADER_INCLUDED
|
||||
|
||||
#include <opm/autodiff/FullyImplicitSolver.hpp>
|
||||
#include <opm/autodiff/NewtonSolver.hpp>
|
||||
|
||||
namespace Opm
|
||||
{
|
||||
template <class PhysicalModel>
|
||||
FullyImplicitSolver<PhysicalModel>::FullyImplicitSolver(const SolverParameter& param,
|
||||
PhysicalModel& model)
|
||||
NewtonSolver<PhysicalModel>::NewtonSolver(const SolverParameter& param,
|
||||
PhysicalModel& model)
|
||||
: param_(param),
|
||||
model_(model),
|
||||
newtonIterations_(0),
|
||||
@ -38,13 +38,13 @@ namespace Opm
|
||||
}
|
||||
|
||||
template <class PhysicalModel>
|
||||
unsigned int FullyImplicitSolver<PhysicalModel>::newtonIterations () const
|
||||
unsigned int NewtonSolver<PhysicalModel>::newtonIterations () const
|
||||
{
|
||||
return newtonIterations_;
|
||||
}
|
||||
|
||||
template <class PhysicalModel>
|
||||
unsigned int FullyImplicitSolver<PhysicalModel>::linearIterations () const
|
||||
unsigned int NewtonSolver<PhysicalModel>::linearIterations () const
|
||||
{
|
||||
return linearIterations_;
|
||||
}
|
||||
@ -52,7 +52,7 @@ namespace Opm
|
||||
|
||||
template <class PhysicalModel>
|
||||
int
|
||||
FullyImplicitSolver<PhysicalModel>::
|
||||
NewtonSolver<PhysicalModel>::
|
||||
step(const double dt,
|
||||
ReservoirState& reservoir_state,
|
||||
WellState& well_state)
|
||||
@ -128,7 +128,7 @@ namespace Opm
|
||||
|
||||
|
||||
template <class PhysicalModel>
|
||||
void FullyImplicitSolver<PhysicalModel>::SolverParameter::
|
||||
void NewtonSolver<PhysicalModel>::SolverParameter::
|
||||
reset()
|
||||
{
|
||||
// default values for the solver parameters
|
||||
@ -141,7 +141,7 @@ namespace Opm
|
||||
}
|
||||
|
||||
template <class PhysicalModel>
|
||||
FullyImplicitSolver<PhysicalModel>::SolverParameter::
|
||||
NewtonSolver<PhysicalModel>::SolverParameter::
|
||||
SolverParameter()
|
||||
{
|
||||
// set default values
|
||||
@ -149,7 +149,7 @@ namespace Opm
|
||||
}
|
||||
|
||||
template <class PhysicalModel>
|
||||
FullyImplicitSolver<PhysicalModel>::SolverParameter::
|
||||
NewtonSolver<PhysicalModel>::SolverParameter::
|
||||
SolverParameter( const parameter::ParameterGroup& param )
|
||||
{
|
||||
// set default values
|
||||
@ -172,9 +172,9 @@ namespace Opm
|
||||
|
||||
template <class PhysicalModel>
|
||||
void
|
||||
FullyImplicitSolver<PhysicalModel>::detectNewtonOscillations(const std::vector<std::vector<double>>& residual_history,
|
||||
const int it, const double relaxRelTol,
|
||||
bool& oscillate, bool& stagnate) const
|
||||
NewtonSolver<PhysicalModel>::detectNewtonOscillations(const std::vector<std::vector<double>>& residual_history,
|
||||
const int it, const double relaxRelTol,
|
||||
bool& oscillate, bool& stagnate) const
|
||||
{
|
||||
// The detection of oscillation in two primary variable results in the report of the detection
|
||||
// of oscillation for the solver.
|
||||
@ -209,8 +209,8 @@ namespace Opm
|
||||
|
||||
template <class PhysicalModel>
|
||||
void
|
||||
FullyImplicitSolver<PhysicalModel>::stabilizeNewton(V& dx, V& dxOld, const double omega,
|
||||
const RelaxType relax_type) const
|
||||
NewtonSolver<PhysicalModel>::stabilizeNewton(V& dx, V& dxOld, const double omega,
|
||||
const RelaxType relax_type) const
|
||||
{
|
||||
// The dxOld is updated with dx.
|
||||
// If omega is equal to 1., no relaxtion will be appiled.
|
@ -24,7 +24,7 @@
|
||||
#include <opm/core/utility/ErrorMacros.hpp>
|
||||
|
||||
#include <opm/autodiff/GeoProps.hpp>
|
||||
#include <opm/autodiff/FullyImplicitSolver.hpp>
|
||||
#include <opm/autodiff/NewtonSolver.hpp>
|
||||
#include <opm/autodiff/BlackoilModel.hpp>
|
||||
#include <opm/autodiff/BlackoilPropsAdInterface.hpp>
|
||||
#include <opm/autodiff/WellStateFullyImplicitBlackoil.hpp>
|
||||
@ -236,7 +236,7 @@ namespace Opm
|
||||
typedef BlackoilModel<Grid> Model;
|
||||
typedef typename Model::ModelParameter ModelParam;
|
||||
ModelParam modelParam( param_ );
|
||||
typedef FullyImplicitSolver<Model> Solver;
|
||||
typedef NewtonSolver<Model> Solver;
|
||||
typedef typename Solver::SolverParameter SolverParam;
|
||||
SolverParam solverParam( param_ );
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user