(a) Let $A$ be an $m \times n$ matrix and let $M=(A \mid \mathbf{b})$ be the augmented matrix for the linear system $A \mathbf{x}=\mathbf{b}$. Show that either (i) $\operatorname{rank} A=\operatorname{rank} M$, or (ii) $\operatorname{rank} A=\operatorname{rank} M-1$.
(b) Prove that the system is compatible if and only if case (i) holds.