adding a initialStep() function to SimulatorTimer

to indicate if the current step is the inital step.
This commit is contained in:
Kai Bao 2016-07-04 11:12:53 +02:00
parent b8ef9cb630
commit 02a3ba39b5
2 changed files with 9 additions and 0 deletions

View File

@ -63,6 +63,12 @@ namespace Opm
start_date_ = start_time.date();
}
/// Whether the current step is the first step.
bool SimulatorTimer::initialStep() const
{
return (current_step_ == 0);
}
/// Total number of steps.
int SimulatorTimer::numSteps() const
{

View File

@ -49,6 +49,9 @@ namespace Opm
/// Use the SimulatorTimer as a shim around opm-parser's Opm::TimeMap
void init(TimeMapConstPtr timeMap, size_t report_step = 0);
/// Whether the current step is the first step.
bool initialStep() const;
/// Total number of steps.
int numSteps() const;