Proof explanation about the computation of a certain determinant by Sylvester's theorem [duplicate]

Let $n\geq 2$, $A=[a_{ij}]\in Mat_n(\mathbb{R})$ the matrix defined by $a_{ij}=0$ if $i=j$ and $a_{ij}=1$ if $i\not =j$

Calculate $\det(A)$

Proof:

Sylvester's theorem: https://en.wikipedia.org/wiki/Sylvester%27s_determinant_identity

Using Sylvester's determinant theorem, which says that for any rectangular matrices of mutually transposed shapes $A\in\mathrm M_{n,m}(K)$ and $B\in \mathrm M_{m,n}(K)$ one has $$\det(I_n+AB)=\det(I_m+BA).$$

If $N$ is your matrix then $-N=I_n-AB$ where $A\in\mathrm M_{n,1}(K)$ is a one column all-one matrix and $B$ is its transpose. Then $$\det(N)=(-1)^n\det(-N)=(-1)^n\det(I_1-BA)=(-1)^n(1-n).$$ I need an explanation about one part of the proof Question:

I don't see this step:

$(-1)^n\det(I_1-BA)=(-1)^n(1-n).$

marked as duplicate by Dietrich Burde, almagest, José Carlos Santos, hardmath, Ethan BolkerJan 27 '18 at 21:31

• Why did you delete your old question about the same determinant? – Dietrich Burde Jan 27 '18 at 16:02
• @DietrichBurde because i don't see the last part of the proof you linked but thanks for the proof! – Bvss12 Jan 27 '18 at 16:04

It's because the matrix $BA=(n)$. The dimension of $BA$ is 1x1
Note that, if $A=[1,1,1]^T$ than $$AB= \begin{bmatrix}1\\1\\1 \end{bmatrix}\begin{bmatrix}1&1&1 \end{bmatrix}= \begin{bmatrix}1&1&1\\1&1&1\\1&1&1 \end{bmatrix}$$
$$BA=\begin{bmatrix}1&1&1 \end{bmatrix}\begin{bmatrix}1\\1\\1 \end{bmatrix}=1+1+1=3$$