calculate_jacobian(sys) is the Jacobian of the right-hand side of a
compiled system with respect to its unknowns, calculate_tgrad(sys) the
partial derivative with respect to time, calculate_paramjac(sys) the
Jacobian with respect to the parameters, calculate_massmatrix(sys) the
mass matrix, and calculate_hessian(sys) the Hessians of the
(scalar) cost of an optimization system or of each equation of a
nonlinear system. The generate_* functions return R functions of
(u, p, t) (or (u, p) for time independent systems).
Usage
calculate_jacobian(sys, sparse = FALSE, simplify = FALSE, ...)
calculate_tgrad(sys, simplify = FALSE, ...)
calculate_paramjac(sys, simplify = FALSE, ...)
calculate_massmatrix(sys, ...)
calculate_hessian(sys, ...)
generate_rhs(sys, ...)
generate_jacobian(sys, sparse = FALSE, ...)
generate_tgrad(sys, ...)
generate_paramjac(sys, ...)
build_explicit_observed_function(sys, exprs, ...)
generate_custom_function(sys, expr, ...)Arguments
- sys
A complete
System.- sparse
For
generate_jacobian(), return a function that builds aMatrix::sparseMatrixof the structural nonzeros. Symbolic matrices are always stored dense, socalculate_jacobian()ignores it.- simplify
Simplify each entry.
- ...
Unused.
- exprs
Expressions of the system's variables.
- expr
An expression to compile.