login
A349049
Number of prime factors (with multiplicity) of the denominator of the harmonic number H(n) = Sum_{k=1..n} 1/k.
0
0, 1, 2, 3, 4, 3, 4, 5, 7, 7, 8, 8, 9, 9, 9, 10, 11, 10, 11, 10, 9, 9, 10, 11, 13, 13, 15, 15, 16, 16, 17, 18, 17, 17, 17, 17, 18, 18, 18, 18, 19, 18, 19, 20, 20, 20, 21, 21, 23, 23, 23, 23, 24, 23, 23, 23, 23, 23, 24, 24, 25, 25, 24, 25, 25, 24, 25, 25, 26, 26, 27, 28, 29, 29, 29, 29, 28
OFFSET
1,3
FORMULA
a(n) = A001222(A002805(n)).
PROG
(SageMath) [sloane.A001222(A002805(n)) for n in range(1, 78)]
(PARI) my(h=0); for(n=1, 77, h+=1/n; print1(bigomega(denominator(h)), ", ")); \\ Joerg Arndt, Nov 07 2021
(Python)
from sympy import harmonic, factorint
def a(n): return sum(factorint(harmonic(n).denominator()).values())
print([a(n) for n in range(1, 78)]) # Michael S. Branicky, Nov 07 2021
CROSSREFS
KEYWORD
nonn
AUTHOR
Kam Kong, Nov 07 2021
STATUS
approved