# Shortest distance between two skew lines

1. Nov 27, 2009

### iamsmooth

1. The problem statement, all variables and given/known data
What is the shortest distance between these two lines?

L1:(x,y,z)=(4,−2,−2)+t(1,1,−3)
L2: The line through the points (−2,−2,0) and (−4,−5,0)

2. Relevant equations
distance formula

3. The attempt at a solution

I thought I was on the right track but apparently not.

For L1, I took 2 arbitrary t's to get 2 points on the line (which looking back, I think might be a wrong way to approach)

With t=1 and t=3, I got the points (5,-1,-5) for t=1 and (7,1,-11) for t=3.
P2-P1 = (2,2,-6) for L1

Now since the points for L2 are given:
P2-P1 = (-2,-3,0) for L2

Now I can take the cross product of the two lines:

$$\left| \begin{array}{ccc} i & j & k \\ 2 & 2 & -6 \\ -2 & -3 & 0 \end{array} \right| = -18i -12j -2k$$

Plugging this all in to the distance formula equation I get:

$$\frac{-4(-18)-5(-12)+6(-2)}{\sqrt{-18^2-12^2-2^2}} = \frac{120}{\sqrt{472}}$$

However, the answer is wrong. Any idea what I did wrong?

Thanks

2. Nov 27, 2009

### Dick

For one thing, if I take the cross the two direction vectors of your lines, I get (-18,12,-2). And for another thing, where did you get the (-4,-5,6) you plugged into the distance formula?

3. Nov 28, 2009

### iamsmooth

I totally mixed up the logic for the algorithm, but I figured it out. I got the parametric equation from the 2 points, and from there solved it. Sorry for the trouble.