Suppose that $mathbf{A}$ and $mathbf{B}$ are two $Ntimes M$ matrices with $Nleq M$ and $text{rank}(mathbf{A}) = text{rank}(mathbf{B}) = N$.

**Question** : Is the following statement true ? Why ?

If $text{rank}((cosalphamathbf{I})mathbf{A}+(sinalphamathbf{I})mathbf{B}) = N$, then $text{rank}(mathbf{C}mathbf{A}+mathbf{S}mathbf{B}) = N$.

where $mathbf{I}$ is the $Ntimes N$ identity matrix, $mathbf{C}$ and $mathbf{S}$ are two $Ntimes N$ **diagonal** matrices with $mathbf{C} = text{diag}(costheta_1,cdots,costheta_N)$ and $mathbf{S} = text{diag}(sintheta_1,cdots,sintheta_N)$.

**Thoughts** : Since $mathbf{C}$, $mathbf{S}$ and $mathbf{I}$ are row-equivalent, I try to prove that $((cosalphamathbf{I})mathbf{A}+(sinalphamathbf{I})mathbf{B})$ and $(mathbf{C}mathbf{A}+mathbf{S}mathbf{B})$ are also row-equivalent. Any ideas on how to proceed with this ?