BornAgain  1.19.79
Open-source research software to simulate and fit neutron and x-ray reflectometry and grazing-incidence small-angle scattering
DecouplingApproximationStrategy.h
Go to the documentation of this file.
1 // ************************************************************************************************
2 //
3 // BornAgain: simulate and fit reflection and scattering
4 //
5 //! @file Resample/Interparticle/DecouplingApproximationStrategy.h
6 //! @brief Defines class DecouplingApproximationStrategy.
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 #ifdef SWIG
16 #error no need to expose this header to Swig
17 #endif
18 
19 #ifndef USER_API
20 #ifndef BORNAGAIN_RESAMPLE_INTERPARTICLE_DECOUPLINGAPPROXIMATIONSTRATEGY_H
21 #define BORNAGAIN_RESAMPLE_INTERPARTICLE_DECOUPLINGAPPROXIMATIONSTRATEGY_H
22 
24 
25 class DiffuseElement;
26 
27 //! Strategy class to compute the total scattering from a particle layout
28 //! in the decoupling approximation.
29 
31 public:
33  const std::vector<std::unique_ptr<const CoherentFFSum>>& weighted_formfactors,
34  const IInterference* iff, SimulationOptions sim_params, bool polarized);
35 
36 private:
37  double scalarCalculation(const DiffuseElement& ele) const override;
38  double polarizedCalculation(const DiffuseElement& ele) const override;
39 
40  const std::unique_ptr<IInterference> m_iff;
41 };
42 
43 #endif // BORNAGAIN_RESAMPLE_INTERPARTICLE_DECOUPLINGAPPROXIMATIONSTRATEGY_H
44 #endif // USER_API
Defines interface IInterparticleStrategy.
Strategy class to compute the total scattering from a particle layout in the decoupling approximation...
double polarizedCalculation(const DiffuseElement &ele) const override
This is the polarized version.
const std::unique_ptr< IInterference > m_iff
double scalarCalculation(const DiffuseElement &ele) const override
Returns the total incoherent and coherent scattering intensity for given kf and for one particle layo...
DecouplingApproximationStrategy(const std::vector< std::unique_ptr< const CoherentFFSum >> &weighted_formfactors, const IInterference *iff, SimulationOptions sim_params, bool polarized)
Data stucture containing both input and output of a single detector cell.
Abstract base class of interference functions.
Definition: IInterference.h:24
Abstract base class of DecouplingApproximationStrategy, SSCAStrategy. Provides function 'evaluate' th...
Collect the different options for simulation.SimulationOptions.