BornAgain  1.19.79
Open-source research software to simulate and fit neutron and x-ray reflectometry and grazing-incidence small-angle scattering
CoherentFFSum Class Reference

Description

Information about particle form factor and abundance.

Definition at line 33 of file CoherentFFSum.h.

Collaboration diagram for CoherentFFSum:
[legend]

Public Member Functions

 CoherentFFSum (double abundance, std::vector< std::shared_ptr< const SumDWBA >> terms)
 
double radialExtension () const
 
double relativeAbundance () const
 
complex_t summedFF (const DiffuseElement &ele) const
 
SpinMatrix summedPolFF (const DiffuseElement &ele) const
 

Private Attributes

const double m_abundance
 
const std::vector< std::shared_ptr< const SumDWBA > > m_terms
 

Constructor & Destructor Documentation

◆ CoherentFFSum()

CoherentFFSum::CoherentFFSum ( double  abundance,
std::vector< std::shared_ptr< const SumDWBA >>  terms 
)

Definition at line 20 of file CoherentFFSum.cpp.

21  : m_abundance(abundance)
22  , m_terms(std::move(terms))
23 {
24 }
const double m_abundance
Definition: CoherentFFSum.h:44
const std::vector< std::shared_ptr< const SumDWBA > > m_terms
Definition: CoherentFFSum.h:45

Member Function Documentation

◆ radialExtension()

double CoherentFFSum::radialExtension ( ) const

Definition at line 42 of file CoherentFFSum.cpp.

43 {
44  return m_terms[0]->ff().radialExtension();
45 }

References m_terms.

◆ relativeAbundance()

double CoherentFFSum::relativeAbundance ( ) const
inline

Definition at line 40 of file CoherentFFSum.h.

40 { return m_abundance; }

References m_abundance.

◆ summedFF()

complex_t CoherentFFSum::summedFF ( const DiffuseElement ele) const

Definition at line 26 of file CoherentFFSum.cpp.

27 {
28  complex_t result = 0.;
29  for (const auto& term : m_terms)
30  result += term->coherentFF(ele);
31  return result;
32 }

References m_terms.

◆ summedPolFF()

SpinMatrix CoherentFFSum::summedPolFF ( const DiffuseElement ele) const

Definition at line 34 of file CoherentFFSum.cpp.

35 {
36  SpinMatrix result;
37  for (const auto& term : m_terms)
38  result += term->coherentPolFF(ele);
39  return result;
40 }

References m_terms.

Member Data Documentation

◆ m_abundance

const double CoherentFFSum::m_abundance
private

Definition at line 44 of file CoherentFFSum.h.

Referenced by relativeAbundance().

◆ m_terms

const std::vector<std::shared_ptr<const SumDWBA> > CoherentFFSum::m_terms
private

Definition at line 45 of file CoherentFFSum.h.

Referenced by radialExtension(), summedFF(), and summedPolFF().


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