Find the minimum value of $\sqrt{(x_1-x_2)^2 + (2-x_1-x_2)^2 + (2x_1-3x_2)^2}$ This is a question from a practice workbook for a college entrance exam.
Find the minimum value of -
$$\sqrt{(x_1-x_2)^2 + (2-x_1-x_2)^2 + (2x_1-3x_2)^2} \text{  where  } x_1,x_2 \in R$$
I think it will possibly involve the decomposition of this function into finding the minimum distance between two loci, possibly conic sections.
So I tried just simplifying -
$$=\sqrt{6x_1^2+11x_2^2-12x_1x_2-4x_1-4x_2+4}$$
Interestingly if you switch out $x_1, x_2$ with $x,y$ then the standard two degree polynomial that emerges has $\Delta \neq 0$ and $h^2<ab$ suggesting a ellipse (or a single point, or a no solution) I don't know what such a substitution actually means theoretically so I don't know what to from there.
 A: Think of the expression given as distance between two points $(x_1,y_1,z_1)$ and $(x_2,y_2,z_2)$ in $\Bbb{R^3}$. So let us figure out what are $y_i$ and $z_i$. For example, we can take $y_1=2-x_1$ and $y_2=x_2$ and so on...
Consider the lines $L_1$ and $L_2$ given by the vector equations
$$L_1: \mathbf{r}_1=\begin{bmatrix}t\\2-t\\2t\end{bmatrix}=\underbrace{\begin{bmatrix}0\\2\\0\end{bmatrix}}_{\color{red}{\mathbf{a}}}+t\underbrace{\begin{bmatrix}1\\-1\\2\end{bmatrix}}_{\color{red}{t\mathbf{b}}} \quad \text{ and } \quad L_2: \mathbf{r}_2=s\underbrace{\begin{bmatrix}1\\1\\3\end{bmatrix}}_{\color{blue}{s\mathbf{d}}}$$
Then the shortest distance between these two lines is what you are looking for. Perhaps you can take it from here and since the lines are not parallel you can use shortest distance between two skew lines
Some helpful details:
The unit normal vector $\vec{\mathbf{n}}=\begin{bmatrix}-\sqrt{\frac{5}{6}}\\-\frac{1}{\sqrt{30}}\\\sqrt{\frac{2}{15}}\end{bmatrix}$ and if my calculations are correct then the minimum value is $\color{magenta}{\sqrt{\frac{2}{15}}}$.
A: This can be interpreted as a LS problem: minimize the norm of vector $v$, with
$$ v = A\,x + b$$
With the matrix $A$ equal to :
$$ A = \begin{bmatrix}
    1 & -1 \\
    1 & 1 \\
    2 & -3 \\
    \end{bmatrix}
$$
and the vector $b$ equal to :
$$ b = \begin{bmatrix}
    0 \\
    -2 \\
    0 \\
    \end{bmatrix}
$$
The solution is provided by using the pseudo-inverse $A^+$ of the matrix $A$:
$$ \begin{bmatrix}
    x_1 \\
    x_2 \\
    \end{bmatrix}
 = - A^+ b
$$
After some straightforward calculations, we get
$$
 A^+ = \frac{1}{30} \begin{bmatrix}
    5 & 17 & 4 \\
    0 & 12 & -6 \\
    \end{bmatrix}
$$
And finally
$$
\begin{cases}
x_1 = \frac{17}{15} \\[2ex]
x_2 = \frac{12}{15}
\end{cases}
$$
Then, the minimum value is equal to
$$
\sqrt{\frac{2}{15}}
$$
The same as the previous answer!
