Main Page | Namespace List | Class Hierarchy | Class List | File List | Class Members | File Members

FitListDialog.h

Go to the documentation of this file.
00001 //LabPlot : FitListDialog.h
00002 
00003 #ifndef FITLISTDIALOG_H
00004 #define FITLISTDIALOG_H
00005 
00006 #include <qtextedit.h>
00007 #include "ListDialog.h"
00008 
00009 #ifdef HAVE_GSL
00010 #include <gsl/gsl_multifit_nlin.h>
00011 int fun_f(const gsl_vector *x, void *params, gsl_vector *f);
00012 int fun_df(const gsl_vector *x, void *params, gsl_matrix *J);
00013 int fun_fdf(const gsl_vector *x, void *params, gsl_vector *f,gsl_matrix *J);
00014 #endif
00015 
00016 #define NR_PARS 9
00017 
00018 class FitListDialog : public ListDialog
00019 {
00020         Q_OBJECT
00021 public:
00022         FitListDialog(MainWin *mw=0, const char *name=0);
00023 private slots:
00024         void updateModel(int model);
00025         void updateParameter();
00026         void weightChanged();
00027         int apply_clicked();
00028 public slots:
00029         void setFunction(QString fun);                                                                  
00030         void setNrParameter(int par);                                                                   
00031         void setInitialValue(int par, double v);                                                        
00032         double initialValue(int par);                                                                   
00033         void showResult(bool b=true) {  resultcb->setChecked(b); }              
00034         void setSteps(int s) { stepsle->setText(QString::number(s)); }          
00035         void setTolerance(double t) { tolle->setText(QString::number(t)); }     
00036         void setWeight(int w) { weightcb->setCurrentItem(w); }                  
00037         void setWeightFunction(QString w);                                                      
00038         void setRegion(double a,double b);                                                      
00039         void setBaseline(double b);                                                                     
00040         void setNrPoints(int p) {       numberle->setText(QString::number(p)); }        
00041         void setRange(double a, double b);                                                      
00042         void showResiduals(bool b=true) { rescb->setChecked(b); }               
00043         int Apply() { return apply_clicked(); }                                                 
00044 private:
00045 #ifdef HAVE_GSL
00046         void print_state(int iter, gsl_multifit_fdfsolver * s);
00047 #endif
00048         QTextEdit *infote;
00049         KComboBox *modelcb, *weightcb;
00050         QCheckBox *regioncb, *baselinecb, *resultcb, *rescb;
00051         KLineEdit *funle, *parle, *stepsle, *tolle, *weightle;
00052         KLineEdit *parNle[NR_PARS];             // parameter line edits
00053         KLineEdit *regionminle, *regionmaxle, *baselinele;
00054         KLineEdit *minle, *maxle;
00055 };
00056 
00057 #endif // FITLISTDIALOG_H
00058 

Generated on Fri Aug 19 21:34:44 2005 for LabPlot by doxygen 1.3.6