Dismiss Notice
Join Physics Forums Today!
The friendliest, high quality science and math community on the planet! Everyone who loves science is here!

Find the shortest distance between two lines:

  1. Oct 18, 2010 #1
    Given the following two skew lines:
    L1: (0, 4, -3) + s(-1, 1, 3)
    L2: (1, 2, 5) + t(-3, 2, 5)

    Find the shortest distance.



    MY WORK::
    Cross-product of the lines (-1, 1, 3) X (-3, 2, 5) = (-1, -4, 1) with length 3*sqrt(2)
    Vector between the points (0, 4, -3) - (1, 2, 5) = (-1, 2, -8)

    Dot product of those results (-1, 2, -8) . (-1, -4, 1) = -15

    Remove sign and divide by cross-product length 15 / (3 sqrt(2)) = 5/sqrt(2)




    I was wondering if the VECTOR between the points is right or is the reverse
    (1,2,5)-(0,4,-3)= (1, -2, 13) ??????????????
     
  2. jcsd
  3. Oct 18, 2010 #2

    Mark44

    Staff: Mentor

    The two lines can be thought of as lying in two parallel planes. The cross product of the directions of the two lines gives you a vector that is perpendicular to these planes.

    Your first vector between the two points on the lines, <-1, 2, -8> is correct, but the opposite, <1, -2, 8> would also work. Was <1, -2, 13> a typo?

    What you want is the projection of the vector <1, -2, 8> in the direction of the vector <-1, 4, 1> (I didn't check your cross-product work). That will give you the shortest distance between the two lines.
     
Share this great discussion with others via Reddit, Google+, Twitter, or Facebook