|
|
Newcastle Scientific
TM Libraries for Numerical Analysis |
|
To use LeastSqX, simply make a single call to the FitData method defined by the control. This call includes passing the number of data points, degrees of freedom to fit, array of independent variables (e.g., time), array of dependent variables (e.g., measurements), array of uncertainties of these measurements (may be all set to 0 for non-weighted fitting), function name (or 0 for a general polynomial fit), and initial guess of the coefficients if supplied user fitting function is non-linear. Upon return, the coefficients are replaced by the fit values. Also returned are the one sigma uncertainties of the fit, along with the Chisq value. Example implementations included with the control demonstrate linear and non-linear fitting, plus a simple demonstration of how to use LeastSqX to perform multidimensional fitting (e.g., z as a function of both x and y). LeasySqX1.FitData (
numpoints As Long, numco As Long, xd As Double, yd As Double, sigd As Double,
userfunc As Long, co As Double, stddev As Double, ChiSquare As Double) As Long |
||
|
|
Home
User Manual
Purchase
Testimonials
|