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.

A010061 Binary self or Colombian numbers: numbers that cannot be expressed as the sum of distinct terms of the form 2^k+1 (k>=0), or equivalently, numbers not of form m + sum of binary digits of m.

Original entry on oeis.org

1, 4, 6, 13, 15, 18, 21, 23, 30, 32, 37, 39, 46, 48, 51, 54, 56, 63, 71, 78, 80, 83, 86, 88, 95, 97, 102, 104, 111, 113, 116, 119, 121, 128, 130, 133, 135, 142, 144, 147, 150, 152, 159, 161, 166, 168, 175, 177, 180, 183, 185, 192, 200, 207, 209, 212, 215, 217
Offset: 1

Views

Author

Keywords

Comments

No two consecutive values appear in this sequence (see Links). - Griffin N. Macris, May 31 2020
The asymptotic density of this sequence is (1/8) * (2 - Sum_{n>=1} 1/2^a(n))^2 = 0.252660... (A242403). - Amiram Eldar, Nov 28 2020

References

  • Steven R. Finch, Mathematical Constants, Cambridge, 2003, Section 2.24, pp. 179-180.
  • József Sándor and Borislav Crstici, Handbook of Number theory II, Kluwer Academic Publishers, 2004, Chapter 4, pp. 384-386.
  • G. Troi and U. Zannier, Note on the density constant in the distribution of self-numbers, Bolletino U. M. I. (7) 9-A (1995), 143-148.

Crossrefs

Complement of A228082, or equally, numbers which do not occur in A092391. Gives the positions of zeros (those occurring after a(0)) in A228085-A228087 and positions of ones in A227643. Leftmost column of A228083. Base-10 analog: A003052.

Programs

  • Haskell
    a010061 n = a010061_list !! (n-1)
    a010061_list = filter ((== 0) . a228085) [1..]
    -- Reinhard Zumkeller, Oct 13 2013
    
  • Maple
    # For Maple code see A230091. - N. J. A. Sloane, Oct 10 2013
  • Mathematica
    Table[n + Total[IntegerDigits[n, 2]], {n, 0, 300}] // Complement[Range[Last[#]], #]& (* Jean-François Alcover, Sep 03 2013 *)
  • PARI
    /* Gen(n, b) returns a list of the generators of n in base b. Written by Max Alekseyev (see Alekseyev et al., 2021).
    For example, Gen(101, 10) returns [91, 101]. - N. J. A. Sloane, Jan 02 2022 */
    { Gen(u, b=10) = my(d, m, k);
      if(u<0 || u==1, return([]); );
      if(u==0, return([0]); );
      d = #digits(u, b)-1;
      m = u\b^d;
      while( sumdigits(m, b) > u - m*b^d,
        m--;
        if(m==0, m=b-1; d--; );
      );
      k = u - m*b^d - sumdigits(m, b);
      vecsort( concat( apply(x->x+m*b^d, Gen(k, b)),
                       apply(x->m*b^d-1-x, Gen((b-1)*d-k-2, b)) ) );
    }

Extensions

More terms from Antti Karttunen, Aug 17 2013
Better definition from Matthew C. Russell, Oct 08 2013