Boost logo

Boost :

From: Andrew Sutton (asutton_at_[hidden])
Date: 2007-12-16 09:39:29

> I think this is along the right lines, but I don't much like the +-1
> parameter: especially as it's a floating point type argument. How
> about
> using an enum here:
> enum extreme_value_type
> {
> type_1_maximum = 1,
> type_1_minimum = -1
> };

I had actually considered doing that, but then started feeling a
little ambiguous about it since I would have been using the
enumerated value in a mathematical context. But, it does make a lot
more sense.

> All these need tests and sanity checks: preferably some sanity
> checks from
> an independent source if we can find one. Mathematica would be a good
> choice, but I don't have access to that here :-(

I don't think my department has an installation of Mathematica, but I
do know a couple of math grads. I'll see what I can come up with.

> Median looks like it needs adjusting to reflect the "sign".
> Skewness for min case is presumably the negative of the max case
> (needs
> checking)?

Yup... I overlooked a negative sign from the MathWorld site.

> BTW the sandbox/math_toolkit directory is open for breaking changes
> again
> now (Boost.Math in 1.35 is effectively frozen bar trivial fixes),
> so when
> you have these worked up feel free to commit to the sandbox. Also
> let me
> know if you get stumped for test cases.

Can do. I'm mostly waiting on my student to finish off the functions
for the skew normal. After that, I'll push those distributions up to
the sandbox along with the random numbers generators.

On a side note, I think it might be interesting to provide a generator
() function for distributions that could return random variates.

Andrew Sutton

Boost list run by bdawes at, gregod at, cpdaniel at, john at