From Jason Turner

[rand.dist.bern]

Diff to HTML by rtfpessoa

tmp/tmp36dfczxz/{from.md → to.md} RENAMED
@@ -1,15 +1,11 @@
1
  #### Bernoulli distributions <a id="rand.dist.bern">[[rand.dist.bern]]</a>
2
 
3
  ##### Class `bernoulli_distribution` <a id="rand.dist.bern.bernoulli">[[rand.dist.bern.bernoulli]]</a>
4
 
5
  A `bernoulli_distribution` random number distribution produces `bool`
6
- values b distributed according to the discrete probability function
7
- $$P(b\,|\,p) = \left\{ \begin{array}{ll}
8
- p & \text{ if $b = \tcode{true}$, or} \\
9
- 1 - p & \text{ if $b = \tcode{false}$.}
10
- \end{array}\right.$$
11
 
12
  ``` cpp
13
  namespace std {
14
  class bernoulli_distribution {
15
  public:
@@ -67,11 +63,11 @@ constructed.
67
 
68
  ##### Class template `binomial_distribution` <a id="rand.dist.bern.bin">[[rand.dist.bern.bin]]</a>
69
 
70
  A `binomial_distribution` random number distribution produces integer
71
  values i ≥ 0 distributed according to the discrete probability function
72
- $$P(i\,|\,t,p) = \binom{t}{i} \cdot p^i \cdot (1-p)^{t-i} \text{ .}$$
73
 
74
  ``` cpp
75
  namespace std {
76
  template<class IntType = int>
77
  class binomial_distribution {
@@ -139,11 +135,11 @@ constructed.
139
 
140
  ##### Class template `geometric_distribution` <a id="rand.dist.bern.geo">[[rand.dist.bern.geo]]</a>
141
 
142
  A `geometric_distribution` random number distribution produces integer
143
  values i ≥ 0 distributed according to the discrete probability function
144
- $$P(i\,|\,p) = p \cdot (1-p)^{i} \text{ .}$$
145
 
146
  ``` cpp
147
  namespace std {
148
  template<class IntType = int>
149
  class geometric_distribution {
@@ -202,12 +198,11 @@ constructed.
202
 
203
  ##### Class template `negative_binomial_distribution` <a id="rand.dist.bern.negbin">[[rand.dist.bern.negbin]]</a>
204
 
205
  A `negative_binomial_distribution` random number distribution produces
206
  random integers i ≥ 0 distributed according to the discrete probability
207
- function
208
- $$P(i\,|\,k,p) = \binom{k+i-1}{i} \cdot p^k \cdot (1-p)^i \text{ .}$$
209
 
210
  [*Note 1*: This implies that P(i | k,p) is undefined when
211
  `p == 1`. — *end note*]
212
 
213
  ``` cpp
 
1
  #### Bernoulli distributions <a id="rand.dist.bern">[[rand.dist.bern]]</a>
2
 
3
  ##### Class `bernoulli_distribution` <a id="rand.dist.bern.bernoulli">[[rand.dist.bern.bernoulli]]</a>
4
 
5
  A `bernoulli_distribution` random number distribution produces `bool`
6
+ values b distributed according to the discrete probability function in .
 
 
 
 
7
 
8
  ``` cpp
9
  namespace std {
10
  class bernoulli_distribution {
11
  public:
 
63
 
64
  ##### Class template `binomial_distribution` <a id="rand.dist.bern.bin">[[rand.dist.bern.bin]]</a>
65
 
66
  A `binomial_distribution` random number distribution produces integer
67
  values i ≥ 0 distributed according to the discrete probability function
68
+ in .
69
 
70
  ``` cpp
71
  namespace std {
72
  template<class IntType = int>
73
  class binomial_distribution {
 
135
 
136
  ##### Class template `geometric_distribution` <a id="rand.dist.bern.geo">[[rand.dist.bern.geo]]</a>
137
 
138
  A `geometric_distribution` random number distribution produces integer
139
  values i ≥ 0 distributed according to the discrete probability function
140
+ in .
141
 
142
  ``` cpp
143
  namespace std {
144
  template<class IntType = int>
145
  class geometric_distribution {
 
198
 
199
  ##### Class template `negative_binomial_distribution` <a id="rand.dist.bern.negbin">[[rand.dist.bern.negbin]]</a>
200
 
201
  A `negative_binomial_distribution` random number distribution produces
202
  random integers i ≥ 0 distributed according to the discrete probability
203
+ function in .
 
204
 
205
  [*Note 1*: This implies that P(i | k,p) is undefined when
206
  `p == 1`. — *end note*]
207
 
208
  ``` cpp