I am trying to prove that the determinant of a magic square, where all rows, columns and diagonal add to the same amount, is divisible by 3.
I proved it for magic squares which have entries $1,\ldots, 9$, but it turns out I need to show it for magic squares which can have any entries, e.g. \begin{pmatrix} 1 & 1 & 1 \\ 1 & 1 & 1 \\ 1 & 1 & 1 \end{pmatrix}
or \begin{pmatrix} 3 & 1 & 2 \\ 1 & 2 & 3 \\ 2 & 3 & 1 \end{pmatrix}
How can I do this? I tried working out the determinant using $a, b,\ldots, i$ as entries but could not find it.
Thank you!