# What is my mistake in this determinant of order $n$?

Consider real numbers $$a_i,b_i\in\mathbb{R}$$ and the following determinant

$$\alpha_n= \begin{vmatrix} a_1 + b_1 & b_1 & b_1 & b_1&\cdots & b_1 \\ b_2 & a_2 + b_2 & b_2 & b_2 & \cdots & b_2 \\ b_3 & b_3 & a_3 + b_3 & b_3 & \cdots & b_3 \\ \vdots & \vdots & \vdots & \vdots & \ddots & \vdots \\ b_n & b_n & b_n & b_n & \cdots & a_n + b_n\end{vmatrix}$$ My attempt was to substitute column 1 with column 1 - column 2 $$(C_1 \to C_1 - C_2)$$. Then do the same with others columns: $$C_2 \to C_2 - C_3$$,..., $$C_n\to C_n - C_1$$. After all these transformations, arise this determinant $$\alpha_n =\begin{vmatrix} a_1 &0& 0 &0&\cdots & -a_1 \\ -a_2 &a_2 & 0 & 0 & \cdots & 0 \\ 0 & -a_3 & a_3 & 0 & \cdots &0 \\ \vdots & \vdots & \vdots & \vdots & \ddots & \vdots \\ 0 & 0 & 0 & 0 & \cdots & a_n \end{vmatrix}$$ So it seems that $$\alpha_n$$ only depends on $$a_i$$. However, computing the case $$n=2$$, gives $$\alpha_2 = \begin{vmatrix} a_1 +b_1 &b_1 \\ b_2 & a_2 + b_2 \end{vmatrix} = a_1a_2 + a_1b_2 + a_2b_1.$$ What am I doing wrong? How can I compute a closed form for $$\alpha_n$$? Thank you in advance.

• The last operation on $C_n$ doesn't seem correct, as $C_1$ has been modified before. Commented Feb 3, 2021 at 9:30
• Thank you for your comment! Commented Feb 3, 2021 at 10:12

As your error was already clarified in other answers here only a hint to solution will be given.

I will assume $$a_i\ne0$$. Observe that your matrix is in form: $$\alpha=A+u^Tv,$$ where $$A=\operatorname {diag}(a_1,a_2,\dots,a_n),\quad u=(b_1,b_2,\dots,b_n),\quad v=(1,1,\dots,1).$$ Then by matrix determinant lemma: $$\det (\alpha)=(1+vA^{-1}u^T)\det (A)=\left(1+\sum_i\frac {b_i }{a_i}\right)\prod_i a_i.$$

• This answers my 2nd question in a very nice way. Thank you! +1 Commented Feb 3, 2021 at 15:01
• In fact the final expression written as $a_1a_2\dots a_{i-1}b_ia_{i+1}\dots a_n$ is valid also for the case of single $a_i$ equal to $0$. If there are more than one $a_i$ equal to $0$ the determinant is $0$.
– user
Commented May 16, 2023 at 10:03

Note that while performing row or column operations on determinants, it is necessary to preserve atleast one column/row, we cannot change all of them at once.

In your case, you cannot do $$C_n \to C_n-C_1$$.

• Thank you for your answer! Commented Feb 3, 2021 at 10:12