Methods
kahan_sum(summands) → {number}
Numerical stable summation with the Kahan summation algorithm.
Parameters:
Name | Type | Description |
---|---|---|
summands | Array | Array of values to sum up. |
- Source
Returns:
The sum.
- Type:
- number
neumair_sum(summands) → {Number}
Numerical stable summation with the Neumair summation algorithm.
Parameters:
Name | Type | Description |
---|---|---|
summands | Array.<Number> | Array of values to sum up. |
- Source
Returns:
The sum.
- Type:
- Number