for (j=0;j<MA;j+=3)
y[i] += a[j]*exp(-SQR((x[i]-a[j+1])/a[j+2]));
y[i] *= (1.0+SPREAD*ndev.dev());
sig[i]=SPREAD*y[i];
}
FGauss fgauss = new FGauss();
Fitmrq myfit=new Fitmrq(x,y,sig,guess,fgauss);
myfit.fit();
// System.out.printf(setw(18) << "chi-squared:%f\n", setw(13) << myfit.chisq);
// System.out.printf(fixed << setprecision(6);