fit_gsl.h
Go to the documentation of this file.
/***************************************************************************
File : fit_gsl.h
Project : QtiPlot
Description : Built-in data fit models for QtiPlot
--------------------------------------------------------------------
Copyright : (C) 2004-2010 Ion Vasilief (ion_vasilief*yahoo.fr)
(replace * with @ in the email address)
***************************************************************************/
/***************************************************************************
* *
* This program is free software; you can redistribute it and/or modify *
* it under the terms of the GNU General Public License as published by *
* the Free Software Foundation; either version 2 of the License, or *
* (at your option) any later version. *
* *
* As a special exception, you may omit the above copyright notice when *
* distributing modified copies of this file (for instance, when using it *
* as a template for your own fit plugin). *
* *
* This program is distributed in the hope that it will be useful, *
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
* GNU General Public License for more details. *
* *
* You should have received a copy of the GNU General Public License *
* along with this program; if not, write to the Free Software *
* Foundation, Inc., 51 Franklin Street, Fifth Floor, *
* Boston, MA 02110-1301 USA *
* *
***************************************************************************/
#ifndef FIT_GSL_H
#define FIT_GSL_H
#include <gsl/gsl_vector.h>
#include <gsl/gsl_matrix.h>
class Fit;
struct FitData {
int n;// number of points to be fitted (size of X, Y and sigma arrays)
int p;// number of fit parameters
double * X;// the data to be fitted (abscissae)
double * Y; // the data to be fitted (ordinates)
double * sigma; // the weighting data
Fit *fitter; //pointer to the fitter object (used only for the NonLinearFit class)
};
int expd3_fdf (const gsl_vector * x, void *params, gsl_vector * f, gsl_matrix * J);
int expd3_df (const gsl_vector * x, void *params, gsl_matrix * J);
int expd3_f (const gsl_vector * x, void *params, gsl_vector * f);
double expd3_d (const gsl_vector * x, void *params);
int expd2_fdf (const gsl_vector * x, void *params, gsl_vector * f, gsl_matrix * J);
int expd2_df (const gsl_vector * x, void *params, gsl_matrix * J);
int expd2_f (const gsl_vector * x, void *params, gsl_vector * f);
double expd2_d (const gsl_vector * x, void *params);
int exp_fdf (const gsl_vector * x, void *params, gsl_vector * f, gsl_matrix * J);
int exp_df (const gsl_vector * x, void *params, gsl_matrix * J);
int exp_f (const gsl_vector * x, void *params, gsl_vector * f);
double exp_d (const gsl_vector * x, void *params);
int boltzmann_fdf (const gsl_vector * x, void *params, gsl_vector * f, gsl_matrix * J);
int boltzmann_df (const gsl_vector * x, void *params, gsl_matrix * J);
int boltzmann_f (const gsl_vector * x, void *params, gsl_vector * f);
double boltzmann_d (const gsl_vector * x, void *params);
int logistic_fdf (const gsl_vector * x, void *params, gsl_vector * f, gsl_matrix * J);
int logistic_df (const gsl_vector * x, void *params, gsl_matrix * J);
int logistic_f (const gsl_vector * x, void *params, gsl_vector * f);
double logistic_d (const gsl_vector * x, void *params);
int gauss_fdf (const gsl_vector * x, void *params, gsl_vector * f, gsl_matrix * J);
int gauss_df (const gsl_vector * x, void *params, gsl_matrix * J);
int gauss_f (const gsl_vector * x, void *params,gsl_vector * f);
double gauss_d (const gsl_vector * x, void *params);
int gauss_multi_peak_f (const gsl_vector * x, void *params, gsl_vector * f);
double gauss_multi_peak_d (const gsl_vector * x, void *params);
int gauss_multi_peak_df (const gsl_vector * x, void *params, gsl_matrix * J);
int gauss_multi_peak_fdf (const gsl_vector * x, void *params, gsl_vector * f, gsl_matrix * J);
int lorentz_multi_peak_f (const gsl_vector * x, void *params, gsl_vector * f);
double lorentz_multi_peak_d (const gsl_vector * x, void *params);
int lorentz_multi_peak_df (const gsl_vector * x, void *params, gsl_matrix * J);
int lorentz_multi_peak_fdf (const gsl_vector * x, void *params, gsl_vector * f, gsl_matrix * J);
int user_f(const gsl_vector * x, void *params, gsl_vector * f);
double user_d(const gsl_vector * x, void *params);
int user_df(const gsl_vector * x, void *params,gsl_matrix * J);
int user_fdf(const gsl_vector * x, void *params,gsl_vector * f, gsl_matrix * J);
#endif
gauss_multi_peak_f
int gauss_multi_peak_f(const gsl_vector *x, void *params, gsl_vector *f)
Definition: fit_gsl.cpp:310
user_d
double user_d(const gsl_vector *x, void *params)
Definition: fit_gsl.cpp:559
FitData
Structure for fitting data.
Definition: fit_gsl.h:42
gauss_multi_peak_df
int gauss_multi_peak_df(const gsl_vector *x, void *params, gsl_matrix *J)
Definition: fit_gsl.cpp:375
FitData::X
double * X
Definition: fit_gsl.h:45
FitData::Y
double * Y
Definition: fit_gsl.h:46
exp_f
int exp_f(const gsl_vector *x, void *params, gsl_vector *f)
Definition: fit_gsl.cpp:188
boltzmann_f
int boltzmann_f(const gsl_vector *x, void *params, gsl_vector *f)
Definition: fit_gsl.cpp:658
gauss_multi_peak_d
double gauss_multi_peak_d(const gsl_vector *x, void *params)
Definition: fit_gsl.cpp:341
expd2_f
int expd2_f(const gsl_vector *x, void *params, gsl_vector *f)
Definition: fit_gsl.cpp:121
boltzmann_d
double boltzmann_d(const gsl_vector *x, void *params)
Definition: fit_gsl.cpp:674
logistic_fdf
int logistic_fdf(const gsl_vector *x, void *params, gsl_vector *f, gsl_matrix *J)
Definition: fit_gsl.cpp:786
expd3_f
int expd3_f(const gsl_vector *x, void *params, gsl_vector *f)
Definition: fit_gsl.cpp:45
user_df
int user_df(const gsl_vector *x, void *params, gsl_matrix *J)
Definition: fit_gsl.cpp:606
expd2_d
double expd2_d(const gsl_vector *x, void *params)
Definition: fit_gsl.cpp:139
exp_df
int exp_df(const gsl_vector *x, void *params, gsl_matrix *J)
Definition: fit_gsl.cpp:219
lorentz_multi_peak_df
int lorentz_multi_peak_df(const gsl_vector *x, void *params, gsl_matrix *J)
Definition: fit_gsl.cpp:474
logistic_df
int logistic_df(const gsl_vector *x, void *params, gsl_matrix *J)
Definition: fit_gsl.cpp:760
FitData::fitter
Fit * fitter
Definition: fit_gsl.h:48
expd2_fdf
int expd2_fdf(const gsl_vector *x, void *params, gsl_vector *f, gsl_matrix *J)
Definition: fit_gsl.cpp:183
lorentz_multi_peak_f
int lorentz_multi_peak_f(const gsl_vector *x, void *params, gsl_vector *f)
Definition: fit_gsl.cpp:411
gauss_multi_peak_fdf
int gauss_multi_peak_fdf(const gsl_vector *x, void *params, gsl_vector *f, gsl_matrix *J)
Definition: fit_gsl.cpp:406
Fit
Fit base class.
Definition: Fit.h:44
expd3_d
double expd3_d(const gsl_vector *x, void *params)
Definition: fit_gsl.cpp:65
FitData::n
int n
Definition: fit_gsl.h:43
logistic_d
double logistic_d(const gsl_vector *x, void *params)
Definition: fit_gsl.cpp:741
user_fdf
int user_fdf(const gsl_vector *x, void *params, gsl_vector *f, gsl_matrix *J)
Definition: fit_gsl.cpp:650
gauss_f
int gauss_f(const gsl_vector *x, void *params, gsl_vector *f)
Definition: fit_gsl.cpp:246
boltzmann_fdf
int boltzmann_fdf(const gsl_vector *x, void *params, gsl_vector *f, gsl_matrix *J)
Definition: fit_gsl.cpp:716
gauss_d
double gauss_d(const gsl_vector *x, void *params)
Definition: fit_gsl.cpp:263
boltzmann_df
int boltzmann_df(const gsl_vector *x, void *params, gsl_matrix *J)
Definition: fit_gsl.cpp:691
lorentz_multi_peak_fdf
int lorentz_multi_peak_fdf(const gsl_vector *x, void *params, gsl_vector *f, gsl_matrix *J)
Definition: fit_gsl.cpp:508
exp_d
double exp_d(const gsl_vector *x, void *params)
Definition: fit_gsl.cpp:203
FitData::sigma
double * sigma
Definition: fit_gsl.h:47
expd2_df
int expd2_df(const gsl_vector *x, void *params, gsl_matrix *J)
Definition: fit_gsl.cpp:158
exp_fdf
int exp_fdf(const gsl_vector *x, void *params, gsl_vector *f, gsl_matrix *J)
Definition: fit_gsl.cpp:240
gauss_fdf
int gauss_fdf(const gsl_vector *x, void *params, gsl_vector *f, gsl_matrix *J)
Definition: fit_gsl.cpp:304
gauss_df
int gauss_df(const gsl_vector *x, void *params, gsl_matrix *J)
Definition: fit_gsl.cpp:281
lorentz_multi_peak_d
double lorentz_multi_peak_d(const gsl_vector *x, void *params)
Definition: fit_gsl.cpp:441
expd3_fdf
int expd3_fdf(const gsl_vector *x, void *params, gsl_vector *f, gsl_matrix *J)
Definition: fit_gsl.cpp:116
FitData::p
int p
Definition: fit_gsl.h:44
expd3_df
int expd3_df(const gsl_vector *x, void *params, gsl_matrix *J)
Definition: fit_gsl.cpp:86
logistic_f
int logistic_f(const gsl_vector *x, void *params, gsl_vector *f)
Definition: fit_gsl.cpp:722
user_f
int user_f(const gsl_vector *x, void *params, gsl_vector *f)
Definition: fit_gsl.cpp:514