OFFSET
1,2
COMMENTS
LINKS
Amiram Eldar, Table of n, a(n) for n = 1..10000
EXAMPLE
9 is a term since its divisors, {1, 3, 9}, can be partitioned into the two disjoint sets, {1, 3} and {9}, whose sums, 1 + 3 = 4 = 2^2 and 9 = 3^2, are both squares.
MATHEMATICA
sqQ[n_] := IntegerQ[Sqrt[n]]; q[n_] := Module[{d = Divisors[n], s, p}, s = Total[d]; p = Position[Rest @ CoefficientList[Product[1 + x^i, {i, d}], x], _?(# > 0 &)] // Flatten; AnyTrue[p, sqQ[#] && sqQ[s - #] &]]; Select[Range[500], q]
CROSSREFS
KEYWORD
nonn
AUTHOR
Amiram Eldar, Jun 30 2023
STATUS
approved