Average Error: 15.2 → 0.3
Time: 22.2s
Precision: 64
Internal precision: 128
\[\frac{\left(\frac{8.0}{3.0} \cdot \sin \left(x \cdot 0.5\right)\right) \cdot \sin \left(x \cdot 0.5\right)}{\sin x}\]
\[\left(8.0 \cdot \frac{\sin \left(x \cdot 0.5\right)}{3.0}\right) \cdot \frac{\sin \left(x \cdot 0.5\right)}{\sin x}\]

Error

Bits error versus x

Target

Original15.2
Comparison0.3
Herbie0.3
\[ \frac{\frac{8.0 \cdot \sin \left(x \cdot 0.5\right)}{3.0}}{\frac{\sin x}{\sin \left(x \cdot 0.5\right)}} \]

Derivation

  1. Initial program 15.2

    \[\frac{\left(\frac{8.0}{3.0} \cdot \sin \left(x \cdot 0.5\right)\right) \cdot \sin \left(x \cdot 0.5\right)}{\sin x}\]
  2. Using strategy rm
  3. Applied *-un-lft-identity 15.2

    \[\leadsto \frac{\left(\frac{8.0}{3.0} \cdot \sin \left(x \cdot 0.5\right)\right) \cdot \sin \left(x \cdot 0.5\right)}{\color{blue}{1 \cdot \sin x}}\]
  4. Applied times-frac 0.5

    \[\leadsto \color{blue}{\frac{\frac{8.0}{3.0} \cdot \sin \left(x \cdot 0.5\right)}{1} \cdot \frac{\sin \left(x \cdot 0.5\right)}{\sin x}}\]
  5. Applied simplify 0.5

    \[\leadsto \color{blue}{\left(\frac{8.0}{3.0} \cdot \sin \left(0.5 \cdot x\right)\right)} \cdot \frac{\sin \left(x \cdot 0.5\right)}{\sin x}\]
  6. Using strategy rm
  7. Applied div-inv 0.5

    \[\leadsto \left(\color{blue}{\left(8.0 \cdot \frac{1}{3.0}\right)} \cdot \sin \left(0.5 \cdot x\right)\right) \cdot \frac{\sin \left(x \cdot 0.5\right)}{\sin x}\]
  8. Applied associate-*l* 0.5

    \[\leadsto \color{blue}{\left(8.0 \cdot \left(\frac{1}{3.0} \cdot \sin \left(0.5 \cdot x\right)\right)\right)} \cdot \frac{\sin \left(x \cdot 0.5\right)}{\sin x}\]
  9. Applied simplify 0.3

    \[\leadsto \left(8.0 \cdot \color{blue}{\frac{\sin \left(x \cdot 0.5\right)}{3.0}}\right) \cdot \frac{\sin \left(x \cdot 0.5\right)}{\sin x}\]
  10. Removed slow pow expressions

Runtime

Time bar (total: 22.2s) Debug log

Please include this information when filing a bug report:

herbie --seed '#(3522717748 3264127147 1886148021 888355725 591090567 1320664872)'
(FPCore (x)
  :name "Graphics.Rasterific.Svg.PathConverter:segmentToBezier from rasterific-svg-0.2.3.1, A"

  :target
  (/ (/ (* 8.0 (sin (* x 0.5))) 3.0) (/ (sin x) (sin (* x 0.5))))

  (/ (* (* (/ 8.0 3.0) (sin (* x 0.5))) (sin (* x 0.5))) (sin x)))