Is any symmetric matrix of which its diagonalvector equals its eigenvalues a diagonal matrix? Let $A$ be an $n \times n$ a real, positive semidefinite and symmetric matrix. Suppose we know that the diagonal of this matrix is equal to its eigenvalues. (So if we have eigenvalues $\lambda_1, ... \lambda_n$, then $diag(A)$ is a permutation of $(\lambda_1, ..., \lambda_n)$.)
Can we prove from these assumptions that $A$ is a diagonal matrix? I.e. all non-diagonal entries are $0$? And if so, how?
It's equal to this question, only the counterexample given there is not symmetric.

Ideas so far:
Proving it the other way around is easier. If a matrix is diagonal and $n \times n$, then its entries are equal to its eigenvalues. But this doesn't help with proving it the other way around.
I know that since $A$ is real, and positive semidefinite, we can do a diagonalization by eigendecomposition to find $A = VBV^{T}$ with $V$ an orthonormal matrix and $B$ a diagonal matrix with eigenvalues on the diagonal. I've tried to prove from here that the $diag(A)$ being a permutation of $diag(B)$ must mean that $V$ is a permutation matrix, i.e. $V$'s orthonormal rows consist of $n-1$ zeros and a single 1, but I couldn't get the math working in cases when there are two equal eigenvalues on $B$'s diagonal.
 A: the underlying ideas come from majorization but all you need to do is check the Frobenius norm
$\big \Vert A\big \Vert_F^2 = \sum_{k=1}^n\lambda_k^2 = \sum_{k=1}^n a_{k,k}^2 =  \big(\sum_{k=1}^n a_{k,k}^2\big) +  \big(\sum_{k=1}^n\sum_{j\neq k} a_{j,k}^2 \big)=\big \Vert A\big \Vert_F^2$
so all off diagonal entries are zero.
With a little care, you can also do this with Hadamard Determinant Inequality.
A: It's true for symmetric matrices. Consider the characteristic polynomial of $A$:
$$\chi_A(x) = (x - \lambda_1) \cdot \ldots \cdot (x - \lambda_n) = x^n + c_{n-1}x^{n-1} + c_{n-2}x^{n-2} + \ldots.$$
By Fadeev-LeVerrier, we must have
$$c_{n-2} = \frac{1}{2} \left(\mathrm{tr}(A)^2 - \mathrm{tr}(A^2)\right).$$
On the other hand, by multiplying out, $c_{n-2}$ must be equal to
$$\sum\limits_{j < k} \lambda_j\lambda_k = \frac{1}{2}\sum\limits_{j \neq k} \lambda_j\lambda_k.$$
Thus
$$\frac{1}{2}\sum\limits_{j \neq k} \lambda_j\lambda_k = \frac{1}{2} \left(\mathrm{tr}(A)^2 - \mathrm{tr}(A^2)\right).$$
Now, as $A$ is symmetric, $\mathrm{tr}(A^2)$ is just the square of all entries of $A$. We thus arrive at
$$\frac{1}{2}\sum\limits_{j \neq k} \lambda_j\lambda_k = \frac{1}{2}\left(\sum\limits_{j,k = 1}^n \lambda_j\lambda_k - \sum\limits_{j,k = 1}^n A_{j,k}^2\right) = \frac{1}{2}\left(\sum\limits_{j = 1}^n \lambda_j^2 + \sum\limits_{j \neq k}^n \lambda_j\lambda_k - \sum\limits_{j,k = 1}^n A_{j,k}^2\right).$$
By assumption we have $\sum\limits_{j = 1}^n \lambda_j^2 = \sum\limits_{j = 1}^n A_{j,j}^2$, hence
$$0 = - \sum\limits_{j \neq k} A_{j,k}^2.$$
Therefore all non-diagonal terms must be $0$.
A: I will suppose that with the eigenvalues you mean the eigenvalues with their proper multiplicity (as roots of the characteristic polynomial). On the other hand I will need no other hypotheses than having a real symmetric matrix.
Then let me rephrase the question as follows: suppose we have a real diagonal matrix $D$, and we add to it a symmetric matrix$~S$ that is non zero but whose diagonal entries are all zero; then is it possible that $S+D$ has the same characteristic polynomial as $D~$? (A counterexample to your question would be such an $S+D$.) The answer is that his is not possible, because if $n$ is the size of the matrix (obviously $n\geq 2$ is necessary), then the coefficient of $X^{n-2}$ in the characteristic polynomial of $S+D$ is strictly less than the corresponding coefficient of the characteristic polynomial of $D$, contradicting equality of those polynomials. To see this, use that the mentioned coefficient is the sum over all principal $2\times 2$ minors of the matrix in question (this is true for all matrices) and each such $2\times 2$ submatrix $\binom{a~~b}{b~~c}$ gives a minor $ac-b^2$ where the product $ac$ of diagonal entries is the same between the matrices $S+D$ and $D$, while $-b^2$ is always nonpositive, is at least once strictly positive for $S+D$ while it is always $0$ for $D$.
