“ANÁLISIS DE SISTEMAS DE DISTRIBUCIÓN DE GAS POR ... - inicio

“ANÁLISIS DE SISTEMAS DE DISTRIBUCIÓN DE GAS POR ... - inicio “ANÁLISIS DE SISTEMAS DE DISTRIBUCIÓN DE GAS POR ... - inicio

tesis.luz.edu.ve
from tesis.luz.edu.ve More from this publisher
20.08.2015 Views

ANEXO 4MATLAB. FUNCIONES AVANZADAS DE SISTEMAS NO LINEALES.LSQNONLINsolves non-linear least squares problems.LSQNONLIN attempts to solve problems of the form:min sum {FUN(X).^2} where X and the values returned by FUN can be xvectors or matrices.X=LSQNONLIN(FUN,X0) starts at the matrix X0 and finds a minimum X to the sumof squares of the functions in FUN. FUN accepts input X and returns a vector (ormatrix) of function values F evaluated at X.NOTE: FUN should return FUN(X) and not the sum-of-squares sum(FUN(X).^2)).(FUN(X) is summed and squared implicitly in the algorithm.)X=LSQNONLIN(FUN,X0,LB,UB) defines a set of lower and upper bounds on thedesign variables, X, so that the solution is in the range LB

If FUN returns a vector F of m components when X has length n, then J is an m-by-nmatrix where J(i,j) is the partial derivative of F(i) with respect to x(j). (Note that theJacobian J is the transpose of the gradient of F.)ANEXO 4. MATLAB. FUNCIONES AVANZADAS DE SISTEMAS NO LINEALES.[X,RESNORM]=LSQNONLIN(FUN,X0,...) returns the value of the squared 2-norm ofthe residual at X: sum(FUN(X).^2).[X,RESNORM,RESIDUAL]=LSQNONLIN(FUN,X0,...) returns the value of theresidual at the solution X: RESIDUAL = FUN(X).[X,RESNORM,RESIDUAL,EXITFLAG]=LSQNONLIN(FUN,X0,...) returns anEXITFLAG that describes the exit condition of LSQNONLIN.Possible values of EXITFLAG and the corresponding exit conditions are1 LSQNONLIN converged to a solution X.2 Change in X smaller than the specified tolerance.3 Change in the residual smaller than the specified tolerance.4 Magnitude search direction smaller than the specified tolerance.0 Maximum number of function evaluations or of iterations reached.-1 Algorithm terminated by the output function.-2 Bounds are inconsistent.-4 Line search cannot sufficiently decrease the residual along thecurrent search direction.[X,RESNORM,RESIDUAL,EXITFLAG,OUTPUT]=LSQNONLIN(FUN,X0,...) returns astructure OUTPUT with the number of iterations taken in OUTPUT.iterations, thenumber of function evaluations in OUTPUT.funcCount, the algorithm used inOUTPUT.algorithm, the number of CG iterations (if used) in OUTPUT.cgiterations,the first-order optimality (if used) in OUTPUT.firstorderopt, and the exit message inOUTPUT.message.

ANEXO 4MATLAB. FUNCIONES AVANZADAS <strong>DE</strong> <strong>SISTEMAS</strong> NO LINEALES.LSQNONLINsolves non-linear least squares problems.LSQNONLIN attempts to solve problems of the form:min sum {FUN(X).^2} where X and the values returned by FUN can be xvectors or matrices.X=LSQNONLIN(FUN,X0) starts at the matrix X0 and finds a minimum X to the sumof squares of the functions in FUN. FUN accepts input X and returns a vector (ormatrix) of function values F evaluated at X.NOTE: FUN should return FUN(X) and not the sum-of-squares sum(FUN(X).^2)).(FUN(X) is summed and squared implicitly in the algorithm.)X=LSQNONLIN(FUN,X0,LB,UB) defines a set of lower and upper bounds on thedesign variables, X, so that the solution is in the range LB

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!