Prev | Next |
CPPAD_BOOL_UNARY(Base, unary_name)
b = unary_name(u)
b = unary_name(x)
CPPAD_BOOL_BINARY(Base, binary_name)
b = binary_name(u, v)
b = binary_name(x, y)
bool
valued function that has
AD<Base>
arguments.
bool
valued function with one argument
(as it is used in the source code).
The user must provide a version of
unary_name
where
the argument has type
Base
.
CppAD uses this to create a version of
unary_name
where the
argument has type
AD<Base>
.
u
has prototype
const Base &u
It is the value at which the user provided version of
unary_name
is to be evaluated.
It is also used for the first argument to the
user provided version of
binary_name
.
x
has prototype
const AD<Base> &x
It is the value at which the CppAD provided version of
unary_name
is to be evaluated.
It is also used for the first argument to the
CppAD provided version of
binary_name
.
b
has prototype
bool b
CPPAD_BOOL_UNARY(Base, unary_name)
defines the version of
unary_name
with a
AD<Base>
argument.
This can with in a namespace
(not the CppAD
namespace)
but must be outside of any routine.
bool
valued function with two arguments
(as it is used in the source code).
The user must provide a version of
binary_name
where
the arguments have type
Base
.
CppAD uses this to create a version of
binary_name
where the
arguments have type
AD<Base>
.
v
has prototype
const Base &v
It is the second argument to
the user provided version of
binary_name
.
x
has prototype
const AD<Base> &y
It is the second argument to
the CppAD provided version of
binary_name
.
CPPAD_BOOL_BINARY(Base, binary_name)
defines the version of
binary_name
with
AD<Base>
arguments.
This can with in a namespace
(not the CppAD
namespace)
but must be outside of any routine.
Base
operation sequence
.
CppADCreateUnaryBool
and CppADCreateBinaryBool
are defined to be the same as
CPPAD_BOOL_UNARY
and CPPAD_BOOL_BINARY
respectively
(but their use is deprecated).