2

I have the lines $L_1 = (9,2,0) + s(2,1,0)$ and $L_2 = (7,3,1) + t(0,2,2)$, I'm looking for a line $L_3$ perpendicular to both, regardless of distance/length. The directional vector should be the cross product of $(2,1,0)$ and $(0,2,2)$ obviously (so $(2,-4,4)$). But I was unable to find the "offset point" to $L_3$'s equation(like what $(9,2,0)$ is in $L_1$).

So I found this: Line perpendicular to two other lines - data sufficiency

And I try to calculate that as follows:

$s((2,1,0) \cdot (2,1,0)) - t((2,1,0) \cdot (0,2,2)) = (2,1,0) \cdot ((7,3,1) - (9,2,0)) <=> s(5) - t(2) = -3$ $s((2,1,0) \cdot (0,2,2)) - t((0,2,2) \cdot (0,2,2)) = (0,2,2) \cdot ((7,3,1) - (9,2,0)) <=> s(2) - t(8) = 4 $

I put in $5$ into $L_1$ and $2$ into $L_2$, and I get the points $P1=(19,7,0)$ & $P2=(7,7,3)$. But if I now try to get the directional vector from these two points(so $P2-P1$), I get $(-12,0,3)$, this is nowhere near $(2,-4,4)$, so what did I get there?? What is $(-12,0,3)$ then?

Same thing if I try to put in $s=2$ & $t=8$ , or $s=-3$ & $t=4 $ I get some strange points unrelated to the directional vector $(2,-4,4)$.

When I plot all these three attempts in matlab, I get lines which do intersect both $L_1$ & $ L_2$, but none of them look orthogonal. Here's an example of what it looks like:

enter image description here

And there's this gap between $L_1$ and $L_2$ where $L_3$ should be going through to make it perpendicular to both surely: enter image description here

So how do I get the actual line equation of the line L3 which is orthogonal to both $L_1$ and $L_2$ regardless of distance or length?

dmtri
  • 3,270
  • Each of these lines determines a family of planes (orthogonal to that line). Pick such a plane from each of the two families. If the planes meet, then any line that is in the intersection of these two planes is orthogonal to both lines. Does that help? – MPW Oct 12 '18 at 17:36
  • I'll have to calculate the planes first and see if I get stuck somewhere along the line(pun marginally intended) or not. – Jack Of Blades Oct 12 '18 at 17:40
  • @MPW I took the directional vectors of each line + t(for example 2(x-t) + 1(y-t) + 0(z-t) + t = 0 for planes of L1) as the equations of their family of orthogonal planes, then made those equal to one another, simplified, put in L1's "general coordinates" instead of x,y,z, and I got t = 5. I put in 5 into L1, got (19,7,0). L3 = (19,7,0) + t(2,-4,4), I made L3=L2 and tried to solve for t but I get that t is -6, 4/6 and 1/2. – Jack Of Blades Oct 12 '18 at 18:04
  • see here https://www.physicsandmathstutor.com/a-level-maths/shortest-distance-two-skew-lines/ – Dr. Sonnhard Graubner Oct 12 '18 at 18:11
  • See https://math.stackexchange.com/questions/704249/distance-between-two-lines-by-orthogonal-projection and https://math.stackexchange.com/questions/1885047/skew-lines-and-whats-between-them – David K Oct 12 '18 at 18:23

2 Answers2

1

We have two lines

$$ L_1\to p = p_0+\lambda_1 \vec v_1\\ L_2\to q = q_0+\lambda_2 \vec v_2 $$

and a third line orthogonal to the previous lines

$$ L_3 = u = u_0 + \lambda_3 \vec v_1\times\vec v_2 $$

let us determine $L_3$ such that it passes by $L_1$ and $L_2$ then

$$ p = q + \lambda_3\vec v_1\times\vec v_2\Rightarrow p_0+\lambda_1 \vec v_1 = q_0 + \lambda_2 \vec v_2+\lambda_3 \vec v_1\times\vec v_2 $$

so multiplying by $\vec v_1,\vec v_2$ we get at

$$ p_0\cdot \vec v_1+\lambda_1\vec v_1\cdot\vec v_1 = q_0\cdot\vec v_1+\lambda_2\vec v_1\cdot\vec v_2\\ p_0\cdot \vec v_2+\lambda_1\vec v_2\cdot\vec v_1 = q_0\cdot\vec v_2+\lambda_2\vec v_2\cdot\vec v_2 $$

Solving this system for $\lambda_1 = \lambda_1^*,\lambda_2=\lambda_2^*$ we have

$$ L_3\to p = p_0+\lambda_1^*\vec v_1 + \lambda \vec v_1\times\vec v_2 $$

$L_3$ is orthogonal to either $L_1,L_2$ and intersects both.

Cesareo
  • 33,252
1

I put in 5 into L1 and 2 into L

Why?

The two equations you derived using the method from Line perpendicular to two other lines - data sufficiency were \begin{align} s(5)−t(2)&=−3\\ s(2)−t(8)&=4. \end{align}

A more usual way to write this is \begin{align} 5s−2t&=−3\\ 2s−8t&=4. \end{align}

Solve these as simultaneous equations. There is only one choice of values for $s$ and $t$ that makes both equations true. That is how you should set $s$ and $t.$

David K
  • 98,388
  • I inserted those values because I thought what the author meant was something like "A(t)"/"t of A", never struck me to poise it like a Gaussian system(I did try elimination a few times, but with "wrong systems" so I never got to the correct answer). Thank you so much, this drove me nuts for four days. – Jack Of Blades Oct 12 '18 at 19:32