Mantid
Loading...
Searching...
No Matches
ConvertToDiffractionMDWorkspace.h
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 +
7#pragma once
8
15#include "MantidKernel/V3D.h"
16#include "MantidMDAlgorithms/DllConfig.h"
17
18namespace Mantid {
19namespace MDAlgorithms {
20
29public:
31
33 const std::string name() const override { return "ConvertToDiffractionMDWorkspace"; };
35 const std::string summary() const override {
36 return "Create a MDEventWorkspace with events in reciprocal space (Qx, Qy, "
37 "Qz) for an elastic diffraction experiment.";
38 }
39
41 int version() const override { return 1; }
43 const std::string category() const override { return "MDAlgorithms\\Creation"; }
44
45private:
46 void init() override;
47 void exec() override;
48
49 template <class T>
50 void convertEventList(int workspaceIndex, const API::SpectrumInfo &specInfo, DataObjects::EventList &el);
51
52 void convertSpectrum(const API::SpectrumInfo &specInfo, int workspaceIndex);
53
56
59
67 bool Append;
73 double l1;
85 std::shared_ptr<Kernel::ProgressBase> prog;
89
94};
95
96} // namespace MDAlgorithms
97} // namespace Mantid
An abstract algorithm sub-class for algorithms that define properties for BoxController settings.
API::SpectrumInfo is an intermediate step towards a SpectrumInfo that is part of Instrument-2....
Definition: SpectrumInfo.h:53
A class for holding :
Definition: EventList.h:56
std::shared_ptr< MDEventWorkspace< MDE, nd > > sptr
Typedef for a shared pointer of this kind of event workspace.
Numerical Matrix class.
Definition: Matrix.h:42
Class for 3D vectors.
Definition: V3D.h:34
ConvertToDiffractionMDWorkspace : Create a MDEventWorkspace with events in reciprocal space (Qx,...
DataObjects::EventWorkspace_sptr m_inEventWS
The input event workspace.
double beamline_norm
Path length between source and sample.
coord_t * m_extentsMax
Maximum extents of the workspace. Cached for speed.
const std::string category() const override
Algorithm's category for identification.
const std::string name() const override
Algorithm's name for identification.
bool ClearInputWorkspace
Do we clear events on the input during loading?
size_t failedDetectorLookupCount
Path length between source and sample.
API::MatrixWorkspace_sptr m_inWS
The input MatrixWorkspace.
detid2det_map allDetectors
Map of all the detectors in the instrument.
DataObjects::MDEventWorkspace3Lean::sptr ws
The output MDEventWorkspace<3>
const std::string summary() const override
Summary of algorithms purpose.
int version() const override
Algorithm's version for identification.
std::shared_ptr< Kernel::ProgressBase > prog
Progress reporter (shared)
coord_t * m_extentsMin
Minimum extents of the workspace. Cached for speed.
bool OneEventPerBin
Use the histogram representation with one event per bin.
std::shared_ptr< MatrixWorkspace > MatrixWorkspace_sptr
shared pointer to the matrix workspace base class
std::shared_ptr< EventWorkspace > EventWorkspace_sptr
shared pointer to the EventWorkspace class
Helper class which provides the Collimation Length for SANS instruments.
float coord_t
Typedef for the data type to use for coordinate axes in MD objects such as MDBox, MDEventWorkspace,...
Definition: MDTypes.h:27
std::map< detid_t, Geometry::IDetector_const_sptr > detid2det_map
Typedef of a map from detector ID to detector shared pointer.
Definition: Instrument.h:27