Average Error: 0 → 0
Time: 1.6s
Precision: 64
\[2 \cdot \left(\left(1 \cdot \frac{1}{9} + \frac{1}{9} \cdot \frac{1}{9}\right) + \frac{1}{9} \cdot 1\right)\]
\[2 \cdot \left(\frac{1}{9} \cdot \left(\left(1 + \frac{1}{9}\right) + 1\right)\right)\]
2 \cdot \left(\left(1 \cdot \frac{1}{9} + \frac{1}{9} \cdot \frac{1}{9}\right) + \frac{1}{9} \cdot 1\right)
2 \cdot \left(\frac{1}{9} \cdot \left(\left(1 + \frac{1}{9}\right) + 1\right)\right)
double f() {
        double r59169 = 2.0;
        double r59170 = 1.0;
        double r59171 = 9.0;
        double r59172 = r59170 / r59171;
        double r59173 = r59170 * r59172;
        double r59174 = r59172 * r59172;
        double r59175 = r59173 + r59174;
        double r59176 = r59172 * r59170;
        double r59177 = r59175 + r59176;
        double r59178 = r59169 * r59177;
        return r59178;
}

double f() {
        double r59179 = 2.0;
        double r59180 = 1.0;
        double r59181 = 9.0;
        double r59182 = r59180 / r59181;
        double r59183 = r59180 + r59182;
        double r59184 = r59183 + r59180;
        double r59185 = r59182 * r59184;
        double r59186 = r59179 * r59185;
        return r59186;
}

Error

Try it out

Your Program's Arguments

    Results

    Enter valid numbers for all inputs

    Target

    Original0
    Target0
    Herbie0
    \[\left(\left(\frac{1}{9} \cdot 1\right) \cdot 2 + 2 \cdot \left(\frac{1}{9} \cdot \frac{1}{9}\right)\right) + 2 \cdot \left(1 \cdot \frac{1}{9}\right)\]

    Derivation

    1. Initial program 0

      \[2 \cdot \left(\left(1 \cdot \frac{1}{9} + \frac{1}{9} \cdot \frac{1}{9}\right) + \frac{1}{9} \cdot 1\right)\]
    2. Simplified0

      \[\leadsto \color{blue}{2 \cdot \left(\frac{1}{9} \cdot \left(\left(1 + \frac{1}{9}\right) + 1\right)\right)}\]
    3. Final simplification0

      \[\leadsto 2 \cdot \left(\frac{1}{9} \cdot \left(\left(1 + \frac{1}{9}\right) + 1\right)\right)\]

    Reproduce

    herbie shell --seed 2020043 
    (FPCore ()
      :name "Rectangular parallelepiped of dimension a×b×c"
      :precision binary64
    
      :herbie-target
      (+ (+ (* (* (/ 1 9) 1) 2) (* 2 (* (/ 1 9) (/ 1 9)))) (* 2 (* 1 (/ 1 9))))
    
      (* 2 (+ (+ (* 1 (/ 1 9)) (* (/ 1 9) (/ 1 9))) (* (/ 1 9) 1))))