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.

A069517 a(n) = (-1)*Sum_{d|n} (moebius(d)*(-1)^d).

Original entry on oeis.org

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

Views

Author

Benoit Cloitre, Apr 16 2002

Keywords

Comments

From Andrew Howroyd, Jul 25 2018: (Start)
Moebius transform of A037227.
Multiplicative because A037227 is. (End)

Crossrefs

Programs

  • Mathematica
    a[n_] := If[n == 2^IntegerExponent[n, 2], 2, 0]; a[1] = 1; Array[a, 100] (* Amiram Eldar, Aug 29 2023 *)
  • PARI
    A069517(n) = (-1)*sumdiv(n,d,moebius(d)*((-1)^d)); \\ Antti Karttunen, Nov 19 2017
    
  • PARI
    a(n) = if(n == 1, 1, if(n >> valuation(n, 2) == 1, 2, 0)); \\ Amiram Eldar, Aug 29 2023

Formula

a(1) = 1 and for n>1, a(n) = 2*A209229(n). - corrected by Antti Karttunen, Nov 19 2017
Multiplicative with a(2^e) = 2 and a(p^e) = 0 for an odd prime p. - Amiram Eldar, Aug 29 2023