Class extending LinearVoidStepLoop to support main simulation loop.
More...
#include <SimulationStepLoop.h>
|
DiscreteTime | dt |
| The discrete time object to handle simulation frequency and time.
|
|
std::function< void(StepInput ...)> | f |
| The function to be invoked when computation region function has been reached.
|
|
int | stepInterval |
| Specify how many simulation steps must elapse so the step loop enters its computation region. More...
|
|
int | currentStep |
| Stores the current step. More...
|
|
Class extending LinearVoidStepLoop to support main simulation loop.
- Author
- Alberto M. Esmoris Pena
- Version
- 1.0
- See also
- LinearVoidStepLoop
-
StepLoop
-
DiscreteTime
◆ SimulationStepLoop()
SimulationStepLoop::SimulationStepLoop |
( |
std::function< void(void)> |
f | ) |
|
|
inline |
Main constructor for simulation step loop.
- Parameters
-
f | The function to compute simulation steps |
◆ getCurrentTime()
double SimulationStepLoop::getCurrentTime |
( |
| ) |
const |
|
inline |
Obtain the virtual time (simulation time) that elapsed to reach current step.
- Returns
- Virtual time (simulation time) that elapsed to reach current step
◆ getFrequency()
std::size_t SimulationStepLoop::getFrequency |
( |
| ) |
const |
|
inline |
- See also
- DiscreteTime::getFrequency
◆ getPeriod()
double SimulationStepLoop::getPeriod |
( |
| ) |
const |
|
inline |
- See also
- DiscreteTime::getPeriod
◆ getPeriodScale()
double SimulationStepLoop::getPeriodScale |
( |
| ) |
const |
|
inline |
- See also
- DiscreteTime::getPeriodScale
◆ setFrequency()
void SimulationStepLoop::setFrequency |
( |
std::size_t const |
frequency | ) |
|
|
inline |
- See also
- DiscreteTime::setFrequency
◆ setPeriodScale()
void SimulationStepLoop::setPeriodScale |
( |
double const |
periodScale | ) |
|
|
inline |
- See also
- DiscreteTime::setPeriodScale
The documentation for this class was generated from the following file: