R bloggers

Numerical Differentiation with Finite Differences in R

FavoriteLoadingAdd to favorites

Numerical differentiation is a method of approximating the derivative of a function at particular value . Often, particularly in physics and engineering, a function may be too complicated to merit the work necessary to find the exact derivative, or the function itself is unknown, and all that is available are some points and the function evaluated at those points. Numerical differentiation, of which finite differences is just one approach, allows one to avoid these complications by approximating the derivative. The most straightforward and simple approximation of the first derivative is defined as: The approximation error of this equation can be found by performing a Taylor expansion of about , which gives: We then rearrange the expansion and substitute with the earlier approximation to arrive at an exact form of the approximation equation: Finite Differences Methods for Numerical Differentiation There…
Original Post: Numerical Differentiation with Finite Differences in R