Date: 2001-06-29 02:23:36
--- In boost_at_y..., Daryle Walker <darylew_at_m...> wrote:
> Are we starting it now? I guess the structure could be:
> - BOOST_ROOT
> - boost
> - math
> advanced_trignometric.hpp (atanh, sinc_pi, sinhc_pi)
> - libs
> - math
> - doc
> + src
> + test
How would you handle functions that might have slightly different
implementations depending on the domain?
Look at pow(T x,I n):
it is defined for every integer n if T is
a group (e.g. x is float),
it is defined only for non-negative n if T is a monoid
(e.g. x is int),
and it is defined only for n>0 of T is a semigroup.
Similar things apply to binomial coefficients:
binom(m,n)=binom(m,m-n) if both m and n are integral,
but binom(x,n) != binom(x,x-n) (the latter is not defined)
if x is float.
One solution might be to have a
This might be easier to implement than
to have clever template specialisation techniques
the derive the respective algorithm from the template types.
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk