Class template negative_binomial_distribution
boost::random::negative_binomial_distribution
 
Synopsis
template<typename IntType = int, typename RealType = double> 
class negative_binomial_distribution {
public:
  
  typedef IntType  result_type;
  typedef RealType input_type; 
  
  class param_type {
  public:
    
    typedef negative_binomial_distribution distribution_type;
    
    explicit param_type(IntType = 1, RealType = 0.5);
    
    IntType k() const;
    RealType p() const;
    
    template<typename CharT, typename Traits> 
      friend std::basic_ostream< CharT, Traits > & 
      operator<<(std::basic_ostream< CharT, Traits > &, const param_type &);
    template<typename CharT, typename Traits> 
      friend std::basic_istream< CharT, Traits > & 
      operator>>(std::basic_istream< CharT, Traits > &, param_type &);
    friend bool operator==(const param_type &, const param_type &);
    friend bool operator!=(const param_type &, const param_type &);
  };
  
  explicit negative_binomial_distribution(IntType = 1, RealType = 0.5);
  explicit negative_binomial_distribution(const param_type &);
  
  template<typename URNG> IntType operator()(URNG &) const;
  template<typename URNG> IntType operator()(URNG &, const param_type &) const;
  IntType k() const;
  RealType p() const;
  IntType min() const;
  IntType max() const;
  param_type param() const;
  void param(const param_type &);
  void reset();
  
  template<typename CharT, typename Traits> 
    friend std::basic_ostream< CharT, Traits > & 
    operator<<(std::basic_ostream< CharT, Traits > &, 
               const negative_binomial_distribution &);
  template<typename CharT, typename Traits> 
    friend std::basic_istream< CharT, Traits > & 
    operator>>(std::basic_istream< CharT, Traits > &, 
               negative_binomial_distribution &);
  friend bool operator==(const negative_binomial_distribution &, 
                         const negative_binomial_distribution &);
  friend bool operator!=(const negative_binomial_distribution &, 
                         const negative_binomial_distribution &);
};
Description
Негативное биномиальное распределение представляет собой целое ценное распределение с двумя параметрами: k и p. Распределение производит неотрицательные значения.
Функция распределения  .
.
Эта реализация использует смесь гамма-поиссона.
negative_binomial_distribution 
        public
       construct/copy/destruct
- explicit >отрицательный_binomial_ Distribution(IntType k = 1, RealType 0>>5>>>>>>32>Построить - 333>>>>
 
- explicit отрицательный_binomial_ Distribution(const param_type & param); - Конструировать - отрицательный_binomial_ Distribution
 
 
negative_binomial_distribution public member functions
- template<typename URNG> IntType оператор()(URNG & urng  const; - Вариации вариатриум по распределенному отрицательному.  
-   > ,>> >>>>> & , >2>> парам_тип> Номин>>>> 
- IntType k() const; -  Возвращает параметр - kраспространения.
 
- RealType p() const; -  Возвращает параметр - pраспространения.
 
- IntType min() const; -  Возвращает наименьшее значение, которое может произвести дистрибутив.  
- IntType max() const; - Returns the largest value that the distribution can produce.  
- param_type param() const; -   
- void param(const param_type & param); -  Параметры распределения.  
- void перезагрузка(); - Эффекты: последующее использование дистрибутива не зависит от значений, произведенных любым двигателем до ссылки на сброс.  
 
negative_binomial_distribution friend functions