With $n>m$, real number matrices $A$, $B$, $C$ are shaped like:
$$A=\left( \begin{array}{ccc} a_{1,1} & \cdots & a_{1,m} \\ \vdots & \ddots & \vdots \\ a_{n,m} & \cdots & a_{n,m} \\ \end{array} \right),B=\left( \begin{array}{cc} b_{1,1} & b_{1,2} \\ \vdots & \vdots \\ b_{m,1} & b_{m,2} \\ \end{array} \right),C=\left( \begin{array}{cc} c_{1,1} & c_{1,2} \\ \vdots & \vdots \\ c_{n,1} & c_{n,2} \\ \end{array} \right)$$ With $A$ and $C$ fixed, how do I find the B matrix that minimizes the expression:
$$\underset{1\leq i\leq n}{\max }\left(\left(c_{i,1}-\left(a_{i,1} b_{1,1}+a_{i,2} b_{2,1}+\text{...}+a_{i,m} b_{m,1}\right)\right){}^2+\left(c_{i,2}-\left(a_{i,1} b_{1,2}+a_{i,2} b_{2,2}+\text{...}+a_{i,m} b_{m,2}\right)\right){}^2\right)$$
That is the largest diagonal element of $(C-A\cdot B)\cdot (C-A\cdot B)^{\mathsf{T}}$
The rank of $A$ is $m$.