Minimize a function using the Newton-CG method.
Parameters : | f : callable f(x,*args)
x0 : ndarray
fprime : callable f’(x,*args)
fhess_p : callable fhess_p(x,p,*args)
fhess : callable fhess(x,*args)
args : tuple
epsilon : float or ndarray
callback : callable
|
---|---|
Returns : | xopt : ndarray
fopt : float
fcalls : int
gcalls : int
hcalls : int
warnflag : int
allvecs : list
|
Other Parameters: | |
avextol : float
maxiter : int
full_output : bool
disp : bool
retall : bool
|
Notes
Only one of fhess_p or fhess need to be given. If fhess is provided, then fhess_p will be ignored. If neither fhess nor fhess_p is provided, then the hessian product will be approximated using finite differences on fprime. fhess_p must compute the hessian times an arbitrary vector. If it is not given, finite-differences on fprime are used to compute it. See Wright & Nocedal, ‘Numerical Optimization’, 1999, pg. 140.