Average Error: 2.0 → 0.3
Time: 4.8s
Precision: binary64
\[\]
\[\]
double code(double x, double y, double z, double t, double a) {
	return ((double) (x - ((double) (((double) (y - z)) / ((double) (((double) (((double) (t - z)) + 1.0)) / a))))));
}
double code(double x, double y, double z, double t, double a) {
	return ((double) (x + ((double) (a * ((double) (((double) (z / ((double) (t + ((double) (1.0 - z)))))) - ((double) (y / ((double) (t + ((double) (1.0 - z))))))))))));
}

Error

Bits error versus x

Bits error versus y

Bits error versus z

Bits error versus t

Bits error versus a

Try it out

Your Program's Arguments

Results

Enter valid numbers for all inputs

Target

Original2.0
Target0.3
Herbie0.3
\[\]

Derivation

  1. Initial program 2.0

    \[\]
  2. Simplified0.3

    \[\leadsto \]
  3. Using strategy rm
  4. Applied div-sub0.3

    \[\leadsto \]
  5. Final simplification0.3

    \[\leadsto \]

Reproduce

herbie shell --seed 2020191 
(FPCore (x y z t a)
  :name "Graphics.Rendering.Chart.SparkLine:renderSparkLine from Chart-1.5.3"
  :precision binary64

  :herbie-target
  (- x (* (/ (- y z) (+ (- t z) 1.0)) a))

  (- x (/ (- y z) (/ (+ (- t z) 1.0) a))))