Average Error: 0.3 → 0.0
Time: 3.8s
Precision: binary64
\[\log x - \log \log x \]
\[\log \left(\frac{x}{-\log \left(\frac{1}{x}\right)}\right) \]
\log x - \log \log x
\log \left(\frac{x}{-\log \left(\frac{1}{x}\right)}\right)
(FPCore (x) :precision binary64 (- (log x) (log (log x))))
(FPCore (x) :precision binary64 (log (/ x (- (log (/ 1.0 x))))))
double code(double x) {
	return log(x) - log(log(x));
}
double code(double x) {
	return log(x / -log(1.0 / x));
}

Error

Bits error versus x

Try it out

Your Program's Arguments

Results

Enter valid numbers for all inputs

Derivation

  1. Initial program 0.3

    \[\log x - \log \log x \]
  2. Taylor expanded in x around inf 0.3

    \[\leadsto \log x - \color{blue}{\log \left(-\log \left(\frac{1}{x}\right)\right)} \]
  3. Applied diff-log_binary640.0

    \[\leadsto \color{blue}{\log \left(\frac{x}{-\log \left(\frac{1}{x}\right)}\right)} \]
  4. Final simplification0.0

    \[\leadsto \log \left(\frac{x}{-\log \left(\frac{1}{x}\right)}\right) \]

Reproduce

herbie shell --seed 2021280 
(FPCore (x)
  :name "Jmat.Real.lambertw, estimator"
  :precision binary64
  (- (log x) (log (log x))))