\frac{2}{1 + e^{-2 \cdot x}} - 1\begin{array}{l}
\mathbf{if}\;-2 \cdot x \le -0.006660654438723100610741933991221230826341:\\
\;\;\;\;\left(\sqrt[3]{\log \left(\sqrt{e^{\frac{2}{1 + e^{-2 \cdot x}} - 1}}\right)} \cdot \sqrt[3]{\log \left(\sqrt{e^{\frac{2}{1 + e^{-2 \cdot x}} - 1}}\right)}\right) \cdot \sqrt[3]{\log \left(\sqrt{e^{\frac{2}{1 + e^{-2 \cdot x}} - 1}}\right)} + \log \left(\sqrt{e^{\frac{2}{1 + e^{-2 \cdot x}} - 1}}\right)\\
\mathbf{elif}\;-2 \cdot x \le 5.083912517384328794752684776980800052115 \cdot 10^{-5}:\\
\;\;\;\;1 \cdot x - {x}^{3} \cdot \left(0.3333333333333333703407674875052180141211 + x \cdot 5.5511151231257827021181583404541015625 \cdot 10^{-17}\right)\\
\mathbf{else}:\\
\;\;\;\;\log \left(\sqrt{e^{\left(\frac{\sqrt{2}}{\sqrt{1 + e^{-2 \cdot x}}} + \sqrt{1}\right) \cdot \left(\frac{\sqrt{2}}{\sqrt{1 + e^{-2 \cdot x}}} - \sqrt{1}\right)}}\right) + \log \left(\sqrt{e^{\frac{2}{1 + e^{-2 \cdot x}} - 1}}\right)\\
\end{array}double f(double x, double __attribute__((unused)) y) {
double r60944 = 2.0;
double r60945 = 1.0;
double r60946 = -2.0;
double r60947 = x;
double r60948 = r60946 * r60947;
double r60949 = exp(r60948);
double r60950 = r60945 + r60949;
double r60951 = r60944 / r60950;
double r60952 = r60951 - r60945;
return r60952;
}
double f(double x, double __attribute__((unused)) y) {
double r60953 = -2.0;
double r60954 = x;
double r60955 = r60953 * r60954;
double r60956 = -0.006660654438723101;
bool r60957 = r60955 <= r60956;
double r60958 = 2.0;
double r60959 = 1.0;
double r60960 = exp(r60955);
double r60961 = r60959 + r60960;
double r60962 = r60958 / r60961;
double r60963 = r60962 - r60959;
double r60964 = exp(r60963);
double r60965 = sqrt(r60964);
double r60966 = log(r60965);
double r60967 = cbrt(r60966);
double r60968 = r60967 * r60967;
double r60969 = r60968 * r60967;
double r60970 = r60969 + r60966;
double r60971 = 5.083912517384329e-05;
bool r60972 = r60955 <= r60971;
double r60973 = r60959 * r60954;
double r60974 = 3.0;
double r60975 = pow(r60954, r60974);
double r60976 = 0.33333333333333337;
double r60977 = 5.551115123125783e-17;
double r60978 = r60954 * r60977;
double r60979 = r60976 + r60978;
double r60980 = r60975 * r60979;
double r60981 = r60973 - r60980;
double r60982 = sqrt(r60958);
double r60983 = sqrt(r60961);
double r60984 = r60982 / r60983;
double r60985 = sqrt(r60959);
double r60986 = r60984 + r60985;
double r60987 = r60984 - r60985;
double r60988 = r60986 * r60987;
double r60989 = exp(r60988);
double r60990 = sqrt(r60989);
double r60991 = log(r60990);
double r60992 = r60991 + r60966;
double r60993 = r60972 ? r60981 : r60992;
double r60994 = r60957 ? r60970 : r60993;
return r60994;
}



Bits error versus x



Bits error versus y
Results
if (* -2.0 x) < -0.006660654438723101Initial program 0.0
rmApplied add-log-exp0.0
Applied add-log-exp0.0
Applied diff-log0.0
Simplified0.0
rmApplied add-sqr-sqrt0.0
Applied log-prod0.0
rmApplied add-sqr-sqrt0.0
Applied add-sqr-sqrt0.0
Applied add-sqr-sqrt0.0
Applied times-frac0.0
Applied difference-of-squares0.0
rmApplied add-cube-cbrt0.0
Simplified0.0
Simplified0.0
if -0.006660654438723101 < (* -2.0 x) < 5.083912517384329e-05Initial program 59.2
rmApplied add-log-exp59.2
Applied add-log-exp59.2
Applied diff-log59.2
Simplified59.2
Taylor expanded around 0 0.0
Simplified0.0
if 5.083912517384329e-05 < (* -2.0 x) Initial program 0.1
rmApplied add-log-exp0.1
Applied add-log-exp0.1
Applied diff-log0.1
Simplified0.1
rmApplied add-sqr-sqrt0.1
Applied log-prod0.1
rmApplied add-sqr-sqrt0.1
Applied add-sqr-sqrt0.1
Applied add-sqr-sqrt0.1
Applied times-frac0.1
Applied difference-of-squares0.1
Final simplification0.1
herbie shell --seed 2019325
(FPCore (x y)
:name "Logistic function from Lakshay Garg"
:precision binary64
(- (/ 2 (+ 1 (exp (* -2 x)))) 1))