login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

A120048
Number of 7-almost primes less than or equal to 10^n.
10
0, 0, 0, 14, 231, 2973, 35585, 409849, 4600247, 50678212, 550454756, 5913771637, 62981797962, 665997804082, 7001087934965
OFFSET
0,4
EXAMPLE
There are 14 seven-almost primes up to 1000: 128, 192, 288, 320, 432, 448, 480, 648, 672, 704, 720, 800, 832 & 972.
MATHEMATICA
AlmostPrimePi[k_Integer, n_] := Module[{a, i}, a[0] = 1; If[k == 1, PrimePi[n], Sum[PrimePi[n/Times @@ Prime[Array[a, k - 1]]] - a[k - 1] + 1, Evaluate[ Sequence @@ Table[{a[i], a[i - 1], PrimePi[(n/Times @@ Prime[Array[a, i - 1]])^(1/(k - i + 1))]}, {i, k - 1}]]]]]; (* Eric W. Weisstein, Feb 07 2006 *)
Table[AlmostPrimePi[7, 10^n], {n, 11}]
KEYWORD
nonn
AUTHOR
Robert G. Wilson v, Feb 07 2006
EXTENSIONS
More terms from Robert G. Wilson v, Jan 07 2007
Example corrected by Harvey P. Dale, Jan 25 2013
STATUS
approved