eLynx SDK
v3.0.1 C++ image processing API reference |
#include <GaussNewton.h>
Static Public Member Functions | |
static void | FitParams (const IFunctionNL &iFunction, const IMatrix &iSamples, const IVector &iInitialGuess, IVector &oParams, double iEpsilon=1e-5, uint32 iMaxIterations=0) |
Definition at line 44 of file GaussNewton.h.
static void eLynx::Math::GaussNewton::FitParams | ( | const IFunctionNL & | iFunction, | |
const IMatrix & | iSamples, | |||
const IVector & | iInitialGuess, | |||
IVector & | oParams, | |||
double | iEpsilon = 1e-5 , |
|||
uint32 | iMaxIterations = 0 | |||
) | [static] |
Fits specified function for the given set of samples, using initial parameters guess for the first iteration. In general, it fits function of n-independent variables and m-parameters to the finite set of samples. Samples are specified as matrix with n+1 columns, one sample per row. Columns 0, 1, ... holds values for independent variables, last column contains values for dependent variable (function results). Initial parameters guess and resulting parameters values are given by vectors of size m.
iFunction | the function to be fitted | |
iSamples | the matrix of samples | |
iInitialGuess | the initial guess for parameters values | |
oParams | the resulting parameters values (the best fit) | |
iEpsilon | the iteration threshold value - if the difference in the length of parameter vector between two iterations is less than this value, the iteration stops | |
iMaxIterations | if nonzero, the iteration will be stopped after specified number of iterations, even if threshold was not reached. Can be used to prevent infinite iteration problem. |