\pi \cdot \ell - \frac{1}{F \cdot F} \cdot \tan \left(\pi \cdot \ell\right)\begin{array}{l}
\mathbf{if}\;\pi \cdot \ell \le -2.9407008719341217 \cdot 10^{+25}:\\
\;\;\;\;\pi \cdot \ell - \left(\left(\frac{\tan \left(\pi \cdot \ell\right)}{F \cdot F}\right)\right)\\
\mathbf{elif}\;\pi \cdot \ell \le 1.897007709166529 \cdot 10^{+17}:\\
\;\;\;\;\pi \cdot \ell - \frac{1}{F} \cdot \frac{1}{\frac{F}{\tan \left(\pi \cdot \ell\right)}}\\
\mathbf{else}:\\
\;\;\;\;\pi \cdot \ell - \left(\left(\frac{\tan \left(\pi \cdot \ell\right)}{F \cdot F}\right)\right)\\
\end{array}double f(double F, double l) {
double r763940 = atan2(1.0, 0.0);
double r763941 = l;
double r763942 = r763940 * r763941;
double r763943 = 1.0;
double r763944 = F;
double r763945 = r763944 * r763944;
double r763946 = r763943 / r763945;
double r763947 = tan(r763942);
double r763948 = r763946 * r763947;
double r763949 = r763942 - r763948;
return r763949;
}
double f(double F, double l) {
double r763950 = atan2(1.0, 0.0);
double r763951 = l;
double r763952 = r763950 * r763951;
double r763953 = -2.9407008719341217e+25;
bool r763954 = r763952 <= r763953;
double r763955 = tan(r763952);
double r763956 = F;
double r763957 = r763956 * r763956;
double r763958 = r763955 / r763957;
double r763959 = /* ERROR: no posit support in C */;
double r763960 = /* ERROR: no posit support in C */;
double r763961 = r763952 - r763960;
double r763962 = 1.897007709166529e+17;
bool r763963 = r763952 <= r763962;
double r763964 = 1.0;
double r763965 = r763964 / r763956;
double r763966 = r763956 / r763955;
double r763967 = r763964 / r763966;
double r763968 = r763965 * r763967;
double r763969 = r763952 - r763968;
double r763970 = r763963 ? r763969 : r763961;
double r763971 = r763954 ? r763961 : r763970;
return r763971;
}



Bits error versus F



Bits error versus l
if (* PI l) < -2.9407008719341217e+25 or 1.897007709166529e+17 < (* PI l) Initial program 24.1
Simplified24.1
rmApplied insert-posit1616.4
if -2.9407008719341217e+25 < (* PI l) < 1.897007709166529e+17Initial program 9.6
Simplified9.1
rmApplied *-un-lft-identity9.1
Applied times-frac1.3
rmApplied clear-num1.3
Final simplification8.9
herbie shell --seed 2019168 +o rules:numerics
(FPCore (F l)
:name "VandenBroeck and Keller, Equation (6)"
(- (* PI l) (* (/ 1 (* F F)) (tan (* PI l)))))