Mantid
Loading...
Searching...
No Matches
CorrectTOFAxis.h
Go to the documentation of this file.
1// Mantid Repository : https://github.com/mantidproject/mantid
2//
3// Copyright © 2016 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
12#include "MantidAlgorithms/DllConfig.h"
13
14#include <vector>
15
16namespace Mantid {
17namespace API {
18class SpectrumInfo;
19}
20
21namespace Algorithms {
22
26class MANTID_ALGORITHMS_DLL CorrectTOFAxis final : public API::Algorithm {
27public:
28 const std::string name() const override;
29 int version() const override;
30 const std::vector<std::string> seeAlso() const override { return {"ConvertToConstantL2"}; }
31 const std::string category() const override;
32 const std::string summary() const override;
33
34private:
39 std::vector<size_t> m_workspaceIndices;
40
41 void init() override;
42 std::map<std::string, std::string> validateInputs() override;
43 void exec() override;
44 void useReferenceWorkspace(const API::MatrixWorkspace_sptr &outputWs);
45 void correctManually(const API::MatrixWorkspace_sptr &outputWs);
46 double averageL2(const API::SpectrumInfo &spectrumInfo);
47 void averageL2AndEPP(const API::SpectrumInfo &spectrumInfo, double &l2Average, double &eppAverage);
48 std::vector<size_t> referenceWorkspaceIndices() const;
49};
50
51} // namespace Algorithms
52} // namespace Mantid
Base class from which all concrete algorithm classes should be derived.
Definition: Algorithm.h:85
API::SpectrumInfo is an intermediate step towards a SpectrumInfo that is part of Instrument-2....
Definition: SpectrumInfo.h:53
CorrectTOFAxis : Corrects the time-of-flight axis with regards to the incident energy and the L1+L2 d...
std::vector< size_t > m_workspaceIndices
API::MatrixWorkspace_const_sptr m_referenceWs
API::MatrixWorkspace_const_sptr m_inputWs
API::ITableWorkspace_const_sptr m_eppTable
const std::vector< std::string > seeAlso() const override
Function to return all of the seeAlso algorithms related to this algorithm.
std::shared_ptr< const ITableWorkspace > ITableWorkspace_const_sptr
shared pointer to Mantid::API::ITableWorkspace (const version)
std::shared_ptr< const MatrixWorkspace > MatrixWorkspace_const_sptr
shared pointer to the matrix workspace base class (const version)
std::shared_ptr< MatrixWorkspace > MatrixWorkspace_sptr
shared pointer to the matrix workspace base class
Helper class which provides the Collimation Length for SANS instruments.