39 #include <unsupported/Eigen/NonLinearOptimization>
64 int inputs()
const {
return m_inputs; }
65 int values()
const {
return m_values; }
68 : m_inputs(dimensions), m_values(num_data_points) {}
72 virtual int operator()(
const Eigen::VectorXd &x, Eigen::VectorXd &fvec)
const = 0;
75 virtual int df(
const Eigen::VectorXd &x, Eigen::MatrixXd &J)
const = 0;
85 this->defaults_.setValue(
"max_iteration", 500,
"Maximum number of iterations using by Levenberg-Marquardt algorithm.", {
"advanced"});
91 max_iteration_(source.max_iteration_)
103 if (&source ==
this)
return *
this;
Abstract base class for all 1D-dimensional model fitter.
Definition: Fitter1D.h:62
virtual Fitter1D & operator=(const Fitter1D &source)
assignment operator
Definition: LevMarqFitter1D.h:62
virtual ~GenericFunctor()
Definition: LevMarqFitter1D.h:70
virtual int df(const Eigen::VectorXd &x, Eigen::MatrixXd &J) const =0
int values() const
Definition: LevMarqFitter1D.h:65
GenericFunctor(int dimensions, int num_data_points)
Definition: LevMarqFitter1D.h:67
virtual int operator()(const Eigen::VectorXd &x, Eigen::VectorXd &fvec) const =0
const int m_inputs
Definition: LevMarqFitter1D.h:78
int inputs() const
Definition: LevMarqFitter1D.h:64
Abstract class for 1D-model fitter using Levenberg-Marquardt algorithm for parameter optimization.
Definition: LevMarqFitter1D.h:53
LevMarqFitter1D()
Default constructor.
Definition: LevMarqFitter1D.h:82
void optimize_(Eigen::VectorXd &x_init, GenericFunctor &functor)
Optimize start parameter.
Int max_iteration_
Maximum number of iterations.
Definition: LevMarqFitter1D.h:116
std::vector< double > ContainerType
Definition: LevMarqFitter1D.h:57
bool symmetric_
Parameter indicates symmetric peaks.
Definition: LevMarqFitter1D.h:114
void updateMembers_() override
This method is used to update extra member variables at the end of the setParameters() method.
~LevMarqFitter1D() override
destructor
Definition: LevMarqFitter1D.h:96
virtual LevMarqFitter1D & operator=(const LevMarqFitter1D &source)
assignment operator
Definition: LevMarqFitter1D.h:101
LevMarqFitter1D(const LevMarqFitter1D &source)
copy constructor
Definition: LevMarqFitter1D.h:89
int Int
Signed integer type.
Definition: Types.h:102
Main OpenMS namespace.
Definition: FeatureDeconvolution.h:47