STAR
Cal STAR — firmware, DAQ server, and engine design
Loading...
Searching...
No Matches
CubicFit Struct Reference

Result of a least-squares polynomial fit over a channel's captured points. More...

#include <CubicCalibrationStore.hpp>

Collaboration diagram for CubicFit:
[legend]

Public Attributes

bool valid = false
double A = 0.0
double B = 0.0
double C = 0.0
double D = 0.0
std::vector< double > poly
double norm_min = 0.0
double norm_scale = 1.0
double rmse = 0.0
int degree = 0

Detailed Description

Result of a least-squares polynomial fit over a channel's captured points.

Two equivalent representations are kept:

  • raw cubic psi = A*adc^3 + B*adc^2 + C*adc + D (consumed by PTCalibrationCoeffs, raw int32)
  • normalized psi = sum poly[i] * ((adc - norm_min)/norm_scale)^i (well-conditioned; TS side) The normalized form is what the frontend evaluates and what passes the backend's coefficient validator (which rejects |A| > 1e-11 on a raw-ADC cubic).

Definition at line 29 of file CubicCalibrationStore.hpp.

Member Data Documentation

◆ A

Definition at line 31 of file CubicCalibrationStore.hpp.

◆ B

Definition at line 31 of file CubicCalibrationStore.hpp.

◆ C

Definition at line 31 of file CubicCalibrationStore.hpp.

◆ D

Definition at line 31 of file CubicCalibrationStore.hpp.

◆ degree

◆ norm_min

Definition at line 33 of file CubicCalibrationStore.hpp.

◆ norm_scale

Definition at line 34 of file CubicCalibrationStore.hpp.

◆ poly

std::vector<double> fsw::calibration::CubicFit::poly

Definition at line 32 of file CubicCalibrationStore.hpp.

◆ rmse

Definition at line 35 of file CubicCalibrationStore.hpp.

◆ valid

Definition at line 30 of file CubicCalibrationStore.hpp.


The documentation for this struct was generated from the following file: