Average Error: 14.1 → 1.2
Time: 28.1s
Precision: 64
Internal Precision: 576
\[x \cdot \frac{\frac{y}{z} \cdot t}{t}\]
\[\begin{array}{l} \mathbf{if}\;\frac{\frac{y}{z} \cdot t}{t} \le -4.1941922266109227 \cdot 10^{+124}:\\ \;\;\;\;\frac{y \cdot x}{z}\\ \mathbf{elif}\;\frac{\frac{y}{z} \cdot t}{t} \le -1.562070457980031 \cdot 10^{-277}:\\ \;\;\;\;x \cdot \frac{\frac{y}{z} \cdot t}{t}\\ \mathbf{elif}\;\frac{\frac{y}{z} \cdot t}{t} \le 1.6151912022715896 \cdot 10^{-208}:\\ \;\;\;\;y \cdot \frac{x}{z}\\ \mathbf{elif}\;\frac{\frac{y}{z} \cdot t}{t} \le 4.674529778337726 \cdot 10^{+292}:\\ \;\;\;\;x \cdot \frac{\frac{y}{z} \cdot t}{t}\\ \mathbf{else}:\\ \;\;\;\;y \cdot \frac{x}{z}\\ \end{array}\]

Error

Bits error versus x

Bits error versus y

Bits error versus z

Bits error versus t

Try it out

Your Program's Arguments

Results

Enter valid numbers for all inputs

Derivation

  1. Split input into 3 regimes
  2. if (/ (* (/ y z) t) t) < -4.1941922266109227e+124

    1. Initial program 31.5

      \[x \cdot \frac{\frac{y}{z} \cdot t}{t}\]
    2. Initial simplification3.8

      \[\leadsto y \cdot \frac{x}{z}\]
    3. Using strategy rm
    4. Applied associate-*r/3.4

      \[\leadsto \color{blue}{\frac{y \cdot x}{z}}\]

    if -4.1941922266109227e+124 < (/ (* (/ y z) t) t) < -1.562070457980031e-277 or 1.6151912022715896e-208 < (/ (* (/ y z) t) t) < 4.674529778337726e+292

    1. Initial program 0.7

      \[x \cdot \frac{\frac{y}{z} \cdot t}{t}\]

    if -1.562070457980031e-277 < (/ (* (/ y z) t) t) < 1.6151912022715896e-208 or 4.674529778337726e+292 < (/ (* (/ y z) t) t)

    1. Initial program 30.2

      \[x \cdot \frac{\frac{y}{z} \cdot t}{t}\]
    2. Initial simplification1.4

      \[\leadsto y \cdot \frac{x}{z}\]
  3. Recombined 3 regimes into one program.
  4. Final simplification1.2

    \[\leadsto \begin{array}{l} \mathbf{if}\;\frac{\frac{y}{z} \cdot t}{t} \le -4.1941922266109227 \cdot 10^{+124}:\\ \;\;\;\;\frac{y \cdot x}{z}\\ \mathbf{elif}\;\frac{\frac{y}{z} \cdot t}{t} \le -1.562070457980031 \cdot 10^{-277}:\\ \;\;\;\;x \cdot \frac{\frac{y}{z} \cdot t}{t}\\ \mathbf{elif}\;\frac{\frac{y}{z} \cdot t}{t} \le 1.6151912022715896 \cdot 10^{-208}:\\ \;\;\;\;y \cdot \frac{x}{z}\\ \mathbf{elif}\;\frac{\frac{y}{z} \cdot t}{t} \le 4.674529778337726 \cdot 10^{+292}:\\ \;\;\;\;x \cdot \frac{\frac{y}{z} \cdot t}{t}\\ \mathbf{else}:\\ \;\;\;\;y \cdot \frac{x}{z}\\ \end{array}\]

Runtime

Time bar (total: 28.1s)Debug logProfile

herbie shell --seed 2018242 +o rules:numerics
(FPCore (x y z t)
  :name "Graphics.Rendering.Chart.Backend.Diagrams:calcFontMetrics from Chart-diagrams-1.5.1"
  (* x (/ (* (/ y z) t) t)))