Services & Resources / Wolfram Forums
-----
 /
MathGroup Archive
2005
*January
*February
*March
*April
*May
*June
*July
*August
*September
*October
*November
*December
*Archive Index
*Ask about this page
*Print this page
*Give us feedback
*Sign up for the Wolfram Insider

MathGroup Archive 2005

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

Search the Archive

nonLinearFit and nonLinearRegress

  • To: mathgroup at smc.vnet.net
  • Subject: [mg55298] nonLinearFit and nonLinearRegress
  • From: john.hawkin at gmail.com (John Hawkin)
  • Date: Fri, 18 Mar 2005 05:34:55 -0500 (EST)
  • Sender: owner-wri-mathgroup at wolfram.com

I'm trying to do a nonLinear fit on some data, fitting a parameter
which appears in the limits of the integral that I'm trying to fit. 
When I do a nonLinearFit, I get about a page of errors, but it does
work.  It takes about 10 minutes to do it for 20 points with a
reasonable initial estimate.  However when I use the nonLinearRegress
command, even with the best fit parameter from nonLinearFit given as
the initial guess, it takes hours to work.  Is it possible there is a
way to speed this up, and is this normal?

The commands that I'm using to integrate this function are:

h[B]:=2/(B pi) NIntegrate[x Sin[x] Exp[-(x/B)^3/2], {x, 0, inf},
Method-Oscillatory];
holts[c_, d_, Q_]:= NIntegrate[h[B], {B, c/Q, d/Q}];

where holts is the function I am fitting (the h[B] integral is known
as the Holtsmark integral).  The fitting command I'm using is:

NonlinearFit[fitData, holts[c,d,Q], {c,d}, {Q, estimateQ}];

where fitData contains sets of size 3, with the values of c and d as
the first two values, and the data point that I'm fitting the integral
to as the 3rd value.  If anyone has any ideas on how I can perform the
nonlinear regression fast enough so that I can do it many times (maybe
50), I would greatly appreciate it.  Thanks very much,

John Hawkin


  • Prev by Date: Re: Re: Sum
  • Next by Date: Re: Re: J/Link problem on Mac OS X
  • Previous by thread: Re: Multiple > and < calculations [great than & less than]
  • Next by thread: Re: nonLinearFit and nonLinearRegress