UniformRNG.h
Go to the documentation of this file.00001 #ifndef CUNIFORMRNG_H
00002 #define CUNIFORMRNG_H
00003
00004 #include "GeneralRNG.h"
00005 #include <boost/random/lagged_fibonacci.hpp>
00006 #include <boost/random/uniform_01.hpp>
00007
00008 namespace gplib
00009 {
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019 class UniformRNG: public GeneralRNG
00020 {
00021 private:
00022 boost::lagged_fibonacci607 generator;
00023 boost::uniform_01<boost::lagged_fibonacci607> real_dist;
00024 public:
00025
00026 float GetNumber(const float low, const float high);
00027
00028 virtual float GetNumber();
00029
00030 virtual unsigned int GetNumber(const unsigned int max);
00031 UniformRNG();
00032 virtual ~UniformRNG();
00033 };
00034
00035 }
00036 #endif // CUNIFORMRNG_H