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.

Showing 1-3 of 3 results.

A171764 Binary expansion of numbers in A171763.

Original entry on oeis.org

101, 1001, 1011, 10001, 10011, 10101, 10111, 100001, 100011, 100101, 100111, 101001, 101011, 101101, 101111, 1000001, 1000011, 1000101, 1000111, 1001001, 1001011, 1001101, 1001111, 1010001, 1010011, 1010101, 1010111, 1011001, 1011011, 1011101, 1011111, 10000001
Offset: 1

Views

Author

N. J. A. Sloane, Oct 12 2010

Keywords

Crossrefs

Programs

  • Mathematica
    bin[n_] := FromDigits[IntegerDigits[n, 2]]; bin /@ Select[Range[3, 130, 2], IntegerDigits[#, 2][[1 ;; 2]] == {1, 0} &] (* Amiram Eldar, Sep 01 2020 *)

Formula

a(n) = A007088(A171763(n)). - Amiram Eldar, Sep 01 2020

A171757 Even numbers whose binary expansion begins 10.

Original entry on oeis.org

2, 4, 8, 10, 16, 18, 20, 22, 32, 34, 36, 38, 40, 42, 44, 46, 64, 66, 68, 70, 72, 74, 76, 78, 80, 82, 84, 86, 88, 90, 92, 94, 128, 130, 132, 134, 136, 138, 140, 142, 144, 146, 148, 150, 152, 154, 156, 158, 160, 162, 164, 166, 168, 170, 172, 174, 176, 178
Offset: 1

Views

Author

N. J. A. Sloane, Oct 12 2010

Keywords

Crossrefs

A subsequence of A004754.

Programs

  • Maple
    n := 1 ;
    for k from 2 to 4000 by 2 do
        dgs := convert(k,base,2) ;
        if op(-1,dgs) = 1 and op(-2,dgs) = 0 then
            printf("%d %d\n",n,k) ;
            n := n+1 ;
        end if;
    end do: # R. J. Mathar, Jan 31 2015
  • Mathematica
    Select[Range[2, 200, 2], IntegerDigits[#, 2][[1 ;; 2]] == {1, 0} &] (* Amiram Eldar, Sep 01 2020 *)
  • PARI
    isok(m) = if (!(m%2), my(b=binary(m)); (b[1]==1) && (b[2]==0)); \\ Michel Marcus, Jun 24 2021
  • Python
    from itertools import count, product, takewhile
    def agen(): # generator for sequence
        yield 2
        for digits in count(0):
            for mid in product("01", repeat=digits):
                yield int("10" + "".join(mid) + "0", 2)
    def aupto(lim): return list(takewhile(lambda x: x <= lim, agen()))
    print(aupto(180)) # Michael S. Branicky, Jun 24 2021
    

Formula

a(n) = 2*A004761(n+1). - Jon Maiga / Georg Fischer, Jun 24 2021

A171781 Numbers for which the second bit of the binary expansion is equal to the last bit.

Original entry on oeis.org

2, 3, 4, 7, 8, 10, 13, 15, 16, 18, 20, 22, 25, 27, 29, 31, 32, 34, 36, 38, 40, 42, 44, 46, 49, 51, 53, 55, 57, 59, 61, 63, 64, 66, 68, 70, 72, 74, 76, 78, 80, 82, 84, 86, 88, 90, 92, 94, 97, 99, 101, 103, 105, 107, 109, 111, 113, 115, 117, 119, 121, 123, 125
Offset: 1

Views

Author

N. J. A. Sloane, Oct 12 2010

Keywords

Comments

Note that A005843 INTERSECT A171781 = A171757. This is an example of two sequences which both have a limiting density, but whose intersection does not.

Examples

			10 is a term since its binary representation is 1010 and both its second and last bits are 0. - _Amiram Eldar_, Sep 01 2020
		

Crossrefs

Programs

  • Mathematica
    Select[Range[2, 125], (d = IntegerDigits[#, 2])[[2]] == d[[-1]] &] (* Amiram Eldar, Sep 01 2020 *)
Showing 1-3 of 3 results.