Closed LittleDogXi closed 2 months ago
According to the user guide for minpack, which can be found at
when you supply the param nprint
a positive integer, it enables controlled printing of iterates.
I set param nprint
a postive integer like +1, but I cannot see any printing of iterates in the console. Is the information printed somewhere else?
I never experimented this nprint
param myself, but judging by the docs linked above, I guess you would be called nprint
times in the callback or something in that direction.
I will try it soon later.
After a few tries, I have figured it out. Set nprint
a positive integer, like 1, and add if(*flag==0){std::cout<<"$";}
in the fcn
function, you could print serval $ characters, which has the same number of iteration times.
I'm glad that you solved the puzzle.
The parameter "nfev" is the number of fcn calls. But how can I know the iteration numbers using hybrd function?