Proving magic squares determinant is a multiple of 3 when any numbers can be used 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!
 A: Let the three rows of the magic square be $r_1$, $r_2$, and $r_3$.  Since the determinant is unchanged by row operations that add a multiple of one row to another, the matrix with rows $r_1$, $r_2$ and $r_1+r_2+r_3$ has the same determinant.  The entries in $r_1 + r_2 + r_3$ are the column sums of the original magic square, which are all equal to the magic constant.  The magic constant is three times the central entry of the magic square, so every entry in this new row is multiple of three; therefore the determinant is, too.
A: Collecting from all the comments above:
Let $s$ be the sum of one row. This $s$ must be divisible by $3$: Since the sum of the two diagonals along with the row and the column going through the center equals $4s$, but it is also the sum of every element in the matrix, along with the center value $c$ an additional three times, which is $3s + 3c$. Equating these two gives $s = 3c$.
Since all the rows have the same sum, the vector $(1, 1, 1)^T$ is an eigenvector of the matrix with eigenvalue $s$. The determinant is (up to a sign) equal to the constant term of the characteristic polynomial. Since we know the characteristic polynomial has $s$ as a root, it must factor as
$$
(\lambda - s)g(\lambda)
$$
for some polynomial $g$ with integer coefficients. Particularily, this means that the constant term of $g$ must be an integer, which means that the constant term of the characteristic polynomial (and therefore the determinant) must be divisible by $s$.
A: Render the elements $\bmod3$. Then the sum of every row and every column is three times the central element, but this is $\equiv0\bmod3$. To make all the column sums zero you then need the last row to be $\equiv$ the sum of the first two rows $\bmod3$, a linear dependence that then forces the determinant to be $\equiv0\bmod3$.
