login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

A336904
The natural sandwiches sequence (see Comments lines for definition).
1
11, 2, 22, 223, 23, 4, 235, 44, 6, 25, 7, 448, 66, 9, 2510, 77, 1, 14, 8, 12, 661, 3, 99, 1420, 15, 771, 61, 117, 141, 88, 81, 91, 220, 612, 13, 32, 29, 92, 310, 24, 152, 5, 71, 26, 6127, 17, 28, 112, 98, 830, 813, 19, 132, 20, 33, 62, 34, 133, 53, 236, 293, 79, 238, 30, 39, 2440, 124, 155, 42, 714
OFFSET
1,1
COMMENTS
Imagine we would have a pair of adjacent integers in the sequence like [1951, 2020]. The sandwich would then be made of the rightmost digit of a(n), the leftmost digit of a(n+1) and, in between, the smallest natural number N not yet inserted into a sandwich. The pair [1951, 2020] would then produce the natural sandwich 1N0. Please note that the pair [2020, 1951] would produce the genuine sandwich 0N1 (we keep the leading zero: these are sandwiches after all, not integers).
Now we want the sequence to be the lexicographically earliest sequence of distinct positive terms such that the successive sandwiches emerging from the sequence rebuild it, digit after digit.
LINKS
EXAMPLE
The first successive sandwiches are: 112, 222, 232, 342, 354, 462,...
The 1st one (112) is visible between a(1) = 11 and a(2) = 2; we get the sandwich by inserting 1 between 1 and 2.
The 2nd sandwich (222) is visible between a(2) = 2 and a(3) = 22; we get this sandwich by inserting 2 between 2 and 2.
The 3rd sandwich (232) is visible between a(3) = 22 and a(4) = 223; we get this sandwich by inserting 3 between 2 and 2;
The 4th sandwich (342) is visible between a(4) = 223 and a(5) = 23; we get this sandwich by inserting 4 between 3 and 2; etc.
The successive sandwiches rebuild, digit by digit, the starting sequence.
CROSSREFS
Cf. A335600.
Sequence in context: A040120 A365220 A176592 * A051309 A077344 A364697
KEYWORD
base,nonn
AUTHOR
Carole Dubois and Eric Angelini, Aug 07 2020
STATUS
approved