MathGroup Archive 2004

[Date Index] [Thread Index] [Author Index]

Search the Archive

Re: NonlinearFit problem

  • To: mathgroup at smc.vnet.net
  • Subject: [mg52051] Re: NonlinearFit problem
  • From: Antti Penttilä@smc.vnet.net
  • Date: Tue, 9 Nov 2004 01:36:35 -0500 (EST)
  • Organization: University of Helsinki
  • References: <cmnabi$7sn$1@smc.vnet.net>
  • Sender: owner-wri-mathgroup at wolfram.com

The algorithm uses model's first or second derivatives, and in your case the partial derivative in respect to a is not numerical at r=0 because the Log[r]-function.

D[ r^a Exp[-b r], a] = e^(-b r) r^a Log[r]
and
D[ r^a Exp[-b r], {a, 2}] = e^(-b r) r^a Log[r]^2

If you change your first datapoint to something like {0.0000001, 1.00002} instead of {0, 1.00002} the fit has no problems.


-- 
   Antti Penttilä       Antti.I.Penttila at helsinki.fi.removethis
     Researcher                     Observatory
tel. +358 50 5240968        00014 University of Helsinki


  • Prev by Date: Re:A NIntegrate question
  • Next by Date: Adding text labels and such to 3D plots?
  • Previous by thread: Re: NonlinearFit problem
  • Next by thread: Re: NonlinearFit problem