Average Error: 58.1 → 58.1
Time: 21.9s
Precision: 64
\[x = 77617 \land y = 33096\]
\[\left(\left(333.75 \cdot {y}^{6} + \left(x \cdot x\right) \cdot \left(\left(\left(\left(\left(\left(11 \cdot x\right) \cdot x\right) \cdot y\right) \cdot y - {y}^{6}\right) - 121 \cdot {y}^{4}\right) - 2\right)\right) + 5.5 \cdot {y}^{8}\right) + \frac{x}{2 \cdot y}\]
\[\mathsf{expm1}\left(\mathsf{log1p}\left({y}^{6} \cdot 333.75\right)\right) + \mathsf{fma}\left(\left(\left(\left(11 \cdot x\right) \cdot x\right) \cdot y\right) \cdot y - \left({y}^{6} + \mathsf{fma}\left({y}^{4}, 121, 2\right)\right), x \cdot x, \mathsf{fma}\left(5.5, {y}^{8}, \frac{x}{2 \cdot y}\right)\right)\]
\left(\left(333.75 \cdot {y}^{6} + \left(x \cdot x\right) \cdot \left(\left(\left(\left(\left(\left(11 \cdot x\right) \cdot x\right) \cdot y\right) \cdot y - {y}^{6}\right) - 121 \cdot {y}^{4}\right) - 2\right)\right) + 5.5 \cdot {y}^{8}\right) + \frac{x}{2 \cdot y}
\mathsf{expm1}\left(\mathsf{log1p}\left({y}^{6} \cdot 333.75\right)\right) + \mathsf{fma}\left(\left(\left(\left(11 \cdot x\right) \cdot x\right) \cdot y\right) \cdot y - \left({y}^{6} + \mathsf{fma}\left({y}^{4}, 121, 2\right)\right), x \cdot x, \mathsf{fma}\left(5.5, {y}^{8}, \frac{x}{2 \cdot y}\right)\right)
double f(double x, double y) {
        double r45002 = 333.75;
        double r45003 = y;
        double r45004 = 6.0;
        double r45005 = pow(r45003, r45004);
        double r45006 = r45002 * r45005;
        double r45007 = x;
        double r45008 = r45007 * r45007;
        double r45009 = 11.0;
        double r45010 = r45009 * r45007;
        double r45011 = r45010 * r45007;
        double r45012 = r45011 * r45003;
        double r45013 = r45012 * r45003;
        double r45014 = r45013 - r45005;
        double r45015 = 121.0;
        double r45016 = 4.0;
        double r45017 = pow(r45003, r45016);
        double r45018 = r45015 * r45017;
        double r45019 = r45014 - r45018;
        double r45020 = 2.0;
        double r45021 = r45019 - r45020;
        double r45022 = r45008 * r45021;
        double r45023 = r45006 + r45022;
        double r45024 = 5.5;
        double r45025 = 8.0;
        double r45026 = pow(r45003, r45025);
        double r45027 = r45024 * r45026;
        double r45028 = r45023 + r45027;
        double r45029 = r45020 * r45003;
        double r45030 = r45007 / r45029;
        double r45031 = r45028 + r45030;
        return r45031;
}

double f(double x, double y) {
        double r45032 = y;
        double r45033 = 6.0;
        double r45034 = pow(r45032, r45033);
        double r45035 = 333.75;
        double r45036 = r45034 * r45035;
        double r45037 = log1p(r45036);
        double r45038 = expm1(r45037);
        double r45039 = 11.0;
        double r45040 = x;
        double r45041 = r45039 * r45040;
        double r45042 = r45041 * r45040;
        double r45043 = r45042 * r45032;
        double r45044 = r45043 * r45032;
        double r45045 = 4.0;
        double r45046 = pow(r45032, r45045);
        double r45047 = 121.0;
        double r45048 = 2.0;
        double r45049 = fma(r45046, r45047, r45048);
        double r45050 = r45034 + r45049;
        double r45051 = r45044 - r45050;
        double r45052 = r45040 * r45040;
        double r45053 = 5.5;
        double r45054 = 8.0;
        double r45055 = pow(r45032, r45054);
        double r45056 = r45048 * r45032;
        double r45057 = r45040 / r45056;
        double r45058 = fma(r45053, r45055, r45057);
        double r45059 = fma(r45051, r45052, r45058);
        double r45060 = r45038 + r45059;
        return r45060;
}

Error

Derivation

  1. Initial program 58.1

    \[\left(\left(333.75 \cdot {y}^{6} + \left(x \cdot x\right) \cdot \left(\left(\left(\left(\left(\left(11 \cdot x\right) \cdot x\right) \cdot y\right) \cdot y - {y}^{6}\right) - 121 \cdot {y}^{4}\right) - 2\right)\right) + 5.5 \cdot {y}^{8}\right) + \frac{x}{2 \cdot y}\]
  2. Simplified58.1

    \[\leadsto \color{blue}{\mathsf{fma}\left({y}^{6}, 333.75, \mathsf{fma}\left(\left(\left(\left(11 \cdot x\right) \cdot x\right) \cdot y\right) \cdot y - \left({y}^{6} + \mathsf{fma}\left({y}^{4}, 121, 2\right)\right), x \cdot x, \mathsf{fma}\left(5.5, {y}^{8}, \frac{x}{2 \cdot y}\right)\right)\right)}\]
  3. Using strategy rm
  4. Applied fma-udef58.1

    \[\leadsto \color{blue}{{y}^{6} \cdot 333.75 + \mathsf{fma}\left(\left(\left(\left(11 \cdot x\right) \cdot x\right) \cdot y\right) \cdot y - \left({y}^{6} + \mathsf{fma}\left({y}^{4}, 121, 2\right)\right), x \cdot x, \mathsf{fma}\left(5.5, {y}^{8}, \frac{x}{2 \cdot y}\right)\right)}\]
  5. Using strategy rm
  6. Applied expm1-log1p-u58.1

    \[\leadsto \color{blue}{\mathsf{expm1}\left(\mathsf{log1p}\left({y}^{6} \cdot 333.75\right)\right)} + \mathsf{fma}\left(\left(\left(\left(11 \cdot x\right) \cdot x\right) \cdot y\right) \cdot y - \left({y}^{6} + \mathsf{fma}\left({y}^{4}, 121, 2\right)\right), x \cdot x, \mathsf{fma}\left(5.5, {y}^{8}, \frac{x}{2 \cdot y}\right)\right)\]
  7. Final simplification58.1

    \[\leadsto \mathsf{expm1}\left(\mathsf{log1p}\left({y}^{6} \cdot 333.75\right)\right) + \mathsf{fma}\left(\left(\left(\left(11 \cdot x\right) \cdot x\right) \cdot y\right) \cdot y - \left({y}^{6} + \mathsf{fma}\left({y}^{4}, 121, 2\right)\right), x \cdot x, \mathsf{fma}\left(5.5, {y}^{8}, \frac{x}{2 \cdot y}\right)\right)\]

Reproduce

herbie shell --seed 2019325 +o rules:numerics
(FPCore (x y)
  :name "Rump's expression from Stadtherr's award speech"
  :precision binary64
  :pre (and (== x 77617) (== y 33096))
  (+ (+ (+ (* 333.75 (pow y 6)) (* (* x x) (- (- (- (* (* (* (* 11 x) x) y) y) (pow y 6)) (* 121 (pow y 4))) 2))) (* 5.5 (pow y 8))) (/ x (* 2 y))))