cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

Previous Showing 11-20 of 51 results. Next

A151964 a(n) = smallest number that leads to a new cycle under the Kaprekar map of A151949.

Original entry on oeis.org

0, 102, 1001, 10001, 10003, 10045, 100001, 100147, 100155, 1000001, 10000001, 10000012, 10000024, 10001567, 100000001, 100000002, 100011555, 1000000001, 1000000003, 1000000004, 1000000005, 1000000014, 1000000024, 1000002499
Offset: 1

Views

Author

Klaus Brockhaus, Aug 19 2009

Keywords

Crossrefs

In other bases: A164887 (base 2), A165009 (base 3), A165029 (base 4), A165048 (base 5), A165068 (base 6), A165087 (base 7), A165107 (base 8), A165127 (base 9). [From Joseph Myers, Sep 05 2009]

Extensions

Extended by Joseph Myers, Aug 22 2009

A151963 (Length of preperiodic part) + (length of cycle) of trajectory of n under iteration of the Kaprekar map in A151949.

Original entry on oeis.org

1, 2, 2, 2, 2, 2, 2, 2, 2, 2, 3, 2, 3, 7, 5, 6, 4, 4, 6, 5, 7, 3, 2, 3, 7, 5, 6, 4, 4, 6, 5, 7, 3, 2, 3, 7, 5, 6, 4, 4, 6, 5, 7, 3, 2, 3, 7, 5, 6, 4, 4, 6, 5, 7, 3, 2, 3, 7, 5, 6, 4, 4, 6, 5, 7, 3, 2, 3, 7, 5, 6, 4, 4, 6, 5, 7, 3, 2, 3, 7, 5, 6, 4, 4, 6, 5, 7, 3, 2, 3, 7, 5, 6, 4, 4, 6, 5, 7, 3
Offset: 0

Views

Author

N. J. A. Sloane, Aug 19 2009

Keywords

Comments

Equals A151962(n) + 1 iff n < 10001 (when a cycle of length greater than 1 occurs for the first time).

Examples

			13->18->63->27->45->9->0->0, so a(13)=6+1 = 7.
		

Crossrefs

In other bases: A164886 (base 2), A164996 (base 3), A165015 (base 4), A165035 (base 5), A165054 (base 6), A165074 (base 7), A165093 (base 8), A165113 (base 9). - Joseph Myers, Sep 05 2009

Programs

  • Maple
    # Maple program from R. J. Mathar:
    A151949 := proc(n)
    local tup;
    tup := sort(convert(n,base,10)) ;
    add( (op(i,tup)-op(-i,tup)) *10^(i-1),i=1..nops(tup)) :
    end:
    A151963 := proc(n)
    local tra,x ;
    tra := [n] ;
    x := n ;
    while true do
    x := A151949(x) ;
    if x in tra then
    RETURN(nops(tra)) ;
    fi;
    tra := [op(tra),x] :
    od:
    end:
    seq(A151963(n),n=0..120) ;
  • Mathematica
    f[n_] := Module[{idn = IntegerDigits@n, idns}, idns = Sort@ idn; FromDigits@ Reverse@ idns - FromDigits@ idns]; g[n_] := Length[ NestWhileList[ f, n, UnsameQ, All]] - 1; Table[g@n, {n, 0, 104}] (* Robert G. Wilson v, Aug 20 2009 *)

Extensions

Typos corrected by Joseph Myers, Aug 20 2009
More terms from R. J. Mathar and Robert G. Wilson v, Aug 20 2009

A069746 Four-digit numbers that do not resolve to 6174 under the Kaprekar map (see A151949).

Original entry on oeis.org

1000, 1011, 1101, 1110, 1111, 1112, 1121, 1211, 1222, 2111, 2122, 2212, 2221, 2222, 2223, 2232, 2322, 2333, 3222, 3233, 3323, 3332, 3333, 3334, 3343, 3433, 3444, 4333, 4344, 4434, 4443, 4444, 4445, 4454, 4544, 4555, 5444, 5455, 5545, 5554, 5555, 5556
Offset: 1

Views

Author

Harvey P. Dale, Apr 22 2002

Keywords

Comments

Dinesh Thakur (email, Mar 01 2015) points out that Kaprekar himself would pad numbers with fewer than four digits by adding initial zeros, so that for him the only four-digit exceptions are those with all four digits equal. - N. J. A. Sloane, Mar 01 2015

Crossrefs

Cf. A151949.

Extensions

There are precisely 77 such numbers.

A164723 Numbers belonging to cycles of length 2 under the Kaprekar map A151949.

Original entry on oeis.org

53955, 59994, 8733209876622, 9665429654331, 873332098766622, 966543296654331, 8764421997755322, 8765431997654322, 87333320987666622, 96654332966654331, 8733333209876666622, 9665433329666654331
Offset: 1

Views

Author

Joseph Myers, Aug 23 2009

Keywords

Crossrefs

A164724 Least element of each cycle of length 2 under the Kaprekar map A151949.

Original entry on oeis.org

53955, 8733209876622, 873332098766622, 8764421997755322, 87333320987666622, 8733333209876666622, 873333332098766666622, 87333333320987666666622, 87764442219997775553222, 8733333333209876666666622
Offset: 1

Views

Author

Joseph Myers, Aug 23 2009

Keywords

Crossrefs

A164725 Numbers belonging to cycles of length 3 under the Kaprekar map A151949.

Original entry on oeis.org

64308654, 83208762, 86526432, 6431088654, 6433086654, 6543086544, 8321088762, 8332087662, 8653266432, 8655264432, 8732087622, 8765264322, 9751088421, 9755084421, 9775084221, 643110888654, 643310886654, 643330866654
Offset: 1

Views

Author

Joseph Myers, Aug 23 2009

Keywords

Crossrefs

A164726 Least element of each cycle of length 3 under the Kaprekar map A151949.

Original entry on oeis.org

64308654, 6431088654, 6433086654, 6543086544, 9751088421, 643110888654, 643310886654, 643330866654, 654310886544, 654330866544, 655430865444, 975110888421, 975310886421, 975510884421, 997510884201, 64311108888654
Offset: 1

Views

Author

Joseph Myers, Aug 23 2009

Keywords

Crossrefs

A164727 Numbers belonging to cycles of length 5 under the Kaprekar map A151949.

Original entry on oeis.org

86420987532, 86541975432, 87641975322, 88431976512, 96641975331, 8643209876532, 8654209875432, 8654319765432, 8764209875322, 8764319765322, 8765419754322, 8843209876512, 8843319766512, 8854319765412, 8874319765212
Offset: 1

Views

Author

Joseph Myers, Aug 23 2009

Keywords

Crossrefs

A164728 Least element of each cycle of length 5 under the Kaprekar map A151949.

Original entry on oeis.org

86420987532, 8643209876532, 8654209875432, 8764209875322, 864332098766532, 865432098765432, 876432098765322, 876542098754322, 885432098765412, 86433320987666532, 86543320987665432, 87643320987665322
Offset: 1

Views

Author

Joseph Myers, Aug 23 2009

Keywords

Crossrefs

A164734 Number of n-digit cycles of length 2 under the Kaprekar map A151949.

Original entry on oeis.org

0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 1, 0, 1, 1, 1, 0, 1, 0, 1, 0, 2, 0, 2, 0, 1, 0, 1, 2, 1, 1, 1, 1, 1, 0, 3, 0, 3, 0, 2, 0, 2, 3, 1, 2, 1, 2, 1, 1, 4, 1, 4, 0, 3, 0, 3, 4, 2, 3, 2, 3, 1, 2, 5, 2, 5, 1, 4, 1, 4, 5, 3, 4, 3, 4, 2, 3, 7, 3, 6, 2, 5, 2, 5, 7, 4, 6, 4, 5, 3, 4, 9, 4, 8, 3, 7, 3, 6, 9, 5, 8, 5, 7, 4
Offset: 1

Views

Author

Joseph Myers, Aug 23 2009

Keywords

Crossrefs

Formula

Conjectures from Chai Wah Wu, Apr 13 2024: (Start)
a(n) = a(n-7) + a(n-9) + a(n-14) - a(n-16) - a(n-21) - a(n-23) + a(n-30) for n > 41.
G.f.: x*(-x^40 - x^38 - x^36 + x^33 - x^32 + 2*x^31 - x^30 + 2*x^29 - x^28 + x^27 + x^25 - x^24 + 2*x^23 - x^22 + 2*x^21 - 2*x^20 + x^19 - x^16 - x^15 - x^14 + x^13 - x^12 + x^11 - x^4)/(x^30 - x^23 - x^21 - x^16 + x^14 + x^9 + x^7 - 1). (End)
Previous Showing 11-20 of 51 results. Next