Flow123d
JS_before_hm-1711-g43b724b37
|
Go to the documentation of this file.
108 OLD_ASSERT(dt > numeric_limits<double>::epsilon(),
"TimeMark's step less then machine precision.\n");
111 for (
unsigned int i = 0; i<=n_steps;i++) {
112 auto mark =
TimeMark(time+i*dt, type);
124 if (mark.match_mask(filter_type)) mark.add_to_type(add_type);
144 auto it =
last(time_step, mask);
146 else return this->
end(mask);
158 while ( ! tg.
step().
lt(first_ge->time()) || ! first_ge->match_mask(mask) ) {
160 if (first_ge ==
marks_[eq_index].
end()) { --first_ge;
break; }
171 while ( ! time_step.
ge(first_ge->time()) || ! first_ge->match_mask(mask) ) {
222 stream <<
"==============================" << endl;
223 stream <<
"time marks:" << endl;
224 for(
unsigned int i=0; i<marks.
marks_.size(); ++i) {
225 stream <<
"------------------------------" << endl;
226 stream <<
"equation_index: " << i << endl;
228 stream << *
it << endl;
230 stream <<
"==============================" << endl;
unsigned long int bitmap_
TimeMarks::iterator next(const TimeGovernor &tg, const TimeMark::Type &mask) const
TimeMarks::iterator current(const TimeStep &time_step, const TimeMark::Type &mask) const
TimeMark::Type new_mark_type()
Basic time management class.
TimeMark::Type type_balance_output_
Predefined type for balance output.
TimeMarks::iterator last(const TimeStep &time_step, const TimeMark::Type &mask) const
#define ASSERT(expr)
Allow use shorter versions of macro names if these names is not used with external library.
TimeMarks::iterator end(TimeMark::Type mask) const
Iterator for the end mimics container-like of TimeMarks.
Type mark_type() const
Getter for mark type.
ostream & operator<<(ostream &stream, const TimeMark &mark)
bool lt(double other_time) const
TimeMark::Type type_fixed_time_
Predefined type for fixed time.
TimeMarks::iterator begin(TimeMark::Type mask) const
Iterator for the begin mimics container-like of TimeMarks.
Class used for marking specified times at which some events occur.
static const double time_step_precision
TimeMark::Type type_output_
Predefined type for output.
Representation of one time step..
Basic time management functionality for unsteady (and steady) solvers (class Equation).
const TimeStep & step(int index=-1) const
unsigned char equation_index_
static const Type every_type
Mark Type with all bits set.
void add_to_type_all(TimeMark::Type filter_type, TimeMark::Type add_type)
TimeMark add(const TimeMark &mark)
static const Type none_type
Mark Type with all bits unset.
std::vector< std::vector< TimeMark > > marks_
TimeMarks list sorted according to the their time.
This class is a collection of time marks to manage various events occurring during simulation time.
Type mark_type_
The type of the TimeMark.
Global macros to enhance readability and debugging, general constants.
TimeMark::Type next_mark_type_
MarkType that will be used at next new_time_mark() call.
static const double inf_time
Infinity time used for steady case.
TimeMark::Type equation_mark_type() const
bool contains(double other_time) const
double time() const
Getter for the time of the TimeMark.
bool ge(double other_time) const
void add_time_marks(double time, double dt, double end_time, TimeMark::Type type)
IntFormatSpec< int, TypeSpec< 'x'> > hex(int value)
Iterator over TimeMark objects in TimeMarks object (database of TimeMark objects).
TimeMark::Type type_input_
Predefined type for change of boundary condition.