
Results
Herbie found 6 alternatives:
| Alternative | Accuracy | Speedup |
|---|
Initial program 98.4%
+-commutative98.4%
sub-neg98.4%
distribute-rgt-in98.4%
*-lft-identity98.4%
associate-+l+98.4%
+-commutative98.4%
*-commutative98.4%
neg-mul-198.4%
associate-*r*98.4%
distribute-rgt-out100.0%
fma-def100.0%
+-commutative100.0%
*-commutative100.0%
neg-mul-1100.0%
unsub-neg100.0%
Simplified100.0%
Taylor expanded in y around 0 100.0%
Final simplification100.0%
if y < -1 or 8.0000000000000002e133 < y < 2.40000000000000011e223 or 2.84999999999999984e277 < y Initial program 95.4%
Taylor expanded in y around inf 98.9%
neg-mul-198.9%
+-commutative98.9%
sub-neg98.9%
Simplified98.9%
Taylor expanded in x around 0 62.7%
mul-1-neg62.7%
distribute-rgt-neg-out62.7%
Simplified62.7%
if -1 < y < 3.90000000000000006e-79Initial program 100.0%
Taylor expanded in y around 0 73.8%
if 3.90000000000000006e-79 < y < 8.0000000000000002e133 or 2.40000000000000011e223 < y < 2.84999999999999984e277Initial program 100.0%
Taylor expanded in x around inf 66.0%
Final simplification68.3%
if y < -1.19999999999999997e-15 or 1.6e-77 < y Initial program 97.2%
Taylor expanded in y around inf 94.0%
neg-mul-194.0%
+-commutative94.0%
sub-neg94.0%
Simplified94.0%
if -1.19999999999999997e-15 < y < 1.6e-77Initial program 100.0%
Taylor expanded in y around 0 74.9%
Final simplification85.6%
if y < -1 or 1 < y Initial program 96.9%
Taylor expanded in y around inf 98.8%
neg-mul-198.8%
+-commutative98.8%
sub-neg98.8%
Simplified98.8%
if -1 < y < 1Initial program 100.0%
+-commutative100.0%
sub-neg100.0%
distribute-rgt-in100.0%
*-lft-identity100.0%
associate-+l+100.0%
+-commutative100.0%
*-commutative100.0%
neg-mul-1100.0%
associate-*r*100.0%
distribute-rgt-out100.0%
fma-def100.0%
+-commutative100.0%
*-commutative100.0%
neg-mul-1100.0%
unsub-neg100.0%
Simplified100.0%
Taylor expanded in y around 0 100.0%
Taylor expanded in x around inf 99.1%
Final simplification99.0%
if y < -1.95000000000000002e-13 or 1.8e-77 < y Initial program 97.2%
Taylor expanded in x around inf 50.3%
if -1.95000000000000002e-13 < y < 1.8e-77Initial program 100.0%
Taylor expanded in y around 0 74.9%
Final simplification61.0%
Initial program 98.4%
Taylor expanded in y around 0 36.3%
Final simplification36.3%
herbie shell --seed 2023167
(FPCore (x y z)
:name "Diagrams.TwoD.Segment:bezierClip from diagrams-lib-1.3.0.3"
:precision binary64
:herbie-target
(- z (* (- z x) y))
(+ (* x y) (* z (- 1.0 y))))