CppAD: A C++ Algorithmic Differentiation Package 20110419
template<class Base >
template<class VectorSet >
VectorSet ADFun< Base >::RevSparseJac ( size_t  p,
const VectorSet &  s 
)

User API for Jacobian sparsity patterns using reverse mode.

The C++ source code corresponding to this operation is

	s = f.RevSparseJac(q, r)
Template Parameters:
Baseis the base type for this recording.
VectorSetis a simple vector with elements of type bool. or std::set<size_t>.
Parameters:
pis the number of rows in the matrix $ S $.
sis a sparsity pattern for the matrix $ S $.
Returns:
If VectorSet::value_type is bool, the return value r is a vector with size p*n where n is the number of independent variables corresponding to the operation sequence stored in f. If VectorSet::value_type is std::set<size_t>, the return value r is a vector of sets with size p and with all its elements between zero and n - 1. The value of r is the sparsity pattern for the matrix

\[ J(x) = S * F^{(1)} (x) \]

where $ F $ is the function corresponding to the operation sequence and x is any argument value.

Definition at line 431 of file rev_sparse_jac.hpp.