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.

A361019 Dirichlet inverse of A038712.

This page as a plain text file.
%I A361019 #9 Mar 03 2023 17:53:48
%S A361019 1,-3,-1,2,-1,3,-1,0,0,3,-1,-2,-1,3,1,0,-1,0,-1,-2,1,3,-1,0,0,3,0,-2,
%T A361019 -1,-3,-1,0,1,3,1,0,-1,3,1,0,-1,-3,-1,-2,0,3,-1,0,0,0,1,-2,-1,0,1,0,1,
%U A361019 3,-1,2,-1,3,0,0,1,-3,-1,-2,1,-3,-1,0,-1,3,0,-2,1,-3,-1,0,0,3,-1,2,1,3,1,0,-1,0,1,-2,1,3,1,0,-1
%N A361019 Dirichlet inverse of A038712.
%C A361019 Multiplicative because A038712 is.
%H A361019 Antti Karttunen, <a href="/A361019/b361019.txt">Table of n, a(n) for n = 1..20000</a>
%F A361019 a(1) = 1, and for n > 1, a(n) = -Sum_{d|n, d<n} A038712(n/d) * a(d).
%F A361019 Multiplicative with a(2) = -3, a(2^2) = 2, and a(2^e) = 0 for e > 2, and for odd prime p, a(p)= -1 and a(p^e) = 0 for e > 1. - _Amiram Eldar_, Mar 02 2023
%t A361019 f[p_, e_] := If[e == 1, -1, 0]; f[2, e_] := If[e < 3, If[e == 1, -3, 2], 0]; a[1] = 1; a[n_] := Times @@ f @@@ FactorInteger[n]; Array[a, 100] (* _Amiram Eldar_, Mar 02 2023 *)
%o A361019 (PARI)
%o A361019 A038712(n) = ((1<<(1+valuation(n,2)))-1);
%o A361019 memoA361019 = Map();
%o A361019 A361019(n) = if(1==n,1,my(v); if(mapisdefined(memoA361019,n,&v), v, v = -sumdiv(n,d,if(d<n,A038712(n/d)*A361019(d),0)); mapput(memoA361019,n,v); (v)));
%Y A361019 Cf. A038712.
%K A361019 sign,mult
%O A361019 1,2
%A A361019 _Antti Karttunen_, Mar 02 2023