|
ADOL-C: Automatic Differentiation in C/C++ 2.7.3
|

Go to the source code of this file.
Functions | |
| int | sparse_jac (short tag, int m, int n, int repeat, const double *x, int *nnz, unsigned int **rind, unsigned int **cind, double **values, int *options) |
| Compute and recover a sparse Jacobian using ColPack. | |
| int | sparse_hess (short tag, int n, int repeat, const double *x, int *nnz, unsigned int **rind, unsigned int **cind, double **values, int *options) |
| Compute and recover a sparse Hessian using ColPack. | |
| int | jac_pat (short tag, int m, int n, const double *x, unsigned int **JP, int *options) |
| Compute a Jacobian sparsity pattern. | |
| int | hess_pat (short tag, int n, const double *x, unsigned int **HP, int *option) |
| Compute a scalar function's Hessian sparsity pattern. | |
| void | generate_seed_jac (int m, int n, unsigned int **JP, double ***S, int *p, int *options) |
| Generate a ColPack seed matrix for compressed Jacobian recovery. | |
| void | generate_seed_hess (int n, unsigned int **HP, double ***S, int *p, int *options) |
| Generate a ColPack seed matrix for compressed Hessian recovery. | |
| void generate_seed_hess | ( | int | n, |
| unsigned int ** | HP, | ||
| double *** | S, | ||
| int * | p, | ||
| int * | options | ||
| ) |
Generate a ColPack seed matrix for compressed Hessian recovery.
| n | Number of independent variables. | |
| HP | Hessian pattern: n rows, each with a count and column indices. | |
| [out] | S | Seed matrix with n rows and p columns. |
| [out] | p | Number of seed columns. |
| options | Two entries; entry 1 selects recovery: 0 indirect or 1 direct. |
delete[], then delete the row-pointer array with delete[]. | void generate_seed_jac | ( | int | m, |
| int | n, | ||
| unsigned int ** | JP, | ||
| double *** | S, | ||
| int * | p, | ||
| int * | options | ||
| ) |
Generate a ColPack seed matrix for compressed Jacobian recovery.
| m | Number of dependent variables. | |
| n | Number of independent variables. | |
| JP | Jacobian pattern: m rows, each with a count and column indices. | |
| [out] | S | Seed matrix: n x p for column compression or p x m for row compression. |
| [out] | p | Compressed dimension. |
| options | One entry selecting compression: 0 column or 1 row. |
delete[], then delete the row-pointer array with delete[]. | int hess_pat | ( | short | tag, |
| int | n, | ||
| const double * | x, | ||
| unsigned int ** | HP, | ||
| int * | option | ||
| ) |
Compute a scalar function's Hessian sparsity pattern.
| tag | Tape identifier. | |
| n | Number of independent variables (rows and columns). | |
| x | Evaluation point, with n entries; may be null in safe modes. | |
| [out] | HP | Array of n row pointers. Each allocated row starts with its nonzero count, followed by zero-based column indices. |
| option | One entry selecting control flow: 0 safe, 1 tight, 2 old safe, or 3 old tight. |
delete[] before reusing the pointer array; this call resets its entries. | int jac_pat | ( | short | tag, |
| int | m, | ||
| int | n, | ||
| const double * | x, | ||
| unsigned int ** | JP, | ||
| int * | options | ||
| ) |
Compute a Jacobian sparsity pattern.
| tag | Tape identifier. | |
| m | Number of dependent variables (rows). | |
| n | Number of independent variables (columns). | |
| x | Evaluation point, with n entries; may be null in safe mode. | |
| [out] | JP | Array of m row pointers. Each allocated row starts with its nonzero count, followed by zero-based column indices. |
| options | Three entries: method (0 index domains, 1 bit patterns), control flow (0 safe, 1 tight), and bit propagation (0 auto, 1 forward, 2 reverse). |
delete[] before reusing the pointer array; this call resets its entries. | int sparse_hess | ( | short | tag, |
| int | n, | ||
| int | repeat, | ||
| const double * | x, | ||
| int * | nnz, | ||
| unsigned int ** | rind, | ||
| unsigned int ** | cind, | ||
| double ** | values, | ||
| int * | options | ||
| ) |
Compute and recover a sparse Hessian using ColPack.
| tag | Tape identifier for a scalar function. | |
| n | Number of independent variables. | |
| repeat | Zero builds and caches the pattern and seed; nonzero reuses them. | |
| x | Evaluation point, with n entries. Required for numeric recovery. | |
| [in,out] | nnz | Nonzero count set on the first call; must match on reuse. |
| [in,out] | rind | Zero-based row indices. |
| [in,out] | cind | Zero-based column indices. |
| [in,out] | values | Nonzero values. |
| options | Two entries: control flow (0 safe, 1 tight, 2 old safe, 3 old tight) and recovery (0 indirect, 1 direct). |
*nnz to reuse them. Otherwise, the routine deletes any supplied buffers and uses ColPack's unmanaged recovery. Release returned buffers with delete[]. | int sparse_jac | ( | short | tag, |
| int | m, | ||
| int | n, | ||
| int | repeat, | ||
| const double * | x, | ||
| int * | nnz, | ||
| unsigned int ** | rind, | ||
| unsigned int ** | cind, | ||
| double ** | values, | ||
| int * | options | ||
| ) |
Compute and recover a sparse Jacobian using ColPack.
| tag | Tape identifier. | |
| m | Number of dependent variables (rows). | |
| n | Number of independent variables (columns). | |
| repeat | Zero builds and caches the pattern and seed; nonzero reuses them. | |
| x | Evaluation point, with n entries. Required for numeric recovery. | |
| [in,out] | nnz | Recovered nonzero count. On entry, the count of any supplied buffers; they are reused only if all three are non-null and the count matches. |
| [in,out] | rind | Zero-based row indices. |
| [in,out] | cind | Zero-based column indices. |
| [in,out] | values | Nonzero values. |
| options | Four entries: method (0 index domains, 1 bit patterns), control flow (0 safe, 1 tight), bit propagation (0 auto, 1 forward, 2 reverse), and compression (0 column, 1 row). |
nnz, rind, cind, values, and options are non-null. new[]. Release returned buffers with delete[].