simplifly polynomial expression
simplifly polynomial expression
(OP)
Hi
i would like to know if there is any function that can be used to reduce the size of polynomial expression (i have a huge one, with several terms and i must made an approximation because my computer can not finish the calculus once i use it in a function)
gabi
i would like to know if there is any function that can be used to reduce the size of polynomial expression (i have a huge one, with several terms and i must made an approximation because my computer can not finish the calculus once i use it in a function)
gabi





RE: simplifly polynomial expression
TTFN
RE: simplifly polynomial expression
gabi
RE: simplifly polynomial expression
Assume a form of the solution with unknown parameters. For example Yhat(X)=A + B*X + C*X^2 with unknown parameters A,B,C. Then to find the values of unknown parameters that minimize the sum of squares of the residuals. Residuals are Ri=Yhati = Yi
In Matlab you can make Matlab do all the programming - use the polyfit function to find a polynomial fit.
If you don't want a polynomial fit, you can program a least squares fit for any functional form using simple matrix algebra. (It may be tough to figure out yourself, search around and you should be able to locate the algorithm or if you really want I can dscribe it).
Also excel has a variety of ways to fit functions which might even be easier. Drop on over to the spreadsheet forum.
=====================================
Eng-tips forums: The best place on the web for engineering discussions.
RE: simplifly polynomial expression
Residuals are Ri=Yhati -Yi
=====================================
Eng-tips forums: The best place on the web for engineering discussions.
RE: simplifly polynomial expression
http://www.library.cornell.edu/nr/cbookfpdf.html
=====================================
Eng-tips forums: The best place on the web for engineering discussions.