SciPy

scipy.optimize.rosen_der

scipy.optimize.rosen_der(x)[source]

The derivative (i.e. gradient) of the Rosenbrock function.

Parameters
xarray_like

1-D array of points at which the derivative is to be computed.

Returns
rosen_der(N,) ndarray

The gradient of the Rosenbrock function at x.

Examples

>>> from scipy.optimize import rosen_der
>>> X = 0.1 * np.arange(9)
>>> rosen_der(X)
array([ -2. ,  10.6,  15.6,  13.4,   6.4,  -3. , -12.4, -19.4,  62. ])

Previous topic

scipy.optimize.rosen

Next topic

scipy.optimize.rosen_hess