Average Error: 0 → 0
Time: 1.6s
Precision: 64
\[\frac{20 \cdot \log \left(\left|x\right|\right)}{\log 10}\]
\[\frac{20 \cdot \log \left(\left|x\right|\right)}{\log 10}\]
\frac{20 \cdot \log \left(\left|x\right|\right)}{\log 10}
\frac{20 \cdot \log \left(\left|x\right|\right)}{\log 10}
double f(double x) {
        double r1158776 = 20.0;
        double r1158777 = x;
        double r1158778 = fabs(r1158777);
        double r1158779 = log(r1158778);
        double r1158780 = r1158776 * r1158779;
        double r1158781 = 10.0;
        double r1158782 = log(r1158781);
        double r1158783 = r1158780 / r1158782;
        return r1158783;
}

double f(double x) {
        double r1158784 = 20.0;
        double r1158785 = x;
        double r1158786 = fabs(r1158785);
        double r1158787 = log(r1158786);
        double r1158788 = r1158784 * r1158787;
        double r1158789 = 10.0;
        double r1158790 = log(r1158789);
        double r1158791 = r1158788 / r1158790;
        return r1158791;
}

Error

Bits error versus x

Try it out

Your Program's Arguments

Results

Enter valid numbers for all inputs

Derivation

  1. Initial program 0

    \[\frac{20 \cdot \log \left(\left|x\right|\right)}{\log 10}\]
  2. Final simplification0

    \[\leadsto \frac{20 \cdot \log \left(\left|x\right|\right)}{\log 10}\]

Reproduce

herbie shell --seed 1 
(FPCore (x)
  :name "20*log(abs(x))/log(10)"
  :precision binary32
  (/ (* 20 (log (fabs x))) (log 10)))