EigenRand  0.5.0
 
Loading...
Searching...
No Matches
Eigen::Rand::BinomialGen< _Scalar > Class Template Reference

Generator of integers on a binomial distribution. More...

#include <Discrete.h>

Inheritance diagram for Eigen::Rand::BinomialGen< _Scalar >:
Collaboration diagram for Eigen::Rand::BinomialGen< _Scalar >:

Public Types

using Scalar = _Scalar
 

Public Member Functions

 BinomialGen (_Scalar _trials=1, double _p=0.5)
 Construct a new Binomial Generator. More...
 
 BinomialGen (const BinomialGen &)=default
 
 BinomialGen (BinomialGen &&)=default
 
BinomialGenoperator= (const BinomialGen &)=default
 
BinomialGenoperator= (BinomialGen &&)=default
 
template<typename Rng >
EIGEN_STRONG_INLINE const _Scalar operator() (Rng &&rng)
 
template<typename Packet , typename Rng >
EIGEN_STRONG_INLINE const Packet packetOp (Rng &&rng)
 
- Public Member Functions inherited from Eigen::Rand::GenBase< BinomialGen< _Scalar >, _Scalar >
const CwiseNullaryOp< internal::scalar_rng_adaptor< BinomialGen< _Scalar > &, _Scalar, Urng >, const Derived > generate (Index rows, Index cols, Urng &&urng)
 generate random values from its distribution More...
 
const CwiseNullaryOp< internal::scalar_rng_adaptor< BinomialGen< _Scalar > &, _Scalar, Urng >, const Derived > generateLike (const Derived &o, Urng &&urng)
 generate random values from its distribution More...
 

Detailed Description

template<typename _Scalar>
class Eigen::Rand::BinomialGen< _Scalar >

Generator of integers on a binomial distribution.

Template Parameters
_Scalar

Constructor & Destructor Documentation

◆ BinomialGen()

template<typename _Scalar >
Eigen::Rand::BinomialGen< _Scalar >::BinomialGen ( _Scalar  _trials = 1,
double  _p = 0.5 
)
inline

Construct a new Binomial Generator.

Parameters
_trialsthe number of trials
_pprobability of a trial generating true

The documentation for this class was generated from the following file: