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”).
%I #7 Jul 06 2012 11:51:58
%S 0,0,0,0,0,0,0,1,1,5,8,22,47,101,229,473,1044,2171,4634,9796,20513,
%T 43020,89684,187361,388633,807508,1671160,3455934,7135226,14708436,
%U 30286472,62280024,127944070,262543635,538266791,1102507513,2256357137
%N Number of 8-almost primes 8ap such that 2^n < 8ap <= 2^(n+1).
%C The partial sum equals the number of Pi_8(2^n).
%e (2^8, 2^9] there is one semiprime, namely 384. 256 was counted in the previous entry.
%t 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 *)
%t t = Table[AlmostPrimePi[8, 2^n], {n, 0, 30}]; Rest@t - Most@t
%Y Cf. A046310, A036378, A120033, A120034, A120035, A120036, A120037, A120038, A120039, A120040, A120041, A120042, A120043.
%K nonn
%O 0,10
%A _Jonathan Vos Post_ and _Robert G. Wilson v_, Mar 21 2006