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.

This page as a plain text file.
%I A164766 #32 Apr 13 2025 16:32:15
%S A164766 1,10,13,103,113,131,135,1013,1031,1035,1135,1231,1235,1351,1357,
%T A164766 10325,10213,10135,10235,10315,10351,10357,11357,12431,12135,13251,
%U A164766 12315,12351,12357,13571,13579,101315,101235,103057,101351,102431,102353,101357,102135,103257
%N A164766 Smallest number m such that exactly n odd numbers can be seen as proper subsequences of m in decimal representation.
%C A164766 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
%H A164766 David A. Corneth, <a href="/A164766/b164766.txt">Table of n, a(n) for n = 0..991</a> (first 101 terms from Amiram Eldar, terms <= 10^10)
%H A164766 David A. Corneth, <a href="/A164766/a164766.gp.txt">PARI program</a>
%F A164766 A045888(a(n)) = n and A045888(m) <> n for m < a(n).
%e A164766 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
%e A164766 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
%t A164766 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 *)
%o A164766 (PARI) \\ See Corneth link
%Y A164766 Cf. A045888.
%K A164766 nonn,base
%O A164766 0,2
%A A164766 _Reinhard Zumkeller_, Aug 25 2009
%E A164766 Revised and a(25)-a(39) added by _Amiram Eldar_, Apr 12 2025