BioCMAMC-ST
simulation_times.hpp
1#ifndef __SIMULATION_TIMES_HPP__
2#define __SIMULATION_TIMES_HPP__
3
4namespace Simulation
5{
7 {
8 // t0 is 0 if new simulation or non zero for loaded simulation
9 double starting_time{ 0. };
10
11 // current relative simulation time
12 double relative_time{ 0. };
13
14 inline void
15 advance(const double dt)
16 {
17 relative_time += dt;
18 }
19
20 [[nodiscard]] inline double
21 relative() const
22 {
23 return relative_time;
24 }
25
26 [[nodiscard]] inline double
27 absolute() const
28 {
30 }
31 };
32} // namespace Simulation
33
34#endif
Namespace that contains classes and structures related to simulation handling.
Definition host_specific.hpp:12
Definition simulation_times.hpp:7
double relative_time
Definition simulation_times.hpp:12
double starting_time
Definition simulation_times.hpp:9
double absolute() const
Definition simulation_times.hpp:27
void advance(const double dt)
Definition simulation_times.hpp:15
double relative() const
Definition simulation_times.hpp:21