How find this matrix value of this $\det(A_{ij})$ Find this value
$$\det(A_{n\times n})=\begin{vmatrix}
0&a_{1}+a_{2}&a_{1}+a_{3}&\cdots&a_{1}+a_{n}\\
a_{2}+a_{1}&0&a_{2}+a_{3}&\cdots&a_{2}+a_{n}\\
a_{3}+a_{1}&a_{3}+a_{2}&0&\cdots&a_{3}+a_{n}\\
\cdots&\cdots&\cdots&\cdots&\cdots\\
a_{n}+a_{1}&a_{n}+a_{2}&a_{n}+a_{3}&\cdots&0
\end{vmatrix}$$
where $a_{j}\neq 0,j=1,2,\cdots,n$
My try: I found this:
$$A_{n\times n}=diag(-2a_{1},-2a_{2},\cdots,-2a_{n})+B_{n\times n}$$
where
$$B=\begin{bmatrix}
a_{1}+a_{1}&a_{1}+a_{2}&\cdots& a_{1}+a_{n}\\
a_{2}+a_{1}&a_{2}+a_{2}&\cdots&a_{2}+a_{n}\\
\cdots&\cdots&\cdots&\cdots\\
a_{n}+a_{1}&a_{n}+a_{2}&\cdots&a_{n}+a_{n}
\end{bmatrix}$$
But I can't,Thank you very much
 A: For a starter, let us first look at the case where $a_i \in \mathbb{R}$ and all of them are positive.
Let $\delta_{ij}$ be the Kronecker deltas.
Let $U, V \in M_{n\times 1}(\mathbb{R})$ and $D \in M_{n\times n}(\mathbb{R})$ be the matrices defined by
$$U_i = \sqrt{\frac{a_i}{2}},\;\;V_i = \sqrt{\frac{1}{2a_i}}\quad\text{ and }\quad
D_{ij} = \sqrt{2\alpha_i} \delta_{ij}$$
It is easy to check the matrix $A$ can be factorized as
$$A = D ( -I_n + U\otimes V^\top + V\otimes U^\top ) D$$
where $X\otimes Y^\top$ is a $n \times n$ matrix, the outer product matrix, formed from two $n \times 1$ matrices $X, Y$. Its entries are given by $( X\otimes Y^\top)_{ij} = X_i Y_j$. From this, we get
$$\det(A) = \prod_{i=1}^n (-2a_i) \times \det( I_n - ( U^\top\!\otimes V + V^\top\!\otimes U) )$$
To evaluate the determinant in RHS. We choose a orthonormal base so that the first two dimensions is the one span by the column vectors $U$ and $V$. 
Let $u_1, u_2$ be the first two components of $U$ in this new base and define $v_1, v_2$ in the same manner. We have
$$\begin{align}
   \det( I_n - ( U^\top\!\otimes V + V^\top\!\otimes U) )
= &\det\begin{pmatrix} 
1 - 2 u_1 v_1 & -( u_1 v_2 + v_1 u_2 )\\-(u_2 v_1 + v_2 u_1 ) & 1 - 2 u_2 v_2\end{pmatrix}\\
= & ( 1 - (u_1 v_1 + u_2 v_2) )^2 - (u_1^2 + u_2^2) (v_1^2 + v_2^2)\\
= & (1 - U^\top V )^2 - (U^\top U)(V^\top V)
\end{align}$$
Since 
$$U^\top V = \frac{n}{2},\;\;U^\top U = \frac12 \sum_{i=1}^n a_i\;\;\text{ and }\;\;
V^\top V =  \frac12 \sum_{i=1}^n \frac{1}{a_i}$$
We get
$$\det(A) = (-2)^{n-2} \prod_{i=1} a_i \left( (n - 2)^2 - \sum_{i=1}^n a_i \sum_{j=1}^n \frac{1}{a_j} \right)\tag{*1}$$
If one expand the RHS out, it is a polynomial in $a_i$. Since the LHS is also a polynomial
in $a_i$ and this equality is true for all $a_i > 0$, it is true as a polynomial for all $a_i \in \mathbb{R}$.
If one look at the coefficients on both sides carefully, you will find that
they are all integers. This means this equality is not only true for matrices over $\mathbb{R}$. If one cancel those $\frac{1}{a_j}$ factors properly, $(*1)$ will be true
for matrices over any commutative ring.
A: Well, it has to be a symmetric polynomial and homogeneous of degree $n$ in $a_1, \ldots, a_n$, and so it can be expressed in terms of the elementary symmetric
functions.  For example,  the cases $n=1$ to $7$ are, according to Maple,
$$0$$
$$- \left( a_{{1}}+a_{{2}} \right) ^{2}$$
$$2\, \left( a_{{2}}a_{{1}}+a_{{3}}a_{{1}}+a_{{2}}a_{{3}} \right) 
 \left( a_{{1}}+a_{{2}}+a_{{3}} \right) -2\,a_{{1}}a_{{2}}a_{{3}}
$$
$$-4\, \left( a_{{1}}a_{{2}}a_{{3}}+a_{{4}}a_{{2}}a_{{1}}+a_{{4}}a_{{3}}
a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