NRAO Home > CASA > CASA Toolkit Reference Manual
measures.expand - Function

1.4.1 expand n positions to n*(n-1)/2 baselines


Description

expand calculates the differences between a series of given measure values: it calculates baseline values from position values. The returned value is a measure, but the value of the optional output variable xyz will be set to an array of values.

Arguments





Outputs

xyz

uvw (quantity array)

allowed:

record

Default:

Inputs

v

measure (baseline, position or uvw measure)

allowed:

record

Default:

Returns
record

Example

 
 
print "\t----\t expand Ex 1 \t----"  
b=me.baseline(’itrf’, qa.quantity([10, 20, 30], ’m’), qa.quantity([10, 20, 30], ’m’), qa.quantity([0, 0, 0], ’m’))  
print me.expand(b)  
me.expand(b)  
 
#{’return’: {’m0’: {’unit’: ’rad’,  
#                   ’value’: array([ 0.78539816,  0.78539816,  0.78539816])},  
#            ’m1’: {’unit’: ’rad’, ’value’: array([ 0.,  0.,  0.])},  
#            ’m2’: {’unit’: ’m’,  
#                   ’value’: array([ 14.14213562,  28.28427125,  14.14213562])},  
#            ’refer’: ’ITRF’,  
#            ’type’: ’baseline’},  
# ’xyz’: {’unit’: ’m’,  
#         ’value’: array([ 10.,  10.,   0.,  20.,  20.,   0.,  10.,  10.,   0.])}}  
 
print me.expand(b)[’xyz’][’value’]  
 
#[ 10.  10.   0.  20.  20.   0.  10.  10.   0.]  
 
 

__________________________________________________________________


More information about CASA may be found at the CASA web page

Copyright © 2016 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