1 - \sqrt{\frac{1}{2} \cdot \left(1 + \frac{1}{\mathsf{hypot}\left(1, x\right)}\right)}\frac{\frac{\frac{\frac{1}{64} - \frac{\frac{1}{8}}{\left(\left(\mathsf{hypot}\left(1, x\right) \cdot \sqrt[3]{\mathsf{hypot}\left(1, x\right)}\right) \cdot \left(\mathsf{hypot}\left(1, x\right) \cdot \sqrt[3]{\mathsf{hypot}\left(1, x\right)}\right)\right) \cdot \sqrt[3]{\mathsf{hypot}\left(1, x\right)}} \cdot \frac{\frac{1}{8}}{\left(\left(\mathsf{hypot}\left(1, x\right) \cdot \sqrt[3]{\mathsf{hypot}\left(1, x\right)}\right) \cdot \left(\mathsf{hypot}\left(1, x\right) \cdot \sqrt[3]{\mathsf{hypot}\left(1, x\right)}\right)\right) \cdot \sqrt[3]{\mathsf{hypot}\left(1, x\right)}}}{\frac{1}{8} + \frac{\frac{1}{8}}{\left(\left(\mathsf{hypot}\left(1, x\right) \cdot \sqrt[3]{\mathsf{hypot}\left(1, x\right)}\right) \cdot \left(\mathsf{hypot}\left(1, x\right) \cdot \sqrt[3]{\mathsf{hypot}\left(1, x\right)}\right)\right) \cdot \sqrt[3]{\mathsf{hypot}\left(1, x\right)}}}}{\frac{1}{4} + \frac{\frac{1}{4} + \frac{\frac{1}{4}}{\mathsf{hypot}\left(1, x\right)}}{\mathsf{hypot}\left(1, x\right)}}}{\sqrt{\frac{1}{2} + \frac{\frac{1}{2}}{\mathsf{hypot}\left(1, x\right)}} + 1}double f(double x) {
double r2798951 = 1.0;
double r2798952 = 0.5;
double r2798953 = x;
double r2798954 = hypot(r2798951, r2798953);
double r2798955 = r2798951 / r2798954;
double r2798956 = r2798951 + r2798955;
double r2798957 = r2798952 * r2798956;
double r2798958 = sqrt(r2798957);
double r2798959 = r2798951 - r2798958;
return r2798959;
}
double f(double x) {
double r2798960 = 0.015625;
double r2798961 = 0.125;
double r2798962 = 1.0;
double r2798963 = x;
double r2798964 = hypot(r2798962, r2798963);
double r2798965 = cbrt(r2798964);
double r2798966 = r2798964 * r2798965;
double r2798967 = r2798966 * r2798966;
double r2798968 = r2798967 * r2798965;
double r2798969 = r2798961 / r2798968;
double r2798970 = r2798969 * r2798969;
double r2798971 = r2798960 - r2798970;
double r2798972 = r2798961 + r2798969;
double r2798973 = r2798971 / r2798972;
double r2798974 = 0.25;
double r2798975 = r2798974 / r2798964;
double r2798976 = r2798974 + r2798975;
double r2798977 = r2798976 / r2798964;
double r2798978 = r2798974 + r2798977;
double r2798979 = r2798973 / r2798978;
double r2798980 = 0.5;
double r2798981 = r2798980 / r2798964;
double r2798982 = r2798980 + r2798981;
double r2798983 = sqrt(r2798982);
double r2798984 = r2798983 + r2798962;
double r2798985 = r2798979 / r2798984;
return r2798985;
}



Bits error versus x
Results
Initial program 15.5
Simplified15.5
rmApplied flip--15.5
Simplified15.0
rmApplied flip3--15.0
Simplified15.0
Simplified15.0
rmApplied add-cube-cbrt15.0
Applied associate-*r*15.0
Simplified15.0
rmApplied flip--15.0
Final simplification15.0
herbie shell --seed 2019128
(FPCore (x)
:name "Given's Rotation SVD example, simplified"
(- 1 (sqrt (* 1/2 (+ 1 (/ 1 (hypot 1 x)))))))