Average Error: 0.5 → 0.3
Time: 2.8m
Precision: 64
\[x1 + \left(\left(\left(\left(\left(\left(\left(2 \cdot x1\right) \cdot \frac{\left(\left(3 \cdot x1\right) \cdot x1 + 2 \cdot x2\right) - x1}{x1 \cdot x1 + 1}\right) \cdot \left(\frac{\left(\left(3 \cdot x1\right) \cdot x1 + 2 \cdot x2\right) - x1}{x1 \cdot x1 + 1} - 3\right) + \left(x1 \cdot x1\right) \cdot \left(4 \cdot \frac{\left(\left(3 \cdot x1\right) \cdot x1 + 2 \cdot x2\right) - x1}{x1 \cdot x1 + 1} - 6\right)\right) \cdot \left(x1 \cdot x1 + 1\right) + \left(\left(3 \cdot x1\right) \cdot x1\right) \cdot \frac{\left(\left(3 \cdot x1\right) \cdot x1 + 2 \cdot x2\right) - x1}{x1 \cdot x1 + 1}\right) + \left(x1 \cdot x1\right) \cdot x1\right) + x1\right) + 3 \cdot \frac{\left(\left(3 \cdot x1\right) \cdot x1 - 2 \cdot x2\right) - x1}{x1 \cdot x1 + 1}\right)\]
\[\mathsf{fma}\left(3, \left(\frac{x1 \cdot \left(x1 \cdot 3\right) - \mathsf{fma}\left(2, x2, x1\right)}{\mathsf{fma}\left(x1, x1, 1\right)}\right), \left(x1 + \mathsf{fma}\left(x1, \left(x1 \cdot x1\right), \left(\mathsf{fma}\left(\left(\frac{\mathsf{fma}\left(x2, 2, \left(x1 \cdot \left(x1 \cdot 3\right)\right)\right) - x1}{\mathsf{fma}\left(x1, x1, 1\right)}\right), \left(x1 \cdot \left(x1 \cdot 3\right)\right), \left(\mathsf{fma}\left(\left(\mathsf{fma}\left(\left(\frac{\mathsf{fma}\left(x2, 2, \left(x1 \cdot \left(x1 \cdot 3\right)\right)\right) - x1}{\mathsf{fma}\left(x1, x1, 1\right)}\right), 4, -6\right)\right), \left(x1 \cdot x1\right), \left(\frac{\left(\left(2 \cdot x1\right) \cdot \left(\mathsf{fma}\left(x2, 2, \left(x1 \cdot \left(x1 \cdot 3\right)\right)\right) - x1\right)\right) \cdot \mathsf{fma}\left(\left(\frac{1}{\sqrt{\mathsf{fma}\left(x1, x1, 1\right)}}\right), \left(\frac{\mathsf{fma}\left(x2, 2, \left(x1 \cdot \left(x1 \cdot 3\right)\right)\right) - x1}{\sqrt{\mathsf{fma}\left(x1, x1, 1\right)}}\right), \left(\left(-\sqrt{3}\right) \cdot \sqrt{3}\right)\right)}{\mathsf{fma}\left(x1, x1, 1\right)}\right)\right) \cdot \mathsf{fma}\left(x1, x1, 1\right)\right)\right)\right)\right)\right)\right) + x1\]
x1 + \left(\left(\left(\left(\left(\left(\left(2 \cdot x1\right) \cdot \frac{\left(\left(3 \cdot x1\right) \cdot x1 + 2 \cdot x2\right) - x1}{x1 \cdot x1 + 1}\right) \cdot \left(\frac{\left(\left(3 \cdot x1\right) \cdot x1 + 2 \cdot x2\right) - x1}{x1 \cdot x1 + 1} - 3\right) + \left(x1 \cdot x1\right) \cdot \left(4 \cdot \frac{\left(\left(3 \cdot x1\right) \cdot x1 + 2 \cdot x2\right) - x1}{x1 \cdot x1 + 1} - 6\right)\right) \cdot \left(x1 \cdot x1 + 1\right) + \left(\left(3 \cdot x1\right) \cdot x1\right) \cdot \frac{\left(\left(3 \cdot x1\right) \cdot x1 + 2 \cdot x2\right) - x1}{x1 \cdot x1 + 1}\right) + \left(x1 \cdot x1\right) \cdot x1\right) + x1\right) + 3 \cdot \frac{\left(\left(3 \cdot x1\right) \cdot x1 - 2 \cdot x2\right) - x1}{x1 \cdot x1 + 1}\right)
\mathsf{fma}\left(3, \left(\frac{x1 \cdot \left(x1 \cdot 3\right) - \mathsf{fma}\left(2, x2, x1\right)}{\mathsf{fma}\left(x1, x1, 1\right)}\right), \left(x1 + \mathsf{fma}\left(x1, \left(x1 \cdot x1\right), \left(\mathsf{fma}\left(\left(\frac{\mathsf{fma}\left(x2, 2, \left(x1 \cdot \left(x1 \cdot 3\right)\right)\right) - x1}{\mathsf{fma}\left(x1, x1, 1\right)}\right), \left(x1 \cdot \left(x1 \cdot 3\right)\right), \left(\mathsf{fma}\left(\left(\mathsf{fma}\left(\left(\frac{\mathsf{fma}\left(x2, 2, \left(x1 \cdot \left(x1 \cdot 3\right)\right)\right) - x1}{\mathsf{fma}\left(x1, x1, 1\right)}\right), 4, -6\right)\right), \left(x1 \cdot x1\right), \left(\frac{\left(\left(2 \cdot x1\right) \cdot \left(\mathsf{fma}\left(x2, 2, \left(x1 \cdot \left(x1 \cdot 3\right)\right)\right) - x1\right)\right) \cdot \mathsf{fma}\left(\left(\frac{1}{\sqrt{\mathsf{fma}\left(x1, x1, 1\right)}}\right), \left(\frac{\mathsf{fma}\left(x2, 2, \left(x1 \cdot \left(x1 \cdot 3\right)\right)\right) - x1}{\sqrt{\mathsf{fma}\left(x1, x1, 1\right)}}\right), \left(\left(-\sqrt{3}\right) \cdot \sqrt{3}\right)\right)}{\mathsf{fma}\left(x1, x1, 1\right)}\right)\right) \cdot \mathsf{fma}\left(x1, x1, 1\right)\right)\right)\right)\right)\right)\right) + x1
double f(double x1, double x2) {
        double r13808393 = x1;
        double r13808394 = 2.0;
        double r13808395 = r13808394 * r13808393;
        double r13808396 = 3.0;
        double r13808397 = r13808396 * r13808393;
        double r13808398 = r13808397 * r13808393;
        double r13808399 = x2;
        double r13808400 = r13808394 * r13808399;
        double r13808401 = r13808398 + r13808400;
        double r13808402 = r13808401 - r13808393;
        double r13808403 = r13808393 * r13808393;
        double r13808404 = 1.0;
        double r13808405 = r13808403 + r13808404;
        double r13808406 = r13808402 / r13808405;
        double r13808407 = r13808395 * r13808406;
        double r13808408 = r13808406 - r13808396;
        double r13808409 = r13808407 * r13808408;
        double r13808410 = 4.0;
        double r13808411 = r13808410 * r13808406;
        double r13808412 = 6.0;
        double r13808413 = r13808411 - r13808412;
        double r13808414 = r13808403 * r13808413;
        double r13808415 = r13808409 + r13808414;
        double r13808416 = r13808415 * r13808405;
        double r13808417 = r13808398 * r13808406;
        double r13808418 = r13808416 + r13808417;
        double r13808419 = r13808403 * r13808393;
        double r13808420 = r13808418 + r13808419;
        double r13808421 = r13808420 + r13808393;
        double r13808422 = r13808398 - r13808400;
        double r13808423 = r13808422 - r13808393;
        double r13808424 = r13808423 / r13808405;
        double r13808425 = r13808396 * r13808424;
        double r13808426 = r13808421 + r13808425;
        double r13808427 = r13808393 + r13808426;
        return r13808427;
}

double f(double x1, double x2) {
        double r13808428 = 3.0;
        double r13808429 = x1;
        double r13808430 = r13808429 * r13808428;
        double r13808431 = r13808429 * r13808430;
        double r13808432 = 2.0;
        double r13808433 = x2;
        double r13808434 = fma(r13808432, r13808433, r13808429);
        double r13808435 = r13808431 - r13808434;
        double r13808436 = 1.0;
        double r13808437 = fma(r13808429, r13808429, r13808436);
        double r13808438 = r13808435 / r13808437;
        double r13808439 = r13808429 * r13808429;
        double r13808440 = fma(r13808433, r13808432, r13808431);
        double r13808441 = r13808440 - r13808429;
        double r13808442 = r13808441 / r13808437;
        double r13808443 = 4.0;
        double r13808444 = -6.0;
        double r13808445 = fma(r13808442, r13808443, r13808444);
        double r13808446 = r13808432 * r13808429;
        double r13808447 = r13808446 * r13808441;
        double r13808448 = sqrt(r13808437);
        double r13808449 = r13808436 / r13808448;
        double r13808450 = r13808441 / r13808448;
        double r13808451 = sqrt(r13808428);
        double r13808452 = -r13808451;
        double r13808453 = r13808452 * r13808451;
        double r13808454 = fma(r13808449, r13808450, r13808453);
        double r13808455 = r13808447 * r13808454;
        double r13808456 = r13808455 / r13808437;
        double r13808457 = fma(r13808445, r13808439, r13808456);
        double r13808458 = r13808457 * r13808437;
        double r13808459 = fma(r13808442, r13808431, r13808458);
        double r13808460 = fma(r13808429, r13808439, r13808459);
        double r13808461 = r13808429 + r13808460;
        double r13808462 = fma(r13808428, r13808438, r13808461);
        double r13808463 = r13808462 + r13808429;
        return r13808463;
}

Error

Bits error versus x1

Bits error versus x2

Derivation

  1. Initial program 0.5

    \[x1 + \left(\left(\left(\left(\left(\left(\left(2 \cdot x1\right) \cdot \frac{\left(\left(3 \cdot x1\right) \cdot x1 + 2 \cdot x2\right) - x1}{x1 \cdot x1 + 1}\right) \cdot \left(\frac{\left(\left(3 \cdot x1\right) \cdot x1 + 2 \cdot x2\right) - x1}{x1 \cdot x1 + 1} - 3\right) + \left(x1 \cdot x1\right) \cdot \left(4 \cdot \frac{\left(\left(3 \cdot x1\right) \cdot x1 + 2 \cdot x2\right) - x1}{x1 \cdot x1 + 1} - 6\right)\right) \cdot \left(x1 \cdot x1 + 1\right) + \left(\left(3 \cdot x1\right) \cdot x1\right) \cdot \frac{\left(\left(3 \cdot x1\right) \cdot x1 + 2 \cdot x2\right) - x1}{x1 \cdot x1 + 1}\right) + \left(x1 \cdot x1\right) \cdot x1\right) + x1\right) + 3 \cdot \frac{\left(\left(3 \cdot x1\right) \cdot x1 - 2 \cdot x2\right) - x1}{x1 \cdot x1 + 1}\right)\]
  2. Simplified0.3

    \[\leadsto \color{blue}{x1 + \mathsf{fma}\left(3, \left(\frac{\left(3 \cdot x1\right) \cdot x1 - \mathsf{fma}\left(2, x2, x1\right)}{\mathsf{fma}\left(x1, x1, 1\right)}\right), \left(\mathsf{fma}\left(x1, \left(x1 \cdot x1\right), \left(\mathsf{fma}\left(\left(\frac{\mathsf{fma}\left(x2, 2, \left(\left(3 \cdot x1\right) \cdot x1\right)\right) - x1}{\mathsf{fma}\left(x1, x1, 1\right)}\right), \left(\left(3 \cdot x1\right) \cdot x1\right), \left(\mathsf{fma}\left(x1, x1, 1\right) \cdot \mathsf{fma}\left(\left(\mathsf{fma}\left(\left(\frac{\mathsf{fma}\left(x2, 2, \left(\left(3 \cdot x1\right) \cdot x1\right)\right) - x1}{\mathsf{fma}\left(x1, x1, 1\right)}\right), 4, -6\right)\right), \left(x1 \cdot x1\right), \left(\left(\frac{\mathsf{fma}\left(x2, 2, \left(\left(3 \cdot x1\right) \cdot x1\right)\right) - x1}{\mathsf{fma}\left(x1, x1, 1\right)} - 3\right) \cdot \left(\left(x1 \cdot 2\right) \cdot \frac{\mathsf{fma}\left(x2, 2, \left(\left(3 \cdot x1\right) \cdot x1\right)\right) - x1}{\mathsf{fma}\left(x1, x1, 1\right)}\right)\right)\right)\right)\right)\right)\right) + x1\right)\right)}\]
  3. Using strategy rm
  4. Applied add-sqr-sqrt0.3

    \[\leadsto x1 + \mathsf{fma}\left(3, \left(\frac{\left(3 \cdot x1\right) \cdot x1 - \mathsf{fma}\left(2, x2, x1\right)}{\mathsf{fma}\left(x1, x1, 1\right)}\right), \left(\mathsf{fma}\left(x1, \left(x1 \cdot x1\right), \left(\mathsf{fma}\left(\left(\frac{\mathsf{fma}\left(x2, 2, \left(\left(3 \cdot x1\right) \cdot x1\right)\right) - x1}{\mathsf{fma}\left(x1, x1, 1\right)}\right), \left(\left(3 \cdot x1\right) \cdot x1\right), \left(\mathsf{fma}\left(x1, x1, 1\right) \cdot \mathsf{fma}\left(\left(\mathsf{fma}\left(\left(\frac{\mathsf{fma}\left(x2, 2, \left(\left(3 \cdot x1\right) \cdot x1\right)\right) - x1}{\mathsf{fma}\left(x1, x1, 1\right)}\right), 4, -6\right)\right), \left(x1 \cdot x1\right), \left(\left(\frac{\mathsf{fma}\left(x2, 2, \left(\left(3 \cdot x1\right) \cdot x1\right)\right) - x1}{\mathsf{fma}\left(x1, x1, 1\right)} - \color{blue}{\sqrt{3} \cdot \sqrt{3}}\right) \cdot \left(\left(x1 \cdot 2\right) \cdot \frac{\mathsf{fma}\left(x2, 2, \left(\left(3 \cdot x1\right) \cdot x1\right)\right) - x1}{\mathsf{fma}\left(x1, x1, 1\right)}\right)\right)\right)\right)\right)\right)\right) + x1\right)\right)\]
  5. Applied add-sqr-sqrt0.3

    \[\leadsto x1 + \mathsf{fma}\left(3, \left(\frac{\left(3 \cdot x1\right) \cdot x1 - \mathsf{fma}\left(2, x2, x1\right)}{\mathsf{fma}\left(x1, x1, 1\right)}\right), \left(\mathsf{fma}\left(x1, \left(x1 \cdot x1\right), \left(\mathsf{fma}\left(\left(\frac{\mathsf{fma}\left(x2, 2, \left(\left(3 \cdot x1\right) \cdot x1\right)\right) - x1}{\mathsf{fma}\left(x1, x1, 1\right)}\right), \left(\left(3 \cdot x1\right) \cdot x1\right), \left(\mathsf{fma}\left(x1, x1, 1\right) \cdot \mathsf{fma}\left(\left(\mathsf{fma}\left(\left(\frac{\mathsf{fma}\left(x2, 2, \left(\left(3 \cdot x1\right) \cdot x1\right)\right) - x1}{\mathsf{fma}\left(x1, x1, 1\right)}\right), 4, -6\right)\right), \left(x1 \cdot x1\right), \left(\left(\frac{\mathsf{fma}\left(x2, 2, \left(\left(3 \cdot x1\right) \cdot x1\right)\right) - x1}{\color{blue}{\sqrt{\mathsf{fma}\left(x1, x1, 1\right)} \cdot \sqrt{\mathsf{fma}\left(x1, x1, 1\right)}}} - \sqrt{3} \cdot \sqrt{3}\right) \cdot \left(\left(x1 \cdot 2\right) \cdot \frac{\mathsf{fma}\left(x2, 2, \left(\left(3 \cdot x1\right) \cdot x1\right)\right) - x1}{\mathsf{fma}\left(x1, x1, 1\right)}\right)\right)\right)\right)\right)\right)\right) + x1\right)\right)\]
  6. Applied *-un-lft-identity0.3

    \[\leadsto x1 + \mathsf{fma}\left(3, \left(\frac{\left(3 \cdot x1\right) \cdot x1 - \mathsf{fma}\left(2, x2, x1\right)}{\mathsf{fma}\left(x1, x1, 1\right)}\right), \left(\mathsf{fma}\left(x1, \left(x1 \cdot x1\right), \left(\mathsf{fma}\left(\left(\frac{\mathsf{fma}\left(x2, 2, \left(\left(3 \cdot x1\right) \cdot x1\right)\right) - x1}{\mathsf{fma}\left(x1, x1, 1\right)}\right), \left(\left(3 \cdot x1\right) \cdot x1\right), \left(\mathsf{fma}\left(x1, x1, 1\right) \cdot \mathsf{fma}\left(\left(\mathsf{fma}\left(\left(\frac{\mathsf{fma}\left(x2, 2, \left(\left(3 \cdot x1\right) \cdot x1\right)\right) - x1}{\mathsf{fma}\left(x1, x1, 1\right)}\right), 4, -6\right)\right), \left(x1 \cdot x1\right), \left(\left(\frac{\color{blue}{1 \cdot \left(\mathsf{fma}\left(x2, 2, \left(\left(3 \cdot x1\right) \cdot x1\right)\right) - x1\right)}}{\sqrt{\mathsf{fma}\left(x1, x1, 1\right)} \cdot \sqrt{\mathsf{fma}\left(x1, x1, 1\right)}} - \sqrt{3} \cdot \sqrt{3}\right) \cdot \left(\left(x1 \cdot 2\right) \cdot \frac{\mathsf{fma}\left(x2, 2, \left(\left(3 \cdot x1\right) \cdot x1\right)\right) - x1}{\mathsf{fma}\left(x1, x1, 1\right)}\right)\right)\right)\right)\right)\right)\right) + x1\right)\right)\]
  7. Applied times-frac0.3

    \[\leadsto x1 + \mathsf{fma}\left(3, \left(\frac{\left(3 \cdot x1\right) \cdot x1 - \mathsf{fma}\left(2, x2, x1\right)}{\mathsf{fma}\left(x1, x1, 1\right)}\right), \left(\mathsf{fma}\left(x1, \left(x1 \cdot x1\right), \left(\mathsf{fma}\left(\left(\frac{\mathsf{fma}\left(x2, 2, \left(\left(3 \cdot x1\right) \cdot x1\right)\right) - x1}{\mathsf{fma}\left(x1, x1, 1\right)}\right), \left(\left(3 \cdot x1\right) \cdot x1\right), \left(\mathsf{fma}\left(x1, x1, 1\right) \cdot \mathsf{fma}\left(\left(\mathsf{fma}\left(\left(\frac{\mathsf{fma}\left(x2, 2, \left(\left(3 \cdot x1\right) \cdot x1\right)\right) - x1}{\mathsf{fma}\left(x1, x1, 1\right)}\right), 4, -6\right)\right), \left(x1 \cdot x1\right), \left(\left(\color{blue}{\frac{1}{\sqrt{\mathsf{fma}\left(x1, x1, 1\right)}} \cdot \frac{\mathsf{fma}\left(x2, 2, \left(\left(3 \cdot x1\right) \cdot x1\right)\right) - x1}{\sqrt{\mathsf{fma}\left(x1, x1, 1\right)}}} - \sqrt{3} \cdot \sqrt{3}\right) \cdot \left(\left(x1 \cdot 2\right) \cdot \frac{\mathsf{fma}\left(x2, 2, \left(\left(3 \cdot x1\right) \cdot x1\right)\right) - x1}{\mathsf{fma}\left(x1, x1, 1\right)}\right)\right)\right)\right)\right)\right)\right) + x1\right)\right)\]
  8. Applied prod-diff0.3

    \[\leadsto x1 + \mathsf{fma}\left(3, \left(\frac{\left(3 \cdot x1\right) \cdot x1 - \mathsf{fma}\left(2, x2, x1\right)}{\mathsf{fma}\left(x1, x1, 1\right)}\right), \left(\mathsf{fma}\left(x1, \left(x1 \cdot x1\right), \left(\mathsf{fma}\left(\left(\frac{\mathsf{fma}\left(x2, 2, \left(\left(3 \cdot x1\right) \cdot x1\right)\right) - x1}{\mathsf{fma}\left(x1, x1, 1\right)}\right), \left(\left(3 \cdot x1\right) \cdot x1\right), \left(\mathsf{fma}\left(x1, x1, 1\right) \cdot \mathsf{fma}\left(\left(\mathsf{fma}\left(\left(\frac{\mathsf{fma}\left(x2, 2, \left(\left(3 \cdot x1\right) \cdot x1\right)\right) - x1}{\mathsf{fma}\left(x1, x1, 1\right)}\right), 4, -6\right)\right), \left(x1 \cdot x1\right), \left(\color{blue}{\left(\mathsf{fma}\left(\left(\frac{1}{\sqrt{\mathsf{fma}\left(x1, x1, 1\right)}}\right), \left(\frac{\mathsf{fma}\left(x2, 2, \left(\left(3 \cdot x1\right) \cdot x1\right)\right) - x1}{\sqrt{\mathsf{fma}\left(x1, x1, 1\right)}}\right), \left(-\sqrt{3} \cdot \sqrt{3}\right)\right) + \mathsf{fma}\left(\left(-\sqrt{3}\right), \left(\sqrt{3}\right), \left(\sqrt{3} \cdot \sqrt{3}\right)\right)\right)} \cdot \left(\left(x1 \cdot 2\right) \cdot \frac{\mathsf{fma}\left(x2, 2, \left(\left(3 \cdot x1\right) \cdot x1\right)\right) - x1}{\mathsf{fma}\left(x1, x1, 1\right)}\right)\right)\right)\right)\right)\right)\right) + x1\right)\right)\]
  9. Simplified0.3

    \[\leadsto x1 + \mathsf{fma}\left(3, \left(\frac{\left(3 \cdot x1\right) \cdot x1 - \mathsf{fma}\left(2, x2, x1\right)}{\mathsf{fma}\left(x1, x1, 1\right)}\right), \left(\mathsf{fma}\left(x1, \left(x1 \cdot x1\right), \left(\mathsf{fma}\left(\left(\frac{\mathsf{fma}\left(x2, 2, \left(\left(3 \cdot x1\right) \cdot x1\right)\right) - x1}{\mathsf{fma}\left(x1, x1, 1\right)}\right), \left(\left(3 \cdot x1\right) \cdot x1\right), \left(\mathsf{fma}\left(x1, x1, 1\right) \cdot \mathsf{fma}\left(\left(\mathsf{fma}\left(\left(\frac{\mathsf{fma}\left(x2, 2, \left(\left(3 \cdot x1\right) \cdot x1\right)\right) - x1}{\mathsf{fma}\left(x1, x1, 1\right)}\right), 4, -6\right)\right), \left(x1 \cdot x1\right), \left(\left(\mathsf{fma}\left(\left(\frac{1}{\sqrt{\mathsf{fma}\left(x1, x1, 1\right)}}\right), \left(\frac{\mathsf{fma}\left(x2, 2, \left(\left(3 \cdot x1\right) \cdot x1\right)\right) - x1}{\sqrt{\mathsf{fma}\left(x1, x1, 1\right)}}\right), \left(-\sqrt{3} \cdot \sqrt{3}\right)\right) + \color{blue}{0}\right) \cdot \left(\left(x1 \cdot 2\right) \cdot \frac{\mathsf{fma}\left(x2, 2, \left(\left(3 \cdot x1\right) \cdot x1\right)\right) - x1}{\mathsf{fma}\left(x1, x1, 1\right)}\right)\right)\right)\right)\right)\right)\right) + x1\right)\right)\]
  10. Using strategy rm
  11. Applied associate-*r/0.3

    \[\leadsto x1 + \mathsf{fma}\left(3, \left(\frac{\left(3 \cdot x1\right) \cdot x1 - \mathsf{fma}\left(2, x2, x1\right)}{\mathsf{fma}\left(x1, x1, 1\right)}\right), \left(\mathsf{fma}\left(x1, \left(x1 \cdot x1\right), \left(\mathsf{fma}\left(\left(\frac{\mathsf{fma}\left(x2, 2, \left(\left(3 \cdot x1\right) \cdot x1\right)\right) - x1}{\mathsf{fma}\left(x1, x1, 1\right)}\right), \left(\left(3 \cdot x1\right) \cdot x1\right), \left(\mathsf{fma}\left(x1, x1, 1\right) \cdot \mathsf{fma}\left(\left(\mathsf{fma}\left(\left(\frac{\mathsf{fma}\left(x2, 2, \left(\left(3 \cdot x1\right) \cdot x1\right)\right) - x1}{\mathsf{fma}\left(x1, x1, 1\right)}\right), 4, -6\right)\right), \left(x1 \cdot x1\right), \left(\left(\mathsf{fma}\left(\left(\frac{1}{\sqrt{\mathsf{fma}\left(x1, x1, 1\right)}}\right), \left(\frac{\mathsf{fma}\left(x2, 2, \left(\left(3 \cdot x1\right) \cdot x1\right)\right) - x1}{\sqrt{\mathsf{fma}\left(x1, x1, 1\right)}}\right), \left(-\sqrt{3} \cdot \sqrt{3}\right)\right) + 0\right) \cdot \color{blue}{\frac{\left(x1 \cdot 2\right) \cdot \left(\mathsf{fma}\left(x2, 2, \left(\left(3 \cdot x1\right) \cdot x1\right)\right) - x1\right)}{\mathsf{fma}\left(x1, x1, 1\right)}}\right)\right)\right)\right)\right)\right) + x1\right)\right)\]
  12. Applied associate-*r/0.3

    \[\leadsto x1 + \mathsf{fma}\left(3, \left(\frac{\left(3 \cdot x1\right) \cdot x1 - \mathsf{fma}\left(2, x2, x1\right)}{\mathsf{fma}\left(x1, x1, 1\right)}\right), \left(\mathsf{fma}\left(x1, \left(x1 \cdot x1\right), \left(\mathsf{fma}\left(\left(\frac{\mathsf{fma}\left(x2, 2, \left(\left(3 \cdot x1\right) \cdot x1\right)\right) - x1}{\mathsf{fma}\left(x1, x1, 1\right)}\right), \left(\left(3 \cdot x1\right) \cdot x1\right), \left(\mathsf{fma}\left(x1, x1, 1\right) \cdot \mathsf{fma}\left(\left(\mathsf{fma}\left(\left(\frac{\mathsf{fma}\left(x2, 2, \left(\left(3 \cdot x1\right) \cdot x1\right)\right) - x1}{\mathsf{fma}\left(x1, x1, 1\right)}\right), 4, -6\right)\right), \left(x1 \cdot x1\right), \color{blue}{\left(\frac{\left(\mathsf{fma}\left(\left(\frac{1}{\sqrt{\mathsf{fma}\left(x1, x1, 1\right)}}\right), \left(\frac{\mathsf{fma}\left(x2, 2, \left(\left(3 \cdot x1\right) \cdot x1\right)\right) - x1}{\sqrt{\mathsf{fma}\left(x1, x1, 1\right)}}\right), \left(-\sqrt{3} \cdot \sqrt{3}\right)\right) + 0\right) \cdot \left(\left(x1 \cdot 2\right) \cdot \left(\mathsf{fma}\left(x2, 2, \left(\left(3 \cdot x1\right) \cdot x1\right)\right) - x1\right)\right)}{\mathsf{fma}\left(x1, x1, 1\right)}\right)}\right)\right)\right)\right)\right) + x1\right)\right)\]
  13. Final simplification0.3

    \[\leadsto \mathsf{fma}\left(3, \left(\frac{x1 \cdot \left(x1 \cdot 3\right) - \mathsf{fma}\left(2, x2, x1\right)}{\mathsf{fma}\left(x1, x1, 1\right)}\right), \left(x1 + \mathsf{fma}\left(x1, \left(x1 \cdot x1\right), \left(\mathsf{fma}\left(\left(\frac{\mathsf{fma}\left(x2, 2, \left(x1 \cdot \left(x1 \cdot 3\right)\right)\right) - x1}{\mathsf{fma}\left(x1, x1, 1\right)}\right), \left(x1 \cdot \left(x1 \cdot 3\right)\right), \left(\mathsf{fma}\left(\left(\mathsf{fma}\left(\left(\frac{\mathsf{fma}\left(x2, 2, \left(x1 \cdot \left(x1 \cdot 3\right)\right)\right) - x1}{\mathsf{fma}\left(x1, x1, 1\right)}\right), 4, -6\right)\right), \left(x1 \cdot x1\right), \left(\frac{\left(\left(2 \cdot x1\right) \cdot \left(\mathsf{fma}\left(x2, 2, \left(x1 \cdot \left(x1 \cdot 3\right)\right)\right) - x1\right)\right) \cdot \mathsf{fma}\left(\left(\frac{1}{\sqrt{\mathsf{fma}\left(x1, x1, 1\right)}}\right), \left(\frac{\mathsf{fma}\left(x2, 2, \left(x1 \cdot \left(x1 \cdot 3\right)\right)\right) - x1}{\sqrt{\mathsf{fma}\left(x1, x1, 1\right)}}\right), \left(\left(-\sqrt{3}\right) \cdot \sqrt{3}\right)\right)}{\mathsf{fma}\left(x1, x1, 1\right)}\right)\right) \cdot \mathsf{fma}\left(x1, x1, 1\right)\right)\right)\right)\right)\right)\right) + x1\]

Reproduce

herbie shell --seed 2019124 +o rules:numerics
(FPCore (x1 x2)
  :name "Rosa's FloatVsDoubleBenchmark"
  (+ x1 (+ (+ (+ (+ (* (+ (* (* (* 2 x1) (/ (- (+ (* (* 3 x1) x1) (* 2 x2)) x1) (+ (* x1 x1) 1))) (- (/ (- (+ (* (* 3 x1) x1) (* 2 x2)) x1) (+ (* x1 x1) 1)) 3)) (* (* x1 x1) (- (* 4 (/ (- (+ (* (* 3 x1) x1) (* 2 x2)) x1) (+ (* x1 x1) 1))) 6))) (+ (* x1 x1) 1)) (* (* (* 3 x1) x1) (/ (- (+ (* (* 3 x1) x1) (* 2 x2)) x1) (+ (* x1 x1) 1)))) (* (* x1 x1) x1)) x1) (* 3 (/ (- (- (* (* 3 x1) x1) (* 2 x2)) x1) (+ (* x1 x1) 1))))))