I have a $3 \times 3$ real symmetric matrix $\bf{A}$ (not necessarily positive definite or semidefinite). Let $I_1$, $I_2$, and $I_3$ denote its three invariants defined as \begin{equation} I_1 = tr({\bf{A}}) \\ I_2 = \frac{1}{2}[tr^2({\bf{A}})-tr({\bf{A}}^2)] \\ I_3 = det({\bf{A}}) \end{equation} Let $\lambda_i$ ($i = 1, 2, 3$) be the three eigenvalues of $\bf{A}$. Then, $\lambda_i$ would satisfy the characteristic equation \begin{equation} \lambda_i^3-I_1\lambda_i^2+I_2\lambda_i-I_3=0 \end{equation} Differentiating the characteristic equation w.r.t $\bf{A}$, I would be able to solve the partial derivatives of $\lambda$'s w.r.t. $\bf{A}$ as: \begin{equation} \frac{\partial \lambda_i}{\partial {\bf{A}}} = \frac{1}{3 \lambda_i^2 - 2 I_1 \lambda_i + I_2}(\lambda_i^2 \frac{\partial I_1}{\partial {\bf{A}}} - \lambda_i \frac{\partial I_2}{\partial {\bf{A}}} + \frac{\partial I_3}{\partial {\bf{A}}}) \end{equation} where let's assume everything on the RHS is known.
However, I noted that this equation does not alwys hold. When $\bf{A}$ has two equal eigenvalues, say $\lambda_1 = \lambda_2$, the denominator $3 \lambda_i^2 - 2 I_1 \lambda_i + I_2 = 0$. I have tried different methods to do the derivation, such as that described in Derivative for eigenvalue with respect to 1st / 2nd / 3rd invariant of a matrix and in Derivation of Eigenvalues w.r.t. the matrix items, but these soultions also appear to be sigular when $\bf{A}$ has repeated eigenvalues.
So, my questions are: (1) does $\frac{\partial \lambda_i}{\partial {\bf{A}}}$ exist when $\lambda_i$ is not unique, and (2) if it exists, how can I obtain it? Can anyone give me any advice? Thanks.
The application is in solid mechanics, where I want to calculate the outward norm of a surface in general stress space, but the expression of the surface is defined by principal stresses (the eigenvalues of the stress tensor).