login
RATS: Reverse Add Then Sort the digits applied to previous term, starting with 3.
10

%I #31 Jun 01 2020 12:28:24

%S 3,6,12,33,66,123,444,888,1677,3489,12333,44556,111,222,444,888,1677,

%T 3489,12333,44556,111,222,444,888,1677,3489,12333,44556,111,222,444,

%U 888,1677,3489,12333,44556,111,222,444,888,1677,3489,12333

%N RATS: Reverse Add Then Sort the digits applied to previous term, starting with 3.

%C a(1) = A114614(1) = 3; A114611(3) = 8. [_Reinhard Zumkeller_, Mar 14 2012]

%H R. K. Guy, <a href="http://www.jstor.org/stable/2325149">Conway's RATS and other reversals</a>, Amer. Math. Monthly, 96 (1989), 425-428.

%H Eric Weisstein's World of Mathematics, <a href="http://mathworld.wolfram.com/RATSSequence.html">RATS Sequence</a>

%H <a href="/index/Rec#order_08">Index entries for linear recurrences with constant coefficients</a>, signature (0,0,0,0,0,0,0,1).

%F Let a(n) = k, form m by Reversing the digits of k, Add m to k Then Sort the digits of the sum into increasing order to get a(n+1).

%F Periodic with period 8.

%F a(n+1) = A036839(a(n)). [_Reinhard Zumkeller_, Mar 14 2012]

%F From _Chai Wah Wu_, Feb 07 2020: (Start)

%F a(n) = a(n-8) for n > 14.

%F G.f.: x*(-99*x^13 - 45*x^12 - 44523*x^11 - 12321*x^10 - 3483*x^9 - 1674*x^8 - 888*x^7 - 444*x^6 - 123*x^5 - 66*x^4 - 33*x^3 - 12*x^2 - 6*x - 3)/(x^8 - 1). (End)

%e 668 -> 668 + 866 = 1534 -> 1345.

%t f[k_] := Module[{m = FromDigits[Reverse[IntegerDigits[k]]]}, FromDigits[ Sort[ IntegerDigits[k + m]]]]; NestList[f, 3, 50] (* _Harvey P. Dale_, Jan 18 2011 *)

%o (Haskell)

%o a066710_list = iterate a036839 3 -- _Reinhard Zumkeller_, Mar 14 2012

%Y Cf. A004000, A036839, A066711, A209878, A209879, A209880.

%K nonn,base

%O 1,1

%A _N. J. A. Sloane_, Jan 19 2002