code: def recsph(rectan):
      
      rectan = stypes.toDoubleVector(rectan)
      r = ctypes.c_double()
      colat = ctypes.c_double()
      lon = ctypes.c_double()
      libspice.recsph_c(rectan, ctypes.byref(r), ctypes.byref(colat),
                        ctypes.byref(lon))
      return r.value, colat.value, lon.value
docs: Convert from rectangular coordinates to spherical coordinates.
  
      http://naif.jpl.nasa.gov/pub/naif/toolkit_docs/C/cspice/recrad_c.html
  
      :param rectan: Rectangular coordinates of a point.
      :type rectan: 3-Element Array of floats
      :return:
              Distance from the origin,
              Angle from the positive Z-axis,
              Longitude in radians.
      :rtype: tuple