|
libcrn
3.9.5
A document image processing library
|
Univariate random toolbox class. More...
Functions | |
| std::vector< double > | NewUniformSample (size_t n=1, bool reseed=true) |
| Creates a data sample following an uniform probability law. More... | |
| std::vector< double > | NewGaussianSample (double mu=0.0, double sigma=1.0, size_t n=1, size_t m=100, bool reseed=true) |
| Creates a data sample following a Gaussian probability law. More... | |
| std::vector< double > | NewGaussianMixtureSample (const UnivariateGaussianMixture &Mx, size_t n=1, size_t m=100, bool reseed=true) |
| Creates a data sample following a Gaussian probability law. More... | |
Univariate random toolbox class.
Tools for random samples
| std::vector< double > crn::UnivariateRandomTools::NewGaussianMixtureSample | ( | const UnivariateGaussianMixture & | Mx, |
| size_t | n = 1, |
||
| size_t | m = 100, |
||
| bool | reseed = true |
||
| ) |
Creates a data sample following a Gaussian probability law.
Simulate a gaussian mixture random sample
| [in] | Mx | UnivariateGaussianMixture* |
| [in] | n | size of gaussian sample (default = 1) |
| [in] | m | size of temporary uniform sample (default = 100) |
| [in] | reseed | shall the random seed be reinitialized? |
Definition at line 103 of file CRNUnivariateRandomTools.cpp.
| std::vector< double > crn::UnivariateRandomTools::NewGaussianSample | ( | double | mu = 0.0, |
| double | sigma = 1.0, |
||
| size_t | n = 1, |
||
| size_t | m = 100, |
||
| bool | reseed = true |
||
| ) |
Creates a data sample following a Gaussian probability law.
Simulate a gaussian random sample
With default values mu = 0 and sigma = 1, we obtain the normal random sample
| [in] | mu | mean of gaussian distribution (default = 0) |
| [in] | sigma | deviation of gaussian distribution (default = 1) |
| [in] | n | size of gaussian sample (default = 1) |
| [in] | m | size of temporary uniform sample (default = 100) |
| [in] | reseed | shall the random seed be reinitialized? |
Definition at line 65 of file CRNUnivariateRandomTools.cpp.
| std::vector< double > crn::UnivariateRandomTools::NewUniformSample | ( | size_t | n = 1, |
| bool | reseed = true |
||
| ) |
Creates a data sample following an uniform probability law.
Simulate a uniform random sample in [0;1]
| [in] | n | size of sample |
| [in] | reseed | shall the random seed be reinitialized? |
Definition at line 38 of file CRNUnivariateRandomTools.cpp.
1.8.6