How to fit an exponential curve to data?

105 Views Asked by At

I would like to fit a curve of the form $$\frac{1}{Y}=\frac{x^u}{c_1}+\frac{(1-x)^v}{c_2}$$ to a dataset with 7 data-points of (x,Y). How can I do this? I already know the values of c1 and c2 and need to find out v. I thought if I had some way to convert it into a linear combination of u,v and their powers, I could apply linear regression. But due to the nature of this research (in chemical engineering), I require an equation that will give me accurate values of Y for given x, even though I have very few data points. Is there a way out?

1

There are 1 best solutions below

0
On

You have $n$ data points $(x_i,y_i)$ and you want to fit the model $$\frac 1 y=\frac{x^u}{c_1}+\frac{(1-x)^v}{c_2}\tag 1$$ In fact, this is not correct since what is measured is $y$ and not $\frac 1 y$. So, even if we work with $(1)$ in a preliminary step, at the end, you will need to work with $$y=\frac 1{ \frac{x^u}{c_1}+\frac{(1-x)^v}{c_2}}\tag 2$$ $(1)$ is a very highly nonlinear model and you need good estimates for starting the full nonlinear regression.

What I would suggest is to fix one of the parameters $u$ or $v$ to an arbitrary value. Say that we fix $x$. So the model write $$\frac 1 y-\frac{x^u}{c_1}=\frac{(1-x)^v}{c_2}\tag 3$$ that is to say $$c_2\left(\frac 1 y-\frac{x^u}{c_1}\right)=(1-x)^v$$ $$\log\left( c_2\left(\frac 1 y-\frac{x^u}{c_1}\right) \right)=v\log(1-x)$$ which is more than simple (a linear regression with no intercept. So, for this given $u$, you know $v$; recompute the $\hat y_i$ and $$\text{SSQ}(v)=\sum_{i=1}^n \left(\hat y_i -y_i\right)^2$$ Try a few values of $u$ and plot them until you see a minimum. Now you are ready.