BornAgain  1.18.0
Simulate and fit neutron and x-ray scattering at grazing incidence
Fit::ScalarFunctionAdapter Class Reference

Converts user objective function to chi2 like function which ROOT expects. More...

+ Inheritance diagram for Fit::ScalarFunctionAdapter:

Public Member Functions

 ScalarFunctionAdapter (fcn_scalar_t func, const Parameters &parameters)
 
const RootScalarFunctionrootObjectiveFunction ()
 
- Public Member Functions inherited from Fit::IFunctionAdapter
int numberOfCalls () const
 
int numberOfGradientCalls () const
 

Additional Inherited Members

- Protected Attributes inherited from Fit::IFunctionAdapter
int m_number_of_calls
 
int m_number_of_gradient_calls
 

Detailed Description

Converts user objective function to chi2 like function which ROOT expects.

More precisely, ROOT call to std::function<double(const double*)> will cause the call of user function std::function<double(std::vector<double>)>, where function input parameters will be current values fit parameters.

Definition at line 36 of file ScalarFunctionAdapter.h.


The documentation for this class was generated from the following files: