\frac{1 - \tan x \cdot \tan x}{1 + \tan x \cdot \tan x}\frac{\sqrt[3]{{\left(1 - \frac{\tan x \cdot \sin x}{\cos x}\right)}^{3}}}{1 + \tan x \cdot \tan x}double code(double x) {
return ((1.0 - (tan(x) * tan(x))) / (1.0 + (tan(x) * tan(x))));
}
double code(double x) {
return (cbrt(pow((1.0 - ((tan(x) * sin(x)) / cos(x))), 3.0)) / (1.0 + (tan(x) * tan(x))));
}



Bits error versus x
Results
Initial program 0.3
rmApplied tan-quot0.4
Applied associate-*r/0.4
rmApplied add-cbrt-cube0.5
Simplified0.5
Final simplification0.5
herbie shell --seed 2020049
(FPCore (x)
:name "Trigonometry B"
:precision binary64
(/ (- 1 (* (tan x) (tan x))) (+ 1 (* (tan x) (tan x)))))