Average Error: 0.3 → 0.3
Time: 1.7m
Precision: 64
Internal precision: 128
\[\left(\left(\log \left(x + y\right) + \log z\right) - t\right) + \left(a - 0.5\right) \cdot \log t\]
\[\log \left(x + y\right) + \left(\log t \cdot \left(a - 0.5\right) + \left(\log z - t\right)\right)\]

Error

Bits error versus x

Bits error versus y

Bits error versus z

Bits error versus t

Bits error versus a

Target

Original0.3
Comparison0.3
Herbie0.3
\[ \log \left(x + y\right) + \left(\left(\log z - t\right) + \left(a - 0.5\right) \cdot \log t\right) \]

Derivation

  1. Initial program 0.3

    \[\left(\left(\log \left(x + y\right) + \log z\right) - t\right) + \left(a - 0.5\right) \cdot \log t\]
  2. Applied taylor 0.3

    \[\leadsto \left(\left(\log \left(x + y\right) + \log z\right) - t\right) + \left(a \cdot \log t - 0.5 \cdot \log t\right)\]
  3. Taylor expanded around 0 0.3

    \[\leadsto \left(\left(\log \left(x + y\right) + \log z\right) - t\right) + \color{blue}{\left(a \cdot \log t - 0.5 \cdot \log t\right)}\]
  4. Applied simplify 0.3

    \[\leadsto \color{blue}{\log \left(x + y\right) + \left(\log t \cdot \left(a - 0.5\right) + \left(\log z - t\right)\right)}\]
  5. Removed slow pow expressions

Runtime

Time bar (total: 1.7m) Debug log

Please include this information when filing a bug report:

herbie --seed '#(1446315536 2105346565 1434350744 3738715101 427431722 894037432)'
(FPCore (x y z t a)
  :name "Numeric.SpecFunctions:logGammaL from math-functions-0.1.5.2"

  :target
  (+ (log (+ x y)) (+ (- (log z) t) (* (- a 0.5) (log t))))

  (+ (- (+ (log (+ x y)) (log z)) t) (* (- a 0.5) (log t))))