From t@|@nepr@@@ @end|ng |rom gm@||@com  Mon May  4 21:26:39 2020
From: t@|@nepr@@@ @end|ng |rom gm@||@com (Taiane S. Prass)
Date: Mon, 4 May 2020 16:26:39 -0300
Subject: [Rd] error in message printed by L-BFGS-B
Message-ID: <CANDZg5rZopSGrgOdierZMk9MLRnm4mR9p120nqvNH0ndcH8dkQ@mail.gmail.com>

Hi

I have a FORTRAN version of the L-BFGS-B algorithm and I was comparing it
to the code in the lbfgsb.c file available at R-4.0.0.tar.gz

Everithing looks the same, except for those two lines that must be printed
by the prn3lb function in case of an error (lines 3559 and 3561 in
lbfgsb.c):

case -5: Rprintf("l(%d) > u(%d).  No feasible solution", k, k); break;

case -7: Rprintf("Warning:  more than 10 function and gradient
evaluations\n   in the last line search\n"); break;

I believe that these two lines are interchanged, as lines 835 to 837 say

if (iback >= 10) info = -5;
/*     i.e., to issue a warning if iback>10 in the line search. */
goto L999;

while lines 1784 and 1785 say

strcpy(task, "ERROR: NO FEASIBLE SOLUTION");
*info = -7;


Best regards,


*Profa. Dra. Taiane Schaedler PrassDepartamento de Estat?stica - Instituto
de Matem?tica e Estat?stica*

*Programa de P?s-Gradua??o em Estat?stica (PPGEst)*
*Universidade Federal do Rio Grande do Sul*
Av. Bento Gon?alves, 9500, Porto Alegre - RS - BRASIL - CEP: 91509-900
*https://www.ufrgs.br/ime/ <https://www.ufrgs.br/ime/>*
www.professor.ufrgs.br/tsprass

*"In order to seek truth, it is necessary once in the course of our life,
to doubt, as far as possible, of all things*
*"  Ren? Descartes (1596-1650)*

	[[alternative HTML version deleted]]



[Rd] error in message printed by L-BFGS-B
Taiane S. Prass