Average Error: 0.4 → 0.4
Time: 19.6s
Precision: 64
• ## could not determine a ground truth for program body (more)

1. x0 = 1.3100436170095023e+65
2. x1 = -7.418868410425896e-99
3. x2 = -60759235271928696.0
4. x3 = 8.747337156785148e-141
$\frac{e^{x0}}{\left(\left(e^{x0} + e^{x1}\right) + e^{x2}\right) + e^{x3}}$
$\frac{1}{\frac{\left(\left(e^{x0} + e^{x1}\right) + e^{x2}\right) + e^{x3}}{e^{x0}}}$
\frac{e^{x0}}{\left(\left(e^{x0} + e^{x1}\right) + e^{x2}\right) + e^{x3}}
\frac{1}{\frac{\left(\left(e^{x0} + e^{x1}\right) + e^{x2}\right) + e^{x3}}{e^{x0}}}
double f(double x0, double x1, double x2, double x3) {
double r1812949 = x0;
double r1812950 = exp(r1812949);
double r1812951 = x1;
double r1812952 = exp(r1812951);
double r1812953 = r1812950 + r1812952;
double r1812954 = x2;
double r1812955 = exp(r1812954);
double r1812956 = r1812953 + r1812955;
double r1812957 = x3;
double r1812958 = exp(r1812957);
double r1812959 = r1812956 + r1812958;
double r1812960 = r1812950 / r1812959;
return r1812960;
}


double f(double x0, double x1, double x2, double x3) {
double r1812961 = 1.0;
double r1812962 = x0;
double r1812963 = exp(r1812962);
double r1812964 = x1;
double r1812965 = exp(r1812964);
double r1812966 = r1812963 + r1812965;
double r1812967 = x2;
double r1812968 = exp(r1812967);
double r1812969 = r1812966 + r1812968;
double r1812970 = x3;
double r1812971 = exp(r1812970);
double r1812972 = r1812969 + r1812971;
double r1812973 = r1812972 / r1812963;
double r1812974 = r1812961 / r1812973;
return r1812974;
}



# Try it out

Results

 In Out
Enter valid numbers for all inputs

# Derivation

1. Initial program 0.4

$\frac{e^{x0}}{\left(\left(e^{x0} + e^{x1}\right) + e^{x2}\right) + e^{x3}}$
2. Using strategy rm
3. Applied clear-num0.4

$\leadsto \color{blue}{\frac{1}{\frac{\left(\left(e^{x0} + e^{x1}\right) + e^{x2}\right) + e^{x3}}{e^{x0}}}}$
4. Final simplification0.4

$\leadsto \frac{1}{\frac{\left(\left(e^{x0} + e^{x1}\right) + e^{x2}\right) + e^{x3}}{e^{x0}}}$

# Reproduce

herbie shell --seed 1
(FPCore (x0 x1 x2 x3)
:name "exp(x0)/(exp(x0)+exp(x1)+exp(x2)+exp(x3))"
:precision binary64
(/ (exp x0) (+ (+ (+ (exp x0) (exp x1)) (exp x2)) (exp x3))))