nraonrao
 
NRAO Home > CASA > CasaRef
measures.direction - Function

1.3.1 define a direction measure
Description

direction defines a direction measure from the CLI. It has to specify a reference code, direction quantity values (see introduction for the action on a scalar quantity with either a vector or scalar value),

and optionally it can specify an offset, which in itself has to be a direction. Allowable reference codes are: J2000 JMEAN JTRUE APP B1950 BMEAN BTRUE GALACTIC HADEC AZEL SUPERGAL ECLIPTIC MECLIPTIC TECLIPTIC MERCURY VENUS MARS JUPITER SATURN URANUS NEPTUNE PLUTO MOON SUN COMET.
Note that additional ones may become available. Check in CASA with:

print "\t----\t direction Ex 1 \t----"  
print me.listcodes(me.direction())  
#{’normal’: [’J2000’, ’JMEAN’, ’JTRUE’, ’APP’, ’B1950’, ’BMEAN’,  
#’BTRUE’, ’GALACTIC’, ’HADEC’, ’AZEL’, ’AZELSW’, ’AZELNE’, ’AZELGEO’,  
#’AZELSWGEO’, ’AZELNEGEO’, ’JNAT’, ’ECLIPTIC’, ’MECLIPTIC’,  
#’TECLIPTIC’, ’SUPERGAL’, ’ITRF’, ’TOPO’, ’ICRS’], ’extra’: [’MERCURY’,  
#’VENUS’, ’MARS’, ’JUPITER’, ’SATURN’, ’URANUS’, ’NEPTUNE’, ’PLUTO’,  
#’SUN’, ’MOON’, ’COMET’]}

The direction quantity values should be longitude(angle) and latitude(angle) (none needed for planets: the frame epoch defines coordinates). See quantity for possible angle formats.

Arguments





Inputs

rf

reference code

allowed:

string

Default:

J2000

v0

longitude

allowed:

any

Default:

variant

v1

latitude

allowed:

any

Default:

variant

off

optional offset direction measure

allowed:

any

Default:

record

Returns
anyrecord

Example

print "\t----\t direction Ex 2 \t----"  
print me.direction(’j2000’,’30deg’,’40deg’)  
#{’m0’: {’value’: 0.52359877559829882, ’unit’: ’rad’},  
# ’m1’: {’value’: 0.69813170079773168, ’unit’: ’rad’},  
# ’refer’: ’J2000’,  
# ’type’: ’direction’}  
#  
print me.direction(’mars’)  
#{’m0’: {’value’: 0.0, ’unit’: ’rad’},  
# ’m1’: {’value’: 1.5707963267948966, ’unit’: ’rad’},  
# ’refer’: ’MARS’,  
# ’type’: ’direction’}

Please send any comments or questions about CASA or AIPS++ to aips2-requests@nrao.edu

Copyright © 2008 Associated Universities Inc., Washington, D.C.

This code is available under the terms of the GNU General Public Lincense


Home | Contact Us | Directories | Site Map | Help | Privacy Policy | Search

Updated daily during alpha development.