Average Error: 17.0 → 0.4
Time: 1.1m
Precision: 64
Internal Precision: 1344
\[\left(J \cdot \left(e^{\ell} - e^{-\ell}\right)\right) \cdot \cos \left(\frac{K}{2}\right) + U\]
\[(\left(\cos \left(\frac{K}{2}\right) \cdot J\right) \cdot \left((\ell \cdot \left((\left(\ell \cdot \frac{1}{3}\right) \cdot \ell + 2)_*\right) + \left({\ell}^{5} \cdot \frac{1}{60}\right))_*\right) + U)_*\]

Error

Bits error versus J

Bits error versus l

Bits error versus K

Bits error versus U

Derivation

  1. Initial program 17.0

    \[\left(J \cdot \left(e^{\ell} - e^{-\ell}\right)\right) \cdot \cos \left(\frac{K}{2}\right) + U\]
  2. Taylor expanded around 0 0.4

    \[\leadsto \left(J \cdot \color{blue}{\left(\frac{1}{3} \cdot {\ell}^{3} + \left(2 \cdot \ell + \frac{1}{60} \cdot {\ell}^{5}\right)\right)}\right) \cdot \cos \left(\frac{K}{2}\right) + U\]
  3. Applied simplify0.4

    \[\leadsto \color{blue}{(\left(\cos \left(\frac{K}{2}\right) \cdot J\right) \cdot \left((\ell \cdot \left((\left(\ell \cdot \frac{1}{3}\right) \cdot \ell + 2)_*\right) + \left({\ell}^{5} \cdot \frac{1}{60}\right))_*\right) + U)_*}\]

Runtime

Time bar (total: 1.1m)Debug logProfile

herbie shell --seed '#(1072330854 3074818769 591214268 3603999196 3863745332 3332387116)' +o rules:numerics
(FPCore (J l K U)
  :name "Maksimov and Kolovsky, Equation (4)"
  (+ (* (* J (- (exp l) (exp (- l)))) (cos (/ K 2))) U))