Average Error: 0.0 → 0.0
Time: 8.3s
Precision: 64
Internal Precision: 320
\[\frac{2}{e^{x} + e^{-x}}\]
\[\frac{2}{(\left(\sqrt{e^{x}}\right) \cdot \left(\sqrt{e^{x}}\right) + \left(e^{-x}\right))_*}\]

Error

Bits error versus x

Derivation

  1. Initial program 0.0

    \[\frac{2}{e^{x} + e^{-x}}\]
  2. Initial simplification0.0

    \[\leadsto \frac{2}{e^{x} + e^{-x}}\]
  3. Using strategy rm
  4. Applied add-sqr-sqrt0.0

    \[\leadsto \frac{2}{\color{blue}{\sqrt{e^{x}} \cdot \sqrt{e^{x}}} + e^{-x}}\]
  5. Applied fma-def0.0

    \[\leadsto \frac{2}{\color{blue}{(\left(\sqrt{e^{x}}\right) \cdot \left(\sqrt{e^{x}}\right) + \left(e^{-x}\right))_*}}\]
  6. Final simplification0.0

    \[\leadsto \frac{2}{(\left(\sqrt{e^{x}}\right) \cdot \left(\sqrt{e^{x}}\right) + \left(e^{-x}\right))_*}\]

Runtime

Time bar (total: 8.3s)Debug logProfile

herbie shell --seed 2018252 +o rules:numerics
(FPCore (x)
  :name "Hyperbolic secant"
  (/ 2 (+ (exp x) (exp (- x)))))