No, the eigenvalues of a matrix are not unchanged if a constant is added to each diagonal element. Adding a constant to the diagonal elements of a matrix is equivalent to performing a diagonal shift, and this operation does affect the eigenvalues of the matrix.
To see this, consider a matrix A with eigenvalues λ₁, λ₂, ..., λₙ. If we add a constant c to each diagonal element, the new matrix A' can be written as A' = A + cI, where I is the identity matrix of the same size as A. The eigenvalues of A' are then the solutions to the equation det(A' - λI) = 0.
Expanding this determinant expression, we have: det(A' - λI) = det((A + cI) - λI) = det(A + (c - λ)I)
Since the determinant is a polynomial expression in the entries of the matrix, adding the constant (c - λ) to each diagonal element will shift the polynomial by that constant. As a result, the eigenvalues of A' are λ₁ + (c - λ), λ₂ + (c - λ), ..., λₙ + (c - λ).
Therefore, adding a constant to each diagonal element of a matrix will shift the eigenvalues by that constant.