diff --git a/Code/Mantid/Framework/SINQ/CMakeLists.txt b/Code/Mantid/Framework/SINQ/CMakeLists.txt index 560e15542dbb..2bbfc3208287 100644 --- a/Code/Mantid/Framework/SINQ/CMakeLists.txt +++ b/Code/Mantid/Framework/SINQ/CMakeLists.txt @@ -24,6 +24,7 @@ set ( SRC_FILES src/PoldiUtilities/PoldiInstrumentAdapter.cpp src/PoldiUtilities/PoldiPeak.cpp src/PoldiUtilities/PoldiPeakCollection.cpp + src/PoldiUtilities/PoldiSpectrumDomainFunction.cpp src/PoldiUtilities/UncertainValue.cpp src/ProjectMD.cpp src/SINQHMListener.cpp @@ -62,6 +63,7 @@ set ( INC_FILES inc/MantidSINQ/PoldiUtilities/PoldiMockInstrumentHelpers.h inc/MantidSINQ/PoldiUtilities/PoldiPeak.h inc/MantidSINQ/PoldiUtilities/PoldiPeakCollection.h + inc/MantidSINQ/PoldiUtilities/PoldiSpectrumDomainFunction.h inc/MantidSINQ/PoldiUtilities/UncertainValue.h inc/MantidSINQ/PoldiUtilities/UncertainValueIO.h inc/MantidSINQ/ProjectMD.h diff --git a/Code/Mantid/Framework/SINQ/inc/MantidSINQ/PoldiUtilities/PoldiSpectrumDomainFunction.h b/Code/Mantid/Framework/SINQ/inc/MantidSINQ/PoldiUtilities/PoldiSpectrumDomainFunction.h new file mode 100644 index 000000000000..211e96b8ce49 --- /dev/null +++ b/Code/Mantid/Framework/SINQ/inc/MantidSINQ/PoldiUtilities/PoldiSpectrumDomainFunction.h @@ -0,0 +1,140 @@ +#ifndef MANTID_SINQ_POLDISPECTRUMDOMAINFUNCTION_H_ +#define MANTID_SINQ_POLDISPECTRUMDOMAINFUNCTION_H_ + +#include "MantidSINQ/DllConfig.h" +#include "MantidAPI/ParamFunction.h" +#include + +#include "MantidSINQ/PoldiUtilities/PoldiInstrumentAdapter.h" +#include "MantidSINQ/PoldiUtilities/PoldiSourceSpectrum.h" +#include "MantidKernel/PhysicalConstants.h" + +#include "MantidDataObjects/Workspace2D.h" + +namespace Mantid +{ +namespace Poldi +{ + +/** PoldiSpectrumDomainFunction : TODO: DESCRIPTION + + Copyright © 2014 ISIS Rutherford Appleton Laboratory & NScD Oak Ridge National Laboratory + + This file is part of Mantid. + + Mantid is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 3 of the License, or + (at your option) any later version. + + Mantid is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program. If not, see . + + File change history is stored at: + Code Documentation is available at: + */ +using namespace API; +using namespace DataObjects; + +struct DetectorElementCharacteristics { + DetectorElementCharacteristics() + { } + + DetectorElementCharacteristics(int element, PoldiAbstractDetector_sptr detector, PoldiAbstractChopper_sptr chopper) + { + distance = detector->distanceFromSample(element); + totalDistance = detector->distanceFromSample(element) + chopper->distanceFromSample(); + twoTheta = detector->twoTheta(element); + sinTheta = sin(twoTheta / 2.0); + cosTheta = cos(twoTheta / 2.0); + tof1A = 4947.990234375;//2.0 * totalDistance * sinTheta * PhysicalConstants::NeutronMass / (PhysicalConstants::h * 1e7);//4947.99013618171464192258; //063732507753820628;//4947.990; //Conversions::dtoTOF(1.0, totalDistance, sinTheta); + } + + double distance; + double totalDistance; + double twoTheta; + double sinTheta; + double cosTheta; + double tof1A; +}; + +class DetectorElementData +{ +public: + DetectorElementData(int element, DetectorElementCharacteristics center, PoldiAbstractDetector_sptr detector, PoldiAbstractChopper_sptr chopper) + { + DetectorElementCharacteristics current(element, detector, chopper); + + m_intensityFactor = pow(center.distance / current.distance, 2.0) * current.sinTheta / center.sinTheta; + m_lambdaFactor = 2.0 * current.sinTheta / center.tof1A; + m_timeFactor = current.sinTheta / center.sinTheta * current.totalDistance / center.totalDistance; + m_widthFactor = current.cosTheta - center.cosTheta; + } + + double intensityFactor() const { return m_intensityFactor; } + double lambdaFactor() const { return m_lambdaFactor; } + double timeFactor() const { return m_timeFactor; } + double widthFactor() const { return m_widthFactor; } + +protected: + double m_intensityFactor; + double m_lambdaFactor; + double m_timeFactor; + double m_widthFactor; +}; + +typedef boost::shared_ptr DetectorElementData_const_sptr; + +class MANTID_SINQ_DLL PoldiSpectrumDomainFunction : public ParamFunction +{ +public: + PoldiSpectrumDomainFunction(); + virtual ~PoldiSpectrumDomainFunction() + {} + + virtual std::string name() const { return "PoldiSpectrumDomainFunction"; } + + virtual void setWorkspace(boost::shared_ptr ws); + virtual void function(const FunctionDomain &domain, FunctionValues &values) const; + + +protected: + virtual void init(); + + double getArrivalTime(double tof); + + void initializeParametersFromWorkspace(Workspace2D_const_sptr workspace2D); + void initializeFromInstrument(PoldiAbstractDetector_sptr detector, PoldiAbstractChopper_sptr chopper); + + std::vector getChopperSlitOffsets(PoldiAbstractChopper_sptr chopper); + std::vector getDetectorElementData(PoldiAbstractDetector_sptr detector, PoldiAbstractChopper_sptr chopper); + DetectorElementCharacteristics getDetectorCenterCharacteristics(PoldiAbstractDetector_sptr detector, PoldiAbstractChopper_sptr chopper); + + double dToTOF(double d) const; + double timeTransformedWidth(double widthT, size_t detectorIndex) const; + double timeTransformedCentre(double centreT, size_t detectorIndex) const; + double timeTransformedIntensity(double areaD, double centreT, size_t detectorIndex) const; + double detectorElementIntensity(double centreT, size_t detectorIndex) const; + + double actualFunction(double x, double x0, double sigma, double area) const; + + PoldiSourceSpectrum_const_sptr m_spectrum; + DetectorElementCharacteristics m_detectorCenter; + std::vector m_detectorElementData; + + std::vector m_chopperSlitOffsets; + + double m_detectorEfficiency; + double m_deltaT; +}; + + +} // namespace Poldi +} // namespace Mantid + +#endif /* MANTID_SINQ_POLDISPECTRUMDOMAINFUNCTION_H_ */ diff --git a/Code/Mantid/Framework/SINQ/src/PoldiUtilities/PoldiSpectrumDomainFunction.cpp b/Code/Mantid/Framework/SINQ/src/PoldiUtilities/PoldiSpectrumDomainFunction.cpp new file mode 100644 index 000000000000..b17595b7ce22 --- /dev/null +++ b/Code/Mantid/Framework/SINQ/src/PoldiUtilities/PoldiSpectrumDomainFunction.cpp @@ -0,0 +1,190 @@ +#include "MantidSINQ/PoldiUtilities/PoldiSpectrumDomainFunction.h" + +#include "MantidAPI/FunctionFactory.h" +#include "MantidAPI/Workspace.h" +#include "MantidDataObjects/Workspace2D.h" +#include + +#include "MantidAPI/FunctionDomain1D.h" + +namespace Mantid +{ +namespace Poldi +{ + +using namespace DataObjects; +using namespace API; + +DECLARE_FUNCTION(PoldiSpectrumDomainFunction) + +PoldiSpectrumDomainFunction::PoldiSpectrumDomainFunction() : + ParamFunction() +{ + +} + +void PoldiSpectrumDomainFunction::initializeParametersFromWorkspace(Workspace2D_const_sptr workspace2D) +{ + PoldiInstrumentAdapter adapter(workspace2D->getInstrument(), workspace2D->run()); + initializeFromInstrument(adapter.detector(), adapter.chopper()); + + m_spectrum = boost::const_pointer_cast(adapter.spectrum()); + m_deltaT = workspace2D->readX(0)[1] - workspace2D->readX(0)[1]; +} + +void PoldiSpectrumDomainFunction::initializeFromInstrument(PoldiAbstractDetector_sptr detector, PoldiAbstractChopper_sptr chopper) +{ + m_chopperSlitOffsets = getChopperSlitOffsets(chopper); + //m_chopperCycleTime = chopper->cycleTime(); + + m_detectorCenter = getDetectorCenterCharacteristics(detector, chopper); + m_detectorElementData = getDetectorElementData(detector, chopper); + m_detectorEfficiency = 0.88; +} + +void PoldiSpectrumDomainFunction::setWorkspace(boost::shared_ptr ws) +{ + Workspace2D_const_sptr workspace2D = boost::dynamic_pointer_cast(ws); + + if(!workspace2D) { + throw std::invalid_argument("PoldiSpectrumDomainFunction can only work with Workspace2D."); + } + + initializeParametersFromWorkspace(workspace2D); +} + +void PoldiSpectrumDomainFunction::function(const FunctionDomain &domain, FunctionValues &values) const +{ + const FunctionDomain1DSpectrum &spectrumDomain = dynamic_cast(domain); + + try{ + spectrumDomain.getWorkspaceIndex(); + } catch(...) { + throw std::invalid_argument("PoldiSpectrumDomainFunction can only work with FunctionDomain1DSpectrum."); + } + + size_t index = spectrumDomain.getWorkspaceIndex(); + int domainSize = static_cast(spectrumDomain.size()); + + /* Parameters are given in d, but need to be processed in arrival time. + * This section performs the conversions. They depend on several factors + * terminated by the position in the detector, so the index is stored. + */ + double fwhm = getParameter("Fwhm"); + double fwhmT = timeTransformedWidth(dToTOF(fwhm), index); + double fwhmChannel = fwhmT / m_deltaT; + double sigmaChannel = fwhmChannel / (2.0 * sqrt(2.0 * log(2.0))); + + double centre = getParameter("Centre"); + double centreTRaw = dToTOF(centre); + double centreT = timeTransformedCentre(centreTRaw, index); + + double area = getParameter("Area"); + double areaT = timeTransformedIntensity(area, centreTRaw, index); + + /* Once all the factors are all there, the calculation needs to be + * performed with one offset per chopper slit. + */ + for(size_t o = 0; o < m_chopperSlitOffsets.size(); ++o) { + double centreTOffset = centreT + m_chopperSlitOffsets[o]; + double centreTOffsetChannel = centreTOffset / m_deltaT; + + /* Calculations are performed in channel units + * Needs to be signed integer, because the profile can extend beyond the left edge, + * which results in negative indices. Since the spectrum "wraps around" the + * indices have to be transformed to the right edge. + */ + int centreChannel = static_cast(centreTOffsetChannel); + int widthChannels = std::max(2, static_cast(fwhmChannel * 2.0)); + + for(int i = centreChannel - widthChannels; i <= centreChannel + widthChannels; ++i) { + /* Since the POLDI spectra "wrap around" on the time axis, the x-value of the + * domain can not be used, because if the profile extends to x < 0, it should appear + * at 500 - x. The same for the other side. + */ + int cleanChannel = i % domainSize; + if(cleanChannel < 0) { + cleanChannel += domainSize; + } + + double xValue = static_cast(i) + 0.5; + + /* This is a workaround for later, when "actualFunction" will be replaced with + * an arbitrary profile. + */ + values.addToCalculated(cleanChannel, actualFunction(xValue, centreTOffsetChannel, sigmaChannel, areaT)); + } + } +} + +void PoldiSpectrumDomainFunction::init() { + declareParameter("Area", 1.0); + declareParameter("Fwhm", 1.0); + declareParameter("Centre", 0.0); +} + +std::vector PoldiSpectrumDomainFunction::getChopperSlitOffsets(PoldiAbstractChopper_sptr chopper) +{ + const std::vector &chopperSlitTimes = chopper->slitTimes(); + std::vector offsets; + offsets.reserve(chopperSlitTimes.size()); + for(std::vector::const_iterator time = chopperSlitTimes.begin(); time != chopperSlitTimes.end(); ++time) { + offsets.push_back(*time + chopper->zeroOffset()); + } + + return offsets; +} + +std::vector PoldiSpectrumDomainFunction::getDetectorElementData(PoldiAbstractDetector_sptr detector, PoldiAbstractChopper_sptr chopper) +{ + std::vector data(detector->elementCount()); + + DetectorElementCharacteristics center = getDetectorCenterCharacteristics(detector, chopper); + + for(int i = 0; i < static_cast(detector->elementCount()); ++i) { + data[i] = DetectorElementData_const_sptr(new DetectorElementData(i, center, detector, chopper)); + } + + return data; +} + +DetectorElementCharacteristics PoldiSpectrumDomainFunction::getDetectorCenterCharacteristics(PoldiAbstractDetector_sptr detector, PoldiAbstractChopper_sptr chopper) +{ + return DetectorElementCharacteristics(static_cast(detector->centralElement()), detector, chopper); +} + +double PoldiSpectrumDomainFunction::dToTOF(double d) const +{ + return m_detectorCenter.tof1A * d; +} + +double PoldiSpectrumDomainFunction::timeTransformedWidth(double widthT, size_t detectorIndex) const +{ + return widthT;// + m_detectorElementData[detectorIndex]->widthFactor() * 0.0; +} + +double PoldiSpectrumDomainFunction::timeTransformedCentre(double centreT, size_t detectorIndex) const +{ + return centreT * m_detectorElementData[detectorIndex]->timeFactor(); +} + +double PoldiSpectrumDomainFunction::timeTransformedIntensity(double areaD, double centreT, size_t detectorIndex) const +{ + return areaD * detectorElementIntensity(centreT, detectorIndex); +} + +double PoldiSpectrumDomainFunction::detectorElementIntensity(double centreT, size_t detectorIndex) const +{ + double lambda = centreT * m_detectorElementData[detectorIndex]->lambdaFactor(); + double intensity = m_spectrum->intensity(lambda) * m_detectorElementData[detectorIndex]->intensityFactor(); + + return intensity * (1.0 - exp(-m_detectorEfficiency * lambda)); +} + +double PoldiSpectrumDomainFunction::actualFunction(double x, double x0, double sigma, double area) const +{ + return area / (sqrt(2.0 * M_PI) * sigma) * exp(-0.5 * pow((x - x0) / sigma, 2.0)); +} + +} // namespace Poldi +} // namespace Mantid diff --git a/Code/Mantid/Framework/SINQ/test/PoldiSpectrumDomainFunctionTest.h b/Code/Mantid/Framework/SINQ/test/PoldiSpectrumDomainFunctionTest.h new file mode 100644 index 000000000000..77e8421f3ee4 --- /dev/null +++ b/Code/Mantid/Framework/SINQ/test/PoldiSpectrumDomainFunctionTest.h @@ -0,0 +1,254 @@ +#ifndef MANTID_SINQ_POLDISPECTRUMDOMAINFUNCTIONTEST_H_ +#define MANTID_SINQ_POLDISPECTRUMDOMAINFUNCTIONTEST_H_ + +#include +#include +#include + +#include "MantidSINQ/PoldiUtilities/PoldiSpectrumDomainFunction.h" +#include "MantidSINQ/PoldiUtilities/PoldiMockInstrumentHelpers.h" +#include "MantidAPI/FunctionDomain1D.h" +#include "MantidAPI/FunctionValues.h" + +using ::testing::Return; + +using namespace Mantid::Poldi; + +class PoldiSpectrumDomainFunctionTest : public CxxTest::TestSuite +{ +public: + // This pair of boilerplate methods prevent the suite being created statically + // This means the constructor isn't called when running other tests + static PoldiSpectrumDomainFunctionTest *createSuite() { return new PoldiSpectrumDomainFunctionTest(); } + static void destroySuite( PoldiSpectrumDomainFunctionTest *suite ) { delete suite; } + + PoldiSpectrumDomainFunctionTest() + { + m_detector = boost::shared_ptr(new ConfiguredHeliumDetector); + m_chopper = boost::shared_ptr(new MockChopper); + + m_spectrum = PoldiSourceSpectrum_sptr(new ConfiguredSpectrum); + + EXPECT_CALL(*m_chopper, distanceFromSample()) + .WillRepeatedly(Return(11800.0)); + + EXPECT_CALL(*m_chopper, zeroOffset()) + .WillRepeatedly(Return(0.15)); + } + + + void testInit() + { + PoldiSpectrumDomainFunction function; + function.initialize(); + + std::vector parameterNames = function.getParameterNames(); + + TS_ASSERT_EQUALS(parameterNames[0], "Area"); + TS_ASSERT_EQUALS(parameterNames[1], "Fwhm"); + TS_ASSERT_EQUALS(parameterNames[2], "Centre"); + } + + void testDetectorCharacteristics() + { + double distance = 1996.017; + double tof1A = 4947.990234375; + double twoTheta = 1.577358; + + double sinTheta = 0.70942287322834615878; + double cosTheta = 0.70478307793280472246; + + DetectorElementCharacteristics characteristics(static_cast(m_detector->centralElement()), m_detector, m_chopper); + + TS_ASSERT_DELTA(characteristics.twoTheta, twoTheta, 1e-6); + TS_ASSERT_DELTA(characteristics.distance, distance, 1e-3); + TS_ASSERT_DELTA(characteristics.totalDistance, distance + 11800.0, 1e-3); + TS_ASSERT_DELTA(characteristics.tof1A, tof1A, 1e-4); + TS_ASSERT_DELTA(characteristics.sinTheta, sinTheta, 1e-6); + TS_ASSERT_DELTA(characteristics.cosTheta, cosTheta, 1e-6); + + TestablePoldiSpectrumDomainFunction function; + DetectorElementCharacteristics center = function.getDetectorCenterCharacteristics(m_detector, m_chopper); + + TS_ASSERT_EQUALS(characteristics.twoTheta, center.twoTheta); + TS_ASSERT_EQUALS(characteristics.distance, center.distance); + TS_ASSERT_EQUALS(characteristics.totalDistance, center.totalDistance); + TS_ASSERT_EQUALS(characteristics.tof1A, center.tof1A); + TS_ASSERT_EQUALS(characteristics.sinTheta, center.sinTheta); + TS_ASSERT_EQUALS(characteristics.cosTheta, center.cosTheta); + } + + void testDetectorFactors() + { + DetectorElementCharacteristics center(static_cast(m_detector->centralElement()), m_detector, m_chopper); + + DetectorElementData data(102, center, m_detector, m_chopper); + + TS_ASSERT_DELTA(data.intensityFactor(), 1.010685, 1e-6); + //TS_ASSERT_DELTA(data.lambdaFactor(), 2.6941614e-4, 1e-11); + TS_ASSERT_DELTA(data.timeFactor(), 0.9346730, 1e-7); + } + + void testChopperSlitOffsets() + { + TestablePoldiSpectrumDomainFunction function; + + std::vector offsets = function.getChopperSlitOffsets(m_chopper); + + for(size_t i = 0; i < offsets.size(); ++i) { + TS_ASSERT_EQUALS(offsets[i], m_chopper->slitTimes()[i] + m_chopper->zeroOffset()); + } + } + + void testGetDetectorElementData() + { + TestablePoldiSpectrumDomainFunction function; + std::vector elements = function.getDetectorElementData(m_detector, m_chopper); + DetectorElementCharacteristics center = function.getDetectorCenterCharacteristics(m_detector, m_chopper); + + DetectorElementData data(102, center, m_detector, m_chopper); + + TS_ASSERT_EQUALS(data.intensityFactor(), elements[102]->intensityFactor()); + //TS_ASSERT_DELTA(data.lambdaFactor(), 2.6941614e-4, 1e-11); + //TS_ASSERT_DELTA(data.timeFactor(), 0.9346730, 1e-7); + } + + void testInitializeFromInstrument() + { + TestablePoldiSpectrumDomainFunction function; + function.initializeFromInstrument(m_detector, m_chopper); + + TS_ASSERT_EQUALS(function.m_chopperSlitOffsets.size(), m_chopper->slitPositions().size()); + TS_ASSERT_EQUALS(function.m_detectorCenter.twoTheta, m_detector->twoTheta(static_cast(m_detector->centralElement()))); + TS_ASSERT_EQUALS(function.m_detectorElementData.size(), m_detector->elementCount()); + } + + void testTimeTransformedWidth() + { + /* Values from existing analysis software */ + double fwhm = 0.0027446316797104233; + double deltaT = 3.0; + + TestablePoldiSpectrumDomainFunction function; + function.initializeFromInstrument(m_detector, m_chopper); + //double fwhmT = function.dToTOF(fwhm); + double fwhmT = fwhm * 4947.990; + + TS_ASSERT_DELTA(function.timeTransformedWidth(fwhmT, 342) / deltaT, 4.526804, 1e-5); + } + + void testTimeTransformedCentre() + { + double centre = 1.10864434901480127601; + + TestablePoldiSpectrumDomainFunction function; + function.initializeFromInstrument(m_detector, m_chopper); + double centreT = function.dToTOF(centre); + //double centreT = centre * 4947.990; + + TS_ASSERT_DELTA(function.timeTransformedCentre(centreT, 342), 5964.820800781, 1e-3); + } + + void testTimeTransformedIntensity() + { + double centre = 1.10864434901480127601; + double areaD = 1.985481; + + TestablePoldiSpectrumDomainFunction function; + function.m_spectrum = m_spectrum; + function.initializeFromInstrument(m_detector, m_chopper); + function.m_detectorEfficiency = 0.88; + double centreT = function.dToTOF(centre); + //double centreT = centre * 4947.990; + TS_ASSERT_DELTA(function.timeTransformedIntensity(areaD, centreT, 342), 4.611182, 1e-5); + } + + void testActualFunction() + { + /* comparison with results from a math program */ + double area = 1.0; + double sigma = 1.0; + double x0 = 0.0; + + std::vector reference; + reference.push_back(0.388349126567583); + reference.push_back(0.398942280401433); + reference.push_back(0.359646701831886); + reference.push_back(0.004431848411938); + + TestablePoldiSpectrumDomainFunction function; + + std::vector x; + x.push_back(-0.232); + x.push_back(0.0); + x.push_back(0.4554); + x.push_back(3.0); + + for(size_t i = 0; i < x.size(); ++i) { + TS_ASSERT_DELTA(function.actualFunction(x[i], x0, sigma, area), reference[i], 1e-15); + } + } + + void testFunction() + { + TestablePoldiSpectrumDomainFunction function; + function.initialize(); + function.setParameter("Area", 1.9854805); + function.setParameter("Fwhm", 0.0027446316797104233); + //function.setParameter("Centre", 1.10864434901480127601); + function.setParameter("Centre", 1.1086444);//(2.0 * M_PI) / 5.667449);//1.10864434901480127601); + + function.initializeFromInstrument(m_detector, m_chopper); + function.m_deltaT = 3.0; + function.m_spectrum = m_spectrum; + + std::vector xvalues(500, 1.0); + + FunctionDomain1DSpectrum domain(342, xvalues); + TS_ASSERT_EQUALS(domain.getWorkspaceIndex(), 342); + FunctionValues values(domain); + values.setCalculated(0.0); + + function.function(domain, values); + + std::vector reference; + reference.push_back(2.5469337E-05); + reference.push_back(2.4222479E-04); + reference.push_back(1.7575109E-03); + reference.push_back(9.7287362E-03); + reference.push_back(4.1085955E-02); + reference.push_back(0.1323760); + reference.push_back(0.3253897); + reference.push_back(0.6102068); + reference.push_back(0.8730301); + reference.push_back(0.9529279); + reference.push_back(0.7935416); + reference.push_back(0.5041480); + reference.push_back(0.2443572); + reference.push_back(9.0358935E-02); + reference.push_back(2.5491528E-02); + reference.push_back(5.4865498E-03); + reference.push_back(9.0091029E-04); + reference.push_back(1.1286059E-04); + reference.push_back(1.0786535E-05); + + for(size_t i = 0; i < reference.size(); ++i) { + TS_ASSERT_DELTA(values[479 + i], reference[i], 9e-5); + } + } + +private: + class TestablePoldiSpectrumDomainFunction : PoldiSpectrumDomainFunction + { + friend class PoldiSpectrumDomainFunctionTest; + + TestablePoldiSpectrumDomainFunction() : PoldiSpectrumDomainFunction() {} + }; + + boost::shared_ptr m_detector; + boost::shared_ptr m_chopper; + PoldiSourceSpectrum_sptr m_spectrum; +}; + + +#endif /* MANTID_SINQ_POLDISPECTRUMDOMAINFUNCTIONTEST_H_ */