"Jessica" <jyorzinski@ucdavis.edu> wrote in message
news:ik9532$298$1@fred.mathworks.com...
> "Steven_Lord" <slord@mathworks.com> wrote in message
> <ik9418$mks$1@fred.mathworks.com>...
*snip*
> x2=[1 50 200 500 800 1000 2000 3000 4000 5000 6000 7000 8000 9000 10000
> 14000 16000];
So for one of these points you're computing exp(16000*b); if b is smaller
than 0.044 then this will overflow, and if it's larger than 0.044 it'll
underflow to 0.
> y2=[67.192431503785585 43.728937550421549 0 26.763054442509919
> 30.580325239212350 31.313687388344004 37.325816541275245
> 39.905287727730567 37.766775948976964 33.290940478772150
> 28.072810933830446 22.968921142266289 18.386543637280138
> 14.476446776414663 11.250690904796071 3.757746258933735
> 2.095333107797992];
>
> When I use the exponential that is provided (a*exp(b*x)+c*exp(d*x)), the
> fit is not quite right. That is why I want to try the next order up:
> a*exp(b*x)+c*exp(d*x)+e*exp(f*x).
Are you sure that this form is appropriate for your data?
> I tried setting some bounds but don't really know how to do this. I run
> this data with the provided a*exp(b*x)+c*exp(d*x), then I can get
> approximate coefficients. But when I enter in these values are starting
> points for a custom fit to a*exp(b*x)+c*exp(d*x)+e*exp(f*x), it does
> not work.
>
> I tried setting the bounds for b differently and this did not help.
Rescale your data instead, and make sure that you're using that form of
equation because it's appropriate for your data, not just because "it
fits"  for the latter you could just use a spline!

Steve Lord
slord@mathworks.com
To contact Technical Support use the Contact Us link on
http://www.mathworks.com
