|
Search: id:A151949
|
|
|
| A151949 |
|
a(n) = image of n under the Kaprekar map n -> (n with digits sorted into descending order) - (n with digits sorted into ascending order). |
|
+0 46
|
|
| 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 9, 18, 27, 36, 45, 54, 63, 72, 18, 9, 0, 9, 18, 27, 36, 45, 54, 63, 27, 18, 9, 0, 9, 18, 27, 36, 45, 54, 36, 27, 18, 9, 0, 9, 18, 27, 36, 45, 45, 36, 27, 18, 9, 0, 9, 18, 27, 36, 54, 45, 36, 27, 18, 9, 0, 9, 18, 27, 63, 54, 45, 36, 27
(list; graph; listen)
|
|
|
OFFSET
|
0,11
|
|
|
COMMENT
|
Entries are multiples of 9 - see A151950.
|
|
LINKS
|
Joseph Myers and Robert G. Wilson v, (rgwv@rgwv.com), Table of n, a(n) for n = 0..1000 .
R. J. Mathar, Maple code for A151949 and A151959
Joseph Myers, C program for computing sequences related to the Kaprekar map
Joseph Myers, List of cycles under Kaprekar map (all numbers with <= 60 digits; cycles are represented by their smallest value)
Index entries for the Kaprekar map
|
|
MATHEMATICA
|
f[n_] := Module[{idn = IntegerDigits@n, idns}, idns = Sort@ idn; FromDigits@ Reverse@ idns - FromDigits@ idns]; Table[ f@n, {n, 0, 200}] (From Harvey P. Dale, Aug 18 2009)
|
|
CROSSREFS
|
In other bases: A164884 (base 2), A164993 (base 3), A165012 (base 4), A165032 (base 5), A165051 (base 6), A165071 (base 7), A165090 (base 8), A165110 (base 9). [From Joseph Myers (jsm(AT)polyomino.org.uk), Sep 05 2009]
Sequence in context: A132268 A029687 A132696 this_sequence A056965 A062047 A117465
Adjacent sequences: A151946 A151947 A151948 this_sequence A151950 A151951 A151952
|
|
KEYWORD
|
nonn,base
|
|
AUTHOR
|
N. J. A. Sloane (njas(AT)research.att.com), Aug 18 2009
|
|
EXTENSIONS
|
More terms from Robert G. Wilson v (rgwv@rgwv.com), Aug 19 2009
|
|
|
Search completed in 0.002 seconds
|