diff options
-rw-r--r-- | dynamical_fit/dynamical_fit.cpp | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/dynamical_fit/dynamical_fit.cpp b/dynamical_fit/dynamical_fit.cpp index 196df0d..23646f7 100644 --- a/dynamical_fit/dynamical_fit.cpp +++ b/dynamical_fit/dynamical_fit.cpp @@ -6,6 +6,7 @@ #include <fstream> #include <string> #include <methods/powell/powell_method.hpp> +#include <methods/gsl_simplex/gsl_simplex.hpp> #include <statistics/chisq.hpp> #include <cstdlib> @@ -22,8 +23,11 @@ int main(int argc,char* argv[]) } ifstream cfg_file(argv[1]); fitter<double,double,std::vector<double>,double,std::string> fit; + chisq<double,double,vector<double>,double,string> stat; + stat.verbose(true); fit.set_opt_method(powell_method<double,vector<double> >()); - fit.set_statistic(chisq<double,double,vector<double>,double,string>()); + // + fit.set_statistic(stat); std::string model_so_name; cfg_file>>model_so_name; cerr<<"loading model shared object "<<model_so_name<<endl; @@ -59,6 +63,8 @@ int main(int argc,char* argv[]) fit.set_precision(1e-5); fit.fit(); + fit.set_opt_method(gsl_simplex<double,vector<double> >()); + fit.fit(); fit.fit(); vector<double> p=fit.fit(); |