Mathematica 9 is now available
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

Fitting numerical data

  • To: mathgroup at smc.vnet.net
  • Subject: [mg62022] Fitting numerical data
  • From: Tomek <rtomek at hotmail.com>
  • Date: Wed, 9 Nov 2005 03:45:48 -0500 (EST)
  • Sender: owner-wri-mathgroup at wolfram.com

I am trying to find a best fit of my data to a function, which is a solution of a partial differential equation integrated over one of the variables:

SOLN = Function[{p, avg}, 
sol = NDSolve[D[u[r,t],t]... <diff equation>]; 
NIntegrate[Evaluate[First[u[r,t] /. sol]], {r, rmin, rmax}]/. t-> p]

When I compute the values at certain points for SOLN, everything works fine, but when I try to use FindFit to actually find the fit of the data:

FindFit[data, a*SOLN[t, av], {a, av}, t]

it fails with 'Unable to solve for the fit paramters; the design matrix is non-rectangular, non-numberical or could not be inverted.'. 

The data provided allows for unique solution of the a,av paramters. Is it possible to solve those type of functions with FindFit. How to go around doing that?

Tomek


  • Prev by Date: Re: Re: Re: Use of Mathematica with Rule-based Equation Derivations
  • Next by Date: Re: Bug in pattern parsing?
  • Previous by thread: Re: Reals and Equal
  • Next by thread: Re: Fitting numerical data