OFFSET
1,4
COMMENTS
a(n) > 0 iff n mod 9 is 0, 1, 4, or 7. - Jon E. Schoenfield, Jul 06 2018
LINKS
Jon E. Schoenfield, Table of n, a(n) for n = 1..228 (first 213 terms from Giovanni Resta)
EXAMPLE
16 is the smallest square with digit sum 7, so a(7)=16.
MATHEMATICA
Array[If[FreeQ[{1, 4, 7, 9}, FixedPoint[Total@ IntegerDigits@ # &, #]], 0, Block[{k = 1, s}, While[Total@ IntegerDigits@ Set[s, k^2] != #, k++]; s]] &, 57] (* Michael De Vlieger, Jul 06 2018 *)
CROSSREFS
KEYWORD
base,nonn
AUTHOR
Erich Friedman, Jul 04 2001
STATUS
approved