53 real_t r_max, std::optional<real_t> number_density = std::nullopt,
54 bool is_radial =
false);
66 [[nodiscard]]
static std::optional<PeakIntegralResult>
68 real_t target_x, std::optional<real_t> number_density = std::nullopt,
69 bool is_radial =
false);
82 std::span<const real_t> y_vals, std::size_t peak_idx,
83 std::size_t min_idx, std::size_t max_idx)
noexcept;
Floating point precision type definitions for Correlation.
High-performance numerical integration and automated peak feature detection.
Definition PeakIntegrationService.hpp:38
static real_t calculateFWHM(std::span< const real_t > x_bins, std::span< const real_t > y_vals, std::size_t peak_idx, std::size_t min_idx, std::size_t max_idx) noexcept
Calculates Full Width at Half Maximum (FWHM) around a identified peak index.
Definition PeakIntegrationService.cpp:66
static std::optional< PeakIntegralResult > autoDetectPeakNear(std::span< const real_t > x_bins, std::span< const real_t > y_vals, real_t target_x, std::optional< real_t > number_density=std::nullopt, bool is_radial=false)
Detects the nearest peak maximum to a clicked coordinate and integrates its shell.
Definition PeakIntegrationService.cpp:160
static PeakIntegralResult integrateRange(std::span< const real_t > x_bins, std::span< const real_t > y_vals, real_t r_min, real_t r_max, std::optional< real_t > number_density=std::nullopt, bool is_radial=false)
Numerically integrates a distribution across a specified domain range.
Definition PeakIntegrationService.cpp:96
Definition AnalysisTypes.hpp:11
double real_t
Definition Precision.hpp:18
Quantitative metrics resulting from peak detection and integration.
Definition PeakIntegrationService.hpp:23
std::optional< real_t > coordination_number
4πρ ∫ r² g(r) dr for radial distributions.
Definition PeakIntegrationService.hpp:29
real_t r_max
Upper integration boundary (Å or unit).
Definition PeakIntegrationService.hpp:26
real_t fwhm
Full width at half maximum.
Definition PeakIntegrationService.hpp:30
real_t r_peak
Coordinate of peak maximum (Å or unit).
Definition PeakIntegrationService.hpp:24
real_t centroid
Weighted center of mass: ∫ x y(x) dx / ∫ y(x) dx.
Definition PeakIntegrationService.hpp:31
real_t peak_height
Amplitude/intensity at peak maximum.
Definition PeakIntegrationService.hpp:27
real_t r_min
Lower integration boundary (Å or unit).
Definition PeakIntegrationService.hpp:25
real_t area
Standard trapezoidal integral: ∫ y(x) dx.
Definition PeakIntegrationService.hpp:28