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-4 of 4 results.

A130161 A054525 * A036989 as a diagonalized matrix.

Original entry on oeis.org

1, -1, 2, -1, 0, 1, 0, -2, 0, 3, -1, 0, 0, 0, 1, 1, -2, -1, 0, 0, 2, -1, 0, 0, 0, 0, 0, 2, 0, 0, 0, -3, 0, 0, 0, 4, 0, 0, -1, 0, 0, 0, 0, 0, 1, 1, -2, 0, 0, -1, 0, 0, 0, 0, 2
Offset: 0

Views

Author

Gary W. Adamson, May 13 2007

Keywords

Comments

Left border = mu(n), A008683.
Right border = A036989, (1, 2, 1, 3, 1, 2, 2, 4, 1, 2, ...) = the inverse Moebius transform (A051731) of the Thue-Morse sequence, offset 1: (1, 1, 0, 1, 0, 0, 1, ...).
Row sums = the Thue-Morse sequence starting with "1".

Examples

			First few rows of the triangle:
   1;
  -1,  2;
  -1,  0,  1;
   0, -2,  0,  3;
  -1,  0,  0,  0,  1;
   1, -2, -1,  0,  0,  2;
  -1,  0,  0,  0,  0,  0,  2;
  ...
		

Crossrefs

Formula

Moebius transform of an infinite lower triangular matrix with A036989 in the main diagonal and the rest zeros.

A036990 Numbers n such that, in the binary expansion of n, reading from right to left, the number of 1's never exceeds the number of 0's.

Original entry on oeis.org

0, 2, 4, 8, 10, 12, 16, 18, 20, 24, 32, 34, 36, 40, 42, 44, 48, 50, 52, 56, 64, 66, 68, 72, 74, 76, 80, 82, 84, 88, 96, 98, 100, 104, 112, 128, 130, 132, 136, 138, 140, 144, 146, 148, 152, 160, 162, 164, 168, 170, 172, 176, 178, 180, 184, 192, 194, 196, 200, 202, 204
Offset: 1

Views

Author

Keywords

Comments

A036989(a(n)) = 1. - Reinhard Zumkeller, Jul 31 2013

Crossrefs

Each term is 2^n * some term of A014486 (n >= 0).
Cf. A030308.

Programs

  • Haskell
    a036990 n = a036990_list !! (n-1)
    a036990_list = filter ((== 1) . a036989) [0..]
    -- Reinhard Zumkeller, Jul 31 2013
  • Mathematica
    fQ[n_] := Block[{od = ev = k = 0, id = Reverse@IntegerDigits[n, 2], lmt = Floor@Log[2, n] + 1}, While[k < lmt && od < ev + 1, If[OddQ@id[[k + 1]], od++, ev++ ]; k++ ]; If[k == lmt && od < ev + 1, True, False]]; Select[ Range[0, 204, 2], fQ@# &] (* Robert G. Wilson v, Jan 11 2007 *)
    (* b = A036989 *) b[0] = 1; b[n_?EvenQ] := b[n] = Max[b[n/2]-1, 1]; b[n_] := b[n] = b[(n-1)/2]+1; Select[Range[0, 300, 2], b[#] == 1 &] (* Jean-François Alcover, Nov 05 2013, after Reinhard Zumkeller *)

Formula

Extensions

More terms from Erich Friedman.

A036988 Has simplest possible tree complexity of all transcendental sequences.

Original entry on oeis.org

1, 0, 1, 0, 1, 0, 0, 0, 1, 0, 1, 0, 1, 0, 0, 0, 1, 0, 1, 0, 1, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 1, 0, 1, 0, 1, 0, 0, 0, 1, 0, 1, 0, 1, 0, 0, 0, 1, 0, 1, 0, 1, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 1, 0, 1, 0, 1, 0, 0, 0, 1, 0, 1, 0, 1, 0, 0, 0, 1, 0, 1, 0, 1, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 1, 0, 1, 0, 1, 0, 0, 0, 1
Offset: 0

Views

Author

Keywords

Crossrefs

Cf. A036989. Characteristic function of A036990.

Programs

Formula

a(n) = 1 iff, in the binary expansion of n, reading from right to left, the number of 1's never exceeds the number of 0's.
a(n) = A063524(A036989(n)). - Reinhard Zumkeller, Jul 31 2013

Extensions

More terms from Larry Reeves (larryr(AT)acm.org), Sep 25 2000

A126387 Read binary expansion of n from the left; keep track of the excess of 1's over 0's that have been seen so far; sequence gives maximum(excess of 1's over 0's).

Original entry on oeis.org

0, 1, 1, 2, 1, 1, 2, 3, 1, 1, 1, 2, 2, 2, 3, 4, 1, 1, 1, 1, 1, 1, 2, 3, 2, 2, 2, 3, 3, 3, 4, 5, 1, 1, 1, 1, 1, 1, 1, 2, 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, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 3, 1, 1, 1, 1, 1, 1, 2, 3, 2, 2, 2, 3, 3, 3, 4, 5, 2, 2, 2, 2, 2, 2, 2, 3, 2
Offset: 0

Views

Author

Keywords

Examples

			59 in binary is 111011, excess from left to right is 1,2,3,2,3,4, maximum is 4, so a(59) = 4.
		

Crossrefs

Cf. A036989.

Formula

a(0) = 0, a(2^i) = 1, if n = 2^i + 2^j + m with j < i and 0 <= m < 2^j, then a(n) = max(a(2^j+m) + j + 2 - i, 1).
Showing 1-4 of 4 results.