OFFSET
1,2
COMMENTS
If m is a term, 10*m is also a term; so, terms with no trailing zeros are all primitive terms.
Palindromes with even number of digits (A056524) are all terms.
FORMULA
A257588(a(n)) = 0.
EXAMPLE
354 is a term since 3^2 - 5^2 + 4^2 = 0 (with Pythagorean triple (3,4,5)).
1487 is a term since 1^2 - 4^2 + 8^2 - 7^2 = 0.
MATHEMATICA
f[n_] := Abs @ Total[(d = IntegerDigits[n]^2) * (-1)^Range[Length[d]]]; Select[Range[0, 2300], f[#] == 0 &] (* Amiram Eldar, Mar 20 2022 *)
PROG
(Python)
from itertools import count, islice
def A352535_gen(startvalue=0): # generator of terms >= startvalue
return filter(lambda m: not sum(int(d)**2*(-1 if i % 2 else 1) for i, d in enumerate(str(m))), count(max(startvalue, 0)))
CROSSREFS
KEYWORD
nonn,base
AUTHOR
Bernard Schott, Mar 20 2022
STATUS
approved