<s>[INST] Determinant of rank-$1$ update of multiple of identity matrix I've got to calculate determinant for such matrix:
$$ \begin{bmatrix}
a_1+b & a_2 & \cdots & a_n\\
a_1 & a_2+b & \cdots & a_n\\
\vdots & \vdots & \ddots & \vdots\\ 
a_1 & a_2 & \cdots & a_n+b\\
\end{bmatrix} $$
Please give me some tips how to calculate this.
 [/INST] Set $A=\sum\limits_{i=1}^na_i$. By multilinearity,
\begin{align*}
&\begin{vmatrix}
a_1+b &a_2&\dots&a_n\\
a_1&b+a_2 &\dots&a_n \\
\vdots&\vdots&&\vdots\\
a_1  a_2&\dots &a_n+b
\end{vmatrix}=
\begin{vmatrix}
 A+b &a_2&\dots&a_n\\
A+b&b+a_2  &\dots&a_n \\
\vdots&\vdots&&\vdots\\
A+b & a_2&\dots &b+a_n 
\end{vmatrix}\\[1ex]
&=(A+b)\begin{vmatrix}
 1 &a_2&\dots&a_n\\
1&b+a_2  &\dots&a_n \\
\vdots&\vdots&&\vdots\\
1 & a_2&\dots &b+a_n 
\end{vmatrix}=(A+b)\begin{vmatrix}
 1 &a_2&\dots&a_n\\
0&b &\dots& 0 \\
\vdots&\vdots&&\vdots\\
0 & 0&\dots &b
\end{vmatrix}\\[1ex]
&=\color{red}{(A+b)b^{n-1}}.
\end{align*}
</s>