Sunday, 30 June 2019

What algorithms exist to quickly compute the inverse factorial?

I'm interested in algorithms to quickly compute the inverse factorial.
I've noted that large factorials have a unique number of digits. How can I use this fact to quickly compute the factorial? Is there a formula,
n = f(n!) = #digits( (n!) )?



I'm mostly interested in the case where we know our input is correct. But, error checking for values that are not factorials would be a bonus. (Perhaps, someone has thought of a way to do the inverse gamma function quickly?)



I'm interested in inputs that have over a million digits, so simply dividing 1,2,3,...,n will not work.

No comments:

Post a Comment

real analysis - How to find $lim_{hrightarrow 0}frac{sin(ha)}{h}$

How to find $\lim_{h\rightarrow 0}\frac{\sin(ha)}{h}$ without lhopital rule? I know when I use lhopital I easy get $$ \lim_{h\rightarrow 0}...