I'm trying to find the analytical solution to the following problem
\begin{align} \min_c & \; c^T Wc \\ \text{s.t. } & \; Xc = x_0 \end{align} where $c,x_0 \in\mathbb R^n$, $W$ is an invertible $n\times n$ diagonal matrix, $X$ is a $m\times n$ matrix.
It's easy to show with Lagrange multiplier that the solution $c^*$ satisfies $$ \begin{pmatrix} W & -X^T\\ X & 0 \end{pmatrix} \begin{pmatrix} c^*\\ \lambda \end{pmatrix} = \begin{pmatrix} 0\\ x_0 \end{pmatrix} $$
With the method in this answer, we can find that $$ \begin{pmatrix} W & -X^T\\ X & 0 \end{pmatrix}^{-1} = \begin{pmatrix} \left[W^TW+X^TX + W^T(-X^T)(XX^T)^{-1}(-X)W \right]^{-1} & **\\ ** & ** \end{pmatrix} \begin{pmatrix} W & X^T\\ -X & 0 \end{pmatrix} \\= \begin{pmatrix} ** & \left[W^TW+X^TX + W^T(-X^T)(XX^T)^{-1}(-X)W \right]^{-1}X^T\\ ** & ** \end{pmatrix} $$
(** are irrelevant elements in calculation.)
Thus $$ c^* = \left[W^TW+X^TX + W^T(-X^T)(XX^T)^{-1}(-X)W \right]^{-1}X^Tx_0 $$
It seems complicated. I read in a note that $$ c^* = WX^T (XWX^T)^{-1} {x}_0 $$
Are they equivalent and how can I simplify the expression? Any reference is appreciated.
The linear system boils down to $Wc^* = X^T\lambda$ and $Xc = x_0$. The first equation gives you $c^*=W^{-1}X^T\lambda$, and plugging that into the second equation you get $XW^{-1}X^T\lambda=x_0$. That means $\lambda=(XW^{-1}X^T)^{-1}x_0$, so $c^*=W^{-1}X^T(XW^{-1}X^T)^{-1}x_0$.