OFFSET
1,2
COMMENTS
All terms == 0, 1, 2, 7 or 8 (mod 9).
LINKS
EXAMPLE
a(3) = 8 = 0^3 + 2^3.
a(4) = 9 = 1^3 + 2^3.
a(5) = 19 = (-2)^3 + 3^3.
MAPLE
filter:= proc(n) local d, dp, r;
for d in numtheory:-divisors(n) do
dp:= n/d;
r:= 12*dp - 3*d^2;
if r > 0 and issqr(r) and (sqrt(r)/6 + d/2)::integer then return true fi
od;
false
end proc:
select(filter, [$0..1000]);
MATHEMATICA
filterQ[n_] := Module[{d, dp, r}, Catch[Do[dp = n/d; r = 12 dp - 3 d^2; If[r > 0 && IntegerQ[Sqrt[r]] && IntegerQ[Sqrt[r]/6 + d/2], Throw[True]], {d, Divisors[n]}]; False]];
Select[Range[1000], filterQ] (* Jean-François Alcover, Oct 17 2020, after Maple *)
CROSSREFS
KEYWORD
nonn
AUTHOR
Robert Israel, Apr 15 2019
STATUS
approved