Average Error: 64.0 → 48.0
Time: 58.7s
Precision: binary64
Cost: 64
\[1.9 \leq t \land t \leq 2.1\]
\[1.7 \cdot 10^{+308} \cdot t - 1.7 \cdot 10^{+308}\]
\[1.7 \cdot 10^{+308}\]
1.7 \cdot 10^{+308} \cdot t - 1.7 \cdot 10^{+308}
1.7 \cdot 10^{+308}
(FPCore (t) :precision binary64 (- (* 1.7e+308 t) 1.7e+308))
(FPCore (t) :precision binary64 1.7e+308)
double code(double t) {
	return (1.7e+308 * t) - 1.7e+308;
}
double code(double t) {
	return 1.7e+308;
}

Error

Bits error versus t

Try it out

Your Program's Arguments

Results

Enter valid numbers for all inputs

Target

Original64.0
Target0
Herbie48.0
\[\mathsf{fma}\left(1.7 \cdot 10^{+308}, t, -1.7 \cdot 10^{+308}\right)\]

Derivation

  1. Initial program 64.0

    \[1.7 \cdot 10^{+308} \cdot t - 1.7 \cdot 10^{+308}\]
  2. Using strategy rm
  3. Applied add-sqr-sqrt_binary64_146464.0

    \[\leadsto \color{blue}{\sqrt{1.7 \cdot 10^{+308} \cdot t - 1.7 \cdot 10^{+308}} \cdot \sqrt{1.7 \cdot 10^{+308} \cdot t - 1.7 \cdot 10^{+308}}}\]
  4. Using strategy rm
  5. Applied *-un-lft-identity_binary64_144264.0

    \[\leadsto \sqrt{\color{blue}{1 \cdot \left(1.7 \cdot 10^{+308} \cdot t - 1.7 \cdot 10^{+308}\right)}} \cdot \sqrt{1.7 \cdot 10^{+308} \cdot t - 1.7 \cdot 10^{+308}}\]
  6. Using strategy rm
  7. Applied flip3--_binary64_144664.0

    \[\leadsto \sqrt{1 \cdot \left(1.7 \cdot 10^{+308} \cdot t - 1.7 \cdot 10^{+308}\right)} \cdot \sqrt{\color{blue}{\frac{{\left(1.7 \cdot 10^{+308} \cdot t\right)}^{3} - {\left( 1.7 \cdot 10^{+308} \right)}^{3}}{\left(1.7 \cdot 10^{+308} \cdot t\right) \cdot \left(1.7 \cdot 10^{+308} \cdot t\right) + \left(1.7 \cdot 10^{+308} \cdot 1.7 \cdot 10^{+308} + \left(1.7 \cdot 10^{+308} \cdot t\right) \cdot 1.7 \cdot 10^{+308}\right)}}}\]
  8. Simplified64.0

    \[\leadsto \sqrt{1 \cdot \left(1.7 \cdot 10^{+308} \cdot t - 1.7 \cdot 10^{+308}\right)} \cdot \sqrt{\frac{\color{blue}{{\left(1.7 \cdot 10^{+308} \cdot t\right)}^{3} - +\infty}}{\left(1.7 \cdot 10^{+308} \cdot t\right) \cdot \left(1.7 \cdot 10^{+308} \cdot t\right) + \left(1.7 \cdot 10^{+308} \cdot 1.7 \cdot 10^{+308} + \left(1.7 \cdot 10^{+308} \cdot t\right) \cdot 1.7 \cdot 10^{+308}\right)}}\]
  9. Simplified64.0

    \[\leadsto \sqrt{1 \cdot \left(1.7 \cdot 10^{+308} \cdot t - 1.7 \cdot 10^{+308}\right)} \cdot \sqrt{\frac{{\left(1.7 \cdot 10^{+308} \cdot t\right)}^{3} - +\infty}{\color{blue}{+\infty + t \cdot \left(+\infty + t \cdot +\infty\right)}}}\]
  10. Taylor expanded around 0 48.0

    \[\leadsto \color{blue}{1.7 \cdot 10^{+308}}\]
  11. Simplified48.0

    \[\leadsto \color{blue}{1.7 \cdot 10^{+308}}\]
  12. Final simplification48.0

    \[\leadsto 1.7 \cdot 10^{+308}\]

Reproduce

herbie shell --seed 2021065 
(FPCore (t)
  :name "fma_test2"
  :precision binary64
  :pre (<= 1.9 t 2.1)

  :herbie-target
  (fma 1.7e+308 t (- 1.7e+308))

  (- (* 1.7e+308 t) 1.7e+308))