Prev | Next |
f.Forward(0, x)
f.Forward(0, x, s)
PrintFor(before, value)
PrintFor(notpos, before, value, after)
f.Forward(0, x)
sets the
independent variable
vector
equal to
x
.
It then computes a value for all of the dependent variables in the
operation sequence
corresponding
to
f
.
Putting a PrintFor
in the operation sequence,
prints
value
, corresponding to
x
,
to be printed during zero order forward operations.
f
,
x
, and the purpose
for this operation, are documented in Forward
.
notpos
has one of the following prototypes
const AD<Base>& notpos
const VecAD<Base>::reference& notpos
In this case
the text and
value
will be printed if and only if
notpos
is not positive (greater than zero) and a finite number.
before
has prototype
const char* before
This text is written to std::cout
before
value
.
value
has one of the following prototypes
const AD<Base>& value
const VecAD<Base>::reference& value
The
value
, that corresponds to
x
,
is written to std::cout
during the execution of
f.Forward(0, x)
Note that
value
may be a
variable
or
parameter
.
If a parameter is
dynamic
its value
will depend on the previous call to new_dynamic
.
after
has prototype
const char* after
This text is written to std::cout
after
value
.
f.Forward(0, x, s)
see s
in the zero order forward mode documentation.
f
is
log(value)
and
value < 0
,
the corresponding result will nan
.