Sphere tangent to two lines at their points of intersection with their common perpendicular

I have solved the following problem, except for the third question, which I have only been able to solve partially.

"Let d be the line passing through the points $A(-3,-3,6)$ and $B(9,3,-6)$ and $d'$ the line with equation $\begin{pmatrix}x\\ y\\ z\end{pmatrix}=\begin{pmatrix}1\\ 2\\8\end{pmatrix}+\lambda \begin{pmatrix}2\\-2\\1\end{pmatrix},\ \lambda\in\mathbb{R}$".

(1) Show that the lines $d$ and $d'$ are orthogonal and skew.

(2) Let $p$ be the common perpendicular to $d$ and $d'$. Verify that the points of intersection of $p$ with $d$ and $d'$ are respectively $P_1(-1,-2,4)$ and $P_2 (1,2,8)$.

(3) Find the radius and the center of the sphere tangent to $d$ and $d'$ at their points of intersection with their common perpendicular.

My solution:

(1) $d=\vec{OA}+t\vec{AB}=(-3,-3,6)+t(12,6,-12)$ so

$\vec{v}=(12,6,-12),\ \vec{v'}=(2,-2,1)$ which implies $\vec{v}\cdot\vec{v'}=0$ and thus $d\perp d'$.

$d=d'\Leftrightarrow \begin{cases}-3+12t=1+2\lambda\\ -3+6t=2-2\lambda\\ 6-12t=8+\lambda\end{cases}\Leftrightarrow \begin{cases}\lambda=-2+6t\\ t=\frac{1}{2}\\ t=0\end{cases}$ impossible; so, the lines are skew.

(2)A vector $\vec{PP'}$, where $P\in d,\ P\in d'$ has the form $\vec{PP'}=(1+2\lambda,2-2\lambda, 8+\lambda)-(-3+12t,-3+6t,6-12t)=(4+2\lambda-12t,5-2\lambda-6t,2+\lambda+12t)$ and it is perpendicular to both lines if $$\begin{cases}\vec{PP'}\cdot\vec{v}=0\\ \vec{PP'}\cdot \vec{v'}=0\end{cases}\Leftrightarrow \begin{cases}t=\frac{1}{6}\\ \lambda=0\end{cases}\Leftrightarrow \vec{PP'}=(2,4,4)$$. So the perpendicular $p$ to both lines passes through the points $\fbox{$(-1,-2,4)$}=(-3,-3,6)+\frac{1}{6}(12,6,-12))$ and $\fbox{$(1,2,8)$}$.

(3) We consider the general equation of a sphere: $\pi: x^2+y^2+z^2+ax+by+cz+d=0$: since $P_1\in \pi$ and $P_2\in \pi$ we have that \begin{cases}-a-2b+4c+d=-21\\ a+2b+8c+d=-69\end{cases}. Now, I need two other equations to solve the system, but I haven't been able to find them, so I would appreciate some help in finding them, thanks.


Solution 1:

The center of the sphere is $P_3=\frac12(P_1+P_2)=(0,0,6)$.

Its radius is $R=\frac12(P_1P_2)=6/2=3$ (do you see why ?).

Therefore, the equation of the sphere is plainly:

$$(x-0)^2+(y-0)^2+(y-6)^2=R^2=9$$