
UnaryMathFunction |
ptolemy.actor.lib.UnaryMathFunction |
Produce an output token on each firing with a value that is
equal to the specified math function of the input.
The input and output types are DoubleToken. The functions
are a subset of those in the java.lang.Math class. They are:
- exp: The exponential function.
This is the default function for this actor
If the argument is NaN, then the result is NaN.
- log: The natural logarithm function.
If the argument is NaN, then the result is NaN.
- sign: If the argument is greater than 0, return 1.0, if
it is less than 0, return -1.0, otherwise return 0.0.
- square: The square function
If the argument is NaN, then the result is NaN.
- sqrt: The square root function.
If the argument is NaN, then the result is NaN.
Author(s): C. Fong, Steve Neuendorffer
Version:$Id: UnaryMathFunction.java,v 1.12 2006/02/07 00:47:52 cxh Exp $
Pt.Proposed Rating:Yellow (neuendor)
Pt.Accepted Rating:Red (neuendor)
function
The function to compute. This is a string-valued attribute
that defaults to "exp".