OFFSET
1,1
COMMENTS
Sphenic numbers are the product of three distinct primes (cf. A007304).
LINKS
Robert Israel, Table of n, a(n) for n = 1..3273 (all terms < 10^8)
EXAMPLE
2526 = 2 * 3 * 421 is a sphenic number; 2523 = 3 * 29^2, 2524 = 2^2 * 631, 2525 = 5^2 * 101, 2527 = 7 * 19^2, 2528 = 2^5 * 79, 2529 = 3^2 * 281 are all nonsquarefree numbers, so 2526 is a term.
MAPLE
N:= 2*10^6: # to get all terms <= N
P:= select(isprime, [2, seq(i, i=3..N/6, 2)]):
nP:= nops(P): R:= NULL:
for i from 1 do
p:= P[i]; if p^3 >= N then break fi;
for j from i+1 do
q:= P[j]: if p*q^2 >= N then break fi;
for k from j+1 to nP do
x:= p*q*P[k];
if x > N then break fi;
if not ormap(numtheory:-issqrfree, [x-3, x-2, x-1, x+1, x+2, x+3]) then R:= R, x fi
od od od:
sort([R]); # Robert Israel, Feb 25 2024
MATHEMATICA
f[n_] := Module[{e = FactorInteger[n][[;; , 2]], p}, p = Times @@ e; If[p > 1, 0, If[e == {1, 1, 1}, 1, -1]]]; SequencePosition[Array[f, 2*10^6], {0, 0, 0, 1, 0, 0, 0}][[;; , 1]] + 3 (* Amiram Eldar, Jan 25 2024 *)
CROSSREFS
KEYWORD
nonn
AUTHOR
Massimo Kofler, Jan 25 2024
STATUS
approved