C# code for gamma and log gamma

Here is stand-alone C# code for the functions Gamma and LogGamma. Both require a positive argument.

Why are there separate functions for gamma and its logarithm? See this post for an explanation.

Note that the functions Gamma and LogGamma are mutually dependent, but do not depend on anything else.

Related links

Click to find out more about consulting for numerical computing