19#include <boost/random/mersenne_twister.hpp>
20#include <boost/random/variate_generator.hpp>
24#if BOOST_VERSION == 106400
25# include <boost/serialization/array_wrapper.hpp>
46 typedef boost::mt19937 base_generator_type;
47 typedef base_generator_type::result_type poisson_result_type;
54 void seed(
unsigned int);
59 template <
int num_dimensions,
class elemTout,
class elemTin>
65 std::bind(generate_scaled_poisson_random, std::placeholders::_1, this->scaling_factor, this->preserve_mean));
71 static base_generator_type generator;
72 const float scaling_factor;
73 const bool preserve_mean;
75 static unsigned int generate_poisson_random(
const float mu);
76 static float generate_scaled_poisson_random(
const float mu,
const float scaling_factor,
const bool preserve_mean);
Declaration of class stir::ProjData.
This class defines multi-dimensional (numeric) arrays.
Definition Array.h:78
full_iterator begin_all()
start value for iterating through all elements in the array, see full_iterator
Definition Array.inl:213
full_iterator end_all()
end value for iterating through all elements in the array, see full_iterator
Definition Array.inl:185
void seed(unsigned int)
The seed value for the random number generator.
Definition GeneralisedPoissonNoiseGenerator.cxx:42
GeneralisedPoissonNoiseGenerator(const float scaling_factor=1.0F, const bool preserve_mean=false)
Constructor intialises the andom number generator with a fixed seed.
Definition GeneralisedPoissonNoiseGenerator.cxx:34
float generate_random(const float mu)
generate a random number according to a distribution with mean mu
Definition GeneralisedPoissonNoiseGenerator.cxx:107
The (abstract) base class for the projection data.
Definition ProjData.h:105