ZenithalProjection

class sofia_redux.scan.coordinate_systems.projection.zenithal_projection.ZenithalProjection[source]

Bases: SphericalProjection

Initialization for the abstract zenithal projection.

A zenithal projection (azimuthal projection) is one in which the surface of projection is a plane. A native coordinate system is defined such that the polar axis is orthogonal to the plane of projection. Meridians are projected as equispaced rays from a central point, and parallels are concentric circles centered on that same point.

By default, the native pole is set to (0, 90) degrees LON/LAT.

Methods Summary

calculate_celestial_pole()

Calculate the celestial pole.

get_offsets(theta, phi[, offsets])

Get the offsets given theta and phi.

get_phi_theta(offsets[, phi_theta])

Return the phi (longitude) and theta (latitude) coordinates.

r(theta)

Return the radius of a point from the center of the projection.

theta_of_r(r)

Return theta (latitude) given a radius from the central point.

Methods Documentation

calculate_celestial_pole()[source]

Calculate the celestial pole.

Returns:
None
get_offsets(theta, phi, offsets=None)[source]

Get the offsets given theta and phi.

Takes the theta (latitude) and phi (longitude) coordinates about the celestial pole and converts them to offsets from a reference position. For a zenithal projection, this is given by:

r = radius_from_angle_function(theta) x = r * sin(phi) y = -r * cos(phi)

where radius_from_angle_function depends on the zenithal projection model.

Parameters:
thetaunits.Quantity

The theta angle.

phiunits.Quantity

The phi angle.

offsetsCoordinate2D, optional

An optional coordinate system in which to place the results.

Returns:
offsetsCoordinate2D
get_phi_theta(offsets, phi_theta=None)[source]

Return the phi (longitude) and theta (latitude) coordinates.

The phi and theta coordinates refer to the inverse projection (deprojection) of projected offsets about the native pole. phi is the deprojected longitude, and theta is the deprojected latitude of the offsets. For a zenithal projection these are given as:

phi = arctan(x, -y) theta = angle_from_radius_function(sqrt(x^2 + y^2))

where angle_from_radius_function depends on the exact zenithal projection model.

Parameters:
offsetsCoordinate2D
phi_thetaSphericalCoordinates, optional

An optional output coordinate system in which to place the results.

Returns:
coordinatesSphericalCoordinates
abstract r(theta)[source]

Return the radius of a point from the center of the projection.

Parameters:
thetafloat or numpy.ndarray or units.Quantity

The latitude angle.

Returns:
runits.Quantity

The distance of the point from the central point.

abstract theta_of_r(r)[source]

Return theta (latitude) given a radius from the central point.

Parameters:
rfloat or numpy.ndarray or units.Quantity

The distance of the point from the central point.

Returns:
thetaunits.Quantity