\frac{1 - \tan x \cdot \tan x}{1 + \tan x \cdot \tan x}\frac{\mathsf{fma}\left(\tan x, \sqrt{1}, 1\right) + \left(-\tan x\right) \cdot \left(\sqrt{1} + \tan x\right)}{1 + \tan x \cdot \tan x}double f(double x) {
double r11830 = 1.0;
double r11831 = x;
double r11832 = tan(r11831);
double r11833 = r11832 * r11832;
double r11834 = r11830 - r11833;
double r11835 = r11830 + r11833;
double r11836 = r11834 / r11835;
return r11836;
}
double f(double x) {
double r11837 = x;
double r11838 = tan(r11837);
double r11839 = 1.0;
double r11840 = sqrt(r11839);
double r11841 = fma(r11838, r11840, r11839);
double r11842 = -r11838;
double r11843 = r11840 + r11838;
double r11844 = r11842 * r11843;
double r11845 = r11841 + r11844;
double r11846 = r11838 * r11838;
double r11847 = r11839 + r11846;
double r11848 = r11845 / r11847;
return r11848;
}



Bits error versus x
Initial program 0.3
rmApplied add-sqr-sqrt0.3
Applied difference-of-squares0.4
rmApplied sub-neg0.4
Applied distribute-lft-in0.4
Simplified0.4
Simplified0.4
Final simplification0.4
herbie shell --seed 2019351 +o rules:numerics
(FPCore (x)
:name "Trigonometry B"
:precision binary64
(/ (- 1 (* (tan x) (tan x))) (+ 1 (* (tan x) (tan x)))))