login
A338667
Numbers that are the sum of two positive cubes in exactly one way.
4
2, 9, 16, 28, 35, 54, 65, 72, 91, 126, 128, 133, 152, 189, 217, 224, 243, 250, 280, 341, 344, 351, 370, 407, 432, 468, 513, 520, 539, 559, 576, 637, 686, 728, 730, 737, 756, 793, 854, 855, 945, 1001, 1008, 1024, 1027, 1064, 1072, 1125, 1216, 1241, 1332, 1339, 1343, 1358, 1395, 1456, 1458, 1512, 1547, 1674, 1736
OFFSET
1,1
COMMENTS
This sequence differs from A003325 at term 61: A003325(61) = 1729 is the famous Ramanujan taxicab number and is excluded from this sequence because it is the sum of two cubes in two distinct ways.
LINKS
David Consiglio, Jr., Table of n, a(n) for n = 1..20000
EXAMPLE
35 is a term of this sequence because 2^3 + 3^3 = 8 + 27 = 35 and this is the one and only way to express 35 as the sum of two cubes.
MATHEMATICA
Select[Range@2000, Length[s=PowersRepresentations[#, 2, 3]]==1&&And@@(#>0&@@@s)&] (* Giorgos Kalogeropoulos, Apr 24 2021 *)
PROG
(Python)
from itertools import combinations_with_replacement as cwr
from collections import defaultdict
from bisect import bisect_left as bisect
keep = defaultdict(lambda: 0)
power_terms = [x**3 for x in range(1, 1000)]
for pos in cwr(power_terms, 2):
tot = sum(pos)
keep[tot] += 1
rets = sorted([k for k, v in keep.items() if v == 1])
for x in range(len(rets)):
print(rets[x])
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
STATUS
approved