\frac{x - \sin x}{x - \tan x}\begin{array}{l}
\mathbf{if}\;x \le -0.03151178590185569478032689971769286785275:\\
\;\;\;\;\frac{{\left(\frac{x}{x - \tan x}\right)}^{3} - {\left(\frac{\sin x}{x - \tan x}\right)}^{3}}{\frac{\sin x}{x - \tan x} \cdot \left(\frac{\sin x}{x - \frac{\sin x}{\cos x}} + \frac{x}{x - \tan x}\right) + \frac{x}{x - \tan x} \cdot \frac{x}{x - \tan x}}\\
\mathbf{elif}\;x \le 0.06543863896081261732895484328764723613858:\\
\;\;\;\;\frac{9}{40} \cdot {x}^{2} - \left(\frac{27}{2800} \cdot {x}^{4} + \frac{1}{2}\right)\\
\mathbf{else}:\\
\;\;\;\;\frac{x}{x - \tan x} - \log \left(e^{\frac{\sin x}{x - \tan x}}\right)\\
\end{array}double f(double x) {
double r14871 = x;
double r14872 = sin(r14871);
double r14873 = r14871 - r14872;
double r14874 = tan(r14871);
double r14875 = r14871 - r14874;
double r14876 = r14873 / r14875;
return r14876;
}
double f(double x) {
double r14877 = x;
double r14878 = -0.031511785901855695;
bool r14879 = r14877 <= r14878;
double r14880 = tan(r14877);
double r14881 = r14877 - r14880;
double r14882 = r14877 / r14881;
double r14883 = 3.0;
double r14884 = pow(r14882, r14883);
double r14885 = sin(r14877);
double r14886 = r14885 / r14881;
double r14887 = pow(r14886, r14883);
double r14888 = r14884 - r14887;
double r14889 = cos(r14877);
double r14890 = r14885 / r14889;
double r14891 = r14877 - r14890;
double r14892 = r14885 / r14891;
double r14893 = r14892 + r14882;
double r14894 = r14886 * r14893;
double r14895 = r14882 * r14882;
double r14896 = r14894 + r14895;
double r14897 = r14888 / r14896;
double r14898 = 0.06543863896081262;
bool r14899 = r14877 <= r14898;
double r14900 = 0.225;
double r14901 = 2.0;
double r14902 = pow(r14877, r14901);
double r14903 = r14900 * r14902;
double r14904 = 0.009642857142857142;
double r14905 = 4.0;
double r14906 = pow(r14877, r14905);
double r14907 = r14904 * r14906;
double r14908 = 0.5;
double r14909 = r14907 + r14908;
double r14910 = r14903 - r14909;
double r14911 = exp(r14886);
double r14912 = log(r14911);
double r14913 = r14882 - r14912;
double r14914 = r14899 ? r14910 : r14913;
double r14915 = r14879 ? r14897 : r14914;
return r14915;
}



Bits error versus x
Results
if x < -0.031511785901855695Initial program 0.0
rmApplied div-sub0.0
rmApplied flip3--0.0
Simplified0.0
Taylor expanded around inf 0.0
if -0.031511785901855695 < x < 0.06543863896081262Initial program 63.0
Taylor expanded around 0 0.0
if 0.06543863896081262 < x Initial program 0.0
rmApplied div-sub0.0
rmApplied add-log-exp0.0
Final simplification0.0
herbie shell --seed 2019352
(FPCore (x)
:name "sintan (problem 3.4.5)"
:precision binary64
(/ (- x (sin x)) (- x (tan x))))