01-19-2006 04:47 PM
01-20-2006 11:43 AM
03-07-2012 03:54 PM
Andrew,
Regarding your statement: "Therefore, the first element in Coef is your offset, second element in Coef is x, third element is x2."
I trust your information, but the order of returned coeficients does not follow from the prototype. And this does not seem to be documented anywhere, either in the Reference Manual or in the examples.
So, for an example, a PolyFit of order 3 (AX^3 + BX^2 + CX + D) returns the coefficients as:
coef[0] = D
coef[1] = C
coef[2] = B
coef[3] = A
Is this correct? It seeme very counter-intuitive!
Thanks!
Jesse