A056812 Number of unitary prime factors of lcm[1..n], i.e., primes in LCM with exponent 1.
0, 1, 2, 1, 2, 2, 3, 3, 2, 2, 3, 3, 4, 4, 4, 4, 5, 5, 6, 6, 6, 6, 7, 7, 6, 6, 6, 6, 7, 7, 8, 8, 8, 8, 8, 8, 9, 9, 9, 9, 10, 10, 11, 11, 11, 11, 12, 12, 11, 11, 11, 11, 12, 12, 12, 12, 12, 12, 13, 13, 14, 14, 14, 14, 14, 14, 15, 15, 15, 15, 16, 16, 17, 17, 17, 17, 17, 17, 18, 18, 18, 18, 19
Offset: 1
Keywords
Examples
n=100, lcm(100) has 25 prime factors of which only 2 and 3 have exponent larger than 1; resulting powers: 64 and 81. So 23 prime factors are unitary, i.e., with exponent 1, so a(100)=23.
Links
- G. C. Greubel, Table of n, a(n) for n = 1..1000
Programs
-
Mathematica
Join[{0}, Table[Count[Transpose[FactorInteger[Product[Cyclotomic[k, 1], {k, 2, n}]]][[2]], 1], {n, 2, 100}]] (* G. C. Greubel, May 13 2017 *)
-
PARI
for(n=1,100, print1(primepi(n) - primepi(sqrt(n)), ", ")) \\ G. C. Greubel, May 13 2017
Comments