\frac{x - \sin x}{x - \tan x}\begin{array}{l}
\mathbf{if}\;x \le -0.02963816903464042487592600139123533153906:\\
\;\;\;\;\frac{x}{x - \tan x} - \frac{\sin x}{x - \tan x}\\
\mathbf{elif}\;x \le 0.02866242393931728651979007338468363741413:\\
\;\;\;\;\frac{9}{40} \cdot {x}^{2} - \mathsf{fma}\left(\frac{27}{2800}, {x}^{4}, \frac{1}{2}\right)\\
\mathbf{else}:\\
\;\;\;\;\log \left(e^{\frac{x - \sin x}{x - \tan x}}\right)\\
\end{array}double f(double x) {
double r24036 = x;
double r24037 = sin(r24036);
double r24038 = r24036 - r24037;
double r24039 = tan(r24036);
double r24040 = r24036 - r24039;
double r24041 = r24038 / r24040;
return r24041;
}
double f(double x) {
double r24042 = x;
double r24043 = -0.029638169034640425;
bool r24044 = r24042 <= r24043;
double r24045 = tan(r24042);
double r24046 = r24042 - r24045;
double r24047 = r24042 / r24046;
double r24048 = sin(r24042);
double r24049 = r24048 / r24046;
double r24050 = r24047 - r24049;
double r24051 = 0.028662423939317287;
bool r24052 = r24042 <= r24051;
double r24053 = 0.225;
double r24054 = 2.0;
double r24055 = pow(r24042, r24054);
double r24056 = r24053 * r24055;
double r24057 = 0.009642857142857142;
double r24058 = 4.0;
double r24059 = pow(r24042, r24058);
double r24060 = 0.5;
double r24061 = fma(r24057, r24059, r24060);
double r24062 = r24056 - r24061;
double r24063 = r24042 - r24048;
double r24064 = r24063 / r24046;
double r24065 = exp(r24064);
double r24066 = log(r24065);
double r24067 = r24052 ? r24062 : r24066;
double r24068 = r24044 ? r24050 : r24067;
return r24068;
}



Bits error versus x
if x < -0.029638169034640425Initial program 0.0
rmApplied div-sub0.0
if -0.029638169034640425 < x < 0.028662423939317287Initial program 63.3
Taylor expanded around 0 0.0
Simplified0.0
if 0.028662423939317287 < x Initial program 0.0
rmApplied add-log-exp0.0
Final simplification0.0
herbie shell --seed 2019325 +o rules:numerics
(FPCore (x)
:name "sintan (problem 3.4.5)"
:precision binary64
(/ (- x (sin x)) (- x (tan x))))