How to find the determinant of this matrix I have the following matrix:
$
\begin{bmatrix}
 a & 1 & 1 & 1 \\
 1 & a & 1 & 1 \\
 1 & 1 & a & 1 \\
 1 & 1 & 1 & a \\
\end{bmatrix}
$
My approach is to rref the matrix so that i can find the determinant by multiplying along the diagonals.
I attempted to do an rref and ended up with 
$
\begin{bmatrix}
 1 & a & 1 & 1 \\
 1-a & a-1 & 0 & 0 \\
 0 & 1-a & a-1 & 1 \\
 0 & 0 & 1-a & a-1 \\
\end{bmatrix}
$
I then factored out (1-a) to get this
$
\begin{bmatrix}
 1 & a & 1 & 1 \\
 1 & -1 & 0 & 0 \\
 0 & 1 & -1 & 1 \\
 0 & 0 & 1 & -1 \\
\end{bmatrix}
$
which will then make my determinant a multipile of $(1-a)^3$: 
$\det(A) = (1-a)^3x$
But now here I don't know what to do. I have a feeling that my approach is wrong. Any help or guide please?
 A: To find the determinant you could just do it brute force by "Expansion by Minors" using the first row:
$$\begin{align}
\det \begin{bmatrix}
 a & 1 & 1 & 1 \\
 1 & a & 1 & 1 \\
 1 & 1 & a & 1 \\
 1 & 1 & 1 & a \\
\end{bmatrix} = a\det 
\begin{bmatrix}
  a & 1 & 1 \\
  1 & a & 1 \\
  1 & 1 & a \\
\end{bmatrix} \\- 1\det\begin{bmatrix}
  1 & 1 & 1 \\
  1 & a & 1 \\
  1 & 1 & a \\
\end{bmatrix} \\+ 1\det \begin{bmatrix}
  1 & a & 1 \\
  1 & 1 & 1 \\
  1 & 1 & a \\
\end{bmatrix} \\- 1\det\begin{bmatrix}
  1 & a & 1 \\
  1 & 1 & a \\
  1 & 1 & 1 \\
\end{bmatrix}
\end{align}
$$
A: How about the LU decomposition (modulo a rearrangements of rows)?
\begin{align*}
&\left[\begin{array}{cccc}0&1&0&0\\0&0&0&1\\0&0&1&0\\1&0&0&0\end{array}\right]\times\left[\begin{array}{cccc}
a&1&1&1\\
1&a&1&1\\
1&1&a&1\\
1&1&1&a\end{array}\right]\\=&\left[\begin{array}{cccc}1&0&0&0\\1&1&0&0\\1&1&1&0\\a&1+a&-1&1\end{array}\right]\times\left[\begin{array}{cccc}1&a&1&1\\0&1-a&0&a-1\\0&0&a-1&1-a\\0&0&0&(3+a)(1-a)\end{array}\right].
\end{align*}
It follows that the determinant is $(a-1)^3(3+a)$.
A: The LDU-decomposition gives
$$ L=\small \begin{bmatrix} 
 1 & . & . & . \\ 
 1/a & 1 & . & . \\ 
 1/a & 1/(a+1) & 1 & . \\ 
 1/a & 1/(a+1) & 1/(a+2) & 1 \\ 
 \end{bmatrix} \\ D= \small \begin{bmatrix}
 a & . & . & . \\ 
 . & (a^2-1)/a & . & . \\ 
 . & . & (a^2+a-2)/(a+1) & . \\ 
 . & . & . & (a^2+2a-3)/(a+2) \\ 
 \end{bmatrix} \\ U=\small \begin{bmatrix}
 1 & 1/a & 1/a & 1/a \\ 
 . & 1 & 1/(a+1) & 1/(a+1) \\ 
 . & . & 1 & 1/(a+2) \\ 
 . & . & . & 1
 \end{bmatrix} $$
Here L and U are simply transposed (which reflects the symmetry of the original matrix), and all of the determinant-compuation happens in the diagonal of D.     
The determinant is $$ a {a^2-1\over a} {a^2+a-2\over a+1}{a^2+2a-3\over a+2} $$
Expanding gives
$$ a\cdot  {(a-1)(a+1)\over a} \cdot {(a-1)(a+2)\over a+ 1}\cdot {(a-1)(a+3)\over a+2}$$ and cancelling over the diagonal gives $$
 1{a-1\over 1}\cdot  {a-1\over 1}\cdot {(a-1)(a+3)\over 1}$$
which is the same as that in the answer of triplesec above    
This representation has also the advantage that it is easily extensible to larger matrices 
A: I think Thomas's solution is more practical but here is an alternative just for fun. This matrix looks highly degenerate and the eigenvalue problem can be solved here just by looking at it. 
Look at what happens when we subtract a pair of columns,
$$ \left( \begin{array}{c} a \\ 1 \\ 1 \\ 1 \end{array} \right)
   -\left( \begin{array}{c} 1 \\ 1 \\ 1 \\ a \end{array} \right)
  = \left( \begin{array}{c} (a-1)\\ 0 \\ 0 \\ (1-a) \end{array} \right)
  = (a-1)\left(\begin{array}{c} 1\\ 0 \\ 0 \\ -1 \end{array} \right)
$$
This means that $(1,0,0,-1)$ is an eigenvector of the matrix with eigenvalue (a-1). A total of three independent eigenvectors with the same eigenvalue can be obtained in this manner by subtracting the other columns from the first column. If you don't see how subtracting the first and last column is the same as multiplying the matrix by $(1,0,0,-1)$ then I recommend two things: first multiply the matrix by each of the standard basis vectors and look at what you get, then multiply the matrix by $(1,0,0,-1)$ and see how that relates to the first thing.
The fourth eigenvector can be found by noticing that the sums of the components of the rows are all the same value $(3+a)$. This means that $(1,1,1,1)$ is an eigenvector with that eigenvalue.
This can be finished off by recognizing that the determinant is the product of the eigenvalues.
A: at lin3 col 4 is 0 not 1

det$\begin{bmatrix}
 1 & a & 1 & 1 \\
 1 & -1 & 0 & 0 \\
 0 & 1 & -1 & 0 \\
 0 & 0 & 1 & -1 \\
\end{bmatrix}$
~det$\begin{bmatrix}
 a+3 & a & 1 & 1 \\
 0 & -1 & 0 & 0 \\
 0 & 1 & -1 & 0 \\
 0 & 0 & 1 & -1 \\
\end{bmatrix}$
etc.
