Average Error: 5.9 → 1.9
Time: 21.5s
Precision: 64
\[\left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.9189385332046700050057097541866824030876\right) + \frac{\left(\left(y + 7.936500793651000149400709382518925849581 \cdot 10^{-4}\right) \cdot z - 0.002777777777777800001512975569539776188321\right) \cdot z + 0.08333333333333299564049667651488562114537}{x}\]
\[\begin{array}{l} \mathbf{if}\;z \le -1.356814701468582121401803660799470759358 \cdot 10^{154}:\\ \;\;\;\;\mathsf{fma}\left(\log x, x - 0.5, \left(\left(\frac{0.08333333333333299564049667651488562114537}{x} - \frac{z \cdot 0.002777777777777800001512975569539776188321}{x}\right) + \frac{z \cdot 7.936500793651000149400709382518925849581 \cdot 10^{-4}}{\frac{x}{z}}\right) + \left(0.9189385332046700050057097541866824030876 - x\right)\right)\\ \mathbf{elif}\;z \le -164070247765506912:\\ \;\;\;\;\mathsf{fma}\left(\frac{z}{\frac{x}{z}}, 7.936500793651000149400709382518925849581 \cdot 10^{-4}, \mathsf{fma}\left(\frac{z \cdot z}{x}, y, x \cdot \log x\right) - x\right)\\ \mathbf{elif}\;z \le 2.055587456165716251508132232159365010533 \cdot 10^{72}:\\ \;\;\;\;\mathsf{fma}\left(\log x, x - 0.5, \left(0.9189385332046700050057097541866824030876 - x\right) + \frac{1}{\frac{\sqrt{x}}{\mathsf{fma}\left(\left(7.936500793651000149400709382518925849581 \cdot 10^{-4} + y\right) \cdot z - 0.002777777777777800001512975569539776188321, z, 0.08333333333333299564049667651488562114537\right)} \cdot \sqrt{x}}\right)\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(\log x, x - 0.5, \left(\left(\frac{0.08333333333333299564049667651488562114537}{x} - \frac{z \cdot 0.002777777777777800001512975569539776188321}{x}\right) + \frac{z \cdot 7.936500793651000149400709382518925849581 \cdot 10^{-4}}{\frac{x}{z}}\right) + \left(0.9189385332046700050057097541866824030876 - x\right)\right)\\ \end{array}\]
\left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.9189385332046700050057097541866824030876\right) + \frac{\left(\left(y + 7.936500793651000149400709382518925849581 \cdot 10^{-4}\right) \cdot z - 0.002777777777777800001512975569539776188321\right) \cdot z + 0.08333333333333299564049667651488562114537}{x}
\begin{array}{l}
\mathbf{if}\;z \le -1.356814701468582121401803660799470759358 \cdot 10^{154}:\\
\;\;\;\;\mathsf{fma}\left(\log x, x - 0.5, \left(\left(\frac{0.08333333333333299564049667651488562114537}{x} - \frac{z \cdot 0.002777777777777800001512975569539776188321}{x}\right) + \frac{z \cdot 7.936500793651000149400709382518925849581 \cdot 10^{-4}}{\frac{x}{z}}\right) + \left(0.9189385332046700050057097541866824030876 - x\right)\right)\\

\mathbf{elif}\;z \le -164070247765506912:\\
\;\;\;\;\mathsf{fma}\left(\frac{z}{\frac{x}{z}}, 7.936500793651000149400709382518925849581 \cdot 10^{-4}, \mathsf{fma}\left(\frac{z \cdot z}{x}, y, x \cdot \log x\right) - x\right)\\

\mathbf{elif}\;z \le 2.055587456165716251508132232159365010533 \cdot 10^{72}:\\
\;\;\;\;\mathsf{fma}\left(\log x, x - 0.5, \left(0.9189385332046700050057097541866824030876 - x\right) + \frac{1}{\frac{\sqrt{x}}{\mathsf{fma}\left(\left(7.936500793651000149400709382518925849581 \cdot 10^{-4} + y\right) \cdot z - 0.002777777777777800001512975569539776188321, z, 0.08333333333333299564049667651488562114537\right)} \cdot \sqrt{x}}\right)\\

\mathbf{else}:\\
\;\;\;\;\mathsf{fma}\left(\log x, x - 0.5, \left(\left(\frac{0.08333333333333299564049667651488562114537}{x} - \frac{z \cdot 0.002777777777777800001512975569539776188321}{x}\right) + \frac{z \cdot 7.936500793651000149400709382518925849581 \cdot 10^{-4}}{\frac{x}{z}}\right) + \left(0.9189385332046700050057097541866824030876 - x\right)\right)\\

\end{array}
double f(double x, double y, double z) {
        double r443870 = x;
        double r443871 = 0.5;
        double r443872 = r443870 - r443871;
        double r443873 = log(r443870);
        double r443874 = r443872 * r443873;
        double r443875 = r443874 - r443870;
        double r443876 = 0.91893853320467;
        double r443877 = r443875 + r443876;
        double r443878 = y;
        double r443879 = 0.0007936500793651;
        double r443880 = r443878 + r443879;
        double r443881 = z;
        double r443882 = r443880 * r443881;
        double r443883 = 0.0027777777777778;
        double r443884 = r443882 - r443883;
        double r443885 = r443884 * r443881;
        double r443886 = 0.083333333333333;
        double r443887 = r443885 + r443886;
        double r443888 = r443887 / r443870;
        double r443889 = r443877 + r443888;
        return r443889;
}

double f(double x, double y, double z) {
        double r443890 = z;
        double r443891 = -1.356814701468582e+154;
        bool r443892 = r443890 <= r443891;
        double r443893 = x;
        double r443894 = log(r443893);
        double r443895 = 0.5;
        double r443896 = r443893 - r443895;
        double r443897 = 0.083333333333333;
        double r443898 = r443897 / r443893;
        double r443899 = 0.0027777777777778;
        double r443900 = r443890 * r443899;
        double r443901 = r443900 / r443893;
        double r443902 = r443898 - r443901;
        double r443903 = 0.0007936500793651;
        double r443904 = r443890 * r443903;
        double r443905 = r443893 / r443890;
        double r443906 = r443904 / r443905;
        double r443907 = r443902 + r443906;
        double r443908 = 0.91893853320467;
        double r443909 = r443908 - r443893;
        double r443910 = r443907 + r443909;
        double r443911 = fma(r443894, r443896, r443910);
        double r443912 = -1.640702477655069e+17;
        bool r443913 = r443890 <= r443912;
        double r443914 = r443890 / r443905;
        double r443915 = r443890 * r443890;
        double r443916 = r443915 / r443893;
        double r443917 = y;
        double r443918 = r443893 * r443894;
        double r443919 = fma(r443916, r443917, r443918);
        double r443920 = r443919 - r443893;
        double r443921 = fma(r443914, r443903, r443920);
        double r443922 = 2.0555874561657163e+72;
        bool r443923 = r443890 <= r443922;
        double r443924 = 1.0;
        double r443925 = sqrt(r443893);
        double r443926 = r443903 + r443917;
        double r443927 = r443926 * r443890;
        double r443928 = r443927 - r443899;
        double r443929 = fma(r443928, r443890, r443897);
        double r443930 = r443925 / r443929;
        double r443931 = r443930 * r443925;
        double r443932 = r443924 / r443931;
        double r443933 = r443909 + r443932;
        double r443934 = fma(r443894, r443896, r443933);
        double r443935 = r443923 ? r443934 : r443911;
        double r443936 = r443913 ? r443921 : r443935;
        double r443937 = r443892 ? r443911 : r443936;
        return r443937;
}

Error

Bits error versus x

Bits error versus y

Bits error versus z

Target

Original5.9
Target1.2
Herbie1.9
\[\left(\left(\left(x - 0.5\right) \cdot \log x + \left(0.9189385332046700050057097541866824030876 - x\right)\right) + \frac{0.08333333333333299564049667651488562114537}{x}\right) + \frac{z}{x} \cdot \left(z \cdot \left(y + 7.936500793651000149400709382518925849581 \cdot 10^{-4}\right) - 0.002777777777777800001512975569539776188321\right)\]

Derivation

  1. Split input into 3 regimes
  2. if z < -1.356814701468582e+154 or 2.0555874561657163e+72 < z

    1. Initial program 40.0

      \[\left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.9189385332046700050057097541866824030876\right) + \frac{\left(\left(y + 7.936500793651000149400709382518925849581 \cdot 10^{-4}\right) \cdot z - 0.002777777777777800001512975569539776188321\right) \cdot z + 0.08333333333333299564049667651488562114537}{x}\]
    2. Simplified40.0

      \[\leadsto \color{blue}{\mathsf{fma}\left(\log x, x - 0.5, \frac{\mathsf{fma}\left(z, \left(y + 7.936500793651000149400709382518925849581 \cdot 10^{-4}\right) \cdot z - 0.002777777777777800001512975569539776188321, 0.08333333333333299564049667651488562114537\right)}{x}\right) + \left(0.9189385332046700050057097541866824030876 - x\right)}\]
    3. Using strategy rm
    4. Applied *-un-lft-identity40.0

      \[\leadsto \mathsf{fma}\left(\log x, x - 0.5, \frac{\mathsf{fma}\left(z, \left(y + 7.936500793651000149400709382518925849581 \cdot 10^{-4}\right) \cdot z - 0.002777777777777800001512975569539776188321, 0.08333333333333299564049667651488562114537\right)}{x}\right) + \color{blue}{1 \cdot \left(0.9189385332046700050057097541866824030876 - x\right)}\]
    5. Applied *-un-lft-identity40.0

      \[\leadsto \color{blue}{1 \cdot \mathsf{fma}\left(\log x, x - 0.5, \frac{\mathsf{fma}\left(z, \left(y + 7.936500793651000149400709382518925849581 \cdot 10^{-4}\right) \cdot z - 0.002777777777777800001512975569539776188321, 0.08333333333333299564049667651488562114537\right)}{x}\right)} + 1 \cdot \left(0.9189385332046700050057097541866824030876 - x\right)\]
    6. Applied distribute-lft-out40.0

      \[\leadsto \color{blue}{1 \cdot \left(\mathsf{fma}\left(\log x, x - 0.5, \frac{\mathsf{fma}\left(z, \left(y + 7.936500793651000149400709382518925849581 \cdot 10^{-4}\right) \cdot z - 0.002777777777777800001512975569539776188321, 0.08333333333333299564049667651488562114537\right)}{x}\right) + \left(0.9189385332046700050057097541866824030876 - x\right)\right)}\]
    7. Simplified40.0

      \[\leadsto 1 \cdot \color{blue}{\mathsf{fma}\left(\log x, x - 0.5, \frac{\mathsf{fma}\left(z, \left(y + 7.936500793651000149400709382518925849581 \cdot 10^{-4}\right) \cdot z - 0.002777777777777800001512975569539776188321, 0.08333333333333299564049667651488562114537\right)}{x} + \left(0.9189385332046700050057097541866824030876 - x\right)\right)}\]
    8. Using strategy rm
    9. Applied clear-num40.0

      \[\leadsto 1 \cdot \mathsf{fma}\left(\log x, x - 0.5, \color{blue}{\frac{1}{\frac{x}{\mathsf{fma}\left(z, \left(y + 7.936500793651000149400709382518925849581 \cdot 10^{-4}\right) \cdot z - 0.002777777777777800001512975569539776188321, 0.08333333333333299564049667651488562114537\right)}}} + \left(0.9189385332046700050057097541866824030876 - x\right)\right)\]
    10. Simplified40.0

      \[\leadsto 1 \cdot \mathsf{fma}\left(\log x, x - 0.5, \frac{1}{\color{blue}{\frac{x}{\mathsf{fma}\left(z, \mathsf{fma}\left(y + 7.936500793651000149400709382518925849581 \cdot 10^{-4}, z, -0.002777777777777800001512975569539776188321\right), 0.08333333333333299564049667651488562114537\right)}}} + \left(0.9189385332046700050057097541866824030876 - x\right)\right)\]
    11. Taylor expanded around 0 40.4

      \[\leadsto 1 \cdot \mathsf{fma}\left(\log x, x - 0.5, \color{blue}{\left(\left(7.936500793651000149400709382518925849581 \cdot 10^{-4} \cdot \frac{{z}^{2}}{x} + 0.08333333333333299564049667651488562114537 \cdot \frac{1}{x}\right) - 0.002777777777777800001512975569539776188321 \cdot \frac{z}{x}\right)} + \left(0.9189385332046700050057097541866824030876 - x\right)\right)\]
    12. Simplified11.5

      \[\leadsto 1 \cdot \mathsf{fma}\left(\log x, x - 0.5, \color{blue}{\mathsf{fma}\left(\frac{z}{\frac{x}{z}}, 7.936500793651000149400709382518925849581 \cdot 10^{-4}, \frac{0.08333333333333299564049667651488562114537}{x} - \frac{0.002777777777777800001512975569539776188321 \cdot z}{x}\right)} + \left(0.9189385332046700050057097541866824030876 - x\right)\right)\]
    13. Using strategy rm
    14. Applied fma-udef11.5

      \[\leadsto 1 \cdot \mathsf{fma}\left(\log x, x - 0.5, \color{blue}{\left(\frac{z}{\frac{x}{z}} \cdot 7.936500793651000149400709382518925849581 \cdot 10^{-4} + \left(\frac{0.08333333333333299564049667651488562114537}{x} - \frac{0.002777777777777800001512975569539776188321 \cdot z}{x}\right)\right)} + \left(0.9189385332046700050057097541866824030876 - x\right)\right)\]
    15. Simplified10.7

      \[\leadsto 1 \cdot \mathsf{fma}\left(\log x, x - 0.5, \left(\color{blue}{\frac{7.936500793651000149400709382518925849581 \cdot 10^{-4} \cdot z}{\frac{x}{z}}} + \left(\frac{0.08333333333333299564049667651488562114537}{x} - \frac{0.002777777777777800001512975569539776188321 \cdot z}{x}\right)\right) + \left(0.9189385332046700050057097541866824030876 - x\right)\right)\]

    if -1.356814701468582e+154 < z < -1.640702477655069e+17

    1. Initial program 9.5

      \[\left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.9189385332046700050057097541866824030876\right) + \frac{\left(\left(y + 7.936500793651000149400709382518925849581 \cdot 10^{-4}\right) \cdot z - 0.002777777777777800001512975569539776188321\right) \cdot z + 0.08333333333333299564049667651488562114537}{x}\]
    2. Simplified9.5

      \[\leadsto \color{blue}{\mathsf{fma}\left(\log x, x - 0.5, \frac{\mathsf{fma}\left(z, \left(y + 7.936500793651000149400709382518925849581 \cdot 10^{-4}\right) \cdot z - 0.002777777777777800001512975569539776188321, 0.08333333333333299564049667651488562114537\right)}{x}\right) + \left(0.9189385332046700050057097541866824030876 - x\right)}\]
    3. Using strategy rm
    4. Applied *-un-lft-identity9.5

      \[\leadsto \mathsf{fma}\left(\log x, x - 0.5, \frac{\mathsf{fma}\left(z, \left(y + 7.936500793651000149400709382518925849581 \cdot 10^{-4}\right) \cdot z - 0.002777777777777800001512975569539776188321, 0.08333333333333299564049667651488562114537\right)}{x}\right) + \color{blue}{1 \cdot \left(0.9189385332046700050057097541866824030876 - x\right)}\]
    5. Applied *-un-lft-identity9.5

      \[\leadsto \color{blue}{1 \cdot \mathsf{fma}\left(\log x, x - 0.5, \frac{\mathsf{fma}\left(z, \left(y + 7.936500793651000149400709382518925849581 \cdot 10^{-4}\right) \cdot z - 0.002777777777777800001512975569539776188321, 0.08333333333333299564049667651488562114537\right)}{x}\right)} + 1 \cdot \left(0.9189385332046700050057097541866824030876 - x\right)\]
    6. Applied distribute-lft-out9.5

      \[\leadsto \color{blue}{1 \cdot \left(\mathsf{fma}\left(\log x, x - 0.5, \frac{\mathsf{fma}\left(z, \left(y + 7.936500793651000149400709382518925849581 \cdot 10^{-4}\right) \cdot z - 0.002777777777777800001512975569539776188321, 0.08333333333333299564049667651488562114537\right)}{x}\right) + \left(0.9189385332046700050057097541866824030876 - x\right)\right)}\]
    7. Simplified9.5

      \[\leadsto 1 \cdot \color{blue}{\mathsf{fma}\left(\log x, x - 0.5, \frac{\mathsf{fma}\left(z, \left(y + 7.936500793651000149400709382518925849581 \cdot 10^{-4}\right) \cdot z - 0.002777777777777800001512975569539776188321, 0.08333333333333299564049667651488562114537\right)}{x} + \left(0.9189385332046700050057097541866824030876 - x\right)\right)}\]
    8. Using strategy rm
    9. Applied clear-num9.5

      \[\leadsto 1 \cdot \mathsf{fma}\left(\log x, x - 0.5, \color{blue}{\frac{1}{\frac{x}{\mathsf{fma}\left(z, \left(y + 7.936500793651000149400709382518925849581 \cdot 10^{-4}\right) \cdot z - 0.002777777777777800001512975569539776188321, 0.08333333333333299564049667651488562114537\right)}}} + \left(0.9189385332046700050057097541866824030876 - x\right)\right)\]
    10. Simplified9.5

      \[\leadsto 1 \cdot \mathsf{fma}\left(\log x, x - 0.5, \frac{1}{\color{blue}{\frac{x}{\mathsf{fma}\left(z, \mathsf{fma}\left(y + 7.936500793651000149400709382518925849581 \cdot 10^{-4}, z, -0.002777777777777800001512975569539776188321\right), 0.08333333333333299564049667651488562114537\right)}}} + \left(0.9189385332046700050057097541866824030876 - x\right)\right)\]
    11. Taylor expanded around inf 9.8

      \[\leadsto 1 \cdot \color{blue}{\left(\left(7.936500793651000149400709382518925849581 \cdot 10^{-4} \cdot \frac{{z}^{2}}{x} + \frac{{z}^{2} \cdot y}{x}\right) - \left(x + x \cdot \log \left(\frac{1}{x}\right)\right)\right)}\]
    12. Simplified0.7

      \[\leadsto 1 \cdot \color{blue}{\mathsf{fma}\left(\frac{z}{\frac{x}{z}}, 7.936500793651000149400709382518925849581 \cdot 10^{-4}, \mathsf{fma}\left(\frac{z \cdot z}{x}, y, \log x \cdot x\right) - x\right)}\]

    if -1.640702477655069e+17 < z < 2.0555874561657163e+72

    1. Initial program 0.6

      \[\left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.9189385332046700050057097541866824030876\right) + \frac{\left(\left(y + 7.936500793651000149400709382518925849581 \cdot 10^{-4}\right) \cdot z - 0.002777777777777800001512975569539776188321\right) \cdot z + 0.08333333333333299564049667651488562114537}{x}\]
    2. Simplified0.6

      \[\leadsto \color{blue}{\mathsf{fma}\left(\log x, x - 0.5, \frac{\mathsf{fma}\left(z, \left(y + 7.936500793651000149400709382518925849581 \cdot 10^{-4}\right) \cdot z - 0.002777777777777800001512975569539776188321, 0.08333333333333299564049667651488562114537\right)}{x}\right) + \left(0.9189385332046700050057097541866824030876 - x\right)}\]
    3. Using strategy rm
    4. Applied *-un-lft-identity0.6

      \[\leadsto \mathsf{fma}\left(\log x, x - 0.5, \frac{\mathsf{fma}\left(z, \left(y + 7.936500793651000149400709382518925849581 \cdot 10^{-4}\right) \cdot z - 0.002777777777777800001512975569539776188321, 0.08333333333333299564049667651488562114537\right)}{x}\right) + \color{blue}{1 \cdot \left(0.9189385332046700050057097541866824030876 - x\right)}\]
    5. Applied *-un-lft-identity0.6

      \[\leadsto \color{blue}{1 \cdot \mathsf{fma}\left(\log x, x - 0.5, \frac{\mathsf{fma}\left(z, \left(y + 7.936500793651000149400709382518925849581 \cdot 10^{-4}\right) \cdot z - 0.002777777777777800001512975569539776188321, 0.08333333333333299564049667651488562114537\right)}{x}\right)} + 1 \cdot \left(0.9189385332046700050057097541866824030876 - x\right)\]
    6. Applied distribute-lft-out0.6

      \[\leadsto \color{blue}{1 \cdot \left(\mathsf{fma}\left(\log x, x - 0.5, \frac{\mathsf{fma}\left(z, \left(y + 7.936500793651000149400709382518925849581 \cdot 10^{-4}\right) \cdot z - 0.002777777777777800001512975569539776188321, 0.08333333333333299564049667651488562114537\right)}{x}\right) + \left(0.9189385332046700050057097541866824030876 - x\right)\right)}\]
    7. Simplified0.5

      \[\leadsto 1 \cdot \color{blue}{\mathsf{fma}\left(\log x, x - 0.5, \frac{\mathsf{fma}\left(z, \left(y + 7.936500793651000149400709382518925849581 \cdot 10^{-4}\right) \cdot z - 0.002777777777777800001512975569539776188321, 0.08333333333333299564049667651488562114537\right)}{x} + \left(0.9189385332046700050057097541866824030876 - x\right)\right)}\]
    8. Using strategy rm
    9. Applied clear-num0.6

      \[\leadsto 1 \cdot \mathsf{fma}\left(\log x, x - 0.5, \color{blue}{\frac{1}{\frac{x}{\mathsf{fma}\left(z, \left(y + 7.936500793651000149400709382518925849581 \cdot 10^{-4}\right) \cdot z - 0.002777777777777800001512975569539776188321, 0.08333333333333299564049667651488562114537\right)}}} + \left(0.9189385332046700050057097541866824030876 - x\right)\right)\]
    10. Simplified0.6

      \[\leadsto 1 \cdot \mathsf{fma}\left(\log x, x - 0.5, \frac{1}{\color{blue}{\frac{x}{\mathsf{fma}\left(z, \mathsf{fma}\left(y + 7.936500793651000149400709382518925849581 \cdot 10^{-4}, z, -0.002777777777777800001512975569539776188321\right), 0.08333333333333299564049667651488562114537\right)}}} + \left(0.9189385332046700050057097541866824030876 - x\right)\right)\]
    11. Using strategy rm
    12. Applied *-un-lft-identity0.6

      \[\leadsto 1 \cdot \mathsf{fma}\left(\log x, x - 0.5, \frac{1}{\frac{x}{\color{blue}{1 \cdot \mathsf{fma}\left(z, \mathsf{fma}\left(y + 7.936500793651000149400709382518925849581 \cdot 10^{-4}, z, -0.002777777777777800001512975569539776188321\right), 0.08333333333333299564049667651488562114537\right)}}} + \left(0.9189385332046700050057097541866824030876 - x\right)\right)\]
    13. Applied add-sqr-sqrt0.8

      \[\leadsto 1 \cdot \mathsf{fma}\left(\log x, x - 0.5, \frac{1}{\frac{\color{blue}{\sqrt{x} \cdot \sqrt{x}}}{1 \cdot \mathsf{fma}\left(z, \mathsf{fma}\left(y + 7.936500793651000149400709382518925849581 \cdot 10^{-4}, z, -0.002777777777777800001512975569539776188321\right), 0.08333333333333299564049667651488562114537\right)}} + \left(0.9189385332046700050057097541866824030876 - x\right)\right)\]
    14. Applied times-frac0.8

      \[\leadsto 1 \cdot \mathsf{fma}\left(\log x, x - 0.5, \frac{1}{\color{blue}{\frac{\sqrt{x}}{1} \cdot \frac{\sqrt{x}}{\mathsf{fma}\left(z, \mathsf{fma}\left(y + 7.936500793651000149400709382518925849581 \cdot 10^{-4}, z, -0.002777777777777800001512975569539776188321\right), 0.08333333333333299564049667651488562114537\right)}}} + \left(0.9189385332046700050057097541866824030876 - x\right)\right)\]
    15. Simplified0.8

      \[\leadsto 1 \cdot \mathsf{fma}\left(\log x, x - 0.5, \frac{1}{\color{blue}{\sqrt{x}} \cdot \frac{\sqrt{x}}{\mathsf{fma}\left(z, \mathsf{fma}\left(y + 7.936500793651000149400709382518925849581 \cdot 10^{-4}, z, -0.002777777777777800001512975569539776188321\right), 0.08333333333333299564049667651488562114537\right)}} + \left(0.9189385332046700050057097541866824030876 - x\right)\right)\]
    16. Simplified0.8

      \[\leadsto 1 \cdot \mathsf{fma}\left(\log x, x - 0.5, \frac{1}{\sqrt{x} \cdot \color{blue}{\frac{\sqrt{x}}{\mathsf{fma}\left(z \cdot \left(7.936500793651000149400709382518925849581 \cdot 10^{-4} + y\right) - 0.002777777777777800001512975569539776188321, z, 0.08333333333333299564049667651488562114537\right)}}} + \left(0.9189385332046700050057097541866824030876 - x\right)\right)\]
  3. Recombined 3 regimes into one program.
  4. Final simplification1.9

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \le -1.356814701468582121401803660799470759358 \cdot 10^{154}:\\ \;\;\;\;\mathsf{fma}\left(\log x, x - 0.5, \left(\left(\frac{0.08333333333333299564049667651488562114537}{x} - \frac{z \cdot 0.002777777777777800001512975569539776188321}{x}\right) + \frac{z \cdot 7.936500793651000149400709382518925849581 \cdot 10^{-4}}{\frac{x}{z}}\right) + \left(0.9189385332046700050057097541866824030876 - x\right)\right)\\ \mathbf{elif}\;z \le -164070247765506912:\\ \;\;\;\;\mathsf{fma}\left(\frac{z}{\frac{x}{z}}, 7.936500793651000149400709382518925849581 \cdot 10^{-4}, \mathsf{fma}\left(\frac{z \cdot z}{x}, y, x \cdot \log x\right) - x\right)\\ \mathbf{elif}\;z \le 2.055587456165716251508132232159365010533 \cdot 10^{72}:\\ \;\;\;\;\mathsf{fma}\left(\log x, x - 0.5, \left(0.9189385332046700050057097541866824030876 - x\right) + \frac{1}{\frac{\sqrt{x}}{\mathsf{fma}\left(\left(7.936500793651000149400709382518925849581 \cdot 10^{-4} + y\right) \cdot z - 0.002777777777777800001512975569539776188321, z, 0.08333333333333299564049667651488562114537\right)} \cdot \sqrt{x}}\right)\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(\log x, x - 0.5, \left(\left(\frac{0.08333333333333299564049667651488562114537}{x} - \frac{z \cdot 0.002777777777777800001512975569539776188321}{x}\right) + \frac{z \cdot 7.936500793651000149400709382518925849581 \cdot 10^{-4}}{\frac{x}{z}}\right) + \left(0.9189385332046700050057097541866824030876 - x\right)\right)\\ \end{array}\]

Reproduce

herbie shell --seed 2019194 +o rules:numerics
(FPCore (x y z)
  :name "Numeric.SpecFunctions:$slogFactorial from math-functions-0.1.5.2, B"

  :herbie-target
  (+ (+ (+ (* (- x 0.5) (log x)) (- 0.91893853320467 x)) (/ 0.083333333333333 x)) (* (/ z x) (- (* z (+ y 0.0007936500793651)) 0.0027777777777778)))

  (+ (+ (- (* (- x 0.5) (log x)) x) 0.91893853320467) (/ (+ (* (- (* (+ y 0.0007936500793651) z) 0.0027777777777778) z) 0.083333333333333) x)))