Base class for generating pseudo-random noise for simulating the Process.
More...
#include <noise.hpp>
Base class for generating pseudo-random noise for simulating the Process.
The class Noise serves as base class for generating pseudo-random noise for simulating the Process within the SimulationEnvironment.
- Author
- Hans Joachim Ferreau, Boris Houska
Definition at line 56 of file noise.hpp.
Default constructor.
Definition at line 40 of file noise.cpp.
Noise::Noise |
( |
const Noise & |
rhs | ) |
|
Copy constructor (deep copy).
@param[in] rhs Right-hand side object.
Definition at line 45 of file noise.cpp.
virtual Noise* Noise::clone |
( |
| ) |
const |
|
pure virtual |
virtual Noise* Noise::clone |
( |
uint |
idx | ) |
const |
|
pure virtual |
Clone constructor for a given noise component (deep copy).
@param[in] idx Right-hand side object.
\return Pointer to deep copy of base class type
Implemented in GaussianNoise, UniformNoise, and ColoredNoise.
uint Noise::getDim |
( |
| ) |
const |
|
inline |
Returns dimension of noise vector.
- Returns
- Dimension of noise vector
Returns current status of noise block, see documentation of BlockStatus for details.
- Returns
- Current status of noise block
double Noise::getUniformRandomNumber |
( |
double |
_lowerLimit, |
|
|
double |
_upperLimit |
|
) |
| const |
|
inlineprotected |
Returns a pseudo-random number based on a uniform distribution with given lower and upper limits.
- Parameters
-
[in] | _lowerLimit | Lower limit of random variable. |
[in] | _upperLimit | Lower limit of random variable. |
- Returns
- Uniformly distributed pseudo-random number
Initializes noise generation and performs a couple of consistency checks. Initialization of the pseudo-random number generator can be based on a seed in order to allow exact reproduction of generated noise. If seed is not specified (i.e. 0), a seed is obtain from the system clock.
- Parameters
-
[in] | seed | Seed for pseudo-random number generator. |
- Returns
- SUCCESSFUL_RETURN,
RET_INVALID_NOISE_SETTINGS,
RET_NO_NOISE_SETTINGS
Implemented in GaussianNoise, UniformNoise, and ColoredNoise.
Returns whether noise vector is empty (i.e. has dimension zero).
- Returns
- BT_TRUE iff noise vector is empty,
BT_FALSE otherwise
Assignment Operator (deep copy)
@param[in] rhs Right-hand side object.
Definition at line 56 of file noise.cpp.
Assigns new status to noise block
@param[in] _status New status.
- Returns
- SUCCESSFUL_RETURN
Generates a single noise vector based on current internal settings.
@param[out] _w Generated noise vector.
- Returns
- SUCCESSFUL_RETURN,
RET_BLOCK_NOT_READY,
RET_VECTOR_DIMENSION_MISMATCH
Implemented in GaussianNoise, UniformNoise, and ColoredNoise.
Generates a noise vector sequence based on current internal settings. Noise is generated for each grid point of the VariablesGrid passed.
- Parameters
-
[in,out] | _w | Generated noise vector sequence. |
- Returns
- SUCCESSFUL_RETURN,
RET_BLOCK_NOT_READY,
RET_VECTOR_DIMENSION_MISMATCH
Implemented in GaussianNoise, UniformNoise, and ColoredNoise.
Current status of the noise.
Definition at line 192 of file noise.hpp.
Sequence of most recently generated noise.
Definition at line 194 of file noise.hpp.
The documentation for this class was generated from the following files: