I need to minimize a sum of squares between two large (10000 by 40000) matrices: Σ(X-A)^2 where X is a vertical concatenation of two matrices (10000 by 20000) and each segme