A356879 Numbers k such that the sum k^x + k^y can be a square with {x, y} >= 0.
0, 2, 3, 8, 15, 18, 24, 32, 35, 48, 50, 63, 72, 80, 98, 99, 120, 128, 143, 162, 168, 195, 200, 224, 242, 255, 288, 323, 338, 360, 392, 399, 440, 450, 483, 512, 528, 575, 578, 624, 648, 675, 722, 728, 783, 800, 840, 882, 899, 960, 968, 1023, 1058, 1088, 1152, 1155, 1224
Offset: 0
Keywords
Examples
Squares that can be produced with k = 8: 8^0 + 8^1 = 9; 8^1 + 8^1 = 16; 8^2 + 8^3 = 576; 8^3 + 8^3 = 1024; 8^4 + 8^5 = 36864; 8^5 + 8^5 = 65536; 8^6 + 8^7 = 2359296, ....
Crossrefs
Programs
-
Mathematica
Select[Range[0, 1225], IntegerQ[Sqrt[# + 1]] || IntegerQ[Sqrt[#/2]] &] (* Amiram Eldar, Sep 18 2022 *)
-
Python
from gmpy2 import is_square print([n for n in range(0,1225) if is_square(n+1) or (n % 2 == 0 and is_square(n//2))])
Comments