While I was working I found a problem in which I encountered $$\det(A+xB)$$ where $A, B \in M_n(\mathbb{C}), x \in \mathbb{R}$. If we denote by $a_1, a_2, ..., a_n$ the eigenvalues of $A$ and by $b_1, b_2, ..., b_n$ the eigenvalues of $B$, it is known, for example, that $\det(A)=a_1a_2...a_n$. My question is:
Is it true that the eigenvalues of $A+xB$ are $(a_1+xb_1), (a_2+xb_2),...,(a_n+xb_n)$? Why? Does it hold for any kind of expression involving $2$ or more matrices?
For example, Lord Shark the Unknown used here that "only possible eigenvalues of $I+A-A^2$ are $1+0-0^2=1$ and $1+1-1^2=1$"
This is not true in general, and it is very easy to write a counterexample. You should do this as an exercise.
However, if $A$ and $B$ have the same eigenspaces, associated with the corresponding indexes, then your formula holds. This is also easy to show. The converse case also holds because of your variable $x$.