TITLE: Calculate the determinant of the $2n \times 2n$ matrix with entries equal to zero on the main diagonal, $1$ below and $-1$ above
QUESTION [6 upvotes]: Calculate the determinant of the $2n \times 2n$ matrix with entries equal to zero on the main diagonal, equal to $1$ below and equal to $-1$ above.
I'll denote this matrix $A_{2n}$.
So for example you have $A_{2} = \begin{bmatrix}
        0 & -1  \\
        1 & 0  \\
              \end{bmatrix} 
$ and $A_{4}= \begin{bmatrix}
        0 & -1 & -1  &-1 \\
        1 & 0  & -1  & -1\\
        1 & 1  & 0   & -1 \\
        1 & 1  & 1   & 0\\
        \end{bmatrix}
$
From trying it out by hand I think you have $\det(A_{2n})=1$ for all odd $n$ , or $=-1$ for all even $n$.
Can anyone come up with some way to prove this?
From doing these two examples my algorithm seems to be something like this:

Switch the first and second rows (multiplies det by $-1$)
If the matrix is now upper triangular, calculate the  determinant by product of main diagonal.
If not, make a new pivot and clear that column below.
Swap the third and fourth rows (multiplies det by $-1$).
Repeat from 2.

REPLY [2 votes]: An elementary method of calculating the determinant through row operations is as follows:

Add row $1$ to rows $3$ through $2n$.
Subtract row $2$ to rows $3$ through $2n$.
Swap rows $1$ and $2$.
Repeat steps (1-3) for the lower right $2(n-1) \times 2(n-1)$ submatrix.  Since there are an even number of rows, this process always terminates in an upper triangular matrix whose entries alternate $\{1, -1, \ldots, 1, -1\}$.
The determinant is then $\det A_{2n} = ((-1)^n)^2 = 1$, because there were $n$ row swaps, and there are $n$ $-1$'s on the main diagonal.

Incidentally, if we were to consider an odd number of rows, it is easy to see that the determinant is zero.