38 lines
1.5 KiB
C++
38 lines
1.5 KiB
C++
// SPDX-FileCopyrightText: 2024 Filip Leonarski, Paul Scherrer Institute <filip.leonarski@psi.ch>
|
|
// SPDX-License-Identifier: GPL-3.0-only
|
|
|
|
#ifndef JFJOCH_AZIMUTHALINTEGRATIONSETTINGS_H
|
|
#define JFJOCH_AZIMUTHALINTEGRATIONSETTINGS_H
|
|
|
|
#include <optional>
|
|
#include <cstdint>
|
|
|
|
class AzimuthalIntegrationSettings {
|
|
bool solid_angle_correction = true;
|
|
float high_q_recipA = 5.0;
|
|
float low_q_recipA = 0.1;
|
|
float bkg_estimate_high_q_recipA = 2.0f * M_PI / 3.0;
|
|
float bkg_estimate_low_q_recipA = 2.0f * M_PI / 5.0;
|
|
float q_spacing = 0.05;
|
|
std::optional<float> polarization_factor;
|
|
public:
|
|
AzimuthalIntegrationSettings& SolidAngleCorrection(bool input);
|
|
AzimuthalIntegrationSettings& PolarizationFactor(const std::optional<float> &input);
|
|
AzimuthalIntegrationSettings& QRange_recipA(float low, float high);
|
|
AzimuthalIntegrationSettings& QSpacing_recipA(float input);
|
|
AzimuthalIntegrationSettings& BkgEstimateQRange_recipA(float low, float high);
|
|
|
|
[[nodiscard]] bool IsSolidAngleCorrection() const;
|
|
[[nodiscard]] std::optional<float> GetPolarizationFactor() const;
|
|
[[nodiscard]] float GetHighQ_recipA() const;
|
|
[[nodiscard]] float GetLowQ_recipA() const;
|
|
[[nodiscard]] float GetQSpacing_recipA() const;
|
|
[[nodiscard]] float GetBinNumber() const;
|
|
[[nodiscard]] float GetBkgEstimateLowQ_recipA() const;
|
|
[[nodiscard]] float GetBkgEstimateHighQ_recipA() const;
|
|
[[nodiscard]] uint16_t QToBin(float q) const;
|
|
};
|
|
|
|
|
|
#endif //JFJOCH_AZIMUTHALINTEGRATIONSETTINGS_H
|