2
$\begingroup$

Let $0<a,b<1.$ How should one solve (for $x$) $$ x+a \log x= \log y -b \log \log y. $$ Please note the two opposite signs on $a,b.$ We can assume $y$ is very large and positive. Maybe the $W$ function is useful, but I am not an expert.

Even locating the solution in a manageable interval, whose two ends are in closed form would be good.

$\endgroup$
3
$\begingroup$

Let $z$ be your right-hand side. Then some manipulations (divide by $a$, exponentiate, divide by $a$ again) yields $$x+a \log x=z\implies (x/a)e^{x/a} = e^{z/a}/a\implies x/a = W(e^{z/a}/a)$$ where $W$ is the Lambert-W function. So $x=a W(e^{z/a}/a)$.

$\endgroup$
2
  • $\begingroup$ Great. My only excuse is it is 6am here and I just had my first sip of coffee $\endgroup$ – kodlu Jan 19 at 21:28
  • 3
    $\begingroup$ @kodiu Can't turn coffee into theorems without coffee. $\endgroup$ – Semiclassical Jan 19 at 21:32
2
$\begingroup$

As @Semiclassical wrote,

$$x+a\log(x)=k \implies x=a W\left(\frac{1}{a}e^{\frac{k}{a}}\right)$$ If you cannot use Lambert function, you will need a numerical method and take into account the fact that $\forall t \geq e$ $$W(t) \geq\log (t)-\log (\log (t))+\frac 12\frac{\log (\log (t))}{ \log (t)}=f(t)$$ $$W(t) \leq \log (t)-\log (\log (t))+\frac e{e-1}\frac{\log (\log (t))}{ \log (t)}=g(t)$$

In the past, I minimized $$\Phi(a)=\int_e^{1000} \Big[a\, f(t)+(1-a) \,g(t)-W(t) \Big]^2\,dt$$ and obtained $a_{opt}=0.57958$ for which $\Phi(a_{opt})=0.134235$; for comparison, $\Phi(0)=35.6714$, $\Phi(0.5)=0.80423$ and $\Phi(1)=18.8333$.

Making numbers rational, a good approximation is $$W(t) \sim \log (t)-\log (\log (t))+\frac{11133}{11659}\frac{\log (\log (t))}{ \log (t)}$$ Over the considered range, the maximum error is $\sim 0.007$.

With such an estimate, Newton method would converge to high accuracy within a couple of iterations.

Edit

For illustration, let use use $y=10^{99}$, $b=\frac 12$ and $a=\pi$. This would give $t\sim 4.36783\times 10^{30}$, $W(t)\sim 66.3531$ and then $x\sim 208.454$ while the "exact" solution is $x \sim 208.466$.

$\endgroup$
2
  • $\begingroup$ Wonderful. Thanks $\endgroup$ – kodlu Jan 20 at 10:45
  • 1
    $\begingroup$ @kodlu. Look at my edit, just for the fun $\endgroup$ – Claude Leibovici Jan 20 at 10:57

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.