Equation of the line AB is x−63=y−7−1=z−41
Equation of the line CD is x−0−3=y+92=z−24
Let x−63=y−7−1=z−41=λ and x−0−3=y+92=z−24=k
So, any point on the line AB and CD can be written as (3λ+6, −λ+7, λ+4) and (−3k, 2k−9, 4k+2) respectively.
Let the coordinates of the points P and Q are (3λ+6, −λ+7, λ+4) and (−3k, 2k−9, 4k+2) respectively.
∴−−→PQ=(3λ+3k+6)^i−(λ+2k−16)^j+(λ−4k+2)^k
∵−−→PQ is perpendicular to both −−→AB and −−→CD.
∴−−→PQ.−−→AB=0 and −−→PQ.−−→CD=0
⇒−−→PQ.−−→AB=0⇒ 9λ+9k+18+λ+2k−16+λ−4k+2 = 0⇒11λ+7k+4=0 ...(1)
⇒−−→PQ.−−→CD=0⇒−9λ−9k−18−2λ−4k+32+4λ−16k+8=0⇒−7λ−29k+22=0 ...(2)
Solving equations (1) and (2), we get
λ=−1 and k=1.
So, the coordinates of P and Q are (3,8,3) and (−3,−7,6) respectively.