Average Error: 0.3 → 0.1
Time: 26.4s
Precision: 64
\[0.0 \le t \le 1\]
\[\left(\left(\left({\left(1 - t\right)}^{3} \cdot a + \left(\left(3 \cdot {\left(1 - t\right)}^{2}\right) \cdot t\right) \cdot b\right) + \left(\left(3 \cdot \left(1 - t\right)\right) \cdot {t}^{2}\right) \cdot c\right) + {t}^{3}\right) + d\]
\[\left(\left(\left({\left(1 - t\right)}^{3} \cdot a + \left(\left(3 \cdot {\left(1 - t\right)}^{2}\right) \cdot t\right) \cdot b\right) + \left(\left(3 \cdot \left(1 - t\right)\right) \cdot {t}^{\left(\frac{2}{2}\right)}\right) \cdot \left({t}^{\left(\frac{2}{2}\right)} \cdot c\right)\right) + {t}^{3}\right) + d\]
\left(\left(\left({\left(1 - t\right)}^{3} \cdot a + \left(\left(3 \cdot {\left(1 - t\right)}^{2}\right) \cdot t\right) \cdot b\right) + \left(\left(3 \cdot \left(1 - t\right)\right) \cdot {t}^{2}\right) \cdot c\right) + {t}^{3}\right) + d
\left(\left(\left({\left(1 - t\right)}^{3} \cdot a + \left(\left(3 \cdot {\left(1 - t\right)}^{2}\right) \cdot t\right) \cdot b\right) + \left(\left(3 \cdot \left(1 - t\right)\right) \cdot {t}^{\left(\frac{2}{2}\right)}\right) \cdot \left({t}^{\left(\frac{2}{2}\right)} \cdot c\right)\right) + {t}^{3}\right) + d
double f(double t, double a, double b, double c, double d) {
        double r2011763 = 1.0;
        double r2011764 = t;
        double r2011765 = r2011763 - r2011764;
        double r2011766 = 3.0;
        double r2011767 = pow(r2011765, r2011766);
        double r2011768 = a;
        double r2011769 = r2011767 * r2011768;
        double r2011770 = 2.0;
        double r2011771 = pow(r2011765, r2011770);
        double r2011772 = r2011766 * r2011771;
        double r2011773 = r2011772 * r2011764;
        double r2011774 = b;
        double r2011775 = r2011773 * r2011774;
        double r2011776 = r2011769 + r2011775;
        double r2011777 = r2011766 * r2011765;
        double r2011778 = pow(r2011764, r2011770);
        double r2011779 = r2011777 * r2011778;
        double r2011780 = c;
        double r2011781 = r2011779 * r2011780;
        double r2011782 = r2011776 + r2011781;
        double r2011783 = pow(r2011764, r2011766);
        double r2011784 = r2011782 + r2011783;
        double r2011785 = d;
        double r2011786 = r2011784 + r2011785;
        return r2011786;
}

double f(double t, double a, double b, double c, double d) {
        double r2011787 = 1.0;
        double r2011788 = t;
        double r2011789 = r2011787 - r2011788;
        double r2011790 = 3.0;
        double r2011791 = pow(r2011789, r2011790);
        double r2011792 = a;
        double r2011793 = r2011791 * r2011792;
        double r2011794 = 2.0;
        double r2011795 = pow(r2011789, r2011794);
        double r2011796 = r2011790 * r2011795;
        double r2011797 = r2011796 * r2011788;
        double r2011798 = b;
        double r2011799 = r2011797 * r2011798;
        double r2011800 = r2011793 + r2011799;
        double r2011801 = r2011790 * r2011789;
        double r2011802 = 2.0;
        double r2011803 = r2011794 / r2011802;
        double r2011804 = pow(r2011788, r2011803);
        double r2011805 = r2011801 * r2011804;
        double r2011806 = c;
        double r2011807 = r2011804 * r2011806;
        double r2011808 = r2011805 * r2011807;
        double r2011809 = r2011800 + r2011808;
        double r2011810 = pow(r2011788, r2011790);
        double r2011811 = r2011809 + r2011810;
        double r2011812 = d;
        double r2011813 = r2011811 + r2011812;
        return r2011813;
}

Error

Bits error versus t

Bits error versus a

Bits error versus b

Bits error versus c

Bits error versus d

Try it out

Your Program's Arguments

Results

Enter valid numbers for all inputs

Derivation

  1. Initial program 0.3

    \[\left(\left(\left({\left(1 - t\right)}^{3} \cdot a + \left(\left(3 \cdot {\left(1 - t\right)}^{2}\right) \cdot t\right) \cdot b\right) + \left(\left(3 \cdot \left(1 - t\right)\right) \cdot {t}^{2}\right) \cdot c\right) + {t}^{3}\right) + d\]
  2. Using strategy rm
  3. Applied sqr-pow0.3

    \[\leadsto \left(\left(\left({\left(1 - t\right)}^{3} \cdot a + \left(\left(3 \cdot {\left(1 - t\right)}^{2}\right) \cdot t\right) \cdot b\right) + \left(\left(3 \cdot \left(1 - t\right)\right) \cdot \color{blue}{\left({t}^{\left(\frac{2}{2}\right)} \cdot {t}^{\left(\frac{2}{2}\right)}\right)}\right) \cdot c\right) + {t}^{3}\right) + d\]
  4. Applied associate-*r*0.3

    \[\leadsto \left(\left(\left({\left(1 - t\right)}^{3} \cdot a + \left(\left(3 \cdot {\left(1 - t\right)}^{2}\right) \cdot t\right) \cdot b\right) + \color{blue}{\left(\left(\left(3 \cdot \left(1 - t\right)\right) \cdot {t}^{\left(\frac{2}{2}\right)}\right) \cdot {t}^{\left(\frac{2}{2}\right)}\right)} \cdot c\right) + {t}^{3}\right) + d\]
  5. Using strategy rm
  6. Applied associate-*l*0.1

    \[\leadsto \left(\left(\left({\left(1 - t\right)}^{3} \cdot a + \left(\left(3 \cdot {\left(1 - t\right)}^{2}\right) \cdot t\right) \cdot b\right) + \color{blue}{\left(\left(3 \cdot \left(1 - t\right)\right) \cdot {t}^{\left(\frac{2}{2}\right)}\right) \cdot \left({t}^{\left(\frac{2}{2}\right)} \cdot c\right)}\right) + {t}^{3}\right) + d\]
  7. Final simplification0.1

    \[\leadsto \left(\left(\left({\left(1 - t\right)}^{3} \cdot a + \left(\left(3 \cdot {\left(1 - t\right)}^{2}\right) \cdot t\right) \cdot b\right) + \left(\left(3 \cdot \left(1 - t\right)\right) \cdot {t}^{\left(\frac{2}{2}\right)}\right) \cdot \left({t}^{\left(\frac{2}{2}\right)} \cdot c\right)\right) + {t}^{3}\right) + d\]

Reproduce

herbie shell --seed 1 
(FPCore (t a b c d)
  :name "pow(1-t,3)*a+3*pow(1-t,2)*t*b+3*(1-t)*pow(t,2)*c+pow(t,3)+d"
  :precision binary64
  :pre (<= 0.0 t 1)
  (+ (+ (+ (+ (* (pow (- 1 t) 3) a) (* (* (* 3 (pow (- 1 t) 2)) t) b)) (* (* (* 3 (- 1 t)) (pow t 2)) c)) (pow t 3)) d))