OFFSET
1,2
COMMENTS
The digit complement of a digit d is 9 - d; e.g., 8 and 3 have complements 1, 6, respectively. The digit complement of a number k is the number formed by replacing each digit of k by its complement; e.g., 83 has complement 16.
LINKS
Giovanni Resta, Table of n, a(n) for n = 1..10000
EXAMPLE
972972 has complement 27027 (the leading 0 is ignored). 972972 * 27027 = 162162^2, so 972972 is a term of the sequence.
MATHEMATICA
j[n_] := 9 - n; Do[If[IntegerQ[Sqrt[n*FromDigits[Map[j, IntegerDigits[n]]]]], Print[n]], {n, 1, 10^6}]
Select[Range[0, 81203000], IntegerQ[Sqrt[# FromDigits[9-IntegerDigits[ #]]]]&] (* Harvey P. Dale, Jun 26 2021 *)
PROG
(PARI) isok(n) = {d = digits(n); nd = vector(#d, k, 9-d[k]); issquare(n*fromdigits(nd)); }
CROSSREFS
KEYWORD
base,nonn
AUTHOR
Joseph L. Pe, Mar 20 2002
EXTENSIONS
More terms from Robert G. Wilson v, Apr 08 2002
a(1), a(21)-a(32) from Giovanni Resta, Apr 14 2017
STATUS
approved