From 7112bd60064c3a50d9e5f26966f0807109e99d5a Mon Sep 17 00:00:00 2001 From: assia Date: Fri, 21 Dec 2007 16:32:21 +0000 Subject: [PATCH] header updated git-svn-id: https://www.dynare.org/svn/dynare/dynare_v4@1512 ac1d8469-bf42-47a9-8791-bf33cf982152 --- matlab/lnsrch1.m | 29 ++++++++++++++++++++++++++++- 1 file changed, 28 insertions(+), 1 deletion(-) diff --git a/matlab/lnsrch1.m b/matlab/lnsrch1.m index b94d1ba37..db8181be9 100644 --- a/matlab/lnsrch1.m +++ b/matlab/lnsrch1.m @@ -1,5 +1,32 @@ -% Copyright (C) 2001 Michel Juillard +% function [x,f,fvec,check]=lnsrch(xold,fold,g,p,stpmax,func,j1,j2,varargin) +% Computes the optimal step by minimizing the residual sum of squares % +% INPUTS +% xold: actual point +% fold: residual sum of squares at the point xold +% g: gradient +% p: Newton direction +% stpmax: maximum step +% func: name of the function +% j1: equations index to be solved +% j2: unknowns index +% varargin: list of arguments following j2 +% +% OUTPUTS +% x: chosen point +% f: residual sum of squares value for a given x +% fvec: residuals vector +% check=1: problem of the looping which continues indefinitely +% +% +% SPECIAL REQUIREMENTS +% none +% +% +% part of DYNARE, copyright Dynare Team (2001-2007) +% Gnu Public License. + + function [x,f,fvec,check]=lnsrch(xold,fold,g,p,stpmax,func,j1,j2,varargin) global options_