OFFSET
1,1
LINKS
David Rabahy and Alois P. Heinz and Chai Wah Wu, Table of n, a(n) for n = 1..90 (first 38 terms from David Rabahy, next 12 terms from Alois P. Heinz)
EXAMPLE
9^3 + 10^3 = 1729 = A001235(1), so 9 is in the sequence.
MAPLE
filter:= proc(n)
local D, b, a, Q;
D:= numtheory:-divisors(n);
for b in D do
a:= n/b;
Q:= 12*b - 3*a^2;
if Q > 9 and issqr(Q) and Q < 9*a^2 then return true fi
od;
false
end proc:
select(x -> filter(x^3 +(x+1)^3), [$1..100000]); # Robert Israel, Jul 07 2015
MATHEMATICA
Select[Range[10000], Length[PowersRepresentations[#^3 + (# + 1)^3, 2, 3]]==2 &] (* Vincenzo Librandi, Jul 10 2015 *)
PROG
(Python 3.x)
start = 9
end = 500000
print(start, end)
cubes = []
t = end**3+(end+1)**3
max = int(t**(1/3)+.5)
for i in range(0, max+1):
cubes.append(i**3)
for x in range(start, end):
t = cubes[x]+cubes[x+1]
for i in range(1, x):
z = t-cubes[i]
n = int(z**(1/3)+.5)
if cubes[n] == z:
print(x, x+1, i, n, '\a')
(Python)
from __future__ import division
from gmpy2 import is_square
from sympy import divisors
A259836_list = []
for n in range(10000):
m = n**3+(n+1)**3
for x in divisors(m):
x2 = x**2
if x2 > m:
break
if x != (2*n+1) and m < x*x2 and is_square(12*m//x-3*x2):
A259836_list.append(n)
break # Chai Wah Wu, Jan 10 2016
CROSSREFS
KEYWORD
nonn
AUTHOR
David Rabahy, Jul 06 2015
STATUS
approved