Average Error: 0.1 → 0.1
Time: 43.0s
Precision: 64
Internal Precision: 320
\[\left(\frac{m \cdot \left(1 - m\right)}{v} - 1\right) \cdot \left(1 - m\right)\]
\[(\left(\frac{m}{v}\right) \cdot \left((m \cdot m + \left(-m\right))_*\right) + m)_* + \left(\frac{m + \left(-m\right) \cdot m}{v} - 1\right)\]

Error

Bits error versus m

Bits error versus v

Derivation

  1. Initial program 0.1

    \[\left(\frac{m \cdot \left(1 - m\right)}{v} - 1\right) \cdot \left(1 - m\right)\]
  2. Using strategy rm
  3. Applied sub-neg0.1

    \[\leadsto \left(\frac{m \cdot \color{blue}{\left(1 + \left(-m\right)\right)}}{v} - 1\right) \cdot \left(1 - m\right)\]
  4. Applied distribute-lft-in0.1

    \[\leadsto \left(\frac{\color{blue}{m \cdot 1 + m \cdot \left(-m\right)}}{v} - 1\right) \cdot \left(1 - m\right)\]
  5. Using strategy rm
  6. Applied sub-neg0.1

    \[\leadsto \left(\frac{m \cdot 1 + m \cdot \left(-m\right)}{v} - 1\right) \cdot \color{blue}{\left(1 + \left(-m\right)\right)}\]
  7. Applied distribute-lft-in0.1

    \[\leadsto \color{blue}{\left(\frac{m \cdot 1 + m \cdot \left(-m\right)}{v} - 1\right) \cdot 1 + \left(\frac{m \cdot 1 + m \cdot \left(-m\right)}{v} - 1\right) \cdot \left(-m\right)}\]
  8. Simplified0.1

    \[\leadsto \left(\frac{m \cdot 1 + m \cdot \left(-m\right)}{v} - 1\right) \cdot 1 + \color{blue}{(\left(\frac{-1 + m}{\frac{v}{m}}\right) \cdot m + m)_*}\]
  9. Taylor expanded around -inf 0.1

    \[\leadsto \left(\frac{m \cdot 1 + m \cdot \left(-m\right)}{v} - 1\right) \cdot 1 + \color{blue}{\left(\left(m + \frac{{m}^{3}}{v}\right) - \frac{{m}^{2}}{v}\right)}\]
  10. Simplified0.1

    \[\leadsto \left(\frac{m \cdot 1 + m \cdot \left(-m\right)}{v} - 1\right) \cdot 1 + \color{blue}{(\left(\frac{m}{v}\right) \cdot \left(m \cdot m - m\right) + m)_*}\]
  11. Using strategy rm
  12. Applied fma-neg0.1

    \[\leadsto \left(\frac{m \cdot 1 + m \cdot \left(-m\right)}{v} - 1\right) \cdot 1 + (\left(\frac{m}{v}\right) \cdot \color{blue}{\left((m \cdot m + \left(-m\right))_*\right)} + m)_*\]
  13. Final simplification0.1

    \[\leadsto (\left(\frac{m}{v}\right) \cdot \left((m \cdot m + \left(-m\right))_*\right) + m)_* + \left(\frac{m + \left(-m\right) \cdot m}{v} - 1\right)\]

Runtime

Time bar (total: 43.0s)Debug logProfile

herbie shell --seed 2018250 +o rules:numerics
(FPCore (m v)
  :name "b parameter of renormalized beta distribution"
  :pre (and (< 0 m) (< 0 v) (< v 0.25))
  (* (- (/ (* m (- 1 m)) v) 1) (- 1 m)))