login
A391449
a(n) = A252489(n) - A059957(n).
5
0, 0, 0, 1, 0, 1, 2, 0, 0, 2, 2, 3, 3, 0, 0, 5, 4, 5, 5, 0, 1, 6, 6, 0, 3, 3, 1, 7, 6, 7, 9, 2, 3, 3, 0, 9, 9, 4, 2, 10, 9, 10, 11, 1, 5, 12, 12, 1, 1, 3, 3, 13, 13, 1, 1, 4, 6, 14, 13, 14, 15, 7, 1, 3, 1, 15, 16, 5, 4, 16, 17, 18, 18, 8, 4, 4, 1, 18, 19, 0, 10, 20, 19, 2, 10, 10, 6, 21, 20, 1
OFFSET
1,7
COMMENTS
This sequence is the difference between the index of the greatest prime divisor of n*(n+1) and the number of distinct prime divisors of n*(n+1). Where these values are equal to 0, the product n*(n+1) has a complete set of prime factors from its greatest down to 2 (that is, is in the sequence A055932). a(633555) = 0 is the last zero in the sequence because A252489 (which picks the greater of the prime indices from n, n+1) grows faster than A059957.
A141399 contains the indices where a(n) = 0. - Jason Yuen, Dec 09 2025
MATHEMATICA
A391449[n_] := PrimePi[#[[-1, 1]]] - Length[#] & [FactorInteger[n*(n + 1)]];
Array[A391449, 100] (* Paolo Xausa, Dec 16 2025 *)
PROG
(Python)
from sympy import primefactors, primepi
def a(n):
pf = primefactors(n * (n+1))
return primepi(pf[-1]) - len(pf)
print([a(n) for n in range(1, 101)])
(PARI) a(n) = my(f=factor(n*(n+1))); primepi(vecmax(f[, 1])) - omega(f); \\ Michel Marcus, Jan 24 2026
CROSSREFS
KEYWORD
nonn
AUTHOR
Ken Clements, Dec 09 2025
STATUS
approved