NonlinearFit work but NonlinearRegress, why?
- To: mathgroup at smc.vnet.net
- Subject: [mg29086] NonlinearFit work but NonlinearRegress, why?
- From: "J. Guillermo Sanchez" <guillerm at gugu.usal.es>
- Date: Sun, 27 May 2001 18:04:52 -0400 (EDT)
- Sender: owner-wri-mathgroup at wolfram.com
I wish fit a13, a21, a31 with the experimental values given by "data" as follow: A = {{-0.15` - a13, a21, a31}, {0.15`, -0.17` - a21, 0}, {a13, 0, -a31}}; model3[t_] := MatrixExp[A t].{0.7 Exp[-0.1 t], 0, 0}; data = {{0.`, 0.`}, {1.`, 0.073`}, {2.`, 0.099`}, {3.`, 0.1`}, {4.`, 0.088`}, {5.`, 0.077`}, {6.`, 0.064`}, {7.`, 0.056`}, {8.`, 0.043`}, {9.`, 0.039`}, {10.`, 0.028`}}; (*I use NonlinearFit using that start points the same that I have obtained using FindMinimum {a21 -> 0.1, a13 -> 0.2, a31 -> 0.04}*) Needs["Statistics`NonlinearFit`"] (* data should be fitted to second output of model3[t], I mean model3[t][[2]]*) NonlinearFit[data, (model3[t] /. {a21 -> A21, a13 -> A13, a31 -> A31})[[2]], {t}, {{A21, 0.1}, {A13, 0.2}, {A31, 0.04}}] It is Ok, but I need to know A21, A13, A31 values and their interval of conficence, It should be posible using NonlinearRegress but it dont work NonlinearRegress[data, (model3[t] /. {a21 -> A21, a13 -> A13, a31 -> A31})[[2]], {t}, {{A21, 0.1}, {A13, 0.2}, {A31, 0.04}}] Any help?