[go: up one dir, main page]

login
A023999
Absolute value of determinant of n X n matrix whose entries are the integers from 1 to n^2 spiraling inward, starting in a corner.
6
1, 5, 48, 660, 11760, 257040, 6652800, 198918720, 6745939200, 255826771200, 10727081164800, 492775291008000, 24610605962342400, 1327677426915840000, 76940526008586240000, 4766815315895592960000, 314406967644177408000000, 21995911456386651463680000
OFFSET
1,2
COMMENTS
Starting in the NW or SE corner, the signs are cyclic (+,-,-,+), starting in the NE or SW corner, the signs are always positive.
LINKS
Gaurav Bhatnagar, Christian Krattenthaler, Spiral determinants, arXiv:1704.02859 [math.CO], 2017.
Charles Vanden Eynden, Problem 1517, Mathematics Magazine, Vol. 70, No. 1, Feb., 1997 p. 65.
FORMULA
a(n) = (3n-1) * (2n-3)!/(n-2)! for n >= 2. [corrected by Robert Israel, Apr 20 2017]
E.g.f.: ((-2*x-1)*sqrt(1-4*x)+1-4*x)/(16*x-4). - Robert Israel, Apr 20 2017
EXAMPLE
n=4: det of
.1..2..3.4
12.13.14.5
11.16.15.6
10..9..8.7
MAPLE
a:= proc(n) option remember; `if`(n<2, (3*n+1)/4,
4*(3*n-1)*(2*n-5)*(2*n-3) *a(n-2) /(3*n-7))
end:
seq(a(n), n=1..20); # Alois P. Heinz, Jan 21 2014
MATHEMATICA
M[0, 0] = 1;
M[i_, j_] := If[i <= j,
If[i + j >= 0, If[i != j, M[i + 1, j] + 1, M[i, j - 1] + 1],
M[i, j + 1] + 1],
If[i + j > 1, M[i, j - 1] + 1, M[i - 1, j] + 1]
]
M[n_] := n^2 + 1 - If[EvenQ[n],
Table[M[i, j], {j, n/2, -n/2 + 1, -1}, {i, -n/2 + 1, n/2}],
Table[M[i, j], {j, (n - 1)/2, -(n - 1)/2, -1}, {i, -(n - 1)/2, (n - 1)/2}]]
a[n_]:=Det[M[n]] (* Christian Krattenthaler, Apr 19 2017 *)
PROG
(Maxima) A023999(n):=if n=1 then 1 else 2*((-1)^((n+4)*(n-1))/2 *(3*n-1) * (2*n-3)!/(n-2)!)$
makelist(A023999(n), n, 1, 30); /* Martin Ettl, Nov 05 2012 */
CROSSREFS
Main diagonal of A226167, A126224 (signed version). - Alois P. Heinz, Jan 21 2014
Sequence in context: A116431 A048435 A293102 * A126224 A360235 A108207
KEYWORD
nonn
AUTHOR
Charles Diminnie (charles.diminnie(AT)rampo.angelo.edu)
EXTENSIONS
Edited and extended by Robert G. Wilson v, May 07 2003
STATUS
approved