Average Error: 46.2 → 0.3
Time: 2.4s
Precision: binary64
\[i \gt 0.0\]
\[\frac{\frac{\left(i \cdot i\right) \cdot \left(i \cdot i\right)}{\left(2 \cdot i\right) \cdot \left(2 \cdot i\right)}}{\left(2 \cdot i\right) \cdot \left(2 \cdot i\right) - 1}\]
\[\begin{array}{l} \mathbf{if}\;i \le 0.497953185309610802:\\ \;\;\;\;1 \cdot \left(-{i}^{4}\right) - \left(4 \cdot {i}^{6} + i \cdot \left(i \cdot 0.25\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\frac{0.00390625}{{i}^{4}} + \left(\frac{0.015625}{i \cdot i} + 0.0625\right)\\ \end{array}\]

Error

Bits error versus i

Derivation

  1. Split input into 2 regimes
  2. if i < 0.497953185309610802

    1. Initial program 45.2

      \[\frac{\frac{\left(i \cdot i\right) \cdot \left(i \cdot i\right)}{\left(2 \cdot i\right) \cdot \left(2 \cdot i\right)}}{\left(2 \cdot i\right) \cdot \left(2 \cdot i\right) - 1}\]
    2. Simplified0.1

      \[\leadsto \color{blue}{\frac{i}{2 \cdot \left(2 \cdot \left(i \cdot \left(2 \cdot 2\right) - \frac{1}{i}\right)\right)}}\]
    3. Taylor expanded around 0 0.3

      \[\leadsto \color{blue}{-\left(1 \cdot {i}^{4} + \left(4 \cdot {i}^{6} + 0.25 \cdot {i}^{2}\right)\right)}\]
    4. Simplified0.3

      \[\leadsto \color{blue}{1 \cdot \left(-{i}^{4}\right) - \left(4 \cdot {i}^{6} + i \cdot \left(i \cdot 0.25\right)\right)}\]

    if 0.497953185309610802 < i

    1. Initial program 47.2

      \[\frac{\frac{\left(i \cdot i\right) \cdot \left(i \cdot i\right)}{\left(2 \cdot i\right) \cdot \left(2 \cdot i\right)}}{\left(2 \cdot i\right) \cdot \left(2 \cdot i\right) - 1}\]
    2. Simplified0.2

      \[\leadsto \color{blue}{\frac{i}{2 \cdot \left(2 \cdot \left(i \cdot \left(2 \cdot 2\right) - \frac{1}{i}\right)\right)}}\]
    3. Taylor expanded around inf 0.3

      \[\leadsto \color{blue}{0.00390625 \cdot \frac{1}{{i}^{4}} + \left(0.015625 \cdot \frac{1}{{i}^{2}} + 0.0625\right)}\]
    4. Simplified0.3

      \[\leadsto \color{blue}{\frac{0.00390625}{{i}^{4}} + \left(\frac{0.015625}{i \cdot i} + 0.0625\right)}\]
  3. Recombined 2 regimes into one program.
  4. Final simplification0.3

    \[\leadsto \begin{array}{l} \mathbf{if}\;i \le 0.497953185309610802:\\ \;\;\;\;1 \cdot \left(-{i}^{4}\right) - \left(4 \cdot {i}^{6} + i \cdot \left(i \cdot 0.25\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\frac{0.00390625}{{i}^{4}} + \left(\frac{0.015625}{i \cdot i} + 0.0625\right)\\ \end{array}\]

Reproduce

herbie shell --seed 2020182 
(FPCore (i)
  :name "Octave 3.8, jcobi/4, as called"
  :precision binary64
  :pre (and (> i 0.0))
  (/ (/ (* (* i i) (* i i)) (* (* 2.0 i) (* 2.0 i))) (- (* (* 2.0 i) (* 2.0 i)) 1.0)))