A383578 Let p = prime(n), then a(n) is the p-smooth part of (p-1)!+1.
2, 3, 25, 7, 11, 169, 17, 19, 23, 29, 31, 37, 41, 43, 47, 53, 59, 61, 67, 71, 73, 79, 83, 89, 97, 101, 103, 107, 109, 113, 127, 131, 137, 139, 149, 151, 157, 163, 167, 173, 179, 181, 191, 193, 197, 199, 211, 223, 227, 229, 233, 239, 241, 251, 257, 263, 269, 271, 277, 281, 283, 293
Offset: 1
Keywords
Examples
a(6) = 169 because the prime factorization of ((13 - 1)! + 1) is 13^2*2834329, and 13^2 = 169.
Programs
-
PARI
a(n) = my(p=prime(n), x=(p-1)! + 1, f=factor((p-1)! + 1, nextprime(p+1))); for (i=1, #f~, if (f[i, 1] <= p, f[1, 1] = 1)); x/factorback(f); \\ Michel Marcus, Apr 30 2025
-
Python
from sympy import prime, factorial def A383578(n): p, c = prime(n), 1 f = factorial(p-1)+1 a, b = divmod(f,p) while not b: c *= p f = a a, b = divmod(f,p) return c # Chai Wah Wu, May 12 2025
Formula
a(n) = ((prime(n) - 1)! + 1) / A383257(n).
Extensions
More terms from Michel Marcus, Apr 30 2025
Comments
=p. Conjecture: a(n) = p^2 if n = 3, 6 or 103 and a(n) = p otherwise. - Chai Wah Wu, May 11 2025