login

Reminder: The OEIS is hiring a new managing editor, and the application deadline is January 26.

Sum of A006368, "the amusical permutation", and its Dirichlet inverse.
4

%I #9 Nov 25 2021 17:37:56

%S 2,0,0,9,0,12,0,9,4,24,0,24,0,30,16,27,0,42,0,30,20,48,0,21,16,60,20,

%T 51,0,54,0,45,32,78,40,30,0,84,40,51,0,90,0,78,52,102,0,96,25,90,52,

%U 84,0,90,64,57,56,132,0,27,0,138,74,99,80,138,0,111,68,114,0,114,0,168,68,132,80,150,0,138,61,186,0

%N Sum of A006368, "the amusical permutation", and its Dirichlet inverse.

%C The first negative term is a(2520) = -918.

%H Antti Karttunen, <a href="/A349352/b349352.txt">Table of n, a(n) for n = 1..20000</a>

%F a(n) = A006368(n) + A349351(n).

%F a(1) = 2, and for n > 1, a(n) = -Sum_{d|n, 1<d<n} A006368(d) * A349351(n/d).

%o (PARI)

%o up_to = 20000;

%o DirInverseCorrect(v) = { my(u=vector(#v)); u[1] = (1/v[1]); for(n=2, #v, u[n] = (-u[1]*sumdiv(n, d, if(d<n, v[n/d]*u[d], 0)))); (u) }; \\ Compute the Dirichlet inverse of the sequence given in input vector v.

%o A006368(n) = ((3*n)+(n%2))\(2+((n%2)*2));

%o v349351 = DirInverseCorrect(vector(up_to,n,A006368(n)));

%o A349351(n) = v349351[n];

%o A349352(n) = (A006368(n)+A349351(n));

%Y Cf. A006368, A349351, A349369, A349378.

%K sign

%O 1,1

%A _Antti Karttunen_, Nov 15 2021