<< newton_XY16 Optimisation numz0 >>

grocer >> Optimisation > newton_XY16_sp

newton_XY16_sp

find the 0 of a function by Xiao and Yin (2016) method

CALLING SEQUENCE

[xs,fs,maxfs]=newton_XY16_sp(x0,func,Jac,indJac,ftol,itermax,alphamin)

PARAMETERS

Input

* x0 = a (n x 1) vector of starting values

* func = a function, whose 0 is searched

* Jac = a function, performing the non zero values of the Jacobian of this function (with the rhs as an output)

* indJac = a (K x 2) matrix, collecting the non zero indexes of the Jacobian

* ftol = the convergence criterion for the function value

* itermax = the maxmimum number for the function calls

* alphamin = the minimum value used to dampen the step when convergence is not acheived

Output

* xs = the value of the parameter at solution

* fs = the value of the function at solution

* maxfs = the maximum value of the absolute function at solution

DESCRIPTION

Finds the 0 of an equation using the variant of the Newton method provided by X. Y. Xiao and H. W. Yin, “Increasing the order of convergence for iterative methods to solve nonlinear systems,” Calcolo. A, Quarterly on Numerical Analysis and Theory of Computation, vol. 53, no. 3, pp. 285–300, 2016. Adpated to a problem when the Jacobian is sparse.

EXAMPLE

// Search the zero of function test_func in the optsci folder. The function codes the problem 7 provided by
// Sharma, Sharma and Bahl (2016), An improved Newton–Traub composition for solving systems of nonlinear equations,
// Applied Mathematics and Computation, N. 290, p. 98-110.
// The function to minimize is:
// x(i)x(i+1)=1 for i=1:98
// x(99)x(1)=1
// The corresponding Jacobian function is coded in function test_Jac_sp
// Starting values are the ones provided in the paper: -4*ones(99,1)
// Convergence criterion is set to 1e-10, maximum # of iterations is set to 1000, minimum value used to dampen the step is set to
 
 
ind_sp=[[1:99 1:99]' , [1:99 2:99 1]']; 
[x0,f0,maxf0]=newton_XY16_sp(-4*ones(99,1),newton_testfunc_sp,newton_testJac_sp,ind_sp,1e-8,100,0.05)
 
 
// Provides the expected result x0 =-1*ones(99,1) and f0=0

AUTHOR

Éric Dubois 2019

Report an issue
<< newton_XY16 Optimisation numz0 >>