login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A316480 Table read by rows: T(n,k), 0 <= k <= 9, is the number of n-digit squares whose average digit is exactly k. 9

%I #18 Jul 15 2018 12:34:12

%S 1,1,0,0,1,0,0,0,0,1,0,0,0,0,0,1,0,0,0,0,0,0,0,5,0,0,2,0,0,0,0,0,0,0,

%T 6,0,0,0,0,0,0,0,5,0,0,21,0,0,1,0,0,0,0,57,0,0,42,0,0,0,0,2,0,0,192,0,

%U 0,14,0,0,0,0,52,0,0,499,0,0,0,0,0,25,191,1281,2658,2282,705,65,0,0

%N Table read by rows: T(n,k), 0 <= k <= 9, is the number of n-digit squares whose average digit is exactly k.

%C The only square whose average digit is 0 is the 1-digit number 0^2 = 0.

%C The only square whose average digit is 9 is the 1-digit number 3^2 = 9.

%C Suppose m^2 is an n-digit number whose average digit is an integer k, i.e., digitsum(m^2) = n*k. Since digitsum(m^2) mod 9 = 0, 1, 4, or 7 (cf. A004159), it follows that

%C - if k = 1, 4, or 7, then n mod 9 = 0, 1, 4, or 7;

%C - if k = 2, 5, or 8, then n mod 9 = 0, 2, 5, or 8;

%C - if k = 3 or 6, then n mod 9 = 0, 3, or 6.

%C In this table, each possible combination of a value of k and a value of n mod 9 is identified with an asterisk (*):

%C .

%C n mod 9

%C .

%C 0 1 2 3 4 5 6 7 8

%C +----------------------------------

%C 1 | * * * *

%C |

%C 2 | * * * *

%C |

%C 3 | * * *

%C |

%C 4 | * * * *

%C k |

%C 5 | * * * *

%C |

%C 6 | * * *

%C |

%C 7 | * * * *

%C |

%C 8 | * * * *

%C .

%C Not surprisingly, among the values k=1..8, the value of k that occurs least frequently as the average digit of a square is 8.

%H Jon E. Schoenfield, <a href="/A316480/b316480.txt">Table of n, a(n) for n = 1..190</a>

%e Table begins

%e n\k| 0 1 2 3 4 5 6 7 8 9

%e ---+---------------------------------------------------------

%e 1 | 1 1 0 0 1 0 0 0 0 1

%e 2 | 0 0 0 0 0 1 0 0 0 0

%e 3 | 0 0 0 5 0 0 2 0 0 0

%e 4 | 0 0 0 0 6 0 0 0 0 0

%e 5 | 0 0 5 0 0 21 0 0 1 0

%e 6 | 0 0 0 57 0 0 42 0 0 0

%e 7 | 0 2 0 0 192 0 0 14 0 0

%e 8 | 0 0 52 0 0 499 0 0 0 0

%e 9 | 0 25 191 1281 2658 2282 705 65 0 0

%e 10 | 0 12 0 0 5308 0 0 93 0 0

%e 11 | 0 0 548 0 0 13597 0 0 1 0

%e 12 | 0 0 0 23310 0 0 12871 0 0 0

%e 13 | 0 77 0 0 143724 0 0 753 0 0

%e 14 | 0 0 5572 0 0 360720 0 0 1 0

%e 15 | 0 0 0 449170 0 0 239403 0 0 0

%e 16 | 0 102 0 0 3990950 0 0 6029 0 0

%e 17 | 0 0 51977 0 0 9994767 0 0 4 0

%e 18 | 0 417 157382 8665925 55115308 45351595 4568205 36552 8 0

%t Block[{nn = 9, s}, s = MapAt[Prepend[#, 0] &, Map[Mean@ IntegerDigits[#] &, SplitBy[Range[10^(nn/2)]^2, IntegerLength], {2}], 1]; Table[Count[s[[n]], k], {n, nn}, {k, 0, 9}]] // Flatten (* _Michael De Vlieger_, Jul 06 2018 *)

%Y Cf. A004159, A069711.

%Y Cf. A316481-A316488 (Squares whose arithmetic mean of digits is k, for k=1..8).

%K nonn,tabf,base

%O 1,24

%A _Jon E. Schoenfield_, Jul 04 2018

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified April 25 11:39 EDT 2024. Contains 371969 sequences. (Running on oeis4.)