Average Error: 0.4 → 0.5
Time: 5.5s
Precision: 64
Internal Precision: 576
$\frac{1}{1 + \cos x}$
$e^{-\left(\log \left(1 + {\left(\cos x\right)}^{3}\right) - \log \left(\left(\cos x \cdot \cos x - \cos x\right) + 1\right)\right)}$

# Try it out

Results

 In Out
Enter valid numbers for all inputs

# Derivation

1. Initial program 0.4

$\frac{1}{1 + \cos x}$
2. Using strategy rm

$\leadsto \frac{1}{\color{blue}{e^{\log \left(1 + \cos x\right)}}}$
4. Applied rec-exp0.4

$\leadsto \color{blue}{e^{-\log \left(1 + \cos x\right)}}$
5. Using strategy rm
6. Applied flip3-+0.5

$\leadsto e^{-\log \color{blue}{\left(\frac{{1}^{3} + {\left(\cos x\right)}^{3}}{1 \cdot 1 + \left(\cos x \cdot \cos x - 1 \cdot \cos x\right)}\right)}}$
7. Applied log-div0.5

$\leadsto e^{-\color{blue}{\left(\log \left({1}^{3} + {\left(\cos x\right)}^{3}\right) - \log \left(1 \cdot 1 + \left(\cos x \cdot \cos x - 1 \cdot \cos x\right)\right)\right)}}$
8. Simplified0.5

$\leadsto e^{-\left(\color{blue}{\log \left(1 + {\left(\cos x\right)}^{3}\right)} - \log \left(1 \cdot 1 + \left(\cos x \cdot \cos x - 1 \cdot \cos x\right)\right)\right)}$
9. Final simplification0.5

$\leadsto e^{-\left(\log \left(1 + {\left(\cos x\right)}^{3}\right) - \log \left(\left(\cos x \cdot \cos x - \cos x\right) + 1\right)\right)}$

# Runtime

Time bar (total: 5.5s)Debug log

herbie shell --seed '#(2775764126 3555076145 3898259844 1891440260 2599947619 1948460636)'
(FPCore (x)
:name "1 / (1 + cos(x))"
(/ 1 (+ 1 (cos x))))