10#include "MantidAlgorithms/DllConfig.h"
13namespace HistogramData {
41 const std::string
name()
const override {
return "CalculateFlatBackground"; }
43 const std::string
summary()
const override {
return "Finds a constant background value of each desired histogram."; }
46 int version()
const override {
return (1); }
48 const std::string
category()
const override {
return "SANS;CorrectionFunctions\\BackgroundCorrections"; }
58 void checkRange(
double &startX,
double &endX);
59 void Mean(
const HistogramData::Histogram &histogram,
double &background,
double &variance,
const double startX,
60 const double endX)
const;
61 void LinearFit(
const HistogramData::Histogram &histogram,
double &background,
double &variance,
const double startX,
63 void MovingAverage(
const HistogramData::Histogram &histogram,
double &background,
double &variance,
64 const size_t windowWidth)
const;
67 std::unique_ptr<API::Progress> m_progress =
nullptr;
IPeaksWorkspace_sptr workspace
Base class for algorithms that can run in parallel on all MPI ranks but not in a distributed fashion.
Finds a constant background value of each desired spectrum and optionally subtracts that value from t...
const std::string name() const override
Algorithm's name.
const std::string summary() const override
Summary of algorithms purpose.
void convertToDistribution(API::MatrixWorkspace_sptr workspace)
int version() const override
Algorithm's version.
const std::string category() const override
Algorithm's category for identification.
void restoreDistributionState(API::MatrixWorkspace_sptr workspace)
std::shared_ptr< MatrixWorkspace > MatrixWorkspace_sptr
shared pointer to the matrix workspace base class
Helper class which provides the Collimation Length for SANS instruments.