Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have a set of $5$ data points $(x, y)$. I need to find two constants ($a$ and $b$), so that the curve $x\cdot y^a=b$ fits my data set. The question states that I can find the constants from the fitting process. However, I'm not sure where to start. Which method do I use to do this?

Thanks for any help.

share|cite|improve this question
For some basic information about writing math at this site see e.g. here, here, here and here. – Julian Kuelshammer Nov 2 '12 at 0:10
Unless you are very lucky, you can't find two constants which make a curve fit five data points --- all you can do is choose the constants so the curve fits the data as closely as possible. How to do this depends on your notion of what makes one curve fit better than another. This vital information is probably hidden in what you are calling "the fitting process". So, if you don't tell us what "the fitting process" is, we are groping in the dark if we try to answer your question. You ask, "which methhod do I use to do this?" I ask, "which methods have you been given?" – Gerry Myerson Nov 2 '12 at 2:25
@GerryMyerson We are not told which method to use. I assume we are supposed to find a linear representation of this function, but all the examples of that that I can find are for when the equation is equal to y. The given equation is more complicated because y is raised to some constant. – edc1591 Nov 3 '12 at 21:31
up vote 2 down vote accepted

Applying the natural logarithm to your curve, we have $$ \ln x + a \ln y = \ln b.$$ This shows a linear relationship between $\ln x$ and $\ln y$.

Take your data points $(x,y)$ and convert them to new points $(\ln x, \ln y)$ by applying the natural logarithm. Take this set of converted data points and find the line of best fit. Apply the exponential function to your line to get the curve you seek.

share|cite|improve this answer
When I find the line of best fit, does the slope = a and the intercept = b? I tried that and it doesn't seem to work out. The curve does not fit my data. – edc1591 Nov 3 '12 at 21:30
@edc1591 No. When you get a line of best fit, think of it as $\ln y =m \ln x + B$. Then $y = e^B x^m$. Take $m$-th roots, to get $y^{1/m} = e^{B/m} x$, so that $x y^{-1/m} = e^{-B/m}$. So for the curve form you seek, a would be -1/m and b would be -B/m. – Matthew Conroy Nov 3 '12 at 22:23
I think you meant $b = e^{-B/m}$. Thanks so much for the help! – edc1591 Nov 4 '12 at 18:42
Yup, I sure did. Cheers! – Matthew Conroy Nov 4 '12 at 23:17

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.