|
Mantid
|
Defines a flat, circular beam profile that has a radius and center point. More...
#include <CircularBeamProfile.h>
Public Member Functions | |
| CircularBeamProfile (const Geometry::ReferenceFrame &frame, const Kernel::V3D ¢er, double radius) | |
| Construct a beam profile. More... | |
| Geometry::BoundingBox | defineActiveRegion (const Geometry::BoundingBox &sampleBox) const override |
| Compute a region that defines how the beam illuminates the given sample/can. More... | |
| IBeamProfile::Ray | generatePoint (Kernel::PseudoRandomNumberGenerator &rng) const override |
| Generate a random point within the beam profile using the supplied random number source. More... | |
| IBeamProfile::Ray | generatePoint (Kernel::PseudoRandomNumberGenerator &rng, const Geometry::BoundingBox &bounds) const override |
| Generate a random point on the profile that is within the given bounding area. More... | |
Public Member Functions inherited from Mantid::Algorithms::IBeamProfile | |
| virtual Geometry::BoundingBox | defineActiveRegion (const Geometry::BoundingBox &) const =0 |
| virtual Ray | generatePoint (Kernel::PseudoRandomNumberGenerator &rng) const =0 |
| virtual Ray | generatePoint (Kernel::PseudoRandomNumberGenerator &rng, const Geometry::BoundingBox &) const =0 |
| virtual | ~IBeamProfile ()=default |
Private Attributes | |
| Kernel::V3D | m_beamDir |
| const unsigned short | m_beamIdx |
| Kernel::V3D | m_center |
| const unsigned short | m_horIdx |
| std::array< double, 3 > | m_min |
| const double | m_radius |
| const unsigned short | m_upIdx |
Defines a flat, circular beam profile that has a radius and center point.
The profile is assumed infinitely thin.
Definition at line 25 of file CircularBeamProfile.h.
| Mantid::Algorithms::CircularBeamProfile::CircularBeamProfile | ( | const Geometry::ReferenceFrame & | frame, |
| const Kernel::V3D & | center, | ||
| double | radius | ||
| ) |
Construct a beam profile.
| frame | Defines the direction of the beam, up and horizontal |
| center | V3D defining the central point of the circle |
| radius | Radius of beam |
Definition at line 25 of file CircularBeamProfile.cpp.
References m_beamDir, m_beamIdx, m_center, m_horIdx, m_min, m_upIdx, and radius.
|
overridevirtual |
Compute a region that defines how the beam illuminates the given sample/can.
| sampleBox | A reference to the bounding box of the sample |
Implements Mantid::Algorithms::IBeamProfile.
Definition at line 87 of file CircularBeamProfile.cpp.
References m_beamIdx, m_center, m_horIdx, m_min, m_radius, m_upIdx, Mantid::Geometry::BoundingBox::maxPoint(), Mantid::Geometry::BoundingBox::minPoint(), Mantid::Kernel::V3D::X(), Mantid::Kernel::V3D::Y(), and Mantid::Kernel::V3D::Z().
|
overridevirtual |
Generate a random point within the beam profile using the supplied random number source.
| rng | A reference to a random number generator |
Implements Mantid::Algorithms::IBeamProfile.
Definition at line 41 of file CircularBeamProfile.cpp.
References m_beamDir, m_beamIdx, m_center, m_horIdx, m_radius, m_upIdx, and Mantid::Kernel::PseudoRandomNumberGenerator::nextValue().
Referenced by generatePoint().
|
overridevirtual |
Generate a random point on the profile that is within the given bounding area.
If the point is outside the area then it is pulled to the boundary of the bounding area.
| rng | A reference to a random number generator |
| bounds | A reference to the bounding area that defines the maximum allowed region for the generated point. |
Implements Mantid::Algorithms::IBeamProfile.
Definition at line 64 of file CircularBeamProfile.cpp.
References generatePoint(), m_horIdx, m_upIdx, Mantid::Geometry::BoundingBox::maxPoint(), and Mantid::Geometry::BoundingBox::minPoint().
|
private |
Definition at line 41 of file CircularBeamProfile.h.
Referenced by CircularBeamProfile(), and generatePoint().
|
private |
Definition at line 36 of file CircularBeamProfile.h.
Referenced by CircularBeamProfile(), defineActiveRegion(), and generatePoint().
|
private |
Definition at line 40 of file CircularBeamProfile.h.
Referenced by CircularBeamProfile(), defineActiveRegion(), and generatePoint().
|
private |
Definition at line 37 of file CircularBeamProfile.h.
Referenced by CircularBeamProfile(), defineActiveRegion(), and generatePoint().
|
private |
Definition at line 39 of file CircularBeamProfile.h.
Referenced by CircularBeamProfile(), and defineActiveRegion().
|
private |
Definition at line 38 of file CircularBeamProfile.h.
Referenced by defineActiveRegion(), and generatePoint().
|
private |
Definition at line 35 of file CircularBeamProfile.h.
Referenced by CircularBeamProfile(), defineActiveRegion(), and generatePoint().