A316480 Table read by rows: T(n,k), 0 <= k <= 9, is the number of n-digit squares whose average digit is exactly k.
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, 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, 0, 14, 0, 0, 0, 0, 52, 0, 0, 499, 0, 0, 0, 0, 0, 25, 191, 1281, 2658, 2282, 705, 65, 0, 0
Offset: 1
Examples
Table begins n\k| 0 1 2 3 4 5 6 7 8 9 ---+--------------------------------------------------------- 1 | 1 1 0 0 1 0 0 0 0 1 2 | 0 0 0 0 0 1 0 0 0 0 3 | 0 0 0 5 0 0 2 0 0 0 4 | 0 0 0 0 6 0 0 0 0 0 5 | 0 0 5 0 0 21 0 0 1 0 6 | 0 0 0 57 0 0 42 0 0 0 7 | 0 2 0 0 192 0 0 14 0 0 8 | 0 0 52 0 0 499 0 0 0 0 9 | 0 25 191 1281 2658 2282 705 65 0 0 10 | 0 12 0 0 5308 0 0 93 0 0 11 | 0 0 548 0 0 13597 0 0 1 0 12 | 0 0 0 23310 0 0 12871 0 0 0 13 | 0 77 0 0 143724 0 0 753 0 0 14 | 0 0 5572 0 0 360720 0 0 1 0 15 | 0 0 0 449170 0 0 239403 0 0 0 16 | 0 102 0 0 3990950 0 0 6029 0 0 17 | 0 0 51977 0 0 9994767 0 0 4 0 18 | 0 417 157382 8665925 55115308 45351595 4568205 36552 8 0
Links
- Jon E. Schoenfield, Table of n, a(n) for n = 1..190
Crossrefs
Programs
-
Mathematica
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 *)
Comments