next up previous 264
Next: AST_INTERVAL - Create a Interval
Up: AST Routine Descriptions
Previous: AST_IMPORT - Import an Object pointer to the current context


AST_INTERSECT - Find the point of intersection between two geodesic curves

Description:
This routine finds the coordinate values at the point of intersection between two geodesic curves. Each curve is specified by two points on the curve. It can only be used with 2-dimensional Frames.

For example, in a basic Frame, it will find the point of intersection between two straight lines. But for a SkyFrame it will find an intersection of two great circles.

Invocation:
CALL AST_INTERSECT( THIS, A1, A2, B1, B2, CROSS, STATUS )
Arguments:
THIS = INTEGER (Given)
Pointer to the Frame.
A1( 2 ) = DOUBLE PRECISION (Given)
An array with one element for each Frame axis (Naxes attribute). This should contain the coordinates of the first point on the first geodesic curve.
A2( 2 ) = DOUBLE PRECISION (Given)
An array with one element for each Frame axis (Naxes attribute). This should contain the coordinates of a second point on the first geodesic curve. It should not be co-incident with the first point.
B1( 2 ) = DOUBLE PRECISION (Given)
An array with one element for each Frame axis (Naxes attribute). This should contain the coordinates of the first point on the second geodesic curve.
B2( 2 ) = DOUBLE PRECISION (Given)
An array with one element for each Frame axis (Naxes attribute). This should contain the coordinates of a second point on the second geodesic curve. It should not be co-incident with the first point.
CROSS( 2 ) = DOUBLE PRECISION (Returned)
An array with one element for each Frame axis in which the coordinates of the required intersection will be returned.
STATUS = INTEGER (Given and Returned)
The global status.
Notes:
  • For SkyFrames each curve will be a great circle, and in general each pair of curves will intersect at two diametrically opposite points on the sky. The returned position is the one which is closest to point A1.

  • This function will return "bad" coordinate values (AST__BAD) if any of the input coordinates has this value, or if the two points defining either geodesic are co-incident, or if the two curves do not intersect.

  • The geodesic curve used by this routine is the path of shortest distance between two points, as defined by the AST_DISTANCE function.

  • An error will be reported if the Frame is not 2-dimensional.


next up previous 264
Next: AST_INTERVAL - Create a Interval
Up: AST Routine Descriptions
Previous: AST_IMPORT - Import an Object pointer to the current context

AST A Library for Handling World Coordinate Systems in Astronomy
Starlink User Note 210
R.F. Warren-Smith & D.S. Berry
24th May 2011
E-mail:ussc@star.rl.ac.uk

Copyright (C) 2009 Science \& Technology Facilities Council