The equations of the given lines are
→r=(^i+2^j+^k)+λ(^i−^j+^k) and
→r=^2i−^j−^k+μ(^2i+^j+2^k)
It is known that the shortest distance between the lines →r=→a1+λ→b1 and →r=→a2+μ→b2 is given by,
d=∣∣
∣
∣∣(→b1×→b2)(→a1−→a2)∣∣→b1×→b2∣∣∣∣
∣
∣∣.....(1)
Comparing the given equations, we obtain
→a1=^i+2^j+^k
→b1=^i−^j+^k
→a2=2^i−^j−^k
→b2=2^i+^j+2^k
→a2−→a1=(2^i−^j−^k)−(^i+2^j+^k)=(^i−3^j−2^k)
→b1×→b2=∣∣
∣
∣∣^i^j^j1−11212∣∣
∣
∣∣
→b1×→b2=(−2−1)^i−(2−2)^j+(1+2)^k=−3^i+3^k
⇒ ∣∣→b1×→b2∣∣=√(−3)2+(3)2=√18=3√2
Substituting all the values in equation (1), we obtain
d=∣∣
∣
∣∣(^3^i+3^k).(^i−3^j−2^k)3√2∣∣
∣
∣∣
⇒ d=∣∣∣−3.1+3(−2)3√2∣∣∣
⇒ d=∣∣∣−93√2∣∣∣
⇒ d=3√2=3×√2√2×√2=3√22
Therefore, the shortest distance between the two lines is 3√22 units.