BornAgain
1.18.0
Simulate and fit neutron and x-ray scattering at grazing incidence
FootprintSquare.h
Go to the documentation of this file.
1
// ************************************************************************** //
2
//
3
// BornAgain: simulate and fit scattering at grazing incidence
4
//
5
//! @file Device/Beam/FootprintSquare.h
6
//! @brief Defines class FootprintSquare.
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_CORE_BEAM_FOOTPRINTSQUARE_H
16
#define BORNAGAIN_CORE_BEAM_FOOTPRINTSQUARE_H
17
18
#include "
Device/Beam/IFootprintFactor.h
"
19
20
//! Calculates footprint coefficient for a square beam
21
//! @ingroup beam
22
23
class
FootprintSquare
:
public
IFootprintFactor
24
{
25
public
:
26
FootprintSquare
(
const
std::vector<double> P);
27
FootprintSquare
(
double
width_ratio);
28
29
void
accept
(
INodeVisitor
* visitor)
const override
{ visitor->
visit
(
this
); }
30
31
FootprintSquare
*
clone
()
const override
;
32
33
//! Calculate footprint correction coefficient from the beam incident angle _alpha_.
34
double
calculate
(
double
alpha)
const override
;
35
36
//! Print python-formatted footprint definition
37
std::string
print
()
const override
;
38
};
39
40
#endif
// BORNAGAIN_CORE_BEAM_FOOTPRINTSQUARE_H
IFootprintFactor.h
Defines class IFootprintFactor.
FootprintSquare
Calculates footprint coefficient for a square beam.
Definition:
FootprintSquare.h:24
FootprintSquare::accept
void accept(INodeVisitor *visitor) const override
Calls the INodeVisitor's visit method.
Definition:
FootprintSquare.h:29
FootprintSquare::clone
FootprintSquare * clone() const override
Definition:
FootprintSquare.cpp:31
FootprintSquare::calculate
double calculate(double alpha) const override
Calculate footprint correction coefficient from the beam incident angle alpha.
Definition:
FootprintSquare.cpp:36
FootprintSquare::FootprintSquare
FootprintSquare(const std::vector< double > P)
Definition:
FootprintSquare.cpp:21
FootprintSquare::print
std::string print() const override
Print python-formatted footprint definition.
Definition:
FootprintSquare.cpp:46
IFootprintFactor
Abstract base for classes that calculate the beam footprint factor.
Definition:
IFootprintFactor.h:28
INodeVisitor
Visitor interface to visit ISample objects.
Definition:
INodeVisitor.h:149
INodeVisitor::visit
virtual void visit(const BasicLattice *)
Definition:
INodeVisitor.h:154
Device
Beam
FootprintSquare.h
Generated by
1.9.1