Mantid
Loading...
Searching...
No Matches
SCDPanelErrors.h
Go to the documentation of this file.
1// Mantid Repository : https://github.com/mantidproject/mantid
2//
3// Copyright © 2007 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//----------------------------------------------------------------------
15#include "MantidCrystal/DllConfig.h"
16#include "MantidKernel/System.h"
17#include <cmath>
18
19namespace Mantid {
20namespace Crystal {
21/*
22@author Vickie Lynch, SNS
23@date 7/25/2016
24*/
25class MANTID_CRYSTAL_DLL SCDPanelErrors : public API::ParamFunction, public API::IFunction1D {
26public:
29
31 std::string name() const override { return "SCDPanelErrors"; }
32 const std::string category() const override { return "General"; }
33 void function1D(double *out, const double *xValues, const size_t nData) const override;
35 void functionDeriv1D(API::Jacobian *out, const double *xValues, const size_t nData) override;
36
38 void setAttribute(const std::string &attName, const IFunction::Attribute &value) override;
39
41 void moveDetector(double x, double y, double z, double rotx, double roty, double rotz, double scalex, double scaley,
42 std::string detname, const API::Workspace_sptr &inputW) const;
43
44private:
46 void load(const std::string &fname);
47
49 void loadWorkspace(const std::string &wsName) const;
50
52 void loadWorkspace(std::shared_ptr<API::Workspace> ws) const;
53
55 void clear() const;
56
58 void eval(double xshift, double yshift, double zshift, double xrotate, double yrotate, double zrotate, double scalex,
59 double scaley, double *out, const double *xValues, const size_t nData, double tShift) const;
60
62 void setupData() const;
63
65 static const int defaultIndexValue;
66
68 mutable std::shared_ptr<API::Workspace> m_workspace;
69
71 mutable std::string m_bank;
72
74 mutable bool m_setupFinished;
75};
76
77} // namespace Crystal
78} // namespace Mantid
double value
The value of the point.
Definition: FitMW.cpp:51
This is a specialization of IFunction for functions of one real argument.
Definition: IFunction1D.h:43
Attribute is a non-fitting parameter.
Definition: IFunction.h:282
Represents the Jacobian in IFitFunction::functionDeriv.
Definition: Jacobian.h:22
Implements the part of IFunction interface dealing with parameters.
Definition: ParamFunction.h:33
std::string m_bank
Stores bank.
static const int defaultIndexValue
The default value for the workspace index.
std::shared_ptr< API::Workspace > m_workspace
Temporary workspace holder.
const std::string category() const override
The categories the Fit function belong to.
bool m_setupFinished
Flag of completing data setup.
std::string name() const override
overwrite IFunction base class methods
std::shared_ptr< Workspace > Workspace_sptr
shared pointer to Mantid::API::Workspace
Definition: Workspace_fwd.h:20
Helper class which provides the Collimation Length for SANS instruments.
adjust instrument component position and orientation
: detector size scale at y-direction