Jump to content

Skew lines/R^3/Distance/Extremal problem/Example

From Wikiversity

Let

G=P+ℝv

and

H=Q+ℝw

be skew lines. We want to understand the distance problem between the two lines as an extremal problem in the sense of higher-dimensional analysis. Let

P=(a1a2a3)

and

Q=(b1b2b3).

The square of the distance between the two points

P′=(a1a2a3)+s(v1v2v3)

and

Q′=(b1b2b3)+t(w1w2w3)

is (setting ci=ai−bi)

d(P′,Q′)2=(c1+sv1−tw1)2+(c2+sv2−tw2)2+(c3+sv3−tw3)2=c12+s2v12+t2w12+2sc1v1−2tc1w1−2stv1w1+c22+s2v22+t2w22+2sa2v2−2tc2w2−2stv2w2+c32+s2v32+t2w32+2sc3v3−2tc3w3−2stv3w3=c12+c22+c32+2s(c1v1+c2v2+c3v3)−2t(c1w1+c2w2+c3w3)+s2(v12+v22+v32)+t2(w12+w22+w32)−2st(v1w1+v2w2+v3w3).

We interpret this expression with methods of Analysis 2. We consider the data given by the lines as fixed parameters, so that we have a real-valued expression f(s,t) in the two real variables s and t, and we want to determine its extrema. The partial derivatives are

∂f∂s=2(c1v1+c2v2+c3v3)+2s(v12+v22+v32)−2t(v1w1+v2w2+v3w3)

and

∂f∂t=2(c1w1+c2w2+c3w3)+2t(w12+w22+w32)−2s(v1w1+v2w2+v3w3).

If we equate this with 0, then we obtain an inhomogeneous linear system of equations with two equations in the variables s and t. Using Cramer's rule, we get

s=det⁡(−c1v1−c2v2−c3v3−v1w1−v2w2−v3w3−c1w1−c2w2−c3w3w12+w22+w32)det⁡(v12+v22+v32−v1w1−v2w2−v3w3−v1w1−v2w2−v3w3w12+w22+w32)

and

t=det⁡(v12+v22+v32−c1v1−c2v2−c3v3−v1w1−v2w2−v3w3−c1w1−c2w2−c3w3)det⁡(v12+v22+v32−v1w1−v2w2−v3w3−v1w1−v2w2−v3w3w12+w22+w32).

If v and w are normed, then these expressions can be simplified to

s=−⟨P−Q,v⟩−⟨P−Q,w⟩⟨v,w⟩1−⟨v,w⟩2

and

t=−⟨P−Q,w⟩−⟨P−Q,v⟩⟨v,w⟩1−⟨v,w⟩2.