Google OR-Tools v9.11
a fast and portable software suite for combinatorial optimization
|
#include <accurate_sum.h>
Public Member Functions | |
AccurateSum () | |
You may copy-construct an AccurateSum. | |
void | Add (const FpNumber &value) |
Adds an FpNumber to the sum. | |
FpNumber | Value () const |
Gets the value of the sum. | |
Kahan summation compensation algorithm.
http://en.wikipedia.org/wiki/Kahan_summation_algorithm
Definition at line 23 of file accurate_sum.h.
|
inline |
You may copy-construct an AccurateSum.
Definition at line 26 of file accurate_sum.h.
|
inline |
Adds an FpNumber to the sum.
Definition at line 29 of file accurate_sum.h.
|
inline |
Gets the value of the sum.
Definition at line 37 of file accurate_sum.h.