BornAgain
1.19.79
Open-source research software to simulate and fit neutron and x-ray reflectometry and grazing-incidence small-angle scattering
|
Computes coherent sum of the four DWBA terms. Wraps an IReParticle, and provides functions evaluate or evaluatePol. Used from CoherentFFSum.
Public Member Functions | |
SumDWBA (const IReParticle &ff) | |
SumDWBA (const IReParticle &ff, size_t i_layer) | |
virtual | ~SumDWBA () |
complex_t | coherentFF (const DiffuseElement &ele) const |
Returns the coherent sum of the four DWBA terms for scalar scattering. More... | |
SpinMatrix | coherentPolFF (const DiffuseElement &ele) const |
Returns the coherent sum of the four DWBA terms for polarized scattering. More... | |
const IReParticle & | ff () const |
size_t | iLayer () const |
Private Attributes | |
const std::unique_ptr< const IReParticle > | m_ff |
const std::optional< size_t > | m_i_layer |
Friends | |
class | TestPolarizedDWBATerm |
SumDWBA::SumDWBA | ( | const IReParticle & | ff, |
size_t | i_layer | ||
) |
Definition at line 23 of file SumDWBA.cpp.
SumDWBA::SumDWBA | ( | const IReParticle & | ff | ) |
Definition at line 29 of file SumDWBA.cpp.
|
virtualdefault |
complex_t SumDWBA::coherentFF | ( | const DiffuseElement & | ele | ) | const |
Returns the coherent sum of the four DWBA terms for scalar scattering.
Definition at line 43 of file SumDWBA.cpp.
References DiffuseElement::fluxIn(), DiffuseElement::fluxOut(), WavevectorInfo::getKf(), WavevectorInfo::getKi(), iLayer(), m_ff, m_i_layer, WavevectorInfo::vacuumLambda(), and DiffuseElement::wavevectorInfo().
SpinMatrix SumDWBA::coherentPolFF | ( | const DiffuseElement & | ele | ) | const |
Returns the coherent sum of the four DWBA terms for polarized scattering.
Definition at line 94 of file SumDWBA.cpp.
References SpinMatrix::a, SpinMatrix::b, SpinMatrix::c, SpinMatrix::d, DotProduct(), DiffuseElement::fluxIn(), DiffuseElement::fluxOut(), WavevectorInfo::getKf(), WavevectorInfo::getKi(), iLayer(), m_ff, m_i_layer, Spinor::u, Spinor::v, WavevectorInfo::vacuumLambda(), and DiffuseElement::wavevectorInfo().
|
inline |
size_t SumDWBA::iLayer | ( | ) | const |
Definition at line 37 of file SumDWBA.cpp.
References ASSERT, and m_i_layer.
Referenced by coherentFF(), and coherentPolFF().
|
private |
Definition at line 54 of file SumDWBA.h.
Referenced by coherentFF(), coherentPolFF(), and ff().
|
private |
Definition at line 55 of file SumDWBA.h.
Referenced by coherentFF(), coherentPolFF(), and iLayer().