0%

Problem 396


Problem 396


Weak Goodstein sequence

For any positive integer n, the nth weak Goodstein sequence {g1, g2, g3, …} is defined as:

  • g1 = n
  • for k > 1, gk is obtained by writing gk-1 in base k, interpreting it as a base k + 1 number, and subtracting 1.

The sequence terminates when gk becomes 0.

For example, the 6th weak Goodstein sequence is {6, 11, 17, 25, …}:

  • g1 = 6.
  • g2 = 11 since 6 = 1102, 1103 = 12, and 12 - 1 = 11.
  • g3 = 17 since 11 = 1023, 1024 = 18, and 18 - 1 = 17.
  • g4 = 25 since 17 = 1014, 1015 = 26, and 26 - 1 = 25.
    and so on.

It can be shown that every weak Goodstein sequence terminates.

Let G(n) be the number of nonzero elements in the nth weak Goodstein sequence.
It can be verified that G(2) = 3, G(4) = 21 and G(6) = 381.
It can also be verified that ΣG(n) = 2517 for 1 ≤ n < 8.

Find the last 9 digits of ΣG(n) for 1 ≤ n < 16.


弱古德斯坦序列

对于任意正整数n,第n个弱古德斯坦序列 {g1, g2, g3, …}按如下方式定义:

  • g1 = n
  • 对于k > 1,将gk-1写成k进制表示,然后将其视为k+1进制的数,最后减去1,得到gk

当gk变为0时序列终止。

例如,第6个弱古德斯坦序列为{6, 11, 17, 25, …}:

  • g1 = 6。
  • g2 = 11,因为6 = 1102,然后1103 = 12,最后12 - 1 = 11。
  • g3 = 17,因为11 = 1023,然后1024 = 18,最后18 - 1 = 17。
  • g4 = 25,因为17 = 1014,然后1015 = 26,最后26 - 1 = 25。
    依此类推。

可以证明所有弱古德斯坦序列都会终止。

记G(n)为第n个弱古德斯坦序列中的非零元素个数。
可以验证G(2) = 3,G(4) = 21以及G(6) = 381。
同样可以验证,对于1 ≤ n < 8,ΣG(n) = 2517。

对于1 ≤ n < 16,求ΣG(n)的最后9位数字。