20 IT::Record(
"TimeGrid",
"Equally spaced grid of time points.")
23 "The start time of the grid.")
25 "The step of the grid. If not specified, the grid consists only of the start time.")
27 "The time greater or equal to the last time in the grid.")
41 double simulation_end_time = tg.
end_time();
44 double t_begin =
it->val<
double>(
"begin", initial_time);
45 double t_end =
it->val<
double>(
"end", simulation_end_time );
47 if (!
it->opt_val(
"step", t_step) ) {
51 if ( t_begin > t_end) {
52 WarningOut().fmt(
"Ignoring output time grid. Time begin {} > time end {}. {}",
53 t_begin, t_end,
it->address_string());
57 WarningOut().fmt(
"Ignoring output time grid. Time step {} < two times machine epsilon {}. {}",
62 this->
add(t_begin, t_step, t_end, mark_type);
75 auto mark =
TimeMark(time, output_mark_type);
77 times_.insert( mark_time );
91 for(
unsigned int i = 0; i <= n_steps; i++) {
92 auto mark =
TimeMark(begin + i * step, output_mark_type);
double end_time() const
End time.
#define ASSERT_GE(a, b)
Definition of comparative assert macro (Greater or Equal)
TimeMark::Type type_output()
void read_from_input(Input::Array in_array, const TimeGovernor &tg)
#define ASSERT_LE(a, b)
Definition of comparative assert macro (Less or Equal)
bool contains(TimeMark mark) const
Basic time management functionality for unsteady (and steady) solvers (class Equation).
static TimeMarks & marks()
Basic time management class.
std::set< double > times_
static const double time_step_precision
TimeMark::Type equation_fixed_mark_type() const
TimeMark add(const TimeMark &mark)
#define ASSERT_LT(a, b)
Definition of comparative assert macro (Less Than)
static const Input::Type::Array get_input_type()
double time() const
Getter for the time of the TimeMark.
#define WarningOut()
Macro defining 'warning' record of log.
Class used for marking specified times at which some events occur.
static const double inf_time
Infinity time used for steady case.
void add(double begin, TimeMark::Type mark_type)