login
The OEIS Foundation is supported by donations from users of the OEIS and by a grant from the Simons Foundation.

 

Logo


Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A034002 A005150 expanded into single digits. 7
1, 1, 1, 2, 1, 1, 2, 1, 1, 1, 1, 1, 2, 2, 1, 3, 1, 2, 2, 1, 1, 1, 3, 1, 1, 2, 2, 2, 1, 1, 1, 1, 3, 2, 1, 3, 2, 1, 1, 3, 1, 1, 3, 1, 2, 1, 1, 1, 3, 1, 2, 2, 1, 1, 3, 2, 1, 1, 3, 1, 1, 1, 2, 3, 1, 1, 3, 1, 1, 2, 2, 1, 1, 1, 1, 1, 3, 1, 2, 2, 1, 1, 3, 3, 1, 1, 2, 1, 3, 2, 1, 1, 3, 2, 1, 2, 2, 2, 1 (list; graph; refs; listen; history; text; internal format)
OFFSET

1,4

COMMENTS

A005150(n) = sum{T(n,k)*10^(A005341(n)-k): k=1..A005341(n)}. - Reinhard Zumkeller, Dec 15 2012

LINKS

Reinhard Zumkeller, Rows n = 1..25 of triangle, flattened

J. H. Conway, The weird and wonderful chemistry of audioactive decay, in T. M. Cover and Gopinath, eds., Open Problems in Communication and Computation, Springer, NY 1987, pp. 173-188. DOI: 10.1007/978-1-4612-4808-8_53.

M. Lothaire, Algebraic Combinatorics on Words, Cambridge, 2002, see p. 36.

Kevin Watkins, Abstract Interpretation Using Laziness: Proving Conway's Lost Cosmological Theorem,

Kevin Watkins, Proving Conway's Lost Cosmological Theorem, POP seminar talk, CMU, Dec 2006

Eric Weisstein's World of Mathematics, Look and Say Sequence

Wikipedia, Look-and-say sequence

EXAMPLE

.  Initial rows                          A005150

.  1:  1                                           1

.  2:  1,1                                        11

.  3:  2,1                                        21

.  4:  1,2,1,1                                  1211

.  5:  1,1,1,2,2,1                            111221

.  6:  3,1,2,2,1,1                            312211

.  7:  1,3,1,1,2,2,2,1                      13112221

.  8:  1,1,1,3,2,1,3,2,1,1                1113213211

.  9:  3,1,1,3,1,2,1,1,1,3,1,2,2,1    31131211131221

-}

PROG

(Haskell)  see Watkins link, p. 3.

import Data.List (group)

a034002 n k = a034002_tabf !! (n-1) !! (k-1)

a034002_row n = a034002_tabf !! (n-1)

a034002_tabf = iterate

               (concat . map (\xs -> [length xs, head xs]) . group) [1]

-- Reinhard Zumkeller, Aug 09 2012

(Python)

from sympy import flatten

l=[1]

L=[1]

n=s=1

y=''

while n<21:

    x=str(l[n - 1]) + ' '

for i in range(len(x) - 1):

        if x[i]==x[i + 1]: s+=1

        else:

            y+=str(s)+str(x[i])

            s=1

    x=''

    n+=1

    l+=[int(y), ]

    L+=[map(int, list(y)), ]

    y=''

    s=1

print l # A005150

print flatten(L) # A034002, Indranil Ghosh, Jul 05 2017

CROSSREFS

See the entry for A005150 for much more about this sequence.

Cf. A088203.

Cf. A005341 (row lengths), A220424 (method B version).

Sequence in context: A322351 A092523 A120891 * A276630 A176048 A322480

Adjacent sequences:  A033999 A034000 A034001 * A034003 A034004 A034005

KEYWORD

nonn,base,tabf

AUTHOR

N. J. A. Sloane.

EXTENSIONS

Offset changed and keyword tabf added by Reinhard Zumkeller, Aug 09 2012

STATUS

approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recent
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified May 27 05:24 EDT 2020. Contains 334649 sequences. (Running on oeis4.)