Mantid
Loading...
Searching...
No Matches
MDBoxImplicitFunction.h
Go to the documentation of this file.
1// Mantid Repository : https://github.com/mantidproject/mantid
2//
3// Copyright © 2011 ISIS Rutherford Appleton Laboratory UKRI,
4// NScD Oak Ridge National Laboratory, European Spallation Source,
5// Institut Laue - Langevin & CSNS, Institute of High Energy Physics, CAS
6// SPDX - License - Identifier: GPL - 3.0 +
7#pragma once
8
11#include "MantidKernel/VMD.h"
12#include <boost/tuple/tuple.hpp>
13#include <vector>
14
15namespace Mantid {
16namespace Geometry {
17
25class MANTID_GEOMETRY_DLL MDBoxImplicitFunction : public MDImplicitFunction {
26public:
28
29 MDBoxImplicitFunction(const std::vector<coord_t> &min, const std::vector<coord_t> &max);
30
31 double volume() const;
32
33 double fraction(const std::vector<boost::tuple<Mantid::coord_t, Mantid::coord_t>> &boxExtents) const;
34
35private:
36 void construct(const Mantid::Kernel::VMD &min, const Mantid::Kernel::VMD &max);
37
43 double m_volume;
44};
45
46} // namespace Geometry
47} // namespace Mantid
General N-dimensional box implicit function: Defines a cuboid in N dimensions that is aligned with th...
const Mantid::Kernel::VMD m_max
Maximum extents of MDBox.
const Mantid::Kernel::VMD m_min
Minimum extents of MDBox.
An "ImplicitFunction" defining a hyper-cuboid-shaped region in N dimensions.
Helper class which provides the Collimation Length for SANS instruments.