|
libstdc++
|
#include <random>
Classes | |
| struct | param_type |
Public Types | |
| typedef _RealType | result_type |
Friends | |
| template<typename _RealType1 , typename _CharT , typename _Traits > | |
| std::basic_ostream< _CharT, _Traits > & | operator<< (std::basic_ostream< _CharT, _Traits > &__os, const std::piecewise_constant_distribution< _RealType1 > &__x) |
| bool | operator== (const piecewise_constant_distribution &__d1, const piecewise_constant_distribution &__d2) |
| template<typename _RealType1 , typename _CharT , typename _Traits > | |
| std::basic_istream< _CharT, _Traits > & | operator>> (std::basic_istream< _CharT, _Traits > &__is, std::piecewise_constant_distribution< _RealType1 > &__x) |
A piecewise_constant_distribution random number distribution.
This distribution produces random numbers 

![\[
p(x | b_0, ..., b_n, \rho_0, ..., \rho_{n-1})
= \rho_i \cdot \frac{b_{i+1} - x}{b_{i+1} - b_i}
+ \rho_{i+1} \cdot \frac{ x - b_i}{b_{i+1} - b_i}
\]](form_32.png)
for 
| typedef _RealType std::piecewise_constant_distribution< _RealType >::result_type |
|
inline |
|
inline |
|
inline |
|
inline |
|
inlineexplicit |
|
inline |
|
inline |
|
inline |
|
inline |
Returns a vector of the probability densities.
Definition at line 5921 of file random.h.
References std::vector< _Tp, _Alloc >::empty().
|
inline |
Returns a vector of the intervals.
Definition at line 5905 of file random.h.
References std::vector< _Tp, _Alloc >::empty().
|
inline |
Returns the least upper bound value of the distribution.
Definition at line 5956 of file random.h.
References std::vector< _Tp, _Alloc >::back(), and std::vector< _Tp, _Alloc >::empty().
|
inline |
Returns the greatest lower bound value of the distribution.
Definition at line 5946 of file random.h.
References std::vector< _Tp, _Alloc >::empty(), and std::vector< _Tp, _Alloc >::front().
|
inline |
Generating functions.
Definition at line 5967 of file random.h.
References std::piecewise_constant_distribution< _RealType >::operator()().
Referenced by std::piecewise_constant_distribution< _RealType >::operator()().
| piecewise_constant_distribution< _RealType >::result_type std::piecewise_constant_distribution< _RealType >::operator() | ( | _UniformRandomNumberGenerator & | __urng, |
| const param_type & | __p | ||
| ) |
Definition at line 2914 of file bits/random.tcc.
|
inline |
|
inline |
|
inline |
|
friend |
Inserts a piecewise_constant_distribution random number distribution __x into the output stream __os.
| __os | An output stream. |
| __x | A piecewise_constant_distribution random number distribution. |
__x inserted or in an error state.
|
friend |
|
friend |
Extracts a piecewise_constant_distribution random number distribution __x from the input stream __is.
| __is | An input stream. |
| __x | A piecewise_constant_distribution random number generator engine. |
__x extracted or in an error state.