- ←Prev
- AST
A Library for Handling
World Coordinate Systems
in Astronomy - Next→
- TOC ↑
Description:
This
function finds the distance between two points whose
Frame coordinates are given. The distance
calculated is that along the geodesic curve that joins the two points.
For example, in a basic Frame, the distance calculated will be the Cartesian distance along
the straight line joining the two points. For a more specialised Frame describing a sky
coordinate system, however, it would be the distance along the great circle passing through
two sky positions.
Invocation
RESULT = AST_DISTANCE( THIS, POINT1, POINT2,
STATUS )
Arguments
THIS = INTEGER (Given)
Pointer to the Frame.
POINT1(
) = DOUBLE PRECISION (Given)
An array with one element for each Frame
axis (
Naxes attribute) containing the coordinates of the first point.
POINT2(
) =
DOUBLE PRECISION (Given)
An array with one element for each Frame axis containing the
coordinates of the second point.
STATUS = INTEGER (Given and Returned)
The global status.
Returned Value
AST_DISTANCE = DOUBLE PRECISION
The distance between the two points.
Notes:
-
This function will return a "
bad"
result value (AST__BAD) if any of the input coordinates has this
value.
-
A "
bad"
value will also be returned if this function is invoked with STATUS set to an error value, or if
it should fail for any reason.
Copyright (C) 2021 East Asian Observatory
- ←Prev
- AST
A Library for Handling
World Coordinate
Systems
in Astronomy - Next→
- TOC ↑