caput.astro.coordinates.spherical#

Spherical coordinate transformations and projections.

Functions#

cart_to_sph(→ numpy.ndarray[numpy.floating])

Convert a vector of Cartesian coordinates into spherical polar coordinates.

cosine_rule(→ numpy.ndarray[numpy.float64])

Calculate the distances between a grid of points.

great_circle_points(→ numpy.ndarray[numpy.floating])

Compute intermediate points on the great circle between endpoints..

ground_to_sph(x, y, lat)

Compute CIRS coordinates from ground-fixed coordinates.

norm_vec2(→ None)

For an array of 2D vectors, normalise each to unit length in-place.

projected_distance(ha, lat, dec, x, y[, z])

Compute distance projected in the direction of a source.

rotate_ypr(rot, xhat, yhat, zhat)

Rotate a basis by a yaw, pitch and roll.

sph_dot(→ numpy.ndarray[numpy.floating])

Take the scalar product in spherical polar coordinates.

sph_to_cart(→ numpy.ndarray[numpy.float64])

Convert a vector in spherical polar coordinates to Cartesian coordinates.

sph_to_ground(ha, lat, dec)

Get the ground based XYZ coordinates.

sphdist(long1, lat1, long2, lat2)

Return the angular distance between two coordinates on the sphere.

thetaphi_plane(→ tuple[numpy.ndarray[numpy.floating], ...)

Compute unit vectors from spherical polar coordinate positions.

thetaphi_plane_cart(→ numpy.ndarray[numpy.float64])

Convert unit vectors in spherical polar coordinates to Cartesian coordinates.