Numbers nn such that the digit sum of n2n^2 is a square

Let S(n) be the digit sum of nN in the decimal system. About a month ago, a friend of mine taught me the following:

S(92)=S(81)=8+1=32
S(102)=S(100)=1+0+0=12
S(112)=S(121)=1+2+1=22
S(122)=S(144)=1+4+4=32
S(132)=S(169)=1+6+9=42
S(142)=S(196)=1+9+6=42
S(152)=S(225)=2+2+5=32

Then, I’ve got the following:

For every mN, each of the following 7 numbers is a square.
S((10(3m2)21)2),S((10(3m2)2)2),,S((10(3m2)2+5)2)

However, I’m facing difficulty in finding such 8 consecutive numbers. So, here is my question:

Question : What is the max of kN such that there exists at least one n which satisfies the following condition?

Condition : Each of the following k numbers is a square.
S((n+1)2),S((n+2)2),,S((n+k1)2),S((n+k)2)

Note that we have k7. Can anyone help?

Added : A user Peter found the following example of k=8 :
S(460458462)=82,S(460458472)=72,,S(460458522)=72,S(460458532)=82
Hence, we have k8.

Answer

As Djalal Ounadjela outlined in the comments, there is probably no such maximal k, we can expect to find an n for any k at an order of magnitude n ~ 10^m with approximately m/log10(m)k.

PS: http://oeis.org/A061910 lists numbers n for which the sum of digits of n^2 is a square.

Attribution
Source : Link , Question Author : mathlove , Answer Author : Max

Leave a Comment