Average Error: 0.0 → 0.0
Time: 14.8s
Precision: 64
Internal Precision: 576
\[\Re(\left(\frac{e^{x} + e^{-x}}{2} \cdot \cos y + \frac{e^{x} - e^{-x}}{2} \cdot \sin y i\right))\]
\[\frac{\sqrt[3]{e^{x}} \cdot \left(\cos y \cdot e^{x \cdot \frac{2}{3}}\right) + \frac{\cos y}{e^{x}}}{2}\]

Error

Bits error versus x

Bits error versus y

Derivation

  1. Initial program 0.0

    \[\Re(\left(\frac{e^{x} + e^{-x}}{2} \cdot \cos y + \frac{e^{x} - e^{-x}}{2} \cdot \sin y i\right))\]
  2. Initial simplification0.0

    \[\leadsto \frac{\frac{\cos y}{e^{x}} + \cos y \cdot e^{x}}{2}\]
  3. Using strategy rm
  4. Applied add-cube-cbrt0.0

    \[\leadsto \frac{\frac{\cos y}{e^{x}} + \cos y \cdot \color{blue}{\left(\left(\sqrt[3]{e^{x}} \cdot \sqrt[3]{e^{x}}\right) \cdot \sqrt[3]{e^{x}}\right)}}{2}\]
  5. Applied associate-*r*0.0

    \[\leadsto \frac{\frac{\cos y}{e^{x}} + \color{blue}{\left(\cos y \cdot \left(\sqrt[3]{e^{x}} \cdot \sqrt[3]{e^{x}}\right)\right) \cdot \sqrt[3]{e^{x}}}}{2}\]
  6. Taylor expanded around -inf 0.0

    \[\leadsto \frac{\frac{\cos y}{e^{x}} + \left(\cos y \cdot \color{blue}{{\left(e^{\frac{1}{3} \cdot x}\right)}^{2}}\right) \cdot \sqrt[3]{e^{x}}}{2}\]
  7. Simplified0.0

    \[\leadsto \frac{\frac{\cos y}{e^{x}} + \left(\cos y \cdot \color{blue}{e^{x \cdot \frac{2}{3}}}\right) \cdot \sqrt[3]{e^{x}}}{2}\]
  8. Final simplification0.0

    \[\leadsto \frac{\sqrt[3]{e^{x}} \cdot \left(\cos y \cdot e^{x \cdot \frac{2}{3}}\right) + \frac{\cos y}{e^{x}}}{2}\]

Runtime

Time bar (total: 14.8s)Debug logProfile

herbie shell --seed 2018249 
(FPCore (x y)
  :name "Euler formula real part (p55)"
  (re (complex (* (/ (+ (exp x) (exp (- x))) 2) (cos y)) (* (/ (- (exp x) (exp (- x))) 2) (sin y)))))