I am hoping there is a library function somewhere that can do this.
And yes it is very important that it be the factorial of a double value (that is it needs to work with non-integer values).
I am hoping there is a library function somewhere that can do this. And
Share
The C99 standard library contains the gamma function,
double tgamma(double). This is closely related to the factorial, so you can define:This should be available in any C++11 implementation, but is not guaranteed to be in a C++03 implementation, which might only include the C90 library. If your implementation doesn’t have it, then the Boost.Math library does.