OFFSET
1,2
COMMENTS
Motivated by a question about solutions to (x-1)! = x^2 in a mathematical discussion group. As can be seen from growth of the respective functions, the only solution in the positive integers is x = 1; (5-1)! ~ 5^2 is a near miss.
If (x-1)! is replaced by the Gamma function Gamma(x), then in addition to the positive non-integer solution x = 5.0367... (see A264785) there are non-integer solutions increasingly close to each negative integer: x = -1.5259... is the largest one (also the farthest from an integer), then come -1.806544..., -3.017901..., -3.997382..., -5.000333... etc. They are to the left of odd and to the right of even negative integers, and the reciprocals of the distances 1/(x[n]+n), rounded to nearest integers, go: -2, 5, -56, 382, -3002, ... (see A339167).
EXAMPLE
The largest negative solution to Gamma(x) = x^2 is x =
-1.525796457200679773601633279969790224330687534492036725687581023492284050966...
MATHEMATICA
RealDigits[x /. FindRoot[Gamma[-x] - x^2, {x, 3/2}, WorkingPrecision -> 120], 10, 100][[1]] (* Amiram Eldar, May 28 2021 *)
PROG
(PARI) localprec(5+N=100); digits(solve(x=-1.7, -1.1, gamma(x)-x^2)\.1^N)
CROSSREFS
KEYWORD
nonn,cons
AUTHOR
M. F. Hasler, Nov 25 2020
STATUS
approved