saturate

class Saturate
#include <saturate.h>

This class is used to saturate an output variable.

Public Functions

Saturate()

The constructor initialies the random number generator used for the walks

Saturate(int64_t size)

class constructor

~Saturate()

The destructor is a placeholder for one that might do something

void setBounds(const Eigen::Ref<const Eigen::MatrixX2d> &bounds)

Set lower and upper bounds for each state.

Set the lower and upper bounds for each state.

Parameters:

bounds – One row per state, with lower and upper bounds in the two columns.

Eigen::VectorXd saturate(const Eigen::Ref<const Eigen::VectorXd> &unsaturatedStates)

Saturate the given states.

Saturate an output vector using the configured bounds.

Parameters:

unsaturatedStates – Vector of unsaturated states.

Returns:

Vector of saturated states.

Private Members

int64_t numStates

&#8212; Number of states to generate noise for

Eigen::MatrixX2d stateBounds

&#8212; one row for each state. lower bounds in left column, upper in right column