How to compute determinant of $A$ such that $A=(I+\ [c_ic_j])\in M_n(\mathbb R)$ ,$c_i\in\mathbb R$ assume   $\ [c_ic_j]_{n\times n}\in M_n(\mathbb R)$ such that $c_1,c_2,\ldots,c_n\in\mathbb R$  and $I$ be identity matrix  
how compute  $$\det (I+\ [c_ic_j])=?$$ 
Thanks in advance 
 A: I've already answered this question but I can't find it... Write you matrix $X=I_n+CC^T$. If $C=0$, the problem is trivial. So assume $C\neq 0$. Then note that $CC^T$ is a rank one matrix, so $0$ is an eigenvalue of multiplicity $n-1$. Now $(CC^T)C=C(C^TC)=\|C\|^2 C$. So $\|C\|^2$ is a nonzero eigenvalue of multiplicity at least $1$. It follows that, with multiplicities:
$$
\mbox{spectrum} (CC^T)=\{\|C\|^2,0\ldots,0\}\quad\Rightarrow\quad\mbox{spectrum} (I_n+CC^T)=\{1+\|C\|^2,1\ldots,1\}.
$$
Therefore (of course, $I_n+CC^T$ is diagonalizable from the above, or directly by observing that it is hermitian):
$$
\det (I_n+CC^T)=1+\|C\|^2=1+\sum_{k=1}^nc_k^2.
$$
Edit: As pointed out by @ChrisGodsil, it is true in general that $\det(I_m+AB)=\det(I_n+BA)$ for every $m\times n$ matrix $A$ and every $n\times m$ matrix $B$. This can even be generalized to the more general fact that the characteristic polynomials satisfy
$$
t^m\chi_{BA}(t)=t^n\chi_{AB}(t).
$$
And this holds over any ring. See here.
