organization of std.numeric
Ilya Yaroshenko via Digitalmars-d
digitalmars-d at puremagic.com
Sun Sep 14 11:30:15 PDT 2014
Hello!
Abstract:
0. http://forum.dlang.org/post/luknet$o2h$1@digitalmars.com
1. I have made PR
https://github.com/D-Programming-Language/phobos/pull/2513
with full precision summation function fsum.
The Precise (full precision), Naive, Reverse, Pairwise, Kahan,
KBN and KB2 summation algorithms are available for floating point
numbers and std.complex.Complex.
Naive, Reverse, Pairwise and Kahan algorithms also available for
user defined types.
fsum works with dmd 64-bit and LDC both 64-bit and 32-bit.
(dmd 32-bit compiler has an optimization bug)
Both std.numeric.fsum and std.algorithm.sum use new
std.internal.math.summation.
Improvements or critics are welcome ;)
Questions:
0. How can I generate Phobos documentation?
1. What the better organization for other numeric algorithms:
normalize, dotProduct, entropy, kullbackLeiblerDivergence,
jensenShannonDivergence?
2. Can the same concept (like in fsum, but with naive summation
algorithm by default) be added for this numeric algorithms?
Best Regards,
Ilya
More information about the Digitalmars-d
mailing list