Average Error: 14.8 → 6.7
Time: 7.3s
Precision: binary64
\[\]
\[\]
double code(double x, double y, double z, double t, double a) {
	return ((double) (x + ((double) (((double) (y - z)) * ((double) (((double) (t - x)) / ((double) (a - z))))))));
}
double code(double x, double y, double z, double t, double a) {
	double VAR;
	if (((((double) (x + ((double) (((double) (y - z)) * ((double) (((double) (t - x)) / ((double) (a - z)))))))) <= -2.385180190418958e-302) || !(((double) (x + ((double) (((double) (y - z)) * ((double) (((double) (t - x)) / ((double) (a - z)))))))) <= 0.0))) {
		VAR = ((double) (x + ((double) (((double) (((double) (y - z)) * ((double) (((double) cbrt(((double) (t - x)))) * ((double) (((double) cbrt(((double) (t - x)))) / ((double) (((double) cbrt(((double) (a - z)))) * ((double) cbrt(((double) (a - z)))))))))))) * ((double) (((double) cbrt(((double) (t - x)))) / ((double) cbrt(((double) (a - z))))))))));
	} else {
		VAR = ((double) (t + ((double) (y * ((double) (((double) (x / z)) - ((double) (t / z))))))));
	}
	return VAR;
}

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

Derivation

  1. Split input into 2 regimes
  2. if (+ x (* (- y z) (/ (- t x) (- a z)))) < -2.38518019041895791e-302 or 0.0 < (+ x (* (- y z) (/ (- t x) (- a z))))

    1. Initial program 7.8

      \[\]
    2. Using strategy rm
    3. Applied add-cube-cbrt8.5

      \[\leadsto \]
    4. Applied add-cube-cbrt8.6

      \[\leadsto \]
    5. Applied times-frac8.6

      \[\leadsto \]
    6. Applied associate-*r*4.8

      \[\leadsto \]
    7. Simplified4.8

      \[\leadsto \]

    if -2.38518019041895791e-302 < (+ x (* (- y z) (/ (- t x) (- a z)))) < 0.0

    1. Initial program 61.5

      \[\]
    2. Using strategy rm
    3. Applied add-cube-cbrt61.3

      \[\leadsto \]
    4. Applied add-cube-cbrt61.2

      \[\leadsto \]
    5. Applied times-frac61.2

      \[\leadsto \]
    6. Applied associate-*r*60.9

      \[\leadsto \]
    7. Simplified61.0

      \[\leadsto \]
    8. Taylor expanded around inf 25.1

      \[\leadsto \]
    9. Simplified19.7

      \[\leadsto \]
  3. Recombined 2 regimes into one program.
  4. Final simplification6.7

    \[\leadsto \]

Reproduce

herbie shell --seed 2020180 
(FPCore (x y z t a)
  :name "Numeric.Signal:interpolate   from hsignal-0.2.7.1"
  :precision binary64
  (+ x (* (- y z) (/ (- t x) (- a z)))))