Average Error: 0.0 → 0.0
Time: 3.2s
Precision: 64
\[\log \left(x + 1\right) + 1\]
\[1 + \log \left(x + 1\right)\]
\log \left(x + 1\right) + 1
1 + \log \left(x + 1\right)
double f(double x) {
        double r45179163 = x;
        double r45179164 = 1.0;
        double r45179165 = r45179163 + r45179164;
        double r45179166 = log(r45179165);
        double r45179167 = r45179166 + r45179164;
        return r45179167;
}

double f(double x) {
        double r45179168 = 1.0;
        double r45179169 = x;
        double r45179170 = r45179169 + r45179168;
        double r45179171 = log(r45179170);
        double r45179172 = r45179168 + r45179171;
        return r45179172;
}

Error

Bits error versus x

Try it out

Your Program's Arguments

Results

Enter valid numbers for all inputs

Derivation

  1. Initial program 0.0

    \[\log \left(x + 1\right) + 1\]
  2. Final simplification0.0

    \[\leadsto 1 + \log \left(x + 1\right)\]

Reproduce

herbie shell --seed 1 
(FPCore (x)
  :name "log(x+1)+1"
  (+ (log (+ x 1.0)) 1.0))