|
|
A066710
|
|
RATS: Reverse Add Then Sort the digits applied to previous term, starting with 3.
|
|
10
|
|
|
3, 6, 12, 33, 66, 123, 444, 888, 1677, 3489, 12333, 44556, 111, 222, 444, 888, 1677, 3489, 12333, 44556, 111, 222, 444, 888, 1677, 3489, 12333, 44556, 111, 222, 444, 888, 1677, 3489, 12333, 44556, 111, 222, 444, 888, 1677, 3489, 12333
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
1,1
|
|
COMMENTS
|
|
|
LINKS
|
|
|
FORMULA
|
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).
Periodic with period 8.
a(n) = a(n-8) for n > 14.
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)
|
|
EXAMPLE
|
668 -> 668 + 866 = 1534 -> 1345.
|
|
MATHEMATICA
|
f[k_] := Module[{m = FromDigits[Reverse[IntegerDigits[k]]]}, FromDigits[ Sort[ IntegerDigits[k + m]]]]; NestList[f, 3, 50] (* Harvey P. Dale, Jan 18 2011 *)
|
|
PROG
|
(Haskell)
|
|
CROSSREFS
|
|
|
KEYWORD
|
nonn,base
|
|
AUTHOR
|
|
|
STATUS
|
approved
|
|
|
|