32 #ifndef LSST_AFW_MATH_RANDOM_H
33 #define LSST_AFW_MATH_RANDOM_H
35 #include "boost/shared_ptr.hpp"
37 #include "gsl/gsl_rng.h"
43 namespace lsst {
namespace afw {
namespace math {
99 explicit Random(std::string
const & algorithm,
unsigned long seed = 1);
134 double flat(
double const a,
double const b);
136 double chisq(
double const nu);
137 double poisson(
double const nu);
140 boost::shared_ptr< ::gsl_rng>
_rng;
157 template<
typename ImageT>
160 template<
typename ImageT>
163 template<
typename ImageT>
166 template<
typename ImageT>
169 template<
typename ImageT>
172 template<
typename ImageT>
175 template<
typename ImageT>
181 #endif // LSST_AFW_MATH_RANDOM_H
void randomUniformImage(ImageT *image, Random &rand)
std::string getAlgorithmName() const
static char const *const _seedEnvVarName
Algorithm getAlgorithm() const
double chisq(double const nu)
unsigned long getSeed() const
double flat(double const a, double const b)
std::size_t getStateSize() const
boost::shared_ptr< Policy > Ptr
::gsl_rng_type const *const _gslRngTypes[NUM_ALGORITHMS]
void randomFlatImage(ImageT *image, Random &rand, double const a, double const b)
double poisson(double const nu)
table::Key< table::Array< Kernel::Pixel > > image
void randomUniformPosImage(ImageT *image, Random &rand)
void randomChisqImage(ImageT *image, Random &rand, double const nu)
Random(Algorithm algorithm=MT19937, unsigned long seed=1)
unsigned long uniformInt(unsigned long n)
static char const *const _algorithmEnvVarName
void randomGaussianImage(ImageT *image, Random &rand)
void setState(State const &state)
void randomUniformIntImage(ImageT *image, Random &rand, unsigned long n)
static std::vector< std::string > const & getAlgorithmNames()
void randomPoissonImage(ImageT *image, Random &rand, double const mu)
static char const *const _algorithmNames[NUM_ALGORITHMS]
afw::table::Key< double > b
Include files required for standard LSST Exception handling.
boost::shared_ptr< ::gsl_rng > _rng