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.

A317419 a(n) = number of k with 1 <= k <= n-1 such that a(k) AND a(n-k) = 0 (where AND denotes the bitwise AND operator).

Original entry on oeis.org

0, 1, 2, 2, 4, 4, 4, 6, 8, 8, 6, 6, 8, 8, 8, 10, 12, 12, 10, 14, 20, 14, 8, 10, 12, 12, 8, 8, 12, 14, 14, 10, 10, 12, 12, 8, 10, 14, 16, 12, 6, 10, 12, 14, 8, 8, 12, 14, 14, 14, 14, 10, 12, 12, 8, 12, 18, 16, 12, 8, 10, 14, 18, 14, 10, 18, 18, 16, 12, 14, 18
Offset: 1

Views

Author

Rémy Sigrist, Jul 27 2018

Keywords

Comments

All terms are even except a(2) = 1.
See A317420 for similar sequences.

Examples

			For n = 4:
- a(1) AND a(3) = 0 AND 2 = 0,
- a(2) AND a(2) = 1 AND 1 = 1 <> 0,
- a(3) AND a(1) = 2 AND 0 = 0,
- hence a(4) = 2.
		

Crossrefs

Cf. A317420.

Programs

  • PARI
    a = vector(71); for (n=1, #a, a[n] = sum(k=1, n-1, bitand(a[k], a[n-k])==0); print1 (a[n] ", "))