tmp/tmp07knxif1/{from.md → to.md}
RENAMED
|
@@ -1,26 +1,25 @@
|
|
| 1 |
##### Class template `weibull_distribution` <a id="rand.dist.pois.weibull">[[rand.dist.pois.weibull]]</a>
|
| 2 |
|
| 3 |
A `weibull_distribution` random number distribution produces random
|
| 4 |
numbers x ≥ 0 distributed according to the probability density function
|
| 5 |
-
$$
|
| 6 |
-
p(x\,|\,a,b)
|
| 7 |
-
= \frac{a}{b}
|
| 8 |
\cdot \left(\frac{x}{b}\right)^{a-1}
|
| 9 |
\cdot \, \exp\left( -\left(\frac{x}{b}\right)^a\right)
|
| 10 |
-
\
|
| 11 |
|
| 12 |
``` cpp
|
| 13 |
template<class RealType = double>
|
| 14 |
class weibull_distribution {
|
| 15 |
public:
|
| 16 |
// types
|
| 17 |
using result_type = RealType;
|
| 18 |
using param_type = unspecified;
|
| 19 |
|
| 20 |
// constructor and reset functions
|
| 21 |
-
|
|
|
|
| 22 |
explicit weibull_distribution(const param_type& parm);
|
| 23 |
void reset();
|
| 24 |
|
| 25 |
// generating functions
|
| 26 |
template<class URBG>
|
|
@@ -37,17 +36,17 @@ template<class RealType = double>
|
|
| 37 |
result_type max() const;
|
| 38 |
};
|
| 39 |
```
|
| 40 |
|
| 41 |
``` cpp
|
| 42 |
-
explicit weibull_distribution(RealType a
|
| 43 |
```
|
| 44 |
|
| 45 |
-
*
|
| 46 |
|
| 47 |
-
*
|
| 48 |
-
|
| 49 |
|
| 50 |
``` cpp
|
| 51 |
RealType a() const;
|
| 52 |
```
|
| 53 |
|
|
|
|
| 1 |
##### Class template `weibull_distribution` <a id="rand.dist.pois.weibull">[[rand.dist.pois.weibull]]</a>
|
| 2 |
|
| 3 |
A `weibull_distribution` random number distribution produces random
|
| 4 |
numbers x ≥ 0 distributed according to the probability density function
|
| 5 |
+
$$p(x\,|\,a,b) = \frac{a}{b}
|
|
|
|
|
|
|
| 6 |
\cdot \left(\frac{x}{b}\right)^{a-1}
|
| 7 |
\cdot \, \exp\left( -\left(\frac{x}{b}\right)^a\right)
|
| 8 |
+
\text{ .}$$
|
| 9 |
|
| 10 |
``` cpp
|
| 11 |
template<class RealType = double>
|
| 12 |
class weibull_distribution {
|
| 13 |
public:
|
| 14 |
// types
|
| 15 |
using result_type = RealType;
|
| 16 |
using param_type = unspecified;
|
| 17 |
|
| 18 |
// constructor and reset functions
|
| 19 |
+
weibull_distribution() : weibull_distribution(1.0) {}
|
| 20 |
+
explicit weibull_distribution(RealType a, RealType b = 1.0);
|
| 21 |
explicit weibull_distribution(const param_type& parm);
|
| 22 |
void reset();
|
| 23 |
|
| 24 |
// generating functions
|
| 25 |
template<class URBG>
|
|
|
|
| 36 |
result_type max() const;
|
| 37 |
};
|
| 38 |
```
|
| 39 |
|
| 40 |
``` cpp
|
| 41 |
+
explicit weibull_distribution(RealType a, RealType b = 1.0);
|
| 42 |
```
|
| 43 |
|
| 44 |
+
*Preconditions:* 0 < `a` and 0 < `b`.
|
| 45 |
|
| 46 |
+
*Remarks:* `a` and `b` correspond to the respective parameters of the
|
| 47 |
+
distribution.
|
| 48 |
|
| 49 |
``` cpp
|
| 50 |
RealType a() const;
|
| 51 |
```
|
| 52 |
|