I had a go at fitting a quadratic using the Scilab leastsq function.
I ended up with the following:
y = -3.6330888 + 0.3255432 * x + 0.0781971 * x^2
for whatever units the xdata and ydata arrays were in another message
with the python code that seems to be doing much the same.
The following s
Perfect.
Chuck Swiger wrote:
Just thought while going to sleep last night, piecemeal linear or
collecting several data
points and doing linear interpolation betwen them should work fine.
For (x1, y1) (x2, y2) (x3, y3) where x1 < x2 < x3 I can get slope m1
and y-intercept b1
between x1-x2,
At 07:06 AM 12/23/2005 -0500, Robert McGwier wrote:
If we know already, a priori, that
the data is from a "smooth function",
The phsical device has a smooth transfer curve ( MVAM109 capacitance /
voltage ) and
resonant frequency is a linear function of capitance ( f = 1 / ( 2 * pi *
L * C ) )
Chuck, John:
If we know already, a priori, that the data is from a "smooth function",
that means (moving from left to right say), the extended line or the
extended parabola from the last two or last three points respectively is
always a very good predictor of the next point, then I would sugge
cswiger wrote:
> This is for the mathematicians out there - what is a simple
> working algorithm for creating a function model to fit an
> arbitrary number of data points.
You could try a least squares fitted polynomial
http://mathworld.wolfram.com/LeastSquaresFittingPolynomial.html
has a descri
This is for the mathematicians out there - what is a simple
working algorithm for creating a function model to fit an
arbitrary number of data points. What I have for a first
approximation, simple linear (y=mx+b) actually works better
than nothing, but there's room for improvement.
I set one frequ