mpfit [message #94820] |
Wed, 25 October 2017 23:34  |
Bhuvi
Messages: 1 Registered: October 2017
|
Junior Member |
|
|
Hi,
I am using mpfit to fit the voigt profile to the given data. But I am getting an error like this
GDL> res=mpfit('voigt',p0,functargs=fa,STATUS=staus,ERRMSG=errmsg )
GDL> print,res
nan
GDL> print,errmsg
ERROR: recursion detected; you cannot run MPFIT recursively
How do we know where is the recursion happening and how to avoid the recursion?
|
|
|
Re: mpfit [message #94843 is a reply to message #94820] |
Thu, 02 November 2017 08:54  |
Craig Markwardt
Messages: 1869 Registered: November 1996
|
Senior Member |
|
|
On Thursday, October 26, 2017 at 2:34:38 AM UTC-4, Bhuvi wrote:
> Hi,
> I am using mpfit to fit the voigt profile to the given data. But I am getting an error like this
> GDL> res=mpfit('voigt',p0,functargs=fa,STATUS=staus,ERRMSG=errmsg )
> GDL> print,res
> nan
> GDL> print,errmsg
> ERROR: recursion detected; you cannot run MPFIT recursively
>
> How do we know where is the recursion happening and how to avoid the recursion?
I'm guessing you had one MPFIT session crash in the middle of a fit, then you tried to run it again. As documented in mpfit.pro, you can run MPFIT_RESET_RECURSION to reset the recursion detection.
Craig
|
|
|