NAME:
XYZ_to_lbd
PURPOSE:
transform from rectangular Galactic coordinates to spherical Galactic coordinates (works with vector inputs)
INPUT:
X - component towards the Galactic Center (in kpc; though this obviously does not matter))
Y - component in the direction of Galactic rotation (in kpc)
Z - component towards the North Galactic Pole (kpc)
degree - (Bool) if True, return l and b in degrees
OUTPUT:
[l,b,d] in (rad,rad,kpc)
For vector inputs [:,3]
HISTORY:
2009-10-24 - Written - Bovy (NYU)