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)\left(\left(x1 + 3 \cdot \frac{\left(\left(3 \cdot x1\right) \cdot x1 - 2 \cdot x2\right) - x1}{x1 \cdot x1 + 1}\right) + \left(x1 + \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(\left(x1 \cdot x1\right) \cdot \left(\sqrt[3]{4 \cdot \frac{\left(\left(3 \cdot x1\right) \cdot x1 + 2 \cdot x2\right) - x1}{x1 \cdot x1 + 1} - 6} \cdot \sqrt[3]{4 \cdot \frac{\left(\left(3 \cdot x1\right) \cdot x1 + 2 \cdot x2\right) - x1}{x1 \cdot x1 + 1} - 6}\right)\right) \cdot \sqrt[3]{4 \cdot \frac{\left(\left(3 \cdot x1\right) \cdot x1 + 2 \cdot x2\right) - x1}{x1 \cdot x1 + 1} - 6}\right) \cdot \left(x1 \cdot x1 + 1\right)\right)\right) + \left(x1 \cdot x1\right) \cdot \left(x1 + \frac{\left(\left(3 \cdot x1\right) \cdot x1 + 2 \cdot x2\right) - x1}{x1 \cdot x1 + 1} \cdot 3\right)double f(double x1, double x2) {
double r107707 = x1;
double r107708 = 2.0;
double r107709 = r107708 * r107707;
double r107710 = 3.0;
double r107711 = r107710 * r107707;
double r107712 = r107711 * r107707;
double r107713 = x2;
double r107714 = r107708 * r107713;
double r107715 = r107712 + r107714;
double r107716 = r107715 - r107707;
double r107717 = r107707 * r107707;
double r107718 = 1.0;
double r107719 = r107717 + r107718;
double r107720 = r107716 / r107719;
double r107721 = r107709 * r107720;
double r107722 = r107720 - r107710;
double r107723 = r107721 * r107722;
double r107724 = 4.0;
double r107725 = r107724 * r107720;
double r107726 = 6.0;
double r107727 = r107725 - r107726;
double r107728 = r107717 * r107727;
double r107729 = r107723 + r107728;
double r107730 = r107729 * r107719;
double r107731 = r107712 * r107720;
double r107732 = r107730 + r107731;
double r107733 = r107717 * r107707;
double r107734 = r107732 + r107733;
double r107735 = r107734 + r107707;
double r107736 = r107712 - r107714;
double r107737 = r107736 - r107707;
double r107738 = r107737 / r107719;
double r107739 = r107710 * r107738;
double r107740 = r107735 + r107739;
double r107741 = r107707 + r107740;
return r107741;
}
double f(double x1, double x2) {
double r107742 = x1;
double r107743 = 3.0;
double r107744 = r107743 * r107742;
double r107745 = r107744 * r107742;
double r107746 = 2.0;
double r107747 = x2;
double r107748 = r107746 * r107747;
double r107749 = r107745 - r107748;
double r107750 = r107749 - r107742;
double r107751 = r107742 * r107742;
double r107752 = 1.0;
double r107753 = r107751 + r107752;
double r107754 = r107750 / r107753;
double r107755 = r107743 * r107754;
double r107756 = r107742 + r107755;
double r107757 = r107746 * r107742;
double r107758 = r107745 + r107748;
double r107759 = r107758 - r107742;
double r107760 = r107759 / r107753;
double r107761 = r107757 * r107760;
double r107762 = r107760 - r107743;
double r107763 = r107761 * r107762;
double r107764 = 4.0;
double r107765 = r107764 * r107760;
double r107766 = 6.0;
double r107767 = r107765 - r107766;
double r107768 = cbrt(r107767);
double r107769 = r107768 * r107768;
double r107770 = r107751 * r107769;
double r107771 = r107770 * r107768;
double r107772 = r107763 + r107771;
double r107773 = r107772 * r107753;
double r107774 = r107742 + r107773;
double r107775 = r107756 + r107774;
double r107776 = r107760 * r107743;
double r107777 = r107742 + r107776;
double r107778 = r107751 * r107777;
double r107779 = r107775 + r107778;
return r107779;
}



Bits error versus x1



Bits error versus x2
Results
Initial program 0.5
Simplified0.5
rmApplied add-cube-cbrt0.6
Applied associate-*r*0.6
Final simplification0.6
herbie shell --seed 2020036
(FPCore (x1 x2)
:name "Rosa's FloatVsDoubleBenchmark"
:precision binary64
(+ 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))))))