curve fit exactly the function I enter
Mostrar comentarios más antiguos
I have some data points and a known function with 4 parameters. But when I tried to use the 'cftool', part of the data points aren't fitting the curve. The function is 2 exponential terms but I enter it as customized function.
3 comentarios
John D'Errico
el 11 de Jun. de 2018
Editada: John D'Errico
el 11 de Jun. de 2018
Just because you picked a function does not mean that it can be used to fit any set of points.
Perhaps you are trying to imply that the points are generated by evaluating them form a known function, and you are tying to test fit the function, to see if the curve fit "works"?
What you need to understand is that you need to supply adequate starting values, that sums of exponentials are difficult things to fit, and that no optimization is guaranteed to converge to the solution that you want to see.
So, if it failed to converge to the solution you wanted, then provide adequate starting values.
JuiChun Lin
el 11 de Jun. de 2018
Walter Roberson
el 11 de Jun. de 2018
Your data probably doesn't match the model very well. That happens a lot.
Respuesta aceptada
Más respuestas (0)
Categorías
Más información sobre Get Started with Curve Fitting Toolbox en Centro de ayuda y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!
