login
A345533
Numbers that are the sum of eight cubes in three or more ways.
8
223, 230, 237, 249, 256, 263, 270, 275, 282, 284, 286, 289, 291, 293, 308, 310, 312, 319, 326, 345, 347, 349, 354, 364, 371, 373, 375, 378, 380, 382, 385, 386, 387, 389, 397, 399, 401, 404, 406, 408, 410, 412, 413, 415, 420, 423, 427, 434, 438, 439, 441, 443
OFFSET
1,1
LINKS
EXAMPLE
230 is a term because 230 = 1^3 + 1^3 + 1^3 + 1^3 + 1^3 + 1^3 + 2^3 + 5^3 = 1^3 + 1^3 + 1^3 + 2^3 + 3^3 + 3^3 + 3^3 + 3^3 = 1^3 + 2^3 + 2^3 + 2^3 + 2^3 + 2^3 + 3^3 + 4^3.
PROG
(Python)
from itertools import combinations_with_replacement as cwr
from collections import defaultdict
keep = defaultdict(lambda: 0)
power_terms = [x**3 for x in range(1, 1000)]
for pos in cwr(power_terms, 8):
tot = sum(pos)
keep[tot] += 1
rets = sorted([k for k, v in keep.items() if v >= 3])
for x in range(len(rets)):
print(rets[x])
KEYWORD
nonn
AUTHOR
STATUS
approved