Average Error: 36.3 → 0
Time: 10.9s
Precision: 64
Internal precision: 128
\[\frac{\tan \left(\frac{x}{y \cdot 2.0}\right)}{\sin \left(\frac{x}{y \cdot 2.0}\right)}\]
\[1.0\]

Error

Bits error versus x

Bits error versus y

Target

Original36.3
Comparison9.3
Herbie0
\[ \begin{array}{l} \mathbf{if}\;y \lt -1.2303690911306994 \cdot 10^{+114}:\\ \;\;\;\;1.0\\ \mathbf{if}\;y \lt -9.102852406811914 \cdot 10^{-222}:\\ \;\;\;\;\frac{\sin \left(\frac{x}{y \cdot 2.0}\right)}{\sin \left(\frac{x}{y \cdot 2.0}\right) \cdot \log \left(e^{\cos \left(\frac{x}{y \cdot 2.0}\right)}\right)}\\ \mathbf{else}:\\ \;\;\;\;1.0\\ \end{array} \]

Derivation

  1. Initial program 36.3

    \[\frac{\tan \left(\frac{x}{y \cdot 2.0}\right)}{\sin \left(\frac{x}{y \cdot 2.0}\right)}\]
  2. Applied taylor 0

    \[\leadsto 1.0\]
  3. Taylor expanded around 0 0

    \[\leadsto \color{blue}{1.0}\]
  4. Removed slow pow expressions

Runtime

Time bar (total: 10.9s) Debug log

Please include this information when filing a bug report:

herbie --seed '#(2610056022 3221263209 3778254270 2080674038 2028339286 3037628873)'
(FPCore (x y)
  :name "Diagrams.TwoD.Layout.CirclePacking:approxRadius from diagrams-contrib-1.3.0.5"

  :target
  (if (< y -1.2303690911306994e+114) 1.0 (if (< y -9.102852406811914e-222) (/ (sin (/ x (* y 2.0))) (* (sin (/ x (* y 2.0))) (log (exp (cos (/ x (* y 2.0))))))) 1.0))

  (/ (tan (/ x (* y 2.0))) (sin (/ x (* y 2.0)))))