|
MCKL
Monte Carlo Kernel Library
|
Collision test. More...
#include <mckl/random/collision_test.hpp>
Inherits mckl::PoissonTest< CollisionTest< D, T > >.
Public Member Functions | |
| CollisionTest (std::size_t n) | |
| double | mean () const |
| template<typename DistributionType > | |
| std::size_t | operator() (DistributionType &&distribution) |
| template<typename RNGType , typename U01DistributionType > | |
| std::size_t | operator() (RNGType &rng, U01DistributionType &u01) |
Public Member Functions inherited from mckl::PoissonTest< CollisionTest< D, T > > | |
| double | cdf (result_type s) const |
| bool | pass (double alpha, result_type s) const |
| double | pdf (result_type s) const |
Additional Inherited Members | |
Public Types inherited from mckl::PoissonTest< CollisionTest< D, T > > | |
| using | result_type = std::size_t |
Collision test.
| D | Multiplier |
| T | Length of the tuple |
The implementation use the Poisson distribution approximation instead of the exact computation. This makes it faster and more easier to conduct some second-level tests. The approximation is only appropriate if \(n\) is large and the number of categories \(D^T\) is even larger.
Definition at line 53 of file collision_test.hpp.
|
inline |
Definition at line 60 of file collision_test.hpp.
|
inline |
Definition at line 87 of file collision_test.hpp.
|
inline |
Definition at line 66 of file collision_test.hpp.
|
inline |
Definition at line 69 of file collision_test.hpp.
1.8.13