Find x-intercepts for polyfit curve

7 views (last 30 days)
Louis Biebuyck
Louis Biebuyck on 21 Jan 2013
I used polyfit to generate a best fit curve for my data. I now want to extrapolate backwards to the x-intercept for this curve. I used poly2sym to generate the equation for the curve, but I am now a bit stuck.
I have tried using fnzeros but I keep getting the error 'Input not a function' or 'Input not recognized variable'. What format does the expression have to be in for fnzeros to work? Or is there some other way of finding the intercept points?
Thanks Louis

Answers (1)

Matt J
Matt J on 21 Jan 2013
Edited: Matt J on 21 Jan 2013
The x-intercepts of a polynomials are its roots. Just use the ROOTS command on the output of POLYFIT. No need to do any symbolic manipulation.

Categories

Find more on Spline Postprocessing in Help Center and File Exchange

Tags

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!