double precision function kutl_distance_line_line(point1, eta1, * point2, eta2) * * begin_doc * * Returns distance between two lines * * Input Parameters: * point1(3) double precision array * (x,y,z) of initial point defining line 1 * * eta1(3) double precision array * direction cosines of line 1 (do not have to be normalized) * * point2(3) double precision array * (x,y,z) of initial point defining line 2 * * eta2(3) double precision array * direction cosines of line 2 (do not have to be normalized) * * Output Parameters: * * Other routines: * * Notes: * * >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> * The lines are defined by * x = x1 + eta1*r1 * x = x2 + eta2*r2 * * where r1, r2 are free parameters and eta1 and eta2 do not have to * be normalized to 1. The distance is calculated from * * delta*(eta1 x eta2) * d = --------------------- * |eta1 x eta2| * * where delta(i) = x2(i) - x1(i) * * The sign convention is chosen to match what you would get for the * distance in the xy plane between a line and a point. * * >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> * * Author: Paul R Avery Created: Sun Nov 16 18:33:24 EST 1997 * * Major revisions: * * * end_doc