In file Math.hh:

class Math

Event columns can be used in math expression which can be used everywhere an event function is needed.

Inheritance:


Public Methods

[more] Math (const Function& f, operation op)
Constructor
[more] Math (const Function& f1, const Function& f2, operation op)
Constructor
[more]virtual Math* Copy () const
Copy the event column
[more]virtual bool Evaluate (const Argument& arg, Value& val) const
Math expression value

Public Members

[more]enum operation
Math operations.

Protected Methods

[more] Math ()
Default constructor


Inherited from Function:

Public Methods

obool operator() (const Argument& arg, Value& val) const
obool operator() (const Event& event, Value& val) const

Protected Methods

oFunction& operator= (const Function&)


Documentation

Event columns can be used in math expression which can be used everywhere an event function is needed. For example one can write
    5 < sqrt (pwr (Column ("Amplitude(0)"), 2) +
              pwr (Column ("Amplitude(1)"), 2) )
    \begin{verbatim}
    to define an event condition which checks whether the vector 
    sum of the amplitudes of two events is larger than 5.
   
    @memo Defines the event math routines
    @author Written June 2001 by Masahiro Ito and Daniel Sigg
    @version 1.0
oenum operation
Math operations supported by the function.

o opPos
Positive value

o opNeg
Negative value

o opInc
Increment (prefix)

o opDec
Decrement (prefix)

o opAdd
Addition

o opSub
Subtraction

o opMul
Multiplication

o opDiv
Division

o opMod
Modulus

o opAbs
Absolute value

o opSqrt
Square root

o opPow
Power

o opExp
Exponential

o opLog
Natural logarithm

o opLog10
Logarithm base 10

o opSin
Sine

o opCos
Cosine

o opTan
Tangent

o opAsin
Arc sine

o opAcos
Arc cosine

o opAtan
Arc tangent

o opAtan2
Arc tangent (2 arguments)

o opSinh
Sine hyp

o opCosh
Cosine hyp

o opTanh
Tangent hyp

o opCeil
Ceiling

o opFloor
Floor

o opNot
Negate ~

o opAnd
And &

o opOr
Or |

o opXor
Xor ^

o opLeft
Left shift <<

o opRight
Right shift >>

o opConj
Complex conjugate

o opPolar
Complex number in polar notation

o opReal
Real part

o opImag
Imaginary part

o opArg
Argument

o opNorm
Norm

o Math(const Function& f, operation op)
Creates an math expression of a single value (unary operator).

o Math(const Function& f1, const Function& f2, operation op)
Creates an math expression of two values (binary operator).

ovirtual Math* Copy() const
Returns a copy of the event column math object. This method must be overriden by all descendents.
Returns:
event copy

ovirtual bool Evaluate(const Argument& arg, Value& val) const
Returns the evaluated math expression.
Parameters:
- arg Event argument list
val - Fucntion value (return)
Returns:
true if successful

o Math()
Default constructor.


This class has no child classes.

Alphabetic index HTML hierarchy of classes or Java


Please send questions and comments to zweizig_j@ligo-wa.caltech.edu