MathGroup Archive 2013

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

Search the Archive

Help: Problems with fitting a list of data with an equation with two parameters

  • To: mathgroup at smc.vnet.net
  • Subject: [mg129704] Help: Problems with fitting a list of data with an equation with two parameters
  • From: dinodeblasio at gmail.com
  • Date: Wed, 6 Feb 2013 01:50:42 -0500 (EST)
  • Delivered-to: l-mathgroup@mail-archive0.wolfram.com
  • Delivered-to: l-mathgroup@wolfram.com
  • Delivered-to: mathgroup-newout@smc.vnet.net
  • Delivered-to: mathgroup-newsend@smc.vnet.net

Hello everyone:
I'd like to fit a list like:
data2211={{0., 0.}, {1., 0.0000202672}, {2., 0.0000606506}, {3., 
  0.0000902571}, {4., 0.00011201}, {5., 0.000122325}, {6., 
  0.000129026}, {7., 0.000136861}, {8., 0.000138904}, {9., 
  0.000142179}, {10., 0.000145617}, {11., 0.000150792}, {12., 
  0.000153723}, {13., 0.000158662}, {14., 0.000163744}, {15., 
  0.000170338}, {16., 0.000176373}, {17., 0.000184436}, {18., 
  0.000191055}, {19., 0.000197175}, {20., 0.000205177}, {21., 
  0.000212824}, {22., 0.000221142}, {23., 0.000228844}, {24., 
  0.000236553}, {25., 0.000243398}, {26., 0.000251118}, {27., 
  0.000258642}, {28., 0.00026638}, {29., 0.000275992}, {30., 
  0.000284433}, {31., 0.000291682}, {32., 0.000300548}, {33., 
  0.000308275}, {34., 0.000316503}, {35., 0.000322813}, {36., 
  0.000332034}, {37., 0.000340994}, {38., 0.000349994}, {39., 
  0.00035922}, {40., 0.000366491}, {41., 0.00037264}, {42., 
  0.000379767}, {43., 0.000388169}, {44., 0.000395309}, {45., 
  0.000403434}, {46., 0.000411034}, {47., 0.00041769}, {48., 
  0.000424886}, {49., 0.000431168}, {50., 0.000437785}, {51., 
  0.000446171}, {52., 0.000453136}, {53., 0.000460042}, {54., 
  0.000467164}, {55., 0.000473857}, {56., 0.00047967}, {57., 
  0.00048695}, {58., 0.000492749}, {59., 0.000499251}, {60., 
  0.000506003}, {61., 0.000512512}, {62., 0.000516679}, {63., 
  0.000522183}};

with something like:
Clear[y];
Column[{model = 
    Solve[-A/(
         2 Sqrt[B^2 + 4 A B]) {Log[(2 A y^2 + b - Sqrt[B^2 + 4 A B])/(
           2 A y^2 + b + Sqrt[B^2 + 4 A B])]} - -A/(
         2 Sqrt[B^2 + 4 A B]) {Log[(b - Sqrt[B^2 + 4 A B])/(
           b + Sqrt[B^2 + 4 A B])]} == t, y[t], t][[1]], 
   param = FindFit[data1211, y[t] /. model, {A, B}, t], 
   Plot[y[t] /. model /. param, {t, 0, Max[data1211[[All, 1]]]}, 
    PlotRange -> All}]}] // Quiet

however there is some errors which I can't figure it out.
Any help is appreciated.

Thanks,
Dino



  • Prev by Date: Re: Mathematica and Lisp
  • Next by Date: Re: Plot[] will not plot functions when one of the functions in list
  • Previous by thread: Re: SFTP
  • Next by thread: Re: Plot[] will not plot functions when one of the functions in list