OFFSET
0,5
COMMENTS
The matrix M(n) is the n-th principal submatrix of the array A010751.
In the n X n matrix M(n): the zero element appears 2*n - 1 times; the positive integers k appears iff 0 < k < floor(n/2), 2*n - 1 - A040002(k-1) times; the negative integer k appears iff -k < ceiling(n/2), 2*n - 5 + 4*(k + 1) times.
det(M(n)) = 0, except for n = 3 for which det(M(3)) = -1.
The trace and the subdiagonal sum of the matrix M(n) are zero.
The antitrace of the matrix M(n) is A142150(n+1).
The superdiagonal sum of the matrix M(n) is equal to n - 1.
The sum of the elements of the matrix M(n) is A002620(n).
EXAMPLE
For n = 3 the matrix M(3) is
0, 1, 1
0, 0, 1
-1, 0, 0
with permanent a(3) = -1.
For n = 4 the matrix M(4) is
0, 1, 1, 2
0, 0, 1, 1
-1, 0, 0, 1
-1, -1, 0, 0
with permanent a(4) = 2.
MAPLE
a:= n-> `if`(n=0, 1, LinearAlgebra[Permanent](
Matrix(n, (i, j)-> floor((j-i+1)/2)))):
seq(a(n), n=0..20); # Alois P. Heinz, Jan 19 2022
MATHEMATICA
Join[{1}, Table[Permanent[Table[Floor[(j-i+1)/2], {i, n}, {j, n}]], {n, 20}]]
PROG
(PARI) a(n) = matpermanent(matrix(n, n, i, j, (j - i + 1)\2)); \\ Michel Marcus, Jan 04 2022
(Python)
from sympy import Matrix
def A350549(n): return 1 if n == 0 else Matrix(n, n, lambda i, j:(j-i+1)//2).per() # Chai Wah Wu, Jan 12 2022
CROSSREFS
KEYWORD
sign
AUTHOR
Stefano Spezia, Jan 04 2022
STATUS
approved