Let $n$ be a positive integer and $A = (a_{ij})_{n\times n}$, where $a_{ij} = |i-j|$, for $i = 1, 2, \dots, n$ and $j = 1, 2, \dots, n$. Calculate $\det A$.
I noticed that $a_{ii} = 0$ and $a_{ij} = a_{ji}$, so A is a symmetric matrix. Also, I saw that, if we make the notation $A_n$ for the A with n elements, $A_n$ is constructed from $A_{n-1}$ with $n-1, n-2, \dots, 0$ as elements for the last line and last column. I tried to use Laplace expansion but with no result.
This is how $A_n$ looks like: $A_n=\begin{bmatrix} 0&1&2& .&.&. &n-1\\ 1&0&1&2& .&.&n-2 \\ 2&1&0&1&.&.&. \\ .&.&.&.&.&.&. \\ .&.&.&.&.&.&2 \\ .&.&.&.&.&.&1 \\ n-1&n-2&.&.&2&1&0 \end{bmatrix}$
I calculated for a few small numers: $\det A_1 = 0$, $\det A_2 = -1$, $\det A_3 = 4$, $\det A_4 = -12$, $\det A_5 = 32$, but I didn't figure out a rule such that I could find the determinant through induction. Can you help me on this one?