Mantid
Loading...
Searching...
No Matches
FractionalRebinning.h
Go to the documentation of this file.
1// Mantid Repository : https://github.com/mantidproject/mantid
2//
3// Copyright © 2011 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
9//------------------------------------------------------------------------------
10// Includes
11//------------------------------------------------------------------------------
12#include "MantidDataObjects/DllConfig.h"
15
16#include <span>
17
18namespace Mantid {
19//------------------------------------------------------------------------------
20// Forward declarations
21//------------------------------------------------------------------------------
22namespace API {
23class Progress;
24}
25namespace Geometry {
26class ConvexPolygon;
27}
28
29namespace DataObjects {
30
36namespace FractionalRebinning {
37
41MANTID_DATAOBJECTS_DLL bool getIntersectionRegion(std::span<double const> xAxis, std::span<double const> verticalAxis,
42 const Geometry::Quadrilateral &inputQ, size_t &qstart, size_t &qend,
43 size_t &x_start, size_t &x_end);
44
46MANTID_DATAOBJECTS_DLL void normaliseOutput(const API::MatrixWorkspace_sptr &outputWS,
48 API::Progress *progress = nullptr);
49
51MANTID_DATAOBJECTS_DLL void rebinToOutput(const Geometry::Quadrilateral &inputQ,
52 const API::MatrixWorkspace_const_sptr &inputWS, const size_t i,
53 const size_t j, API::MatrixWorkspace &outputWS,
54 std::span<double const> verticalAxis);
55
57MANTID_DATAOBJECTS_DLL void rebinToFractionalOutput(const Geometry::Quadrilateral &inputQ,
58 const API::MatrixWorkspace_const_sptr &inputWS, const size_t i,
59 const size_t j, DataObjects::RebinnedOutput &outputWS,
60 std::span<double const> verticalAxis,
61 const DataObjects::RebinnedOutput_const_sptr &inputRB = nullptr);
62
64MANTID_DATAOBJECTS_DLL void finalizeFractionalRebin(DataObjects::RebinnedOutput &outputWS);
65
66} // namespace FractionalRebinning
67
68} // namespace DataObjects
69} // namespace Mantid
Base MatrixWorkspace Abstract Class.
Helper class for reporting progress from algorithms.
Definition Progress.h:25
A ConvexPolygon with only 4 vertices.
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
MANTID_DATAOBJECTS_DLL void normaliseOutput(const API::MatrixWorkspace_sptr &outputWS, const API::MatrixWorkspace_const_sptr &inputWS, API::Progress *progress=nullptr)
Compute sqrt of errors and put back in bin width division if necessary.
MANTID_DATAOBJECTS_DLL void rebinToFractionalOutput(const Geometry::Quadrilateral &inputQ, const API::MatrixWorkspace_const_sptr &inputWS, const size_t i, const size_t j, DataObjects::RebinnedOutput &outputWS, std::span< double const > verticalAxis, const DataObjects::RebinnedOutput_const_sptr &inputRB=nullptr)
Rebin the input quadrilateral to to output grid.
MANTID_DATAOBJECTS_DLL bool getIntersectionRegion(std::span< double const > xAxis, std::span< double const > verticalAxis, const Geometry::Quadrilateral &inputQ, size_t &qstart, size_t &qend, size_t &x_start, size_t &x_end)
Find the intersect region on the output grid.
MANTID_DATAOBJECTS_DLL void rebinToOutput(const Geometry::Quadrilateral &inputQ, const API::MatrixWorkspace_const_sptr &inputWS, const size_t i, const size_t j, API::MatrixWorkspace &outputWS, std::span< double const > verticalAxis)
Rebin the input quadrilateral to to output grid.
MANTID_DATAOBJECTS_DLL void finalizeFractionalRebin(DataObjects::RebinnedOutput &outputWS)
Set finalize flag after fractional rebinning loop.
std::shared_ptr< const RebinnedOutput > RebinnedOutput_const_sptr
shared pointer to a const RebinnedOutput
Definition SumSpectra.h:24
Helper class which provides the Collimation Length for SANS instruments.