10#include "MantidGeometry/DllConfig.h"
27 return !(
fabs(lhs.
X() -
rhs.X()) > m_precision ||
fabs(lhs.
Y() -
rhs.Y()) > m_precision ||
28 fabs(lhs.
Z() -
rhs.Z()) > m_precision);
42 if (
fabs(lhs.
X() -
rhs.X()) > m_precision) {
43 return lhs.
X() <
rhs.X();
46 if (
fabs(lhs.
Y() -
rhs.Y()) > m_precision) {
47 return lhs.
Y() <
rhs.Y();
50 if (
fabs(lhs.
Z() -
rhs.Z()) > m_precision) {
51 return lhs.
Z() <
rhs.Z();
139 enum GroupAxiom { Closure, Identity, Inversion, Associativity };
142 Group(
const std::string &symmetryOperationString);
143 Group(
const std::vector<SymmetryOperation> &symmetryOperations);
146 size_t order()
const;
148 std::vector<SymmetryOperation> getSymmetryOperations()
const;
161 bool isGroup()
const;
164 void setSymmetryOperations(
const std::vector<SymmetryOperation> &symmetryOperations);
166 CoordinateSystem getCoordinateSystemFromOperations(
const std::vector<SymmetryOperation> &symmetryOperations)
const;
168 bool isClosed()
const;
169 bool hasIdentity()
const;
170 bool eachElementHasInverse()
const;
171 bool associativityHolds()
const;
181namespace GroupFactory {
185 return std::make_shared<const T>(initializationString);
191 return std::make_shared<const T>(symmetryOperations);
const std::vector< double > & rhs
Equality-functor for comparison of atom positions with specifiable precision.
AtomPositionsEqual(double precision=1.e-4)
bool operator()(const Kernel::V3D &lhs, const Kernel::V3D &rhs) const
Less-than-functor for comparison of atom positions with specifiable precision.
bool operator()(const Kernel::V3D &lhs, const Kernel::V3D &rhs) const
AtomPositionsLessThan(double precision=1.e-4)
The class Group represents a set of symmetry operations (or symmetry group).
CoordinateSystem m_axisSystem
std::vector< SymmetryOperation > m_allOperations
std::set< SymmetryOperation > m_operationSet
Crystallographic symmetry operations are composed of a rotational component, which is represented by ...
constexpr double X() const noexcept
Get x.
constexpr double Y() const noexcept
Get y.
constexpr double Z() const noexcept
Get z.
MatrixWorkspace_sptr MANTID_API_DLL operator*(const MatrixWorkspace_sptr &lhs, const MatrixWorkspace_sptr &rhs)
Multiply two workspaces.
std::unique_ptr< T > create(const P &parent, const IndexArg &indexArg, const HistArg &histArg)
This is the create() method that all the other create() methods call.
MANTID_GEOMETRY_DLL bool operator==(const Group_const_sptr &lhs, const Group_const_sptr &rhs)
Equality operator for shared pointers.
std::shared_ptr< Group > Group_sptr
MANTID_GEOMETRY_DLL Group_const_sptr operator*(const Group_const_sptr &lhs, const Group_const_sptr &rhs)
Convenience operator* for directly multiplying groups using shared pointers.
MANTID_GEOMETRY_DLL bool operator!=(const Group_const_sptr &lhs, const Group_const_sptr &rhs)
Inequality operator for shared pointers.
std::shared_ptr< const Group > Group_const_sptr
Helper class which provides the Collimation Length for SANS instruments.
constexpr bool operator==(const wide_integer< Bits, Signed > &lhs, const wide_integer< Bits2, Signed2 > &rhs)
constexpr bool operator!=(const wide_integer< Bits, Signed > &lhs, const wide_integer< Bits2, Signed2 > &rhs)