|
Boost : |
From: John Maddock (john_at_[hidden])
Date: 2006-10-06 05:04:56
Janek Kozicki wrote:
> John Maddock said: (by the date of Wed, 4 Oct 2006 18:43:00 +0100)
>
>> Mathematical Special Functions
>
> how about sigmoid, double sigmoid and their derivatives? Used for
> neural networks.
Those are new ones to me.
> Just a suggestion. They are so simple, that perhaps you can assume
> that the user can write them himself (as it was done in the past).
>
> Unless you know some optimized way to implement them....
I suspect you will never improve on a call to exp() ?
Of course if you want 1 - sigmoid(x) then you can rearrange things to avoid
cancellation error. But I don't know how important such things are.
One of the problems we have is that there are a virtually unlimited number
of special functions, not least all those in TR1. So it's a case of trying
to draw the line in the right place, but do feel free to lobby for your
favorites :-)
John.
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk