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.

A004749 Numbers whose binary expansion contains the substring '110'.

This page as a plain text file.
%I A004749 #35 Mar 29 2021 15:06:59
%S A004749 6,12,13,14,22,24,25,26,27,28,29,30,38,44,45,46,48,49,50,51,52,53,54,
%T A004749 55,56,57,58,59,60,61,62,70,76,77,78,86,88,89,90,91,92,93,94,96,97,98,
%U A004749 99,100,101,102,103,104,105,106,107,108,109,110,111,112,113
%N A004749 Numbers whose binary expansion contains the substring '110'.
%H A004749 Indranil Ghosh, <a href="/A004749/b004749.txt">Table of n, a(n) for n = 1..50000</a>
%H A004749 <a href="/index/Ar#2-automatic">Index entries for 2-automatic sequences</a>.
%F A004749 a(n) ~ n. - _Charles R Greathouse IV_, Oct 23 2015
%e A004749 22 is in the sequence because 22 = 10110_2 and '10110' has '110' as one of its substrings. - _Indranil Ghosh_, Feb 11 2017
%t A004749 Select[Range[200],SequenceCount[IntegerDigits[#,2],{1,1,0}]>0&] (* Requires Mathematica version 10 or later *) (* _Harvey P. Dale_, Mar 07 2017 *)
%o A004749 (Python)
%o A004749 i=j=0
%o A004749 while j<=500:
%o A004749     if "110" in bin(i)[2:]:
%o A004749         print(str(j)+" "+str(i))
%o A004749         j+=1
%o A004749     i+=1 # _Indranil Ghosh_, Feb 11 2017
%o A004749 (PARI) is(n)=while(n>5,if(bitand(n,7)==6, return(1)); n>>=1); 0 \\ _Charles R Greathouse IV_, Feb 11 2017
%Y A004749 Cf. A004748, A004750, A004751, A004752, A004753.
%K A004749 nonn,base,easy
%O A004749 1,1
%A A004749 _N. J. A. Sloane_
%E A004749 Offset corrected by _Charles R Greathouse IV_, Feb 11 2017