![]() |
Prev | Next |
z = pow(x, y)
pow
function may use
logarithms and exponentiation to compute derivatives.
This will not work if
x
is less than or equal zero.
If the value of
y
is an integer,
the pow_int
function is used to compute this value
using only multiplication (and division if
y
is negative).
(This will work even if
x
is less than or equal zero.)
x
has one of the following prototypes
const Base& x
const AD<Base>& x
const VecAD<Base>::reference& x
y
has one of the following prototypes
const Base& y
const AD<Base>& y
const VecAD<Base>::reference& y
x
and
y
are
Base
objects,
the result
z
is also a
Base
object.
Otherwise, it has prototype
AD<Base> z
Base
atomic operation
and hence is part of the current
AD of
Base
operation sequence
.