Created on 2008-02-09.00:00:00 last changed 172 months ago
Proposed resolution:
Change synopsis in [rand.dist.samp.pconst]:
template <class RealType = double> class piecewise_constant_distribution { public: ... vector<double>densitiesprobabilities() const; ... };
Change [rand.dist.samp.pconst]/6:
vector<double>densitiesprobabilities() const;
[ Bellevue: ]
Fermilab does not agree with this summary. As defined in the equation in 26.4.8.5.2/4, the quantities are indeed probability densities not probabilities. Because we view this distribution as a parameterization of a *probability density function*, we prefer to work in terms of probability densities.
We don't think this should be changed.
If there is a technical argument about why the implementation dealing with these values can't be as efficient as one dealing with probabilities, we might reconsider. We don't care about this one member function being somewhat more or less efficient; we care about the size of the distribution object and the speed of the calls to generate variates.
piecewise_constant_distribution::densities() should be probabilities(), just like discrete_distribution. (There's no real use for weights divided by areas.)
History | |||
---|---|---|---|
Date | User | Action | Args |
2010-10-21 18:28:33 | admin | set | messages: + msg3786 |
2010-10-21 18:28:33 | admin | set | messages: + msg3785 |
2008-02-09 00:00:00 | admin | create |