std::negative_binomial_distribution(3)

NAME
std::negative_binomial_distribution - A negative_binomial_distribution random number distribution.

SYNOPSIS

  Classes
struct param_type

  Public Types
typedef _IntType result_type

  Public Member Functions
_IntType k () const
result_type max () const
result_type min () const
negative_binomial_distribution (const param_type &__p)
negative_binomial_distribution (_IntType __k=1, double __p=0.5)
template<typename _UniformRandomNumberGenerator > result_type operator() (_UniformRandomNumberGenerator &__urng, const param_type &__p)
template<typename _UniformRandomNumberGenerator > result_type operator() (_UniformRandomNumberGenerator &__urng)
double p () const
void param (const param_type &__param)
param_type param () const
void reset ()

Detailed Description

  template<typename _IntType = int> class std::negative_binomial_distribution< _IntType >
A negative_binomial_distribution random number distribution. The formula for the negative binomial probability mass function is $ p(i) = n} p^i (1 - p)^{t - i} $ where $ t $ and $ p $ are the parameters of the distribution.

Definition at line 3355 of file bits/random.h.

Member Typedef Documentation

  template<typename _IntType = int> typedef _IntType std::negative_binomial_distribution< _IntType >::result_type

The type of the range of the distribution.

Definition at line 3361 of file bits/random.h.

Member Function Documentation

  template<typename _IntType = int> _IntType std::negative_binomial_distribution< _IntType >::k () const [inline]

Return the $ k $ parameter of the distribution.

Definition at line 3410 of file bits/random.h.

References std::negative_binomial_distribution< _IntType >::negative_binomial_distribution::param_type::k().

  template<typename _IntType = int> result_type std::negative_binomial_distribution< _IntType >::max () const [inline]

Returns the least upper bound value of the distribution.

Definition at line 3446 of file bits/random.h.

  template<typename _IntType = int> result_type std::negative_binomial_distribution< _IntType >::min () const [inline]

Returns the greatest lower bound value of the distribution.

Definition at line 3439 of file bits/random.h.

  template<typename _IntType = int> double std::negative_binomial_distribution< _IntType >::p () const [inline]

Return the $ p $ parameter of the distribution.

Definition at line 3417 of file bits/random.h.

References std::negative_binomial_distribution< _IntType >::negative_binomial_distribution::param_type::p().

  template<typename _IntType = int> void std::negative_binomial_distribution< _IntType >::param (const param_type & __param) [inline]

Sets the parameter set of the distribution.

Parameters:
    __param The new parameter set of the distribution.

Definition at line 3432 of file bits/random.h.

  template<typename _IntType = int> param_type std::negative_binomial_distribution< _IntType >::param () const [inline]

Returns the parameter set of the distribution.

Definition at line 3424 of file bits/random.h.

Referenced by std::operator==(), and std::operator>>().

  template<typename _IntType = int> void std::negative_binomial_distribution< _IntType >::reset () [inline]

Resets the distribution state.

Definition at line 3403 of file bits/random.h.

Author

Generated automatically by Doxygen for libstdc++ from the source code.