login
A023989
Look and Say sequence: describe the previous term! (method C - initial term is 2).
6
2, 12, 1112, 3112, 211213, 312213, 212223, 114213, 31121314, 41122314, 31221324, 21322314, 21322314, 21322314, 21322314, 21322314, 21322314, 21322314, 21322314, 21322314, 21322314, 21322314, 21322314, 21322314, 21322314, 21322314, 21322314, 21322314, 21322314
OFFSET
0,1
COMMENTS
Method C = 'frequency' followed by 'digit'-indication with digits in increasing order.
Converges to 21322314 at the eleventh term.
Depending on the initial value, the sequence may converge to a cycle of 2 or more values, for example: 123456, 111213141516, 711213141516, 61121314151617, 71121314152617, 61221314151627, 51321314152617, 51222314251617, 41421314251617, 51221334151617, 51222314251617, 41421314251617, 51221334151617. [Corrected by Pontus von Brömssen, Jun 04 2023]
a(n) = A005151(n) for n > 6. - Reinhard Zumkeller, Jan 26 2014
FORMULA
a(n) = A047842(a(n-1)). - Pontus von Brömssen, Jun 04 2023
EXAMPLE
a(1) = 12, so a(2) = 1112 because 12 contains a digit 1 and a digit 2; a(3) = 3112 because 1112 contains three digits 1 and a digit 2
PROG
(Haskell)
import Data.List (group, sort, transpose)
a023989 n = a023989_list !! (n-1)
a023989_list = 2 : f [2] :: [Integer] where
f xs = (read $ concatMap show ys) : f (ys) where
ys = concat $ transpose [map length zss, map head zss]
zss = group $ sort xs
-- Reinhard Zumkeller, Jan 26 2014
CROSSREFS
KEYWORD
nonn,base
AUTHOR
Artemario Tadeu Medeiros da Silva (artemario(AT)uol.com.br), Mar 19 2002
STATUS
approved