Solution to $2^x=x!$

factorialfunctionsreal-analysis

I was trying to solve the equation for $x!=2^x$, where $x\ge0$.

I plotted it on Desmos and found two solutions for the same.

Attaching image for reference. Graph plot of $2^x$ and $x!$

As per the plot, there are two solutions for the equation. But I am only able to derive the solution $x=0$. (Through observation and guesswork).

How can the second solution be derived ($x\approx3.46$)?

I couldn't figure it out!

It looks so simple, yet its quite a bummer actually(at least for me).

Can someone please help regarding the same?

Thanks in advance!

Best Answer

I cannot see any form of analytical solution possible to this equation. Instead, you can set a function $$f(x)=2^x-\Gamma(x+1)$$ and perform numerical methods for the second solution. You can use Newton's method for approximating roots.

Here, we start with the initial value $x=3$

enter image description here enter image description here

and so on to the desired accuracy.

The root we get is $$x\approx 3.45986564404499913418786108106898120277518459906428314529806887...$$

Related Question