<s>[INST] How can we prove the equality of the following determinants? Assume that $A$ is an $n\times n$ real matrix whose entries are all $1$. Then how can we show the following determinant equality for any $x$?
$\det(A-xI)$=\begin{vmatrix}
  1 -x  &    1   &     1 &  \cdots  &   1 \\
  1 &    1 -x  &   1 &   \cdots  &   1 \\
  1  &  1  &     1 -x &   \cdots &    1\\
  \vdots  &   \vdots  &   \vdots &    \ddots  &   \vdots\\
  1  & 1 &   1 &    \cdots  &     1 -x
  \end{vmatrix}=
\begin{vmatrix}
 n-x  &   n-x   &    n-x &  \cdots  &   n -x \\
  1 &    1 -x &   1 &   \cdots  &   1 \\
  1  &  1  &     1 -x &   \cdots &    1\\
  \vdots  &   \vdots  &   \vdots &    \ddots  &   \vdots\\
  1  & 1 &   1 &    \cdots  &     1 -x
  \end{vmatrix}
Thanks.
 [/INST] Note that
$$
\begin{bmatrix}
 n-x  &   n-x   &    n-x &  \cdots  &   n -x \\
  1 &    1 -x &   1 &   \cdots  &   1 \\
  1  &  1  &     1 -x &   \cdots &    1\\
  \vdots  &   \vdots  &   \vdots &    \ddots  &   \vdots\\
  1  & 1 &   1 &    \cdots  &     1 -x
  \end{bmatrix} = \\
\begin{bmatrix}
1&1&1&\cdots&1\\
&1&0&\cdots&0\\
&&\ddots&\ddots&\vdots\\
&&&&0\\
&&&&1
  \end{bmatrix}
\begin{bmatrix}
  1 -x  &    1   &     1 &  \cdots  &   1 \\
  1 &    1 -x  &   1 &   \cdots  &   1 \\
  1  &  1  &     1 -x &   \cdots &    1\\
  \vdots  &   \vdots  &   \vdots &    \ddots  &   \vdots\\
  1  & 1 &   1 &    \cdots  &     1 -x
  \end{bmatrix}
$$
</s>