Trying to solve for a common magnitude of two non-parallel vectors such that they intersect. I am currently solving using a left inverse, but I am not sure if this is correct.
Let $ x_1 = x_1^0 + tu_1\space$ and $y_1 = y_1^0 +t v_1$ be the parametric equations for the first vector, and $x_2 = x_2^0 + tu_2\space$ and $y_2 = y_2^0 + tv_2$ be the parametric equations for the second vector. To solve for a common factor, $t$, set both equations equal to each other:
$ \begin{bmatrix} x_1^0 \\ y_1^0 \end{bmatrix} + t\begin{bmatrix} u_1 \\ v_1 \end{bmatrix} = \begin{bmatrix} x_2^0 \\ y_2^0 \end{bmatrix} + t\begin{bmatrix} u_2 \\ v_2 \end{bmatrix} $
and solve for $t$
$t= \frac{\begin{bmatrix} x_1^0 - x_2^0 \\ y_1^0 - y_2^0 \end{bmatrix}}{\begin{bmatrix} u_2 - u_1 \\ v_2 - v_1 \end{bmatrix}} $
Of course no such operation exists for vectors, so setting $ \begin{bmatrix} x_1^0 - x_2^0 \\ y_1^0 - y_2^0 \end{bmatrix} = d\vec{x} \space $ and $\begin{bmatrix} u_2 - u_1 \\ v_2 - v_1 \end{bmatrix} = d\vec{u} $, I am taking the left inverse of $d\vec{u}$ to solve for $t$:
$t = (d\vec{u}^Td\vec{u})^{-1}d\vec{u}^Td\vec{x}$
I have tried visualising the results using MATLAB, but they are not consistent with my predictions. I feel as though I have made a mistake with my math. Any insight would be $\textit{greatly}$ appreciated.
At the point of intersection, the values of the parameters do NOT have to be the same. So the correct equation for the desired point of intersection is $$\begin{bmatrix} x_1^0 \\ y_1^0 \end{bmatrix} + t\begin{bmatrix} u_1 \\ v_1 \end{bmatrix} = \begin{bmatrix} x_2^0 \\ y_2^0 \end{bmatrix} + s\begin{bmatrix} u_2 \\ v_2 \end{bmatrix},$$ which you need to solve for two unknown parameters $t$ and $s$. Now this is just a system of two linear equations with two unknowns.