casa  $Rev:20696$
 All Classes Namespaces Files Functions Variables
Public Member Functions | Public Attributes | Static Private Attributes
__casac__.quanta.quanta Class Reference
Inheritance diagram for __casac__.quanta.quanta:
__casac__.quanta._object

List of all members.

Public Member Functions

def __init__
def convertfreq
def convertdop
def quantity
def getvalue
def getunit
def canonical
def canon
def convert
def define
def map
def maprec
def fits
def angle
def time
def add
def sub
def mul
def div
def neg
def norm
def le
def lt
def eq
def ne
def gt
def ge
def sin
def cos
def tan
def asin
def acos
def atan
def atan2
def abs
def ceil
def floor
def log
def log10
def exp
def sqrt
def compare
def check
def checkfreq
def pow
def constants
def isangle
def totime
def toangle
def splitdate
def tos
def type
def done
def unit
def isquantity
def setformat
def getformat
def formxxx

Public Attributes

 this

Static Private Attributes

dictionary __swig_setmethods__
tuple __setattr__
dictionary __swig_getmethods__
tuple __getattr__
 __repr__
 __swig_destroy__
 __del__

Detailed Description

Proxy of C++ casac::quanta class

Definition at line 70 of file quanta.py.


Constructor & Destructor Documentation

__init__(self) -> quanta

Definition at line 77 of file quanta.py.


Member Function Documentation

def __casac__.quanta.quanta.abs (   self,
  args,
  kwargs 
)
abs(self, v) -> record *

Summary
absolute value of quantity

Input Parameters:
v                value 

--------------------------------------------------------------------------------

Definition at line 600 of file quanta.py.

def __casac__.quanta.quanta.acos (   self,
  args,
  kwargs 
)
acos(self, v) -> record *

Summary
arccosine of quantity

Input Parameters:
v                non-dimensioned quantity 

--------------------------------------------------------------------------------

Definition at line 554 of file quanta.py.

def __casac__.quanta.quanta.add (   self,
  args,
  kwargs 
)
add(self, v, a=initialize_variant("0")) -> record *

Summary
add quantities

Input Parameters:
v                value 
a                value 0 

--------------------------------------------------------------------------------

Definition at line 303 of file quanta.py.

def __casac__.quanta.quanta.angle (   self,
  args,
  kwargs 
)
angle(self, v, prec=0, form=std::vector< string >(1, ""), showform=False) -> std::vector< std::string >

Summary
show an angle as a formatted string

Input Parameters:
v                angle quantity value to output 
prec             number of digits shown 0 
form             formatting information in coded string array 
showform         show square brackets and separating , false 

--------------------------------------------------------------------------------

Definition at line 267 of file quanta.py.

def __casac__.quanta.quanta.asin (   self,
  args,
  kwargs 
)
asin(self, v) -> record *

Summary
arcsine of quantity

Input Parameters:
v                non-dimensioned quantity 

--------------------------------------------------------------------------------

Definition at line 539 of file quanta.py.

def __casac__.quanta.quanta.atan (   self,
  args,
  kwargs 
)
atan(self, v) -> record *

Summary
arctangent of quantity

Input Parameters:
v                non-dimensioned quantity 

--------------------------------------------------------------------------------

Definition at line 569 of file quanta.py.

def __casac__.quanta.quanta.atan2 (   self,
  args,
  kwargs 
)
atan2(self, v, a) -> record *

Summary
arctangent of two quantity

Input Parameters:
v                non-dimensioned quantity 
a                non-dimensioned quantity 

--------------------------------------------------------------------------------

Definition at line 584 of file quanta.py.

def __casac__.quanta.quanta.canon (   self,
  args,
  kwargs 
)
canon(self, v) -> record *

Summary
get canonical value of quantity

Input Parameters:
v                value to convert 

--------------------------------------------------------------------------------

Definition at line 178 of file quanta.py.

def __casac__.quanta.quanta.canonical (   self,
  args,
  kwargs 
)
canonical(self, v=initialize_variant("1.0")) -> record *

Summary
get canonical value of quantity

Input Parameters:
v                value to convert 1.0 

--------------------------------------------------------------------------------

Definition at line 163 of file quanta.py.

def __casac__.quanta.quanta.ceil (   self,
  args,
  kwargs 
)
ceil(self, v) -> record *

Summary
ceil value of quantity

Input Parameters:
v                value 

--------------------------------------------------------------------------------

Definition at line 615 of file quanta.py.

def __casac__.quanta.quanta.check (   self,
  args,
  kwargs 
)
def __casac__.quanta.quanta.checkfreq (   self,
  args,
  kwargs 
)
checkfreq(self, cm) -> bool

Summary
check for proper frequency unit

Input Parameters:
cm               value 

--------------------------------------------------------------------------------

Definition at line 736 of file quanta.py.

def __casac__.quanta.quanta.compare (   self,
  args,
  kwargs 
)
compare(self, v, a) -> bool

Summary
compare dimensionality of units

Input Parameters:
v                value 
a                value 

--------------------------------------------------------------------------------

Definition at line 705 of file quanta.py.

def __casac__.quanta.quanta.constants (   self,
  args,
  kwargs 
)
constants(self, v=string("pi")) -> record *

Summary
get a constant

Input Parameters:
v                name pi 

--------------------------------------------------------------------------------

Definition at line 767 of file quanta.py.

def __casac__.quanta.quanta.convert (   self,
  args,
  kwargs 
)
convert(self, v, outunit) -> record *

Summary
convert a quantity to another unit

Input Parameters:
v                quantity to convert 
outunit          unit to convert to 

--------------------------------------------------------------------------------

Definition at line 193 of file quanta.py.

def __casac__.quanta.quanta.convertdop (   self,
  args,
  kwargs 
)
convertdop(self, v=initialize_variant("0.0"), outunit=string("km/s")) -> record *

Summary
convert a doppler velocity quantity to another unit

Input Parameters:
v                quantity to convert 0.0 
outunit          unit to convert to km/s 

--------------------------------------------------------------------------------

Definition at line 100 of file quanta.py.

def __casac__.quanta.quanta.convertfreq (   self,
  args,
  kwargs 
)
convertfreq(self, v=initialize_variant("1.0"), outunit=string("Hz")) -> record *

Summary
convert a frequency quantity to another unit

Input Parameters:
v                quantity to convert 1.0 
outunit          unit to convert to Hz 

--------------------------------------------------------------------------------

Definition at line 84 of file quanta.py.

def __casac__.quanta.quanta.cos (   self,
  args,
  kwargs 
)
cos(self, v) -> record *

Summary
cosine of quantity

Input Parameters:
v                angle quantity 

--------------------------------------------------------------------------------

Definition at line 509 of file quanta.py.

def __casac__.quanta.quanta.define (   self,
  args,
  kwargs 
)
define(self, name, v=initialize_variant("1")) -> bool

Summary
define a new unit name

Input Parameters:
name             name of unit to define 
v                quantity value of new unit 1 

--------------------------------------------------------------------------------

Definition at line 209 of file quanta.py.

def __casac__.quanta.quanta.div (   self,
  args,
  kwargs 
)
div(self, v, a=initialize_variant("1")) -> record *

Summary
divides quantities

Input Parameters:
v                value 
a                value 1 

--------------------------------------------------------------------------------

Definition at line 351 of file quanta.py.

def __casac__.quanta.quanta.done (   self,
  kill = False 
)
done(self, kill=False) -> bool

Summary
Free resources used by tool.  Current implementation
    ignores input parameter, does nothing and returns true

Input Parameters:
kill             force kill of the default tool (ignored) false 

--------------------------------------------------------------------------------

Definition at line 869 of file quanta.py.

def __casac__.quanta.quanta.eq (   self,
  args,
  kwargs 
)
eq(self, v, a=initialize_variant("0")) -> bool

Summary
compare quantities

Input Parameters:
v                value 
a                value 0 

--------------------------------------------------------------------------------

Definition at line 430 of file quanta.py.

def __casac__.quanta.quanta.exp (   self,
  args,
  kwargs 
)
exp(self, v) -> record *

Summary
exponential of quantity

Input Parameters:
v                dimensionless quantity 

--------------------------------------------------------------------------------

Definition at line 675 of file quanta.py.

fits(self) -> bool

Summary
define some FITS units
--------------------------------------------------------------------------------

Definition at line 256 of file quanta.py.

def __casac__.quanta.quanta.floor (   self,
  args,
  kwargs 
)
floor(self, v) -> record *

Summary
floor value of quantity

Input Parameters:
v                value 

--------------------------------------------------------------------------------

Definition at line 630 of file quanta.py.

def __casac__.quanta.quanta.formxxx (   self,
  args,
  kwargs 
)
formxxx(self, v, format=string("dms"), prec=2) -> string

Summary
Format a quantity using given format, allowed are hms, dms, deg, rad, +deg.
   

Input Parameters:
v                value to be converted 
format           xxx can be hms, dms, deg, rad or +deg dms 
prec             # digits in fractional part of output string for dms,hms 2 

--------------------------------------------------------------------------------

Definition at line 949 of file quanta.py.

def __casac__.quanta.quanta.ge (   self,
  args,
  kwargs 
)
ge(self, v, a=initialize_variant("0")) -> bool

Summary
compare quantities

Input Parameters:
v                value 
a                value 0 

--------------------------------------------------------------------------------

Definition at line 478 of file quanta.py.

def __casac__.quanta.quanta.getformat (   self,
  args,
  kwargs 
)
getformat(self, t=string("")) -> string

Summary
get current output format
   (NOT IMPLEMENTED YET!)

Input Parameters:
t                type - coded string 

--------------------------------------------------------------------------------

Definition at line 933 of file quanta.py.

def __casac__.quanta.quanta.getunit (   self,
  args,
  kwargs 
)
getunit(self, v) -> string

Summary
get the internal unit of a quantity

Input Parameters:
v                quantity 

--------------------------------------------------------------------------------

Definition at line 148 of file quanta.py.

def __casac__.quanta.quanta.getvalue (   self,
  args,
  kwargs 
)
getvalue(self, v) -> std::vector< double >

Summary
get the internal value of a quantity

Input Parameters:
v                quantity 

--------------------------------------------------------------------------------

Definition at line 133 of file quanta.py.

def __casac__.quanta.quanta.gt (   self,
  args,
  kwargs 
)
gt(self, v, a=initialize_variant("0")) -> bool

Summary
compare quantities

Input Parameters:
v                value 
a                value 0 

--------------------------------------------------------------------------------

Definition at line 462 of file quanta.py.

def __casac__.quanta.quanta.isangle (   self,
  args,
  kwargs 
)
isangle(self, v) -> bool

Summary
check if valid angle or time quantity

Input Parameters:
v                angle/time quantity 

--------------------------------------------------------------------------------

Definition at line 782 of file quanta.py.

def __casac__.quanta.quanta.isquantity (   self,
  args,
  kwargs 
)
isquantity(self, v) -> bool

Summary
Check if quantity

Input Parameters:
v                value to be tested 

--------------------------------------------------------------------------------

Definition at line 901 of file quanta.py.

Referenced by simutil.simutil.calc_pointings2(), simutil.simutil.modifymodel(), and simutil.simutil.sensitivity().

def __casac__.quanta.quanta.le (   self,
  args,
  kwargs 
)
le(self, v, a=initialize_variant("0")) -> bool

Summary
compare quantities

Input Parameters:
v                value 
a                value 0 

--------------------------------------------------------------------------------

Definition at line 398 of file quanta.py.

def __casac__.quanta.quanta.log (   self,
  args,
  kwargs 
)
log(self, v) -> record *

Summary
logarithm of quantity

Input Parameters:
v                dimensionless quantity 

--------------------------------------------------------------------------------

Definition at line 645 of file quanta.py.

def __casac__.quanta.quanta.log10 (   self,
  args,
  kwargs 
)
log10(self, v) -> record *

Summary
logarithm of quantity

Input Parameters:
v                dimensionless quantity 

--------------------------------------------------------------------------------

Definition at line 660 of file quanta.py.

def __casac__.quanta.quanta.lt (   self,
  args,
  kwargs 
)
lt(self, v, a=initialize_variant("0")) -> bool

Summary
compare quantities

Input Parameters:
v                value 
a                value 0 

--------------------------------------------------------------------------------

Definition at line 414 of file quanta.py.

def __casac__.quanta.quanta.map (   self,
  args,
  kwargs 
)
map(self, v=string("all")) -> string

Summary
list known unit names and constants

Input Parameters:
v                type of information to list - coded string all 

--------------------------------------------------------------------------------

Definition at line 225 of file quanta.py.

def __casac__.quanta.quanta.maprec (   self,
  args,
  kwargs 
)
maprec(self, v=string("all")) -> record *

Summary
create record containing list of known unit names and
   constants

Input Parameters:
v                type of information to list - coded string all 

--------------------------------------------------------------------------------

Definition at line 240 of file quanta.py.

def __casac__.quanta.quanta.mul (   self,
  args,
  kwargs 
)
mul(self, v, a=initialize_variant("1")) -> record *

Summary
multiply quantities

Input Parameters:
v                value 
a                value 1 

--------------------------------------------------------------------------------

Definition at line 335 of file quanta.py.

def __casac__.quanta.quanta.ne (   self,
  args,
  kwargs 
)
ne(self, v, a=initialize_variant("0")) -> bool

Summary
compare quantities

Input Parameters:
v                value 
a                value 0 

--------------------------------------------------------------------------------

Definition at line 446 of file quanta.py.

def __casac__.quanta.quanta.neg (   self,
  args,
  kwargs 
)
neg(self, v=initialize_variant("1")) -> record *

Summary
negate quantities

Input Parameters:
v                value 1 

--------------------------------------------------------------------------------

Definition at line 367 of file quanta.py.

def __casac__.quanta.quanta.norm (   self,
  args,
  kwargs 
)
norm(self, v, a=-0.5) -> record *

Summary
normalise angle

Input Parameters:
v                angle quantity 
a                lower interval boundary -0.5 

--------------------------------------------------------------------------------

Definition at line 382 of file quanta.py.

def __casac__.quanta.quanta.pow (   self,
  args,
  kwargs 
)
pow(self, v, a=1) -> record *

Summary
raise quantity to power

Input Parameters:
v                value 
a                power 1 

--------------------------------------------------------------------------------

Definition at line 751 of file quanta.py.

def __casac__.quanta.quanta.quantity (   self,
  args,
  kwargs 
)
quantity(self, v, unitname=string("")) -> record *

Summary
make a quantity from a string or from a numeric value
    and a unit string

Input Parameters:
v                quantity or numeric or string to convert to quantity 
unitname         unit string if v numeric 

--------------------------------------------------------------------------------

Definition at line 116 of file quanta.py.

def __casac__.quanta.quanta.setformat (   self,
  args,
  kwargs 
)
setformat(self, t=string(""), v=string("F")) -> bool

Summary
set format for output of numbers. 
   (NOT IMPLEMENTED YET!)

Input Parameters:
t                type -coded string indicating which format parameter to set 
v                format parameter value - numeric or coded string, depending on format type to be set F 

--------------------------------------------------------------------------------

Definition at line 916 of file quanta.py.

def __casac__.quanta.quanta.sin (   self,
  args,
  kwargs 
)
sin(self, v) -> record *

Summary
sine of quantity

Input Parameters:
v                angle quantity 

--------------------------------------------------------------------------------

Definition at line 494 of file quanta.py.

def __casac__.quanta.quanta.splitdate (   self,
  args,
  kwargs 
)
splitdate(self, v) -> record *

Summary
split a date/time into a record

Input Parameters:
v                angle/time quantity 

--------------------------------------------------------------------------------

Definition at line 827 of file quanta.py.

def __casac__.quanta.quanta.sqrt (   self,
  args,
  kwargs 
)
sqrt(self, v) -> record *

Summary
square root of quantity

Input Parameters:
v                dimensionless quantity 

--------------------------------------------------------------------------------

Definition at line 690 of file quanta.py.

def __casac__.quanta.quanta.sub (   self,
  args,
  kwargs 
)
sub(self, v, a=initialize_variant("0")) -> record *

Summary
subtract quantities

Input Parameters:
v                value 
a                value 0 

--------------------------------------------------------------------------------

Definition at line 319 of file quanta.py.

def __casac__.quanta.quanta.tan (   self,
  args,
  kwargs 
)
tan(self, v) -> record *

Summary
tangent of quantity

Input Parameters:
v                angle quantity 

--------------------------------------------------------------------------------

Definition at line 524 of file quanta.py.

def __casac__.quanta.quanta.time (   self,
  args,
  kwargs 
)
time(self, v, prec=0, form=std::vector< string >(1, ""), showform=False) -> std::vector< std::string >

Summary
show a time (or date) as a formatted string

Input Parameters:
v                time quantity value to output 
prec             number of digits shown 0 
form             formatting information in coded string array 
showform         show square brackets and separating , false 

--------------------------------------------------------------------------------

Definition at line 285 of file quanta.py.

def __casac__.quanta.quanta.toangle (   self,
  args,
  kwargs 
)
toangle(self, v) -> record *

Summary
convert a time (or an angle) to an angle

Input Parameters:
v                angle/time quantity 

--------------------------------------------------------------------------------

Definition at line 812 of file quanta.py.

def __casac__.quanta.quanta.tos (   self,
  args,
  kwargs 
)
tos(self, v, prec=9) -> string

Summary
convert quantity to string

Input Parameters:
v                value 
prec             convert precision of value 9 

--------------------------------------------------------------------------------

Definition at line 842 of file quanta.py.

def __casac__.quanta.quanta.totime (   self,
  args,
  kwargs 
)
totime(self, v) -> record *

Summary
convert an angle (or a time) to a time

Input Parameters:
v                angle/time quantity 

--------------------------------------------------------------------------------

Definition at line 797 of file quanta.py.

type(self) -> string

Summary
type of tool
--------------------------------------------------------------------------------

Definition at line 858 of file quanta.py.

def __casac__.quanta.quanta.unit (   self,
  args,
  kwargs 
)
unit(self, v, unitname=string("")) -> record *

Summary
quantity from value v and unit string

Input Parameters:
v                
unitname         

--------------------------------------------------------------------------------

Definition at line 885 of file quanta.py.


Member Data Documentation

Definition at line 83 of file quanta.py.

tuple __casac__.quanta.quanta.__getattr__ [static, private]

Definition at line 75 of file quanta.py.

Definition at line 76 of file quanta.py.

tuple __casac__.quanta.quanta.__setattr__ [static, private]

Definition at line 73 of file quanta.py.

Definition at line 82 of file quanta.py.

dictionary __casac__.quanta.quanta.__swig_getmethods__ [static, private]

Definition at line 74 of file quanta.py.

dictionary __casac__.quanta.quanta.__swig_setmethods__ [static, private]

Definition at line 72 of file quanta.py.

Definition at line 81 of file quanta.py.


The documentation for this class was generated from the following file: