Answer
a) $ \cos^2 \phi=\sin^2 \phi$ or, $\cos (2\phi)=0$
b) $\rho ^2 (\sin^2 \phi \cos^2 \theta+ \cos^2 \phi)=9$
Work Step by Step
Conversion of rectangular to spherical coordinates is as follows:
$x=\rho \sin \phi \cos \theta; y=\rho \sin \phi \sin \theta;z=\rho \cos \phi$
and
$\rho=\sqrt {x^2+y^2+z^2}$;
$\cos \phi =\dfrac{z}{\rho}$; $\cos \theta=\dfrac{x}{\rho \sin \phi}$
a) Here, $z^2=x^2+y^2$
This implies that $\rho \cos \phi= (\rho \sin \phi \cos \theta)^2+(\rho \sin \phi \sin \theta)^2$
$ \cos^2 \phi=\sin^2 \phi$ or, $\cos (2\phi)=0$
b) Here, $x^2+z^2=9$
This implies that
$(\rho \sin \phi \cos \theta)^2+(\rho \cos \phi)^2=9$
or, $\rho ^2 \sin^2 \phi \cos^2 \theta+\rho^2 \cos^2 \phi=9$
Hence,$\rho ^2 (\sin^2 \phi \cos^2 \theta+ \cos^2 \phi)=9$