OFFSET
1,3
COMMENTS
If k is a term then k+1 is not composite (since k! + k^3 + 1 is divisible by k+1 for a composite k > 4). - Amiram Eldar, Sep 14 2023
Any further terms exceed 50000. - Lucas A. Brown, Mar 05 2024
MATHEMATICA
Select[Range[0, 50], ! CompositeQ[# + 1] && PrimeQ[#! + #^3 + 1] &] (* Amiram Eldar, Sep 14 2023 *)
PROG
(Python)
from sympy import isprime, factorial
print([k for k in range(0, 43) if isprime((factorial(k)+ k**3 + 1))])
CROSSREFS
KEYWORD
nonn,hard,more
AUTHOR
Darío Clavijo, Sep 14 2023
STATUS
approved