File indexing completed on 2024-09-10 02:58:37
0001 #ifndef _COMMONDET_MEASUREMENT1DFLOAT_H_
0002 #define _COMMONDET_MEASUREMENT1DFLOAT_H_
0003
0004
0005
0006
0007
0008
0009 class Measurement1DFloat {
0010 public:
0011
0012
0013 Measurement1DFloat() : theValue(0.), theError(0.) {}
0014
0015 Measurement1DFloat(const float& aValue) : theValue(aValue), theError(0.) {}
0016
0017 Measurement1DFloat(const float& aValue, const float& aError) : theValue(aValue), theError(aError) {}
0018
0019
0020
0021 ~Measurement1DFloat() {}
0022
0023 float value() const { return theValue; }
0024
0025 float error() const { return theError; }
0026
0027 float significance() const {
0028 if (theError == 0)
0029 return 0;
0030 else
0031 return theValue / theError;
0032 }
0033
0034 private:
0035 float theValue;
0036 float theError;
0037 };
0038
0039 #endif