Average Error: 59.4 → 59.4
Time: 10.8s
Precision: 64
\[\sqrt{0.5 \cdot \left(1 - \sqrt{1 - ti \cdot ti}\right)}\]
\[\sqrt{0.5 \cdot \sqrt[3]{{\left(1 - \sqrt{\sqrt{1} + ti} \cdot \sqrt{\sqrt{1} - ti}\right)}^{3}}}\]
\sqrt{0.5 \cdot \left(1 - \sqrt{1 - ti \cdot ti}\right)}
\sqrt{0.5 \cdot \sqrt[3]{{\left(1 - \sqrt{\sqrt{1} + ti} \cdot \sqrt{\sqrt{1} - ti}\right)}^{3}}}
double f(double ti) {
        double r403577 = 0.5;
        double r403578 = 1.0;
        double r403579 = ti;
        double r403580 = r403579 * r403579;
        double r403581 = r403578 - r403580;
        double r403582 = sqrt(r403581);
        double r403583 = r403578 - r403582;
        double r403584 = r403577 * r403583;
        double r403585 = sqrt(r403584);
        return r403585;
}

double f(double ti) {
        double r403586 = 0.5;
        double r403587 = 1.0;
        double r403588 = sqrt(r403587);
        double r403589 = ti;
        double r403590 = r403588 + r403589;
        double r403591 = sqrt(r403590);
        double r403592 = r403588 - r403589;
        double r403593 = sqrt(r403592);
        double r403594 = r403591 * r403593;
        double r403595 = r403587 - r403594;
        double r403596 = 3.0;
        double r403597 = pow(r403595, r403596);
        double r403598 = cbrt(r403597);
        double r403599 = r403586 * r403598;
        double r403600 = sqrt(r403599);
        return r403600;
}

Error

Bits error versus ti

Try it out

Your Program's Arguments

Results

Enter valid numbers for all inputs

Derivation

  1. Initial program 59.4

    \[\sqrt{0.5 \cdot \left(1 - \sqrt{1 - ti \cdot ti}\right)}\]
  2. Using strategy rm
  3. Applied add-sqr-sqrt59.4

    \[\leadsto \sqrt{0.5 \cdot \left(1 - \sqrt{\color{blue}{\sqrt{1} \cdot \sqrt{1}} - ti \cdot ti}\right)}\]
  4. Applied difference-of-squares59.4

    \[\leadsto \sqrt{0.5 \cdot \left(1 - \sqrt{\color{blue}{\left(\sqrt{1} + ti\right) \cdot \left(\sqrt{1} - ti\right)}}\right)}\]
  5. Applied sqrt-prod59.4

    \[\leadsto \sqrt{0.5 \cdot \left(1 - \color{blue}{\sqrt{\sqrt{1} + ti} \cdot \sqrt{\sqrt{1} - ti}}\right)}\]
  6. Using strategy rm
  7. Applied add-cbrt-cube59.4

    \[\leadsto \sqrt{0.5 \cdot \color{blue}{\sqrt[3]{\left(\left(1 - \sqrt{\sqrt{1} + ti} \cdot \sqrt{\sqrt{1} - ti}\right) \cdot \left(1 - \sqrt{\sqrt{1} + ti} \cdot \sqrt{\sqrt{1} - ti}\right)\right) \cdot \left(1 - \sqrt{\sqrt{1} + ti} \cdot \sqrt{\sqrt{1} - ti}\right)}}}\]
  8. Simplified59.4

    \[\leadsto \sqrt{0.5 \cdot \sqrt[3]{\color{blue}{{\left(1 - \sqrt{\sqrt{1} + ti} \cdot \sqrt{\sqrt{1} - ti}\right)}^{3}}}}\]
  9. Final simplification59.4

    \[\leadsto \sqrt{0.5 \cdot \sqrt[3]{{\left(1 - \sqrt{\sqrt{1} + ti} \cdot \sqrt{\sqrt{1} - ti}\right)}^{3}}}\]

Reproduce

herbie shell --seed 1 
(FPCore (ti)
  :name "sqrt(.5*(1-sqrt(1-ti*ti)))"
  :precision binary64
  (sqrt (* 0.5 (- 1 (sqrt (- 1 (* ti ti)))))))