SOLUTION: I'm stumped. Given an array of known X and Y values, and a list of *new* X values, how can I solve for what the new Y value will be ? A bit more detail: In Excel, I plotted t

Algebra ->  Quadratic Equations and Parabolas  -> Quadratic Equations Lessons  -> Quadratic Equation Lesson -> SOLUTION: I'm stumped. Given an array of known X and Y values, and a list of *new* X values, how can I solve for what the new Y value will be ? A bit more detail: In Excel, I plotted t      Log On


   



Question 313163: I'm stumped.
Given an array of known X and Y values, and a list of *new* X values, how can I solve for what the new Y value will be ?
A bit more detail: In Excel, I plotted these known X and Y values by means of a XY Scatter Chart, then asked it to create me a Trend Line, showing me the formula. The formula, for this data, is: y = 14.132x² - 63.03x + 79.647. I need to know how to actually *arrive* at that formula by a more manual means.
Thanks! :)

Answer by Fombitz(32388) About Me  (Show Source):
You can put this solution on YOUR website!
Check out the link below for the particulars.
You can do this all within an EXCEL spreadsheet.
You're trying to fit y=a0%2Ba1%2Ax%2Ba2%2Ax%5E2to the given N sets of data (xi,yi).
.
.
.
You need to create a matrix of values.
[X]=%28matrix%283%2C3%2Ca%2Cb%2Cc%2Cb%2Cc%2Cd%2Cc%2Cd%2Ce%29%29
where
a=N
b=sum%28xi%2C1%2CN%29
c=sum%28xi%5E2%2C1%2CN%29
d=sum%28xi%5E3%2C1%2CN%29
e=sum%28xi%5E4%2C1%2CN%29
.
.
.
Then create another matrix of values,
[Y]=%28matrix%283%2C1%2Cp%2Cq%2Cr%29%29
where
p=sum%28yi%2C1%2CN%29
q=sum%28xi%2Ayi%2C1%2CN%29
r=sum%28xi%5E2%2Ayi%2C1%2CN%29
Then you have the coefficients a0,a1, and a2.
[a]=%28matrix%283%2C1%2Ca0%2Ca1%2Ca2%29%29
.
.
.
The matrix equation you need to solve is,
[X][a]=[Y]
[a]=[X]inv[Y]
So find the inverse of [X] and matrix multiply by [Y].
That will provide you the coefficients of the least square fit quadratic, [a].
.
.
.
http://mathworld.wolfram.com/LeastSquaresFittingPolynomial.html