I\'ve been profiling an application all day long and, having optimized a couple bits of code, I\'m left with this on my todo list. It\'s the activation function for a neural
Doing a Google search, I found an alternative implementation of the Sigmoid function.
public double Sigmoid(double x) { return 2 / (1 + Math.Exp(-2 * x)) - 1; }
Is that correct for your needs? Is it faster?
http://dynamicnotions.blogspot.com/2008/09/sigmoid-function-in-c.html