Re: NonlinearFit for specific data
- To: mathgroup at smc.vnet.net
- Subject: [mg117824] Re: NonlinearFit for specific data
- From: Daniel Lichtblau <danl at wolfram.com>
- Date: Fri, 1 Apr 2011 02:31:56 -0500 (EST)
Alexandre Souza wrote: > Dear Group, > I have the following data : > data2 = { {0, 773.59},{30, 2351.12},{60, 4205.8}, {90, 4222.69},{120, > 4222.69},{150, 704.328}, > {180, 1388.28},{210, 1388.28},{240, 1821.23},{270, 1821.23},{300, > 754.109},{330, 773.59},{360, 773.59}}; > I want the following curve fit : > NonlinearFit[data2, Exp[ a + b x + c x^2], x, {a, b, c}] > Unfortunatelly I get some "FindFit::sszero > FindMinimum::sszero" message, and the given result is ackward. > I also tried FindFit and NonlinearRegress without success. > Any comment would be very welcome. > Alex Judging from ListPlot[data2] I would surmise you just have a really bad model for that data. The quartic below seems better (though not great). model = a*x^4 + b*x^3 + c*x^2 + d*x + e; I do not recommend using that quartic for the problem at hand. I simply wanted to give a model that would behave much better, to provide some contrast with the bad model. If you have reason to believe that the exponential is a viable model, then you will need to provide reasonable bounds and starting points to give e.g. FindFit a fighting chance. Daniel Lichtblau Wolfram Research