\frac{x - \sin x}{x - \tan x}\begin{array}{l}
\mathbf{if}\;x \le -0.02687365489421502:\\
\;\;\;\;\log \left(\sqrt{e^{\frac{x - \sin x}{x - \tan x}}}\right) + \log \left(\sqrt{e^{\frac{x - \sin x}{x - \tan x}}}\right)\\
\mathbf{elif}\;x \le 0.026232161789625133:\\
\;\;\;\;\frac{9}{40} \cdot \left(x \cdot x\right) - \left(\frac{1}{2} + \frac{27}{2800} \cdot \left(\left(x \cdot x\right) \cdot \left(x \cdot x\right)\right)\right)\\
\mathbf{else}:\\
\;\;\;\;\log \left(\sqrt{e^{\frac{x - \sin x}{x - \tan x}}}\right) + \log \left(\sqrt{e^{\frac{x - \sin x}{x - \tan x}}}\right)\\
\end{array}double f(double x) {
double r889526 = x;
double r889527 = sin(r889526);
double r889528 = r889526 - r889527;
double r889529 = tan(r889526);
double r889530 = r889526 - r889529;
double r889531 = r889528 / r889530;
return r889531;
}
double f(double x) {
double r889532 = x;
double r889533 = -0.02687365489421502;
bool r889534 = r889532 <= r889533;
double r889535 = sin(r889532);
double r889536 = r889532 - r889535;
double r889537 = tan(r889532);
double r889538 = r889532 - r889537;
double r889539 = r889536 / r889538;
double r889540 = exp(r889539);
double r889541 = sqrt(r889540);
double r889542 = log(r889541);
double r889543 = r889542 + r889542;
double r889544 = 0.026232161789625133;
bool r889545 = r889532 <= r889544;
double r889546 = 0.225;
double r889547 = r889532 * r889532;
double r889548 = r889546 * r889547;
double r889549 = 0.5;
double r889550 = 0.009642857142857142;
double r889551 = r889547 * r889547;
double r889552 = r889550 * r889551;
double r889553 = r889549 + r889552;
double r889554 = r889548 - r889553;
double r889555 = r889545 ? r889554 : r889543;
double r889556 = r889534 ? r889543 : r889555;
return r889556;
}



Bits error versus x
Results
if x < -0.02687365489421502 or 0.026232161789625133 < x Initial program 0.0
rmApplied add-log-exp0.1
rmApplied add-sqr-sqrt0.1
Applied log-prod0.1
if -0.02687365489421502 < x < 0.026232161789625133Initial program 62.8
Taylor expanded around 0 0.0
Simplified0.0
Final simplification0.0
herbie shell --seed 2019121
(FPCore (x)
:name "sintan (problem 3.4.5)"
(/ (- x (sin x)) (- x (tan x))))