login
A393168
Integers k which can be written in the form x^2 + y^2 - z^2, where x, y, z are integers and x^2, y^2, z^2 <= k.
2
0, 1, 2, 4, 5, 7, 8, 9, 10, 12, 13, 14, 16, 17, 18, 19, 20, 21, 23, 24, 25, 26, 28, 29, 30, 31, 32, 33, 34, 36, 37, 39, 40, 41, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 56, 57, 58, 60, 61, 62, 63, 64, 65, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 79, 80, 81, 82, 84, 85, 86
OFFSET
1,3
COMMENTS
It is conjectured that every number greater than 6563 can be written in this form.
LINKS
Emmanuel Osalotioman Osazuwa, Table of n, a(n) for n = 1..10000
Thomas Bloom, Problem 1148, Erdős Problems.
PROG
(Python) isok = lambda k, math=__import__('math'): any(any(0 <= (k + z**2 - x**2) <= k and math.isqrt(k + z**2 - x**2)**2 == (k + z**2 - x**2) for x in range(math.isqrt(k) + 1)) for z in range(math.isqrt(k) + 1))
CROSSREFS
Cf. A390380 (complement).
Sequence in context: A235331 A175969 A183573 * A187895 A079726 A047498
KEYWORD
nonn
AUTHOR
STATUS
approved