Average Error: 31.2 → 0.0
Time: 34.5s
Precision: 64
Internal precision: 2432
\[\frac{x - \sin x}{x - \tan x}\]
\[\begin{array}{l} \mathbf{if}\;x \le -0.0004749914434913193:\\ \;\;\;\;\frac{x - \sin x}{x - \tan x}\\ \mathbf{if}\;x \le 28.042920304023237:\\ \;\;\;\;\frac{-1}{2} - \left(\frac{9}{20} \cdot {x}^2 - \frac{27}{1400} \cdot {x}^{4}\right) \cdot \sqrt[3]{\frac{-1}{8}}\\ \mathbf{else}:\\ \;\;\;\;\frac{x - \sin x}{x - \tan x}\\ \end{array}\]

Error

Bits error versus x

Derivation

  1. Split input into 2 regimes.
  2. if x < -0.0004749914434913193 or 28.042920304023237 < x

    1. Initial program 0.1

      \[\frac{x - \sin x}{x - \tan x}\]

    if -0.0004749914434913193 < x < 28.042920304023237

    1. Initial program 62.9

      \[\frac{x - \sin x}{x - \tan x}\]
    2. Using strategy rm
    3. Applied add-cbrt-cube 62.9

      \[\leadsto \frac{x - \sin x}{\color{blue}{\sqrt[3]{{\left(x - \tan x\right)}^3}}}\]
    4. Applied add-cbrt-cube 62.9

      \[\leadsto \frac{\color{blue}{\sqrt[3]{{\left(x - \sin x\right)}^3}}}{\sqrt[3]{{\left(x - \tan x\right)}^3}}\]
    5. Applied cbrt-undiv 62.9

      \[\leadsto \color{blue}{\sqrt[3]{\frac{{\left(x - \sin x\right)}^3}{{\left(x - \tan x\right)}^3}}}\]
    6. Applied simplify 62.9

      \[\leadsto \sqrt[3]{\color{blue}{{\left(\frac{x - \sin x}{x - \tan x}\right)}^3}}\]
    7. Applied taylor 63.6

      \[\leadsto \left(\frac{27}{1400} \cdot \left({\frac{-1}{8}}^{\frac{1}{3}} \cdot {x}^{4}\right) + {\left({\frac{-1}{2}}^{3}\right)}^{\frac{1}{3}}\right) - \frac{9}{20} \cdot \left({\frac{-1}{8}}^{\frac{1}{3}} \cdot {x}^2\right)\]
    8. Taylor expanded around 0 63.6

      \[\leadsto \color{blue}{\left(\frac{27}{1400} \cdot \left({\frac{-1}{8}}^{\frac{1}{3}} \cdot {x}^{4}\right) + {\left({\frac{-1}{2}}^{3}\right)}^{\frac{1}{3}}\right) - \frac{9}{20} \cdot \left({\frac{-1}{8}}^{\frac{1}{3}} \cdot {x}^2\right)}\]
    9. Applied simplify 0.0

      \[\leadsto \color{blue}{\frac{-1}{2} - \sqrt[3]{\frac{-1}{8}} \cdot \left(x \cdot \left(x \cdot \frac{9}{20}\right) - {x}^{4} \cdot \frac{27}{1400}\right)}\]
    10. Applied simplify 0.0

      \[\leadsto \frac{-1}{2} - \color{blue}{\left(\frac{9}{20} \cdot {x}^2 - \frac{27}{1400} \cdot {x}^{4}\right) \cdot \sqrt[3]{\frac{-1}{8}}}\]
  3. Recombined 2 regimes into one program.
  4. Removed slow pow expressions

Runtime

Time bar (total: 34.5s) Debug log

Please include this information when filing a bug report:

herbie shell --seed '#(2277612311 2645429965 1090895633 2857793080 2144184008 3989768357)'
(FPCore (x)
  :name "sintan (problem 3.4.5)"
  (/ (- x (sin x)) (- x (tan x))))