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.

A016037 Map numbers to number of letters in English name; sequence gives number of steps to converge (to 4).

Original entry on oeis.org

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

Views

Author

Keywords

Comments

The smallest n with a(n) = 7 is 1103323373373373373373373373373 (one nonillion one hundred and three octillion ...) which has 323 letters. - Roland Kneer, Jul 04 2013
From Robert G. Wilson v, Mar 13 2017: (Start)
First occurrence of k = 0,1,2,...: 4, 0, 3, 1, 11, 23, 323, 1103323373373373373373373373373, etc.;
0 only occurs at 4;
1 only occurs for n = 0, 5 & 9;
2 only occurs for n = 3, 7, 8, 17, 21, 22, 26, 31, 32, 36, 40, 44, 45, 49, 50, 54, 55, 59, 60, 64, 65, 69, 81, 82, 86, 91, 92 & 96;
3 occurs for n = 1, 2, 6, 10, 13, 14, 15, 16, 18, 19, 41, 42, 46, 51, 52, ..., ;
4 occurs for n = 11, 12, 20, 24, 25, 29, 30, 34, 35, 39, 43, 47, 48, 53, ..., ;
5 occurs for n = 23, 27, 28, 33, 37, 38, 73, 74, 75, 77, 78, 79, 83, 87, ..., ;
6 occurs for n = 323, 327, 328, 333, 337, 338, 374, 375, 379, 383, 387, ..., ; etc.
(End)
The basis of this sequence is that integers are named without the use of "and". As a minor correction at the time of this comment, therefore, the 31-digit number above beginning 1103 ... should be described as "one nonillion one hundred three octillion ...". If naming is done in accordance with UK English usage ("one hundred", "one hundred and one", ...), the first occurrence of a(n) = 0, 1, 2, 3, 4, 5, 6, 7, ... is for n = 4, 0, 3, 1, 11, 23, 124, 113373373373, ... Ian Duff, Dec 04 2019

Examples

			1 -> 3 -> 5 -> 4, so a(1) = 3.
		

Programs

  • Mathematica
    (* get t from A005589 *) f[n_] := Length@ NestWhileList[ StringLength@ t[[# + 1]] &, n, UnsameQ, 2] - 2; Array[f, 100, 0] (* Robert G. Wilson v, Jun 01 2012 *)

Extensions

Corrected at the suggestion of Kevin Ryde by Robert G. Wilson v, Jun 01 2012