a_double_unary_fun#

View page source

Unary Functions with AD Result#

Syntax#

C++#

ay = ax . fun ()

Python#

ay = ax . fun ()
ay = numpy.fun ( ax )

ax#

This object has prototype

      const a_double& ax

This is the argument for the function evaluation.

fun#

This specifies which function is being evaluated and is one of following value: abs , acos , asin , atan , cos , cosh , erf , exp , fabs , log , sin , sinh , sqrt , tan , tanh . The numpy version of the python syntax does not work with the abs function. 2DO: Add the C++11 functions asinh, acosh, atanh, expm1, and log1p to this list.

ay#

The result object has c++ prototype

      a_double ay

and is the value of the function fun evaluated at the argument ax; i.e.,

      ay = fun ( ax )

Example#

c++, python.