|
|
A215218
|
|
Number of sphenic numbers, i.e., numbers with exactly three distinct prime factors, up to 10^n.
|
|
6
|
|
|
0, 5, 135, 1800, 19919, 206964, 2086746, 20710806, 203834084, 1997171674, 19522428788, 190614467420, 1860310801454, 18155356377267, 177224592578839, 1730651760050923, 16908343191198752, 165279853754232019, 1616504757072680964
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
1,2
|
|
LINKS
|
|
|
EXAMPLE
|
a(2) = 5 since there are the five sphenic numbers 30, 42, 66, 70, 78 up to 100.
|
|
MATHEMATICA
|
f[n_] := Sum[ PrimePi[n/(Prime@ i*Prime@ j)] - j, {i, PrimePi[n^(1/3)]}, {j, i +1, PrimePi@ Sqrt[n/Prime@ i]}]; (* Robert G. Wilson v, Dec 28 2016 *)
|
|
PROG
|
(Python)
from math import isqrt
from sympy import primepi, primerange, integer_nthroot
def A215218(n): return int(sum(primepi(10**n//(k*m))-b for a, k in enumerate(primerange(integer_nthroot(10**n, 3)[0]+1), 1) for b, m in enumerate(primerange(k+1, isqrt(10**n//k)+1), a+1))) # Chai Wah Wu, Aug 26 2024
|
|
CROSSREFS
|
|
|
KEYWORD
|
nonn
|
|
AUTHOR
|
|
|
EXTENSIONS
|
|
|
STATUS
|
approved
|
|
|
|