comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » LMFIT
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Switch to threaded view of this topic Create a new topic Submit Reply
LMFIT [message #18206] Sat, 11 December 1999 00:00
Alberto Verga is currently offline  Alberto Verga
Messages: 3
Registered: April 1999
Junior Member
I tried the following example on the use of LMFIT given in the IDL 5.2
help:

FUNCTION myfunct, X, A
bx = A[0]*EXP(A[1]*X)
RETURN,[ [bx+A[2]+A[3]*SIN(X)], [EXP(A[1]*X)], [bx*X], $
[1.0] ,[SIN(X)] ]
END

X = FINDGEN(40)/20.0
Y = 8.8 * EXP(-9.9 * X) + 11.11 + 4.9 * SIN(X)
sig = 0.05 * Y
A = [10.0, -0.1, 2.0, 4.0] fita = [1,1,1,1]
PLOTERR, X, Y, sig
coefs = LMFIT(X, Y, A, WEIGHTS = (1/sig^2.0), FITA = fita, $
FUNCTION_NAME = 'myfunct')
OPLOT, X, coefs

I obtained
% LMFIT: Warning: Failed to Converge.

and in consequence a bad fit!
Does anyone known if this LMFIT is correctly implemented?


--
Alberto Verga - verga@marius.univ-mrs.fr
Institut de Recherche sur les Ph�nom�nes Hors Equilibre.
12, av. G�n�ral Leclerc, 13003 Marseille, France.
Tel: 33 (0) 4 91 64 44 76 - Fax 33 (0) 4 91 08 16 37
  Switch to threaded view of this topic Create a new topic Submit Reply
Previous Topic: Re: Breakdown after 10 min: IDL + WinNT
Next Topic: Segmentation Fault

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Sat Oct 11 08:48:52 PDT 2025

Total time taken to generate the page: 0.40585 seconds