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.

A272604 Maximum subrange sum over n written out in binary with -1 for each zero (cf. A276691).

Original entry on oeis.org

0, 1, 1, 2, 1, 1, 2, 3, 1, 1, 1, 2, 2, 2, 3, 4, 1, 1, 1, 2, 1, 1, 2, 3, 2, 2, 2, 3, 3, 3, 4, 5, 1, 1, 1, 2, 1, 1, 2, 3, 1, 1, 1, 2, 2, 2, 3, 4, 2, 2, 2, 2, 2, 2, 3, 4, 3, 3, 3, 4, 4, 4, 5, 6, 1, 1, 1, 2, 1, 1, 2, 3, 1, 1, 1, 2, 2, 2, 3, 4, 1, 1, 1, 2, 1, 1, 2, 3, 2, 2, 2, 3, 3, 3, 4, 5, 2, 2, 2, 2, 2, 2, 2, 3, 2, 2, 2, 3, 3, 3, 4, 5, 3, 3, 3, 3, 3, 3, 4, 5, 4, 4, 4, 5
Offset: 0

Views

Author

Joerg Arndt, Sep 14 2016

Keywords

Examples

			   n [ binary n ]   a(n)
   0 [ - - - - - ]   0
   1 [ - - - - + ]   1
   2 [ - - - + - ]   1
   3 [ - - - + + ]   2
   4 [ - - + - - ]   1
   5 [ - - + - + ]   1
   6 [ - - + + - ]   2
   7 [ - - + + + ]   3
   8 [ - + - - - ]   1
   9 [ - + - - + ]   1
  10 [ - + - + - ]   1
  11 [ - + - + + ]   2
  12 [ - + + - - ]   2
  13 [ - + + - + ]   2
  14 [ - + + + - ]   3
  15 [ - + + + + ]   4
  16 [ + - - - - ]   1
  17 [ + - - - + ]   1
  18 [ + - - + - ]   1
  19 [ + - - + + ]   2
  20 [ + - + - - ]   1
  21 [ + - + - + ]   1
  22 [ + - + + - ]   2
  23 [ + - + + + ]   3
  24 [ + + - - - ]   2
  25 [ + + - - + ]   2
  26 [ + + - + - ]   2
  27 [ + + - + + ]   3
  28 [ + + + - - ]   3
  29 [ + + + - + ]   3
  30 [ + + + + - ]   4
  31 [ + + + + + ]   5
		

Crossrefs

Cf. A276691.

Formula

A276691(n) = sum(k=1..2^n-1, a(n)).