login
A086095
Permanent of the n X n matrix M where M(i,i) = 0 and for i != j, M(i,j) = mu(|i-j|) where mu( ) is the moebius function.
1
1, 0, 1, -2, 1, 0, 4, 16, 16, -64, 1184, -4176, 11588, -45320, 60177, -107154, 596001, -2059576, 9159736, 8005616, 313722880, 1052525600, 9682854977, 55241475020, 489566327904, 4159594989264, 34384770630704, 347985635900764, 3590752406671641, 36608921259384368
OFFSET
0,4
LINKS
MAPLE
with(linalg):with(numtheory):mu:=proc(n) if n=0 then 0 else mobius(n) fi end:a:=(i, j)->mu(abs(i-j)):seq(permanent(matrix(n, n, a)), n=1..19); # the Maple mobius command is not used since it assigns mobius(0)=-1 # Emeric Deutsch, Dec 23 2004
# second Maple program:
a:= n-> `if`(n=0, 1, LinearAlgebra[Permanent](Matrix(n, (i, j)
-> `if`(i=j, 0, numtheory[mobius](abs(i-j)))))):
seq(a(n), n=0..18); # Alois P. Heinz, Jan 28 2021
MATHEMATICA
a[n_] := Permanent[Table[MoebiusMu[Abs[i - j]], {i, 1, n}, {j, 1, n}]]; Table[an = a[n]; Print["a(", n, ") = ", an]; an, {n, 1, 19}] (* Jean-François Alcover, Jan 07 2016 *)
PROG
(PARI) permRWN(a)=n=matsize(a)[1]; if(n==1, return(a[1, 1])); n1=n-1; sg=1; m=1; nc=0; in=vector(n); x=in; for(i=1, n, x[i]=a[i, n]-sum(j=1, n, a[i, j])/2); p=prod(i=1, n, x[i]); while(m, sg=-sg; j=1; if((nc%2)!=0, j++; while(in[j-1]==0, j++)); in[j]=1-in[j]; z=2*in[j]-1; nc+=z; m=nc!=in[n1]; for(i=1, n, x[i]+=z*a[i, j]); p+=sg*prod(i=1, n, x[i])); return(2*(2*(n%2)-1)*p)
mobius(n)=if(n!=0, moebius(n), 0)
for(n=1, 40, a=matrix(n, n, i, j, mobius(abs(i-j))); print1(permRWN(a)", ")) \\ Herman Jamke (hermanjamke(AT)fastmail.fm), May 11 2007
CROSSREFS
Sequence in context: A178039 A185411 A254882 * A322119 A363731 A112334
KEYWORD
sign
AUTHOR
Yuval Dekel (dekelyuval(AT)hotmail.com), Aug 24 2003
EXTENSIONS
More terms from Emeric Deutsch, Dec 23 2004
More terms from Herman Jamke (hermanjamke(AT)fastmail.fm), May 11 2007
a(0) and a(26)-a(29) from Pontus von Brömssen, Jan 28 2021
STATUS
approved