I'm beginning one of my first C# projects--need to find the curve fit for several x-y data points.
For example:
x: 1,2,3,4,5,6 y: 0.5,5,0.5,2.5,5,0.5
As it happens, the proper curve fit I need for these points is a sixth-order polynomial, according to excel.
How can I get the coefficients and exponents of this curve to write the proper expression in C#? I want to stay away from libraries, because this will most likely end up being converted to C for use on microprocessors.
I'm new to C# and know very little about hardware/software integration.
That said, I'm reading about numerical methodology right now...step two of this project will be to take the curve and numerically integrate between successive minimums...
Any advice/pointers are greatly appreciated.
The input will be given by six x-y coordinates...
Problem #1: How do I write a polynomial given six coordinates?