# 4-Digit Numbers forming Longest Reverse-and-Add Sequence

## Theorem

Let $m \in \Z_{>0}$ be a positive integer expressed in decimal notation.

Let $r \left({m}\right)$ be the reverse-and-add process on $m$.

Let $r$ be applied iteratively to $m$.

The $4$-digit integers $m$ which need the largest number of iterations before reaching a palindromic number are:

$6999, 7998, 8997, 9996$

all of which need $20$ iterations.

## Proof

 $(1):\quad$ $\displaystyle$  $\, \displaystyle 6999 + 9996 \,$ $\, \displaystyle =\,$ $\displaystyle 16995$ $(2):\quad$ $\displaystyle$  $\, \displaystyle 16995 + 59961 \,$ $\, \displaystyle =\,$ $\displaystyle 76956$ $(3):\quad$ $\displaystyle$  $\, \displaystyle 76956 + 65967 \,$ $\, \displaystyle =\,$ $\displaystyle 142923$ $(4):\quad$ $\displaystyle$  $\, \displaystyle 142923 + 329241 \,$ $\, \displaystyle =\,$ $\displaystyle 472164$ $(5):\quad$ $\displaystyle$  $\, \displaystyle 472164 + 461274 \,$ $\, \displaystyle =\,$ $\displaystyle 933438$ $(6):\quad$ $\displaystyle$  $\, \displaystyle 933438 + 834339 \,$ $\, \displaystyle =\,$ $\displaystyle 1767777$ $(7):\quad$ $\displaystyle$  $\, \displaystyle 1767777 + 7777671 \,$ $\, \displaystyle =\,$ $\displaystyle 9545448$ $(8):\quad$ $\displaystyle$  $\, \displaystyle 9545448 + 8445459 \,$ $\, \displaystyle =\,$ $\displaystyle 17990907$ $(9):\quad$ $\displaystyle$  $\, \displaystyle 17990907 + 70909971 \,$ $\, \displaystyle =\,$ $\displaystyle 88900878$ $(10):\quad$ $\displaystyle$  $\, \displaystyle 88900878 + 87800988 \,$ $\, \displaystyle =\,$ $\displaystyle 176701866$ $(11):\quad$ $\displaystyle$  $\, \displaystyle 176701866 + 668107671 \,$ $\, \displaystyle =\,$ $\displaystyle 844809537$ $(12):\quad$ $\displaystyle$  $\, \displaystyle 844809537 + 735908448 \,$ $\, \displaystyle =\,$ $\displaystyle 1580717985$ $(13):\quad$ $\displaystyle$  $\, \displaystyle 1580717985 + 5897170851 \,$ $\, \displaystyle =\,$ $\displaystyle 7477888836$ $(14):\quad$ $\displaystyle$  $\, \displaystyle 7477888836 + 6388887747 \,$ $\, \displaystyle =\,$ $\displaystyle 13866776583$ $(15):\quad$ $\displaystyle$  $\, \displaystyle 13866776583 + 38567766831 \,$ $\, \displaystyle =\,$ $\displaystyle 52434543414$ $(16):\quad$ $\displaystyle$  $\, \displaystyle 52434543414 + 41434543425 \,$ $\, \displaystyle =\,$ $\displaystyle 93869086839$ $(17):\quad$ $\displaystyle$  $\, \displaystyle 93869086839 + 93868096839 \,$ $\, \displaystyle =\,$ $\displaystyle 187737183678$ $(18):\quad$ $\displaystyle$  $\, \displaystyle 187737183678 + 876381737781 \,$ $\, \displaystyle =\,$ $\displaystyle 1064118921459$ $(19):\quad$ $\displaystyle$  $\, \displaystyle 1064118921459 + 9541298114601 \,$ $\, \displaystyle =\,$ $\displaystyle 10605417036060$ $(20):\quad$ $\displaystyle$  $\, \displaystyle 10605417036060 + 06063071450601 \,$ $\, \displaystyle =\,$ $\displaystyle 16668488486661$

which is palindromic.

$7998$ and its reversal converge on the same sequence immediately:

 $\displaystyle 7998 + 9996$ $=$ $\displaystyle 16995$