3 #ifndef ROBOWFLEX_RANDOM_
4 #define ROBOWFLEX_RANDOM_
20 void setSeed(
unsigned int seed);
32 double uniformReal(
double lower_bound,
double upper_bound);
39 int uniformInt(
int lower_bound,
int upper_bound);
57 double gaussian(
double mean,
double stddev);
72 Eigen::Vector3d
uniformRPY(
const Eigen::Vector3d &lbound,
const Eigen::Vector3d &ubound);
79 Eigen::Vector3d
uniformRPY(
const Eigen::Vector3d &bounds);
92 Eigen::Vector3d
uniformVec(
const Eigen::Vector3d &lbound,
const Eigen::Vector3d &ubound);
98 Eigen::Vector3d
uniformVec(
const Eigen::Vector3d &bounds);
106 Eigen::Vector3d
gaussianVec(
const Eigen::Vector3d &mean,
const Eigen::Vector3d &stddev);
113 Eigen::Vector3d
gaussianVec(
const Eigen::Vector3d &stddev);
120 template <
typename Iter>
131 template <
typename Type>
double uniformReal(double lower_bound, double upper_bound)
Generate a random real within given bounds: [lower_bound, upper_bound)
double uniform01()
Generate a random real in [0,1).
double gaussian(double mean, double stddev)
Generate a random real using a normal distribution with given mean and standard deviation.
bool uniformBool()
Generate a random boolean.
Eigen::Vector3d uniformRPY(const Eigen::Vector3d &lbound, const Eigen::Vector3d &ubound)
Uniform random sampling of Euler roll-pitch-yaw angles within lower bound lbound and upper bound ubou...
Iter uniformSample(Iter start, Iter end)
Choose a random element between start and end.
Eigen::Vector3d unifromRPY()
Uniform random sampling of Euler roll-pitch-yaw angles, roll, yaw in range [-pi, pi) and pitch in ran...
int uniformInt(int lower_bound, int upper_bound)
Generate a random integer within given bounds: [lower_bound, upper_bound)
void setSeed(unsigned int seed)
Set the random seed of the underlying generator.
Eigen::Vector3d uniformVec(const Eigen::Vector3d &lbound, const Eigen::Vector3d &ubound)
Generate a uniform real vector within given bounds: [lower_bound, upper_bound)
Eigen::Vector3d gaussianVec(const Eigen::Vector3d &mean, const Eigen::Vector3d &stddev)
Generate a random real vector using a normal distribution with given mean and standard deviation.
Main namespace. Contains all library classes and functions.