11#include "MantidAlgorithms/DllConfig.h"
13#include <boost/tuple/tuple.hpp>
23 const std::string
name()
const override {
return "Stitch1D"; }
25 int version()
const override {
return 3; }
27 const std::string
category()
const override {
return "Reflectometry"; }
29 const std::string
summary()
const override {
return "Stitches single histogram matrix workspaces together"; }
30 const std::vector<std::string>
seeAlso()
const override {
return {
"Rebin",
"Stitch1DMany"}; }
34 std::map<std::string, std::string> validateInputs()
override;
45 double getStartOverlap(
const double intesectionMin,
const double intesectionMax)
const;
47 double getEndOverlap(
const double intesectionMin,
const double intesectionMax)
const;
65 boost::tuple<int, int> findStartEndIndexes(
double startOverlap,
double endOverlap,
IPeaksWorkspace_sptr workspace
Base class from which all concrete algorithm classes should be derived.
Stitch1D : Stitches two Matrix Workspaces together into a single output.
SpecialTypeIndexes m_infEIndexes
Index per workspace spectra of Infs.
const std::string summary() const override
Summary of algorithm's purpose.
SpecialTypeIndexes m_nanYIndexes
const std::vector< std::string > seeAlso() const override
Function to return all of the seeAlso algorithms related to this algorithm.
std::vector< std::vector< size_t > > SpecialTypeIndexes
Helper typedef.
const std::string name() const override
Algorithm's name for identification.
double m_errorScaleFactor
Mantid::API::MatrixWorkspace_sptr singleValueWS(const double val)
const std::string category() const override
Algorithm's category for identification.
int version() const override
Algorithm's version for identification.
SpecialTypeIndexes m_nanEIndexes
Index per workspace spectra of Nans.
SpecialTypeIndexes m_infYIndexes
SpecialTypeIndexes m_nanDxIndexes
double m_scaleFactor
Scaling factors.
static const double range_tolerance
Range tolerance.
SpecialTypeIndexes m_infDxIndexes
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
void MANTID_KERNEL_DLL rebin(const std::vector< double > &xold, const std::vector< double > &yold, const std::vector< double > &eold, const std::vector< double > &xnew, std::vector< double > &ynew, std::vector< double > &enew, bool distribution, bool addition=false)
Rebins data according to a new output X array.
Helper class which provides the Collimation Length for SANS instruments.