Mantid
Loading...
Searching...
No Matches
CrystalFieldPeakUtils.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#include <string>
9#include <vector>
10
11namespace Mantid {
12
13namespace API {
14class CompositeFunction;
15class FunctionValues;
16class IPeakFunction;
17} // namespace API
18
19namespace CurveFitting {
20namespace Functions {
21namespace CrystalFieldUtils {
25size_t buildSpectrumFunction(API::CompositeFunction &spectrum, const std::string &peakShape,
26 const API::FunctionValues &centresAndIntensities, const std::vector<double> &xVec,
27 const std::vector<double> &yVec, double fwhmVariation, double defaultFWHM,
28 size_t nRequiredPeaks, bool fixAllPeaks);
29size_t updateSpectrumFunction(API::CompositeFunction &spectrum, const std::string &peakShape,
30 const API::FunctionValues &centresAndIntensities, size_t iFirst,
31 const std::vector<double> &xVec, const std::vector<double> &yVec, double fwhmVariation,
32 double defaultFWHM, bool fixAllPeaks);
33size_t calculateNPeaks(const API::FunctionValues &centresAndIntensities);
34size_t calculateMaxNPeaks(size_t nPeaks);
35
36} // namespace CrystalFieldUtils
37} // namespace Functions
38} // namespace CurveFitting
39} // namespace Mantid
A composite function is a function containing other functions.
A class to store values calculated by a function.
size_t calculateMaxNPeaks(size_t nPeaks)
Calculate the maximum number of peaks a spectrum can have.
size_t updateSpectrumFunction(API::CompositeFunction &spectrum, const std::string &peakShape, const API::FunctionValues &centresAndIntensities, size_t iFirst, const std::vector< double > &xVec, const std::vector< double > &yVec, double fwhmVariation, double defaultFWHM, bool fixAllPeaks)
Update the peaks parameters after recalculationof the crystal field.
size_t calculateNPeaks(const API::FunctionValues &centresAndIntensities)
Calculate the number of visible peaks.
size_t buildSpectrumFunction(API::CompositeFunction &spectrum, const std::string &peakShape, const API::FunctionValues &centresAndIntensities, const std::vector< double > &xVec, const std::vector< double > &yVec, double fwhmVariation, double defaultFWHM, size_t nRequiredPeaks, bool fixAllPeaks)
Utility functions to help set up peak functions in a Crystal Field spectrum.
Helper class which provides the Collimation Length for SANS instruments.