Speed Testing Gradient of Determinant by Minor Expansion
Keywords: speed testing gradient determinant minor expansion link_det_minor test prototype purpose method return value size repeat matrix double

| Prev | Next |  |  |  |  |  | link_det_minor |

Speed Testing Gradient of Determinant by Minor Expansion
Prototype
`extern bool link_det_minor(
size_t size ,
size_t repeat ,
CppAD::vector<double> &matrix ,
CppAD::vector<double> &gradient
);
`
Purpose
Each package must define a version of this routine as specified below. This is used by the speed_main program to run the corresponding speed and correctness tests.
Method
The same template class det_by_minor is used by the different AD packages.
Return Value
If this speed test is not yet supported by a particular `package` , the corresponding return value for `link_det_minor` should be `false`.
size
The argument `size` is the number of rows and columns in the matrix.
repeat
The argument `repeat` is the number of different matrices that the gradient (or determinant) is computed for.
matrix
The argument `matrix` is a vector with `size*size` elements. The input value of its elements does not matter. The output value of its elements is the last matrix that the gradient (or determinant) is computed for.
gradient
The argument `gradient` is a vector with `size*size` elements. The input value of its elements does not matter. The output value of its elements is the gradient of the determinant of `matrix` with respect to its elements.
double
In the case where `package` is `double`, only the first element of `gradient` is used and it is actually the determinant value (the gradient value is not computed).

Input File: speed/src/link_det_minor.cpp