This is the mail archive of the gcc-help@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: simple question [OT]


Hi Charles,

I believe the algorithm, and the results (including 15!) are correct... given the number of significant digits that the algorithm commits to, which I think is around 6 significant digits.

The algorithm is an approximation of the mathematical gamma function, relying on the asymptotic nature of the natural log of the gamma function.

Also, floats and doubles have digits of precision as well, which I assume is accounted for in the number of significant digits in the lnGamma contract.

Sincerely,
--Eljay


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]