



Bits error versus i




Bits error versus n
| Original | 46.9 |
|---|---|
| Target | 46.7 |
| Herbie | 16.7 |
if i < -36704894.51776019 or 13.484694512673506 < i Initial program 28.4
rmApplied flip--28.4
Applied simplify28.4
if -36704894.51776019 < i < 13.484694512673506Initial program 57.4
Taylor expanded around 0 57.1
Applied simplify25.6
rmApplied *-un-lft-identity25.6
Applied times-frac25.6
Applied add-cube-cbrt25.7
Applied times-frac25.6
Applied simplify10.0
Taylor expanded around 0 10.0
Time bar (total: 1.8m)Debug logProfile
herbie shell --seed '#(1070609872 3456127585 2380521889 2328837196 1765472538 734540918)'
(FPCore (i n)
:name "Compound Interest"
:herbie-target
(* 100 (/ (- (exp (* n (if (== (+ 1 (/ i n)) 1) (/ i n) (/ (* (/ i n) (log (+ 1 (/ i n)))) (- (+ (/ i n) 1) 1))))) 1) (/ i n)))
(* 100 (/ (- (pow (+ 1 (/ i n)) n) 1) (/ i n))))