Average Error: 30.2 → 23.2
Time: 31.8s
Precision: 64
$\left(\left(1 - e^{x}\right) \cdot \left(1 - e^{y}\right)\right) \cdot \left(1 - e^{z}\right)$
$\begin{array}{l} \mathbf{if}\;y \le -1.784607988805008376801857848630002830716 \cdot 10^{193}:\\ \;\;\;\;\left(\left(\frac{-1}{2} \cdot {x}^{2} - \left(x + \frac{1}{6} \cdot {x}^{3}\right)\right) \cdot \left(1 - e^{y}\right)\right) \cdot \left(1 - e^{z}\right)\\ \mathbf{elif}\;y \le -1.495996173302568656004893201146287726525 \cdot 10^{-11}:\\ \;\;\;\;\frac{\left(\left({1}^{3} - {\left(e^{x}\right)}^{3}\right) \cdot \left({1}^{3} - {\left(e^{y}\right)}^{3}\right)\right) \cdot \left(\frac{-1}{6} \cdot {z}^{3} - \left(\frac{1}{2} \cdot {z}^{2} + z\right)\right)}{\left(1 \cdot 1 + \left(e^{x} \cdot e^{x} + 1 \cdot e^{x}\right)\right) \cdot \left(1 \cdot 1 + \left(e^{y} \cdot e^{y} + 1 \cdot e^{y}\right)\right)}\\ \mathbf{else}:\\ \;\;\;\;\left(\left(1 - e^{x}\right) \cdot \left(-\left(y + \left(\frac{1}{2} \cdot {y}^{2} + \frac{1}{6} \cdot {y}^{3}\right)\right)\right)\right) \cdot \left(1 - e^{z}\right)\\ \end{array}$
\left(\left(1 - e^{x}\right) \cdot \left(1 - e^{y}\right)\right) \cdot \left(1 - e^{z}\right)
\begin{array}{l}
\mathbf{if}\;y \le -1.784607988805008376801857848630002830716 \cdot 10^{193}:\\
\;\;\;\;\left(\left(\frac{-1}{2} \cdot {x}^{2} - \left(x + \frac{1}{6} \cdot {x}^{3}\right)\right) \cdot \left(1 - e^{y}\right)\right) \cdot \left(1 - e^{z}\right)\\

\mathbf{elif}\;y \le -1.495996173302568656004893201146287726525 \cdot 10^{-11}:\\
\;\;\;\;\frac{\left(\left({1}^{3} - {\left(e^{x}\right)}^{3}\right) \cdot \left({1}^{3} - {\left(e^{y}\right)}^{3}\right)\right) \cdot \left(\frac{-1}{6} \cdot {z}^{3} - \left(\frac{1}{2} \cdot {z}^{2} + z\right)\right)}{\left(1 \cdot 1 + \left(e^{x} \cdot e^{x} + 1 \cdot e^{x}\right)\right) \cdot \left(1 \cdot 1 + \left(e^{y} \cdot e^{y} + 1 \cdot e^{y}\right)\right)}\\

\mathbf{else}:\\
\;\;\;\;\left(\left(1 - e^{x}\right) \cdot \left(-\left(y + \left(\frac{1}{2} \cdot {y}^{2} + \frac{1}{6} \cdot {y}^{3}\right)\right)\right)\right) \cdot \left(1 - e^{z}\right)\\

\end{array}
double f(double x, double y, double z) {
double r432474 = 1.0;
double r432475 = x;
double r432476 = exp(r432475);
double r432477 = r432474 - r432476;
double r432478 = y;
double r432479 = exp(r432478);
double r432480 = r432474 - r432479;
double r432481 = r432477 * r432480;
double r432482 = z;
double r432483 = exp(r432482);
double r432484 = r432474 - r432483;
double r432485 = r432481 * r432484;
return r432485;
}


double f(double x, double y, double z) {
double r432486 = y;
double r432487 = -1.7846079888050084e+193;
bool r432488 = r432486 <= r432487;
double r432489 = -0.5;
double r432490 = x;
double r432491 = 2.0;
double r432492 = pow(r432490, r432491);
double r432493 = r432489 * r432492;
double r432494 = 0.16666666666666666;
double r432495 = 3.0;
double r432496 = pow(r432490, r432495);
double r432497 = r432494 * r432496;
double r432498 = r432490 + r432497;
double r432499 = r432493 - r432498;
double r432500 = 1.0;
double r432501 = exp(r432486);
double r432502 = r432500 - r432501;
double r432503 = r432499 * r432502;
double r432504 = z;
double r432505 = exp(r432504);
double r432506 = r432500 - r432505;
double r432507 = r432503 * r432506;
double r432508 = -1.4959961733025687e-11;
bool r432509 = r432486 <= r432508;
double r432510 = pow(r432500, r432495);
double r432511 = exp(r432490);
double r432512 = pow(r432511, r432495);
double r432513 = r432510 - r432512;
double r432514 = pow(r432501, r432495);
double r432515 = r432510 - r432514;
double r432516 = r432513 * r432515;
double r432517 = -0.16666666666666666;
double r432518 = pow(r432504, r432495);
double r432519 = r432517 * r432518;
double r432520 = 0.5;
double r432521 = pow(r432504, r432491);
double r432522 = r432520 * r432521;
double r432523 = r432522 + r432504;
double r432524 = r432519 - r432523;
double r432525 = r432516 * r432524;
double r432526 = r432500 * r432500;
double r432527 = r432511 * r432511;
double r432528 = r432500 * r432511;
double r432529 = r432527 + r432528;
double r432530 = r432526 + r432529;
double r432531 = r432501 * r432501;
double r432532 = r432500 * r432501;
double r432533 = r432531 + r432532;
double r432534 = r432526 + r432533;
double r432535 = r432530 * r432534;
double r432536 = r432525 / r432535;
double r432537 = r432500 - r432511;
double r432538 = pow(r432486, r432491);
double r432539 = r432520 * r432538;
double r432540 = pow(r432486, r432495);
double r432541 = r432494 * r432540;
double r432542 = r432539 + r432541;
double r432543 = r432486 + r432542;
double r432544 = -r432543;
double r432545 = r432537 * r432544;
double r432546 = r432545 * r432506;
double r432547 = r432509 ? r432536 : r432546;
double r432548 = r432488 ? r432507 : r432547;
return r432548;
}



# Try it out

Results

 In Out
Enter valid numbers for all inputs

# Derivation

1. Split input into 3 regimes
2. ## if y < -1.7846079888050084e+193

1. Initial program 41.5

$\left(\left(1 - e^{x}\right) \cdot \left(1 - e^{y}\right)\right) \cdot \left(1 - e^{z}\right)$
2. Taylor expanded around 0 34.3

$\leadsto \left(\color{blue}{\left(-\left(\frac{1}{2} \cdot {x}^{2} + \left(x + \frac{1}{6} \cdot {x}^{3}\right)\right)\right)} \cdot \left(1 - e^{y}\right)\right) \cdot \left(1 - e^{z}\right)$
3. Simplified34.3

$\leadsto \left(\color{blue}{\left(\frac{-1}{2} \cdot {x}^{2} - \left(x + \frac{1}{6} \cdot {x}^{3}\right)\right)} \cdot \left(1 - e^{y}\right)\right) \cdot \left(1 - e^{z}\right)$

## if -1.7846079888050084e+193 < y < -1.4959961733025687e-11

1. Initial program 40.0

$\left(\left(1 - e^{x}\right) \cdot \left(1 - e^{y}\right)\right) \cdot \left(1 - e^{z}\right)$
2. Using strategy rm
3. Applied flip3--40.0

$\leadsto \left(\left(1 - e^{x}\right) \cdot \color{blue}{\frac{{1}^{3} - {\left(e^{y}\right)}^{3}}{1 \cdot 1 + \left(e^{y} \cdot e^{y} + 1 \cdot e^{y}\right)}}\right) \cdot \left(1 - e^{z}\right)$
4. Applied flip3--40.0

$\leadsto \left(\color{blue}{\frac{{1}^{3} - {\left(e^{x}\right)}^{3}}{1 \cdot 1 + \left(e^{x} \cdot e^{x} + 1 \cdot e^{x}\right)}} \cdot \frac{{1}^{3} - {\left(e^{y}\right)}^{3}}{1 \cdot 1 + \left(e^{y} \cdot e^{y} + 1 \cdot e^{y}\right)}\right) \cdot \left(1 - e^{z}\right)$
5. Applied frac-times40.0

$\leadsto \color{blue}{\frac{\left({1}^{3} - {\left(e^{x}\right)}^{3}\right) \cdot \left({1}^{3} - {\left(e^{y}\right)}^{3}\right)}{\left(1 \cdot 1 + \left(e^{x} \cdot e^{x} + 1 \cdot e^{x}\right)\right) \cdot \left(1 \cdot 1 + \left(e^{y} \cdot e^{y} + 1 \cdot e^{y}\right)\right)}} \cdot \left(1 - e^{z}\right)$
6. Applied associate-*l/40.0

$\leadsto \color{blue}{\frac{\left(\left({1}^{3} - {\left(e^{x}\right)}^{3}\right) \cdot \left({1}^{3} - {\left(e^{y}\right)}^{3}\right)\right) \cdot \left(1 - e^{z}\right)}{\left(1 \cdot 1 + \left(e^{x} \cdot e^{x} + 1 \cdot e^{x}\right)\right) \cdot \left(1 \cdot 1 + \left(e^{y} \cdot e^{y} + 1 \cdot e^{y}\right)\right)}}$
7. Taylor expanded around 0 34.8

$\leadsto \frac{\left(\left({1}^{3} - {\left(e^{x}\right)}^{3}\right) \cdot \left({1}^{3} - {\left(e^{y}\right)}^{3}\right)\right) \cdot \color{blue}{\left(-\left(\frac{1}{6} \cdot {z}^{3} + \left(\frac{1}{2} \cdot {z}^{2} + z\right)\right)\right)}}{\left(1 \cdot 1 + \left(e^{x} \cdot e^{x} + 1 \cdot e^{x}\right)\right) \cdot \left(1 \cdot 1 + \left(e^{y} \cdot e^{y} + 1 \cdot e^{y}\right)\right)}$
8. Simplified34.8

$\leadsto \frac{\left(\left({1}^{3} - {\left(e^{x}\right)}^{3}\right) \cdot \left({1}^{3} - {\left(e^{y}\right)}^{3}\right)\right) \cdot \color{blue}{\left(\frac{-1}{6} \cdot {z}^{3} - \left(\frac{1}{2} \cdot {z}^{2} + z\right)\right)}}{\left(1 \cdot 1 + \left(e^{x} \cdot e^{x} + 1 \cdot e^{x}\right)\right) \cdot \left(1 \cdot 1 + \left(e^{y} \cdot e^{y} + 1 \cdot e^{y}\right)\right)}$

## if -1.4959961733025687e-11 < y

1. Initial program 24.9

$\left(\left(1 - e^{x}\right) \cdot \left(1 - e^{y}\right)\right) \cdot \left(1 - e^{z}\right)$
2. Taylor expanded around 0 17.2

$\leadsto \left(\left(1 - e^{x}\right) \cdot \color{blue}{\left(-\left(y + \left(\frac{1}{2} \cdot {y}^{2} + \frac{1}{6} \cdot {y}^{3}\right)\right)\right)}\right) \cdot \left(1 - e^{z}\right)$
3. Recombined 3 regimes into one program.
4. Final simplification23.2

$\leadsto \begin{array}{l} \mathbf{if}\;y \le -1.784607988805008376801857848630002830716 \cdot 10^{193}:\\ \;\;\;\;\left(\left(\frac{-1}{2} \cdot {x}^{2} - \left(x + \frac{1}{6} \cdot {x}^{3}\right)\right) \cdot \left(1 - e^{y}\right)\right) \cdot \left(1 - e^{z}\right)\\ \mathbf{elif}\;y \le -1.495996173302568656004893201146287726525 \cdot 10^{-11}:\\ \;\;\;\;\frac{\left(\left({1}^{3} - {\left(e^{x}\right)}^{3}\right) \cdot \left({1}^{3} - {\left(e^{y}\right)}^{3}\right)\right) \cdot \left(\frac{-1}{6} \cdot {z}^{3} - \left(\frac{1}{2} \cdot {z}^{2} + z\right)\right)}{\left(1 \cdot 1 + \left(e^{x} \cdot e^{x} + 1 \cdot e^{x}\right)\right) \cdot \left(1 \cdot 1 + \left(e^{y} \cdot e^{y} + 1 \cdot e^{y}\right)\right)}\\ \mathbf{else}:\\ \;\;\;\;\left(\left(1 - e^{x}\right) \cdot \left(-\left(y + \left(\frac{1}{2} \cdot {y}^{2} + \frac{1}{6} \cdot {y}^{3}\right)\right)\right)\right) \cdot \left(1 - e^{z}\right)\\ \end{array}$

# Reproduce

herbie shell --seed 1
(FPCore (x y z)
:name "(1-exp(x))*(1-exp(y))*(1-exp(z))"
:precision binary64
(* (* (- 1 (exp x)) (- 1 (exp y))) (- 1 (exp z))))