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.

A353349 Sum of A353350 and its Dirichlet inverse.

Original entry on oeis.org

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

Views

Author

Antti Karttunen, Apr 15 2022

Keywords

Comments

a(720) = -1 is the first negative term.

Crossrefs

Programs

  • Mathematica
    f[p_, e_] := e*2^(PrimePi[p] - 1); s[1] = 1; s[n_] := Boole@Divisible[Plus @@ f @@@ FactorInteger[n], 3]; sinv[1] = 1; sinv[n_] := -DivisorSum[n, sinv[#]*s[n/#] &, # < n &]; a[n_] := s[n] + sinv[n]; Array[a, 100] (* Amiram Eldar, Apr 15 2022 *)
  • PARI
    up_to = 16384;
    DirInverseCorrect(v) = { my(u=vector(#v)); u[1] = (1/v[1]); for(n=2, #v, u[n] = (-u[1]*sumdiv(n, d, if(dA048675(n) = { my(f = factor(n)); sum(k=1, #f~, f[k, 2]*2^primepi(f[k, 1]))/2; };
    A353350(n) = (0==(A048675(n)%3));
    v353348 = DirInverseCorrect(vector(up_to,n,A353350(n)));
    A353348(n) = v353348[n];
    A353349(n) = (A353348(n)+A353350(n));

Formula

a(n) = A353348(n) + A353350(n).
a(1) = 2, and for n > 1, a(n) = -Sum_{d|n, 1A353348(d) * A353350(n/d).
a(p) = 0 for all primes p.
a(n) = a(A003961(n)) = a(A348717(n)), for all n >= 1.