This site is supported by donations to The OEIS Foundation.

 Hints (Greetings from The On-Line Encyclopedia of Integer Sequences!)
 A007651 Describe the previous term! (method B - initial term is 1). (Formerly M4768) 20

%I M4768

%S 1,11,12,1121,122111,112213,12221131,1123123111,12213111213113,

%T 11221131132111311231,12221231123121133112213111,

%U 1123112131122131112112321222113113

%N Describe the previous term! (method B - initial term is 1).

%C Method B = 'digit'-indication followed by 'frequency'.

%D N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).

%H _Reinhard Zumkeller_, <a href="/A007651/b007651.txt">Table of n, a(n) for n = 1..25</a>

%F a(n) = sum{A220424(n,k)*10^(A005341(n)-k): k=1..A005341(n)}. - _Reinhard Zumkeller_, Dec 15 2012

%e E.g. the term after 1121 is obtained by saying "1 twice, 2 once, 1 once", which gives 122111.

%t RunLengthEncode[ x_List ] := (Through[ {First, Length}[ #1 ] ] &) /@ Split[ x ]; LookAndSay[ n_, d_:1 ] := NestList[ Flatten[ Reverse /@ RunLengthEncode[ # ] ] &, {d}, n - 1 ]; F[ n_ ] := LookAndSay[ n, 1 ][ [ n ] ]; Table[ FromDigits[ Reverse[ F[ n ] ] ], {n, 1, 15} ]

%t a[1] = 1; a[n_] := a[n] = FromDigits[Flatten[{First[#], Length[#]}&/@Split[IntegerDigits[a[n-1]]]]]; Map[a, Range[25]] (* _Peter J. C. Moses_, Mar 22 2013 *)

%o a007651 = foldl1 (\v d -> 10 * v + d) . map toInteger . a220424_row

%o -- _Reinhard Zumkeller_, Dec 15 2012

%Y Cf. A005150, A022470, A022499, A022500-A022505.

%K nonn,base,easy,nice

%O 1,2

%A _N. J. A. Sloane_.

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Transforms | Puzzles | Hot | Classics
Recent Additions | More pages | Superseeker | Maintained by The OEIS Foundation Inc.

Content is available under The OEIS End-User License Agreement .