Prev | Next |
f.rev_hes_sparsity(
select_range, transpose, internal_bool, pattern_out
)
f
.
Fix @(@
R \in \B{R}^{n \times \ell}
@)@, @(@
s \in \B{R}^m
@)@
and define the function
@[@
H(x) = ( s^\R{T} F )^{(2)} ( x ) R
@]@
Given a sparsity pattern
for @(@
R
@)@
and for the vector @(@
s
@)@,
rev_hes_sparsity
computes a sparsity pattern for @(@
H(x)
@)@.
f
and does not depend on
the argument
x
.
BoolVector
is a SimpleVector
class with
elements of type
bool
.
SizeVector
is a SimpleVector
class with
elements of type
size_t
.
f
has prototype
ADFun<Base> f
f.for_jac_sparsity(
pattern_in, transpose, dependency, internal_bool, pattern_out
)
select_range
has prototype
const BoolVector& select_range
It has size @(@
m
@)@ and specifies which components of the vector
@(@
s
@)@ are non-zero; i.e.,
select_range[i]
is true
if and only if @(@
s_i
@)@ is possibly non-zero.
bool transpose
See pattern_out
below.
f.for_jac_sparsity
.
sparse_rc<SizeVector>& pattern_out
This input value of
pattern_out
does not matter.
If
transpose
it is false (true),
upon return
pattern_out
is a sparsity pattern for
@(@
H(x)
@)@ (@(@
H(x)^\R{T}
@)@).
pattern_out
is a sparsity pattern for
@(@
(s^\R{T} F) F^{(2)} ( x )
@)@.