Usage of angularSeparationOfStrings

Return to directory of Todd's CASA extensions

Computes the angular separation between two directions on the sky. Returns the value in degrees. It computes great circle angle using the Vincenty formula.

See also angularSeparationOfStringsFromFile, angularSeparation, angularSeparationOfFields, angularSeparationOfPlanets, angularSeparationRadians, and angularSeparationRadiansTuples.


au.angularSeparationOfStrings(radec0='', radec1='', returnComponents=False, uncertainties=None, 
                                                   date=None, observatory='ALMA')
Accepts input in any of the following forms:
  • '23:29:17.70000, -47:30:19.211595' (comma-delimited positions)
  • '23:29:17.70000 -47:30:19.211595' (space-delimited positions)
  • '23:29:17.70000, -' (casa format for declination)
  • '23:29:17.70000 -' (casa format for declination)
  • '23 29 17.70 -47 30 19.211595' (fully space-delimited)
  • Ampersands and leading spaces are removed from both coordinates.

If date is specified, then it will also convert the coordinates to Az/El at ALMA, then compute the delta Az and delta El, using the specified observatory name.

If returnComponents is True, it also returns the separation along the two coordinate system components via the following list: [separation, separationRA, separationDec, separationRA*cosine(Dec), positionAngle(degrees)]

If uncertainties is a list of 4 numbers, then run a Monte-Carlo simulation using these values as ra0unc, dec0unc, ra1unc, dec1unc


CASA <3> au.angularSeparationOfStrings('01:06:45.10636, -040:34:19.951581','01:06:45.10700 -')
radian = 5.39982e-08, degrees = 0.000003, arcsec = 0.011138
  Out[3]: 3.0938673771271819e-06
CASA <4>: au.angularSeparationOfStrings('01:06:45.10636, -040:34:19.951581','01:06:45.10700 -', True)
RA Separation: radian = -3.53528e-08, degrees = -0.000002, arcsec = -0.007292
Dec Separation: radian = 4.08165e-08, degrees = 0.000002, arcsec = 0.008419
Separation: radian = 5.39982e-08, degrees = 0.000003, arcsec = 0.011138

-- ToddHunter - 2012-09-05
Topic revision: r11 - 2014-10-27, ToddHunter
This site is powered by FoswikiCopyright © by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding NRAO Public Wiki? Send feedback