Average Error: 9.8 → 5.3
Time: 6.4m
Precision: 64
Internal Precision: 1344
\[x + \frac{y - z}{\left(t + 1.0\right) - z} \cdot \left(a - x\right)\]
\[\begin{array}{l} \mathbf{if}\;\frac{y - z}{\left(t + 1.0\right) - z} \le 0.9999999999999996:\\ \;\;\;\;x + \left(\frac{1}{\sqrt[3]{\left(t + 1.0\right) - z} \cdot \sqrt[3]{\left(t + 1.0\right) - z}} \cdot \frac{y - z}{\sqrt[3]{\left(t + 1.0\right) - z}}\right) \cdot \left(a - x\right)\\ \mathbf{if}\;\frac{y - z}{\left(t + 1.0\right) - z} \le 1.0:\\ \;\;\;\;a + \frac{y}{z} \cdot \left(x - a\right)\\ \mathbf{else}:\\ \;\;\;\;x + \left(y - z\right) \cdot \frac{a - x}{t - \left(z - 1.0\right)}\\ \end{array}\]

Error

Bits error versus x

Bits error versus y

Bits error versus z

Bits error versus t

Bits error versus a

Derivation

  1. Split input into 3 regimes
  2. if (/ (- y z) (- (+ t 1.0) z)) < 0.9999999999999996

    1. Initial program 0.8

      \[x + \frac{y - z}{\left(t + 1.0\right) - z} \cdot \left(a - x\right)\]
    2. Using strategy rm
    3. Applied add-cube-cbrt0.9

      \[\leadsto x + \frac{y - z}{\color{blue}{\left(\sqrt[3]{\left(t + 1.0\right) - z} \cdot \sqrt[3]{\left(t + 1.0\right) - z}\right) \cdot \sqrt[3]{\left(t + 1.0\right) - z}}} \cdot \left(a - x\right)\]
    4. Applied *-un-lft-identity0.9

      \[\leadsto x + \frac{\color{blue}{1 \cdot \left(y - z\right)}}{\left(\sqrt[3]{\left(t + 1.0\right) - z} \cdot \sqrt[3]{\left(t + 1.0\right) - z}\right) \cdot \sqrt[3]{\left(t + 1.0\right) - z}} \cdot \left(a - x\right)\]
    5. Applied times-frac0.9

      \[\leadsto x + \color{blue}{\left(\frac{1}{\sqrt[3]{\left(t + 1.0\right) - z} \cdot \sqrt[3]{\left(t + 1.0\right) - z}} \cdot \frac{y - z}{\sqrt[3]{\left(t + 1.0\right) - z}}\right)} \cdot \left(a - x\right)\]

    if 0.9999999999999996 < (/ (- y z) (- (+ t 1.0) z)) < 1.0

    1. Initial program 30.3

      \[x + \frac{y - z}{\left(t + 1.0\right) - z} \cdot \left(a - x\right)\]
    2. Taylor expanded around inf 19.9

      \[\leadsto \color{blue}{\left(\frac{y \cdot x}{z} + a\right) - \frac{y \cdot a}{z}}\]
    3. Applied simplify14.2

      \[\leadsto \color{blue}{a + \frac{y}{z} \cdot \left(x - a\right)}\]

    if 1.0 < (/ (- y z) (- (+ t 1.0) z))

    1. Initial program 1.5

      \[x + \frac{y - z}{\left(t + 1.0\right) - z} \cdot \left(a - x\right)\]
    2. Using strategy rm
    3. Applied div-inv1.6

      \[\leadsto x + \color{blue}{\left(\left(y - z\right) \cdot \frac{1}{\left(t + 1.0\right) - z}\right)} \cdot \left(a - x\right)\]
    4. Applied associate-*l*3.9

      \[\leadsto x + \color{blue}{\left(y - z\right) \cdot \left(\frac{1}{\left(t + 1.0\right) - z} \cdot \left(a - x\right)\right)}\]
    5. Applied simplify3.8

      \[\leadsto x + \left(y - z\right) \cdot \color{blue}{\frac{a - x}{t - \left(z - 1.0\right)}}\]
  3. Recombined 3 regimes into one program.

Runtime

Time bar (total: 6.4m)Debug logProfile

herbie shell --seed '#(1939690843 327321720 555351923 2438475338 4053368242 4228276045)' 
(FPCore (x y z t a)
  :name "Hakyll.Web.Tags:renderTagCloud from hakyll-4.7.2.3"
  (+ x (* (/ (- y z) (- (+ t 1.0) z)) (- a x))))