BornAgain  1.19.79
Open-source research software to simulate and fit neutron and x-ray reflectometry and grazing-incidence small-angle scattering
ResolutionFunction2DGaussian.h
Go to the documentation of this file.
1 // ************************************************************************************************
2 //
3 // BornAgain: simulate and fit reflection and scattering
4 //
5 //! @file Device/Resolution/ResolutionFunction2DGaussian.h
6 //! @brief Defines class ResolutionFunction2DGaussian.
7 //!
8 //! @homepage http://www.bornagainproject.org
9 //! @license GNU General Public License v3 or higher (see COPYING)
10 //! @copyright Forschungszentrum Jülich GmbH 2018
11 //! @authors Scientific Computing Group at MLZ (see CITATION, AUTHORS)
12 //
13 // ************************************************************************************************
14 
15 #ifndef BORNAGAIN_DEVICE_RESOLUTION_RESOLUTIONFUNCTION2DGAUSSIAN_H
16 #define BORNAGAIN_DEVICE_RESOLUTION_RESOLUTIONFUNCTION2DGAUSSIAN_H
17 
19 
20 //! Simple gaussian two-dimensional resolution function.
21 
23 public:
24  ResolutionFunction2DGaussian(double sigma_x, double sigma_y);
25 
27  {
29  }
30  std::string className() const final { return "ResolutionFunction2DGaussian"; }
31  std::vector<ParaMeta> parDefs() const final
32  {
33  return {{"Sigma_x", "?", "sigma_x", 0, +INF, 0}, {"Sigma_y", "?", "sigma_y", 0, +INF, 0}};
34  }
35 
36  double evaluateCDF(double x, double y) const override;
37 
38  double sigmaX() const { return m_sigma_x; }
39  double sigmaY() const { return m_sigma_y; }
40 
41 private:
43 
44  double m_sigma_x;
45  double m_sigma_y;
46 };
47 
48 #endif // BORNAGAIN_DEVICE_RESOLUTION_RESOLUTIONFUNCTION2DGAUSSIAN_H
const double INF
Definition: INode.h:26
Defines interface class IResolutionFunction2D.
Interface providing two-dimensional resolution function.
Simple gaussian two-dimensional resolution function.
ResolutionFunction2DGaussian & operator=(const ResolutionFunction2DGaussian &)
std::string className() const final
Returns the class name, to be hard-coded in each leaf class that inherits from INode.
ResolutionFunction2DGaussian(double sigma_x, double sigma_y)
ResolutionFunction2DGaussian * clone() const override
double evaluateCDF(double x, double y) const override
std::vector< ParaMeta > parDefs() const final
Returns the parameter definitions, to be hard-coded in each leaf class.