Suppose $A\in\mathbb R^{n\times n}$, $a,b\in\mathbb R$, $a\ne b$ and $$(A+aI_n)(A+bI_n)=0$$ where $I_n$ denotes the identity. Prove
1). $\text{rank}(A+aI_n)+\text{rank}(A+bI_n)=n$
2). $A$ is similar to a diagonal matrix.
Since I'm still struggling with the first, I haven't yet seen the relation between the two.
Here is my attempt for the first:
Clearly, $$\mathscr C[(A+bI_n)]\subset \text{Ker}(A+aI_n)$$, where $\mathscr C(\cdot)$ denotes column space. And note that
$$\begin{align}
\dim\text{Ker}(A+aI_n)+\dim\text{Im}(A+aI_n)
&=\dim\text{Ker}(A+aI_n)+\dim\mathscr C[(A+aI_n)]
\\&=\dim\text{Ker}(A+aI_n)+\text{rank}(A+aI_n)
\\&=n
\end{align}$$
Then all I need to do is to show
$$\dim\mathscr C[(A+bI_n)]=\dim \text{Ker}(A+aI_n)$$
or equivalently,
$$\mathscr C[(A+bI_n)]= \text{Ker}(A+aI_n)$$
and that's where I get stuck.
Any help or hint will be appreciated. Best regards!
We start by noting $$ \mathscr C[(A+bI)]\subset \text{Ker}(A+aI) $$ as you say. It follows that $$ \operatorname{rank}(A + bI) \leq \dim\ker(A + aI) $$ By the rank-nullity theorem, we have
$$ \operatorname{rank}(A + bI) \leq n - \operatorname{rank}(A + aI) \implies\\ \operatorname{rank}(A + bI) + \operatorname{rank}(A + aI) \leq n $$ Up to some slight differences, this is basically what you have so far
It now remains to be shown that $$ \operatorname{rank}(A + bI) + \operatorname{rank}(A + aI) \geq n $$ In order to do this, we note that $$ \ker(A + aI) \cap \ker(A + bI) = \{0\} $$ I will leave the proof of this fact to you (at least give it a shot). From there, it follows that $$ \dim \ker(A + aI) + \dim \ker(A + bI) \leq n \implies\\ (n - \operatorname{rank}(A + aI)) + (n - \operatorname{rank}(A + bI)) \leq n $$ and I will let you take it from there.
We now have enough to answer the first part of the question.
First, remember $(A + aI)$ and $(A + bI)$ have disjoint kernels whose direct sum is $\Bbb R^n$.
Let $\{v_1,\dots,v_k\}$ denote a basis for $\ker(A + aI)$. Let $\{v_{k+1},\dots,v_n\}$ be a basis for $\ker(A + bI)$. The vectors $\{v_1,\dots,v_n\}$ form a basis of $\Bbb R^n$, and the matrix of $A$ relative to this basis is diagonal.
Since you have vague knowledge of minimal polynomials, here is the quick-and-easy approach to part $2$. Let $p$ denote the polynomial $p(x) = (x+a)(x+b)$. Because $p(A) = 0$, the minimal polynomial of $A$ divides $p$. It follows that the minimal polynomial of $A$ has no repeated factors, which means that $A$ diagonalizable.