In
public static int Main(string[] args)
{
double[,] x = new double[,]{{-1},{-0.8},{-0.6},{-0.4},{-0.2},{0},{0.2},{0.4},{0.6},{0.8},{1.0}};
double[] y = new double[]{0.223130,0.382893,0.582748,0.786628,0.941765,1.000000,0.941765,0.786628,0.582748,0.382893,0.223130};
double[] c = new double[]{0.3};
...
is the idea to make x[,] a column array/table of x,y points, and then 'y' (from above) is the corresponding value at the point? As in (using c++ .net code):
Code:
int N = Gaussian_Data->Length();//the total number of data points in the Gaussian surface data to fit
array<double,2>^ x = gcnew array<double,2>(2, N);
array<double>^ y = gcnew array<double>(N);
int i = 0;
for (int xaxis = 0; xaxis = Gaussian_Data->GetLength(0); xaxis++)
for (int yaxis = 0; yaxis = Gaussian_Data->GetLength(1); yaxis++)
{
x[0, i] = (double)xaxis;
x[1, i] = (double)yaxis;
y[i] = Gaussian_Data[xaxis, yaxis];
i++;
}
So is that the idea for doing multidimensional fitting?
I guess I can just try coding it this way and see what happens.