Mantid
Loading...
Searching...
No Matches
PeakTransformHKL.cpp
Go to the documentation of this file.
1// Mantid Repository : https://github.com/mantidproject/mantid
2//
3// Copyright © 2018 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 +
8#include <memory>
9
10using boost::regex;
11
12namespace Mantid::Geometry {
13
15 : PeakTransform("H", "K", regex("^(H.*)|(\\[H,0,0\\].*)$"), regex("^(K.*)|(\\[0,K,0\\].*)$"),
16 regex("^(L.*)|(\\[0,0,L\\].*)$")) {}
17
18PeakTransformHKL::PeakTransformHKL(const std::string &xPlotLabel, const std::string &yPlotLabel)
19 : PeakTransform(xPlotLabel, yPlotLabel, regex("^(H.*)|(\\[H,0,0\\].*)$"), regex("^(K.*)|(\\[0,K,0\\].*)$"),
20 regex("^(L.*)|(\\[0,0,L\\].*)$")) {}
21
25PeakTransform_sptr PeakTransformHKL::clone() const { return std::make_shared<PeakTransformHKL>(*this); }
26
32 return PeakTransform::transform(peak.getHKL());
33}
34
39} // namespace Mantid::Geometry
Structure describing a single-crystal peak.
Definition: IPeak.h:26
virtual Mantid::Kernel::V3D getHKL() const =0
PeakTransform_sptr clone() const override
Virtual constructor.
Mantid::Kernel::SpecialCoordinateSystem getCoordinateSystem() const override
Getter for the special coordinate representation of this transform type.
Mantid::Kernel::V3D transformPeak(const Mantid::Geometry::IPeak &peak) const override
Transform peak.
Used to remap coordinates into a form consistent with an axis reordering.
Definition: PeakTransform.h:21
virtual Mantid::Kernel::V3D transform(const Mantid::Kernel::V3D &original) const
Perform Transform.
Class for 3D vectors.
Definition: V3D.h:34
std::shared_ptr< PeakTransform > PeakTransform_sptr
Typedef for a PeakTransform wrapped in a shared_pointer.
Definition: PeakTransform.h:59
SpecialCoordinateSystem
Special coordinate systems for Q3D.