#include <TimeStepControl.hpp>

Inheritance diagram for Opm::HardcodedTimeStepControl:
Inheritance graph

Public Member Functions

 HardcodedTimeStepControl ()=default
 
 HardcodedTimeStepControl (const std::string &filename)
 constructor More...
 
double computeTimeStepSize (const double dt, const int, const RelativeChangeInterface &, const AdaptiveSimulatorTimer &substepTimer) const override
 
bool timeStepAccepted (const double, const double) const override
 
template<class Serializer >
void serializeOp (Serializer &serializer)
 
bool operator== (const HardcodedTimeStepControl &) const
 

Static Public Member Functions

static HardcodedTimeStepControl serializationTestObject ()
 

Static Public Attributes

static constexpr TimeStepControlType Type = TimeStepControlType::HardCodedTimeStep
 

Protected Attributes

std::vector< double > subStepTime_
 

Detailed Description

HardcodedTimeStepControl Input generated from summary file using the ert application:

ecl_summary DECK TIME > filename

Assumes time is given in days

Constructor & Destructor Documentation

◆ HardcodedTimeStepControl() [1/2]

Opm::HardcodedTimeStepControl::HardcodedTimeStepControl ( )
default

◆ HardcodedTimeStepControl() [2/2]

Opm::HardcodedTimeStepControl::HardcodedTimeStepControl ( const std::string &  filename)
explicit

constructor

Parameters
filenamefilename contaning the timesteps

Member Function Documentation

◆ computeTimeStepSize()

double Opm::HardcodedTimeStepControl::computeTimeStepSize ( const double  dt,
const int  ,
const RelativeChangeInterface ,
const AdaptiveSimulatorTimer substepTimer 
) const
overridevirtual

compute new time step size suggestions based on the PID controller

Parameters
dttime step size used in the current step
iterationsnumber of iterations used (linear/nonlinear)
timeErrorobject to compute || u^n+1 - u^n || / || u^n+1 ||
Returns
suggested time step size for the next step

Implements Opm::TimeStepControlInterface.

◆ operator==()

bool Opm::HardcodedTimeStepControl::operator== ( const HardcodedTimeStepControl ) const

◆ serializationTestObject()

static HardcodedTimeStepControl Opm::HardcodedTimeStepControl::serializationTestObject ( )
static

◆ serializeOp()

template<class Serializer >
void Opm::HardcodedTimeStepControl::serializeOp ( Serializer &  serializer)
inline

References subStepTime_.

◆ timeStepAccepted()

bool Opm::HardcodedTimeStepControl::timeStepAccepted ( const double  error,
const double  timeStepJustCompleted 
) const
inlineoverridevirtual

For the general 3rd order controller, the internal shifting of errors and time steps happens here, and hence this method needs to be called for (after) each time step

Implements Opm::TimeStepControlInterface.

Member Data Documentation

◆ subStepTime_

std::vector<double> Opm::HardcodedTimeStepControl::subStepTime_
protected

Referenced by serializeOp().

◆ Type

constexpr TimeStepControlType Opm::HardcodedTimeStepControl::Type = TimeStepControlType::HardCodedTimeStep
staticconstexpr

The documentation for this class was generated from the following file: