Average Error: 5.3 → 2.2
Time: 2.7m
Precision: 64
Internal Precision: 384
\[\left(\left(\left(\left(\left(\left(x \cdot 18.0\right) \cdot y\right) \cdot z\right) \cdot t - \left(a \cdot 4.0\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4.0\right) \cdot i\right) - \left(j \cdot 27.0\right) \cdot k\]
\[\begin{array}{l} \mathbf{if}\;\left(b \cdot c - 4.0 \cdot \left(x \cdot i + a \cdot t\right)\right) + \left(18.0 \cdot \left(\left(z \cdot y\right) \cdot \left(t \cdot x\right)\right) - 27.0 \cdot \left(k \cdot j\right)\right) = -\infty:\\ \;\;\;\;\left(\left(\left(\left(\left(\left(x \cdot 18.0\right) \cdot y\right) \cdot z\right) \cdot t - \left(a \cdot 4.0\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4.0\right) \cdot i\right) - \left(j \cdot 27.0\right) \cdot k\\ \mathbf{if}\;\left(b \cdot c - 4.0 \cdot \left(x \cdot i + a \cdot t\right)\right) + \left(18.0 \cdot \left(\left(z \cdot y\right) \cdot \left(t \cdot x\right)\right) - 27.0 \cdot \left(k \cdot j\right)\right) \le 1.0232093772859075 \cdot 10^{+258}:\\ \;\;\;\;\left(b \cdot c - 4.0 \cdot \left(x \cdot i + a \cdot t\right)\right) + \left(18.0 \cdot \left(\left(z \cdot y\right) \cdot \left(t \cdot x\right)\right) - 27.0 \cdot \left(k \cdot j\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\left(\left(\left(\left(\left(\left(x \cdot 18.0\right) \cdot y\right) \cdot z\right) \cdot t - \left(a \cdot 4.0\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4.0\right) \cdot i\right) - \left(j \cdot 27.0\right) \cdot k\\ \end{array}\]

Error

Bits error versus x

Bits error versus y

Bits error versus z

Bits error versus t

Bits error versus a

Bits error versus b

Bits error versus c

Bits error versus i

Bits error versus j

Bits error versus k

Derivation

  1. Split input into 2 regimes
  2. if (+ (- (* b c) (* 4.0 (+ (* x i) (* a t)))) (- (* 18.0 (* (* z y) (* t x))) (* 27.0 (* k j)))) < -inf.0 or 1.0232093772859075e+258 < (+ (- (* b c) (* 4.0 (+ (* x i) (* a t)))) (- (* 18.0 (* (* z y) (* t x))) (* 27.0 (* k j))))

    1. Initial program 11.6

      \[\left(\left(\left(\left(\left(\left(x \cdot 18.0\right) \cdot y\right) \cdot z\right) \cdot t - \left(a \cdot 4.0\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4.0\right) \cdot i\right) - \left(j \cdot 27.0\right) \cdot k\]

    if -inf.0 < (+ (- (* b c) (* 4.0 (+ (* x i) (* a t)))) (- (* 18.0 (* (* z y) (* t x))) (* 27.0 (* k j)))) < 1.0232093772859075e+258

    1. Initial program 4.0

      \[\left(\left(\left(\left(\left(\left(x \cdot 18.0\right) \cdot y\right) \cdot z\right) \cdot t - \left(a \cdot 4.0\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4.0\right) \cdot i\right) - \left(j \cdot 27.0\right) \cdot k\]
    2. Applied simplify1.8

      \[\leadsto \color{blue}{\left(b \cdot c - 4.0 \cdot \left(x \cdot i + a \cdot t\right)\right) + \left(t \cdot \left(\left(18.0 \cdot x\right) \cdot \left(y \cdot z\right)\right) - 27.0 \cdot \left(k \cdot j\right)\right)}\]
    3. Taylor expanded around inf 1.7

      \[\leadsto \left(b \cdot c - 4.0 \cdot \left(x \cdot i + a \cdot t\right)\right) + \left(\color{blue}{18.0 \cdot \left(z \cdot \left(y \cdot \left(t \cdot x\right)\right)\right)} - 27.0 \cdot \left(k \cdot j\right)\right)\]
    4. Using strategy rm
    5. Applied associate-*r*0.2

      \[\leadsto \left(b \cdot c - 4.0 \cdot \left(x \cdot i + a \cdot t\right)\right) + \left(18.0 \cdot \color{blue}{\left(\left(z \cdot y\right) \cdot \left(t \cdot x\right)\right)} - 27.0 \cdot \left(k \cdot j\right)\right)\]
  3. Recombined 2 regimes into one program.

Runtime

Time bar (total: 2.7m)Debug logProfile

herbie shell --seed '#(1070258749 1877548225 2229079127 1588002776 3179087814 1886870650)' 
(FPCore (x y z t a b c i j k)
  :name "Diagrams.Solve.Polynomial:cubForm  from diagrams-solve-0.1"
  (- (- (+ (- (* (* (* (* x 18.0) y) z) t) (* (* a 4.0) t)) (* b c)) (* (* x 4.0) i)) (* (* j 27.0) k)))