Teaching Numerical Gradients and Hessians (Scripts) Publisher's description
This submission is a set of m-files to demonstrate how to take a simple numerical derivative and Hessian of an arbitrary function
This submission is a set of m-files to demonstrate how to take a simple numerical derivative and Hessian of an arbitrary function. Each step in the code is documented. There is a test script included which computes the numerical Hessian of a test function and compares it to a symbolically-determined result (with a numerical point substituted into the symbolic Hessian). The gradient and Hessian functions support varying tolerance, and also counting the number of function evaluations in order to give a sense of just how expensive numerical derivatives can be.
The test script requires the Symbolic Math Toolbox.
System Requirements:MATLAB 7.11 (2010b)
Program Release Status: New Release
Program Install Support: Install and Uninstall