Average Error: 29.1 → 0.5
Time: 50.1s
Precision: 64
Internal Precision: 1344
$\frac{1}{700 \cdot \log x} - \frac{1}{700 \cdot \log \left(x + 300\right)}$
$\begin{array}{l} \mathbf{if}\;\left(\left(\frac{\frac{\frac{900}{7}}{\log x \cdot \log x}}{\left(-\log x\right) \cdot \left(x \cdot x\right)} + \left(\frac{\frac{\frac{3}{7}}{x}}{\log x \cdot \log x} + \frac{\frac{\frac{\frac{90000}{7}}{x}}{x \cdot x}}{\log x \cdot \log x}\right)\right) + \left(\frac{\frac{\frac{\frac{270000}{7}}{x}}{x \cdot x}}{{\left(-\log x\right)}^{4}} - \frac{\frac{\frac{\frac{270000}{7}}{x}}{x \cdot x}}{\left(\log x \cdot \log x\right) \cdot \left(-\log x\right)}\right)\right) - \frac{\frac{\frac{450}{7}}{x \cdot x}}{\log x \cdot \log x} \le 9.48947906084216 \cdot 10^{-12}:\\ \;\;\;\;\left(\left(\frac{\frac{\frac{900}{7}}{\log x \cdot \log x}}{\left(-\log x\right) \cdot \left(x \cdot x\right)} + \left(\frac{\frac{\frac{3}{7}}{x}}{\log x \cdot \log x} + \frac{\frac{\frac{\frac{90000}{7}}{x}}{x \cdot x}}{\log x \cdot \log x}\right)\right) + \left(\frac{\frac{\frac{\frac{270000}{7}}{x}}{x \cdot x}}{{\left(-\log x\right)}^{4}} - \frac{\frac{\frac{\frac{270000}{7}}{x}}{x \cdot x}}{\left(\log x \cdot \log x\right) \cdot \left(-\log x\right)}\right)\right) - \frac{\frac{\frac{450}{7}}{x \cdot x}}{\log x \cdot \log x}\\ \mathbf{else}:\\ \;\;\;\;\frac{\frac{1}{700}}{\log x} - \frac{1}{700 \cdot \log \left(x + 300\right)}\\ \end{array}$

Try it out

Results

 In Out
Enter valid numbers for all inputs

Derivation

1. Split input into 2 regimes
2. if (- (+ (+ (/ (/ 900/7 (* (log x) (log x))) (* (- (log x)) (* x x))) (+ (/ (/ 3/7 x) (* (log x) (log x))) (/ (/ (/ 90000/7 x) (* x x)) (* (log x) (log x))))) (- (/ (/ (/ 270000/7 x) (* x x)) (pow (- (log x)) 4)) (/ (/ (/ 270000/7 x) (* x x)) (* (* (log x) (log x)) (- (log x)))))) (/ (/ 450/7 (* x x)) (* (log x) (log x)))) < 9.48947906084216e-12

1. Initial program 59.3

$\frac{1}{700 \cdot \log x} - \frac{1}{700 \cdot \log \left(x + 300\right)}$
2. Taylor expanded around inf 1.5

$\leadsto \color{blue}{\left(\frac{900}{7} \cdot \frac{1}{{\left(\log \left(\frac{1}{x}\right)\right)}^{3} \cdot {x}^{2}} + \left(\frac{3}{7} \cdot \frac{1}{{\left(\log \left(\frac{1}{x}\right)\right)}^{2} \cdot x} + \left(\frac{270000}{7} \cdot \frac{1}{{\left(\log \left(\frac{1}{x}\right)\right)}^{4} \cdot {x}^{3}} + \frac{90000}{7} \cdot \frac{1}{{\left(\log \left(\frac{1}{x}\right)\right)}^{2} \cdot {x}^{3}}\right)\right)\right) - \left(\frac{450}{7} \cdot \frac{1}{{\left(\log \left(\frac{1}{x}\right)\right)}^{2} \cdot {x}^{2}} + \frac{270000}{7} \cdot \frac{1}{{\left(\log \left(\frac{1}{x}\right)\right)}^{3} \cdot {x}^{3}}\right)}$
3. Applied simplify0.6

$\leadsto \color{blue}{\left(\left(\frac{\frac{\frac{900}{7}}{\log x \cdot \log x}}{\left(-\log x\right) \cdot \left(x \cdot x\right)} + \left(\frac{\frac{\frac{3}{7}}{x}}{\log x \cdot \log x} + \frac{\frac{\frac{\frac{90000}{7}}{x}}{x \cdot x}}{\log x \cdot \log x}\right)\right) + \left(\frac{\frac{\frac{\frac{270000}{7}}{x}}{x \cdot x}}{{\left(-\log x\right)}^{4}} - \frac{\frac{\frac{\frac{270000}{7}}{x}}{x \cdot x}}{\left(\log x \cdot \log x\right) \cdot \left(-\log x\right)}\right)\right) - \frac{\frac{\frac{450}{7}}{x \cdot x}}{\log x \cdot \log x}}$

if 9.48947906084216e-12 < (- (+ (+ (/ (/ 900/7 (* (log x) (log x))) (* (- (log x)) (* x x))) (+ (/ (/ 3/7 x) (* (log x) (log x))) (/ (/ (/ 90000/7 x) (* x x)) (* (log x) (log x))))) (- (/ (/ (/ 270000/7 x) (* x x)) (pow (- (log x)) 4)) (/ (/ (/ 270000/7 x) (* x x)) (* (* (log x) (log x)) (- (log x)))))) (/ (/ 450/7 (* x x)) (* (log x) (log x))))

1. Initial program 0.4

$\frac{1}{700 \cdot \log x} - \frac{1}{700 \cdot \log \left(x + 300\right)}$
2. Using strategy rm
3. Applied associate-/r*0.4

$\leadsto \color{blue}{\frac{\frac{1}{700}}{\log x}} - \frac{1}{700 \cdot \log \left(x + 300\right)}$
3. Recombined 2 regimes into one program.

Runtime

Time bar (total: 50.1s)Debug log

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