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 24 results. Next

A005151 Summarize the previous term (digits in increasing order), starting with a(1) = 1.

Original entry on oeis.org

1, 11, 21, 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
Offset: 1

Views

Author

Keywords

Comments

a(n) = 21322314 for n > 12. - Reinhard Zumkeller, Jan 25 2014
The digits of each term a(n) are a permutation of those of the corresponding term A063850(n). - Chayim Lowen, Jul 16 2015

Examples

			The term after 312213 is obtained by saying "Two 1's, two 2's, two 3's", which gives 21-22-23, i.e., 212223.
		

References

  • C. Fleenor, "A litteral sequence", Solution to Problem 2562, Journal of Recreational Mathematics, vol. 31 No. 4 pp. 307 2002-3 Baywood NY.
  • Problem in J. Recreational Math., 30 (4) (1999-2000), p. 309.
  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).

Crossrefs

Cf. A005150, A047842. See A083671 for another version.

Programs

  • Haskell
    import Data.List (group, sort, transpose)
    a005151 n = a005151_list !! (n-1)
    a005151_list = 1 : f [1] :: [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 25 2014
    
  • Mathematica
    RunLengthEncode[x_List] := (Through[{Length, First}[ #1]] &) /@ Split[ Sort[x]]; LookAndSay[n_, d_:1] := NestList[ Flatten[ RunLengthEncode[ # ]] &, {d}, n - 1]; F[n_] := LookAndSay[n, 1][[n]]; Table[ FromDigits[ F[n]], {n, 25}] (* Robert G. Wilson v, Jan 22 2004 *)
    a[1] = 1; a[n_] := a[n] = FromDigits[Reverse /@ Sort[Tally[a[n-1] // IntegerDigits], #1[[1]] < #2[[1]]&] // Flatten]; Array[a, 26] (* Jean-François Alcover, Jan 25 2016 *)
  • PARI
    say(n) = {digs = digits(n); d = vecsort(digs,,8); s = ""; for (k=1, #d, nbk = #select(x->x==d[k], digs); s = concat(s, Str(nbk)); s = concat(s, d[k]);); eval(s);}
    lista(nn) = {print1(n = 1, ", "); for (k=1, nn, m = say(n); print1(m, ", "); n = m;);} \\ Michel Marcus, Feb 12 2016
    
  • PARI
    a(n,show_all=1,a=1)={for(i=2,n,show_all&&print1(a",");a=A047842(a));a} \\ M. F. Hasler, Feb 25 2018
    
  • PARI
    Vec(x*(1 + 10*x + 10*x^2 + 1091*x^3 + 2000*x^4 + 208101*x^5 + 101000*x^6 - 99990*x^7 - 98010*x^8 + 31007101*x^9 + 10001000*x^10 - 9900990*x^11 - 9899010*x^12) / (1 - x) + O(x^40)) \\ Colin Barker, Aug 23 2018
    
  • Python
    from itertools import accumulate, groupby, repeat
    def summarize(n, _):
      return int("".join(str(len(list(g)))+k for k, g in groupby(sorted(str(n)))))
    def aupton(nn): return list(accumulate(repeat(1, nn+1), summarize))
    print(aupton(25)) # Michael S. Branicky, Jan 11 2021

Formula

a(n+1) = A047842(a(n)). - M. F. Hasler, Feb 25 2018
G.f.: x*(1 + 10*x + 10*x^2 + 1091*x^3 + 2000*x^4 + 208101*x^5 + 101000*x^6 - 99990*x^7 - 98010*x^8 + 31007101*x^9 + 10001000*x^10 - 9900990*x^11 - 9899010*x^12) / (1 - x). - Colin Barker, Aug 23 2018

A138484 Say what you see in previous term, from the right, reporting total number for each digit encountered. Initial term is 0.

Original entry on oeis.org

0, 10, 1011, 3110, 102113, 13311210, 10411223, 1322311410, 1041142322, 3213243110, 1031331422, 2214313310, 1031331422, 2214313310, 1031331422, 2214313310, 1031331422, 2214313310, 1031331422, 2214313310, 1031331422
Offset: 0

Views

Author

Keywords

Comments

After a while sequence has period 2 -> {1031331422,2214313310}

Examples

			To get the term after 102113, we say: one 3's, three 1's, one 2's, one 0's, so 13311210.
		

Crossrefs

A138493 Say what you see in previous term, from the right, reporting total number for each digit encountered. Initial term is 9.

Original entry on oeis.org

9, 19, 1911, 3119, 192113, 13311219, 19411223, 1322311419, 1941142322, 3213243119, 1931331422, 2214313319, 1931331422, 2214313319, 1931331422, 2214313319, 1931331422, 2214313319, 1931331422, 2214313319, 1931331422
Offset: 0

Views

Author

Keywords

Comments

After a while sequence has period 2 -> {1931331422,2214313319}

Examples

			To get the term after 192113, we say: one 3's, three 1's, one 2's, one 9's, so 13311219
		

Crossrefs

A123132 Describe prime factorization of n (primes in ascending order and with repetition) (method A - initial term is 2).

Original entry on oeis.org

12, 13, 22, 15, 1213, 17, 32, 23, 1215, 111, 2213, 113, 1217, 1315, 42, 117, 1223, 119, 2215, 1317, 12111, 123, 3213, 25, 12113, 33, 2217, 129, 121315, 131, 52, 13111, 12117, 1517, 2223, 137, 12119, 13113, 3215, 141, 121317, 143, 22111, 2315, 12123
Offset: 2

Views

Author

Herman Jamke (hermanjamke(AT)fastmail.fm), Sep 30 2006

Keywords

Comments

Method A = 'frequency' followed by 'digit'-indication. Say 'what you see' in prime factors of n, n>1.

Examples

			2 has "one 2" in its prime decomposition, so a(2)=12.
3 has "one 3" in its prime decomposition, so a(3)=13.
4=2*2 has "two 2" in its prime decomposition, so a(4)=22.
5 has "one 5" in its prime decomposition, so a(5)=15.
6=2*3 has "one 2 and one 3" in its prime decomposition, so a(6)=1213.
.....
		

Crossrefs

Programs

  • Mathematica
    a[n_] := FromDigits@ Flatten@ IntegerDigits[ Reverse /@ FactorInteger@ n]; a/@ Range[2,30] (* Giovanni Resta, Jun 16 2013 *)
  • PARI
    for(n=2,25,factn=factor(n); for(i=1,omega(n),print1(factn[i,2],factn[i,1])); print1(","))
    
  • PARI
    a(n) = my(factn=factor(n), sout = ""); for(i=1, omega(n), sout = concat(sout, Str(factn[i, 2])); sout = concat(sout, Str(factn[i, 1]))); eval(sout); \\ Michel Marcus, Jun 29 2017

A138485 Say what you see in previous term, from the right, reporting total number for each digit encountered. Initial term is 1.

Original entry on oeis.org

1, 11, 21, 1112, 1231, 211312, 223113, 232122, 421113, 13311214, 14411223, 13223124, 14322123, 23322114, 14213223, 23322114, 14213223, 23322114, 14213223, 23322114, 14213223, 23322114, 14213223, 23322114, 14213223
Offset: 0

Views

Author

Keywords

Comments

After a while sequence has period 2 -> {23322114,14213223}

Examples

			To get the term after 211312, we say: two 2's, three 1's, one 3's, so 223113.
		

Crossrefs

A138486 Say what you see in previous term, from the right, reporting total number for each digit encountered. Initial term is 2.

Original entry on oeis.org

2, 12, 1211, 3112, 122113, 133122, 222123, 134211, 31121413, 23411412, 22312413, 23211432, 32231421, 21321423, 23321421, 21321423, 23321421, 21321423, 23321421, 21321423, 23321421, 21321423, 23321421, 21321423
Offset: 0

Views

Author

Keywords

Comments

After a while sequence has period 2 -> {21321423,23321421}

Examples

			To get the term after 122113, we say: one 3's, three 1's, two 2's, so 133122
		

Crossrefs

Extensions

Duplicate term 21321423 removed by Georg Fischer, Sep 18 2023

A138487 Say what you see in previous term, from the right, reporting total number for each digit encountered. Initial term is 3.

Original entry on oeis.org

3, 13, 1311, 3113, 2321, 112213, 133122, 222123, 134211, 31121413, 23411412, 22312413, 23211432, 32231421, 21321423, 23321421, 21321423, 23321421, 21321423, 23321421, 21321423, 23321421, 21321423, 23321421, 21321423
Offset: 0

Views

Author

Keywords

Comments

After a while sequence has period 2 -> {21321423,23321421}

Examples

			To get the term after 112213, we say: one 3's, three 1's, two 2's, so 133122
		

Crossrefs

A138488 Say what you see in previous term, from the right, reporting total number for each digit encountered. Initial term is 4.

Original entry on oeis.org

4, 14, 1411, 3114, 142113, 13311214, 14411223, 13223124, 14322123, 23322114, 14213223, 23322114
Offset: 0

Views

Author

Keywords

Comments

After a while sequence has period 2 -> {23322114,14213223}

Examples

			To get the term after 142113, we say: one 3's, three 1's, one 2's, one 4's, so 13311214
		

Crossrefs

A138489 Say what you see in previous term, from the right, reporting total number for each digit encountered. Initial term is 5.

Original entry on oeis.org

5, 15, 1511, 3115, 152113, 13311215, 15411223, 1322311415, 1541142322, 3213243115, 1531331422, 2214313315, 1531331422, 2214313315, 1531331422, 2214313315, 1531331422, 2214313315, 1531331422, 2214313315, 1531331422
Offset: 0

Views

Author

Keywords

Comments

After a while sequence has period 2 -> {1531331422,2214313315}

Examples

			To get the term after 152113, we say: one 3's, three 1's, one 2's, one 5's, so 13311215
		

Crossrefs

A138490 Say what you see in previous term, from the right, reporting total number for each digit encountered. Initial term is 6.

Original entry on oeis.org

6, 16, 1611, 3116, 162113, 13311216, 16411223, 1322311416, 1641142322, 3213243116, 1631331422, 2214313316, 1631331422, 2214313316, 1631331422, 2214313316, 1631331422, 2214313316, 1631331422, 2214313316, 1631331422
Offset: 0

Views

Author

Keywords

Comments

After a while sequence has period 2 -> {1631331422,2214313316}

Examples

			To get the term after 162113, we say: one 3's, three 1's, one 2's, one 6's, so 13311216
		

Crossrefs

Previous Showing 11-20 of 24 results. Next