1#ifndef CPPAD_CG_GENERIC_MODEL_EXTERNAL_FUNCTION_WRAPPER_INCLUDED
2#define CPPAD_CG_GENERIC_MODEL_EXTERNAL_FUNCTION_WRAPPER_INCLUDED
39 CPPADCG_ASSERT_KNOWN(!
tx[0].sparse,
"independent array must be dense");
42 CPPADCG_ASSERT_KNOWN(!
ty.sparse,
"dependent array must be dense");
51 CPPADCG_ASSERT_KNOWN(
tx[1].sparse,
"independent Taylor array must be sparse");
52 Base*
tx1 =
static_cast<Base*
> (
tx[1].data);
68 CPPADCG_ASSERT_KNOWN(!
tx[0].sparse,
"independent array must be dense");
71 CPPADCG_ASSERT_KNOWN(!
px.sparse,
"independent partials array must be dense");
75 CPPADCG_ASSERT_KNOWN(
py[0].sparse,
"dependent partials array must be sparse");
76 Base*
pyb =
static_cast<Base*
> (
py[0].data);
84 CPPADCG_ASSERT_KNOWN(
tx[1].sparse,
"independent array must be sparse");
85 const Base*
tx1 =
static_cast<const Base*
> (
tx[1].data);
86 CPPADCG_ASSERT_KNOWN(
py[0].sparse,
"dependent partials array must be sparse");
87 CPPADCG_ASSERT_KNOWN(
py[0].nnz == 0,
"first order dependent partials must be zero");
88 CPPADCG_ASSERT_KNOWN(!
py[1].sparse,
"independent partials array must be dense");
virtual bool reverse(FunctorGenericModel< Base > &libModel, int p, const Array tx[], Array &px, const Array py[])
virtual bool forward(FunctorGenericModel< Base > &libModel, int q, int p, const Array tx[], Array &ty)
VectorBase ForwardZero(const VectorBase &x)
VectorBase ReverseTwo(const VectorBase &tx, const VectorBase &ty, const VectorBase &py)
VectorBase ReverseOne(const VectorBase &tx, const VectorBase &ty, const VectorBase &py)
VectorBase ForwardOne(const VectorBase &tx)
bool GreaterThanZero(const cg::CG< Base > &x)