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.

A164766 Smallest number m such that exactly n odd numbers can be seen as proper subsequences of m in decimal representation.

Original entry on oeis.org

1, 10, 13, 103, 113, 131, 135, 1013, 1031, 1035, 1135, 1231, 1235, 1351, 1357, 10325, 10213, 10135, 10235, 10315, 10351, 10357, 11357, 12431, 12135, 13251, 12315, 12351, 12357, 13571, 13579, 101315, 101235, 103057, 101351, 102431, 102353, 101357, 102135, 103257
Offset: 0

Views

Author

Reinhard Zumkeller, Aug 25 2009

Keywords

Comments

For any term first occurrences of positive even digits (2, 4, 6, 8) are in order. First 2 (if any) before first 4. Any number with an even digit d has all positive even digits < d. Same goes for odd digits (1, 3, 5, 7, 9). - David A. Corneth, Apr 12 2025

Examples

			a(6) = 135 as 135 is the smallest number such that exactly 6 numbers can be seen as proper subsequences of digits of 135 (namely 1, 3, 5, 13, 15, 35). Note that 135 is no proper substring of 135. - _David A. Corneth_, Apr 12 2025
153 is no term as the first 5 is before the first 3 and 5 is a larger odd digit than 3. - _David A. Corneth_, Apr 12 2025
		

Crossrefs

Cf. A045888.

Programs

  • Mathematica
    f[n_] := Count[Union[Most[Rest[Subsets[IntegerDigits[n]]]]], ?(First[#] > 0 && OddQ[Last[#]] &)]; seq[len] := Module[{s = Table[0, {len}], c = 0, m = 1, i}, While[c < len, i = f[m] + 1; If[i <= len && s[[i]] == 0, c++; s[[i]] = m]; m++]; s]; seq[20] (* Amiram Eldar, Apr 12 2025 *)
  • PARI
    \\ See Corneth link

Formula

A045888(a(n)) = n and A045888(m) <> n for m < a(n).

Extensions

Revised and a(25)-a(39) added by Amiram Eldar, Apr 12 2025