Solving $a x = [\ln(x) - b]^c$

121 Views Asked by At

I'm trying to solve the nonlinear equation $a x = [\ln(x) - b]^c$ for x, where a, b, and c are constants, for a project. I've tried numerical techniques like in Excel Solver, but the solutions seem to be at local points where the solvers get stuck. Those "solutions" aren't sufficiently accurate for my purpose. I'm thinking that there may be a closed-form solution, perhaps using the Lambert W function after converting the equation to the proper form if possible. I'm not a mathematician, so any help finding the global root(s) is much appreciated.

2

There are 2 best solutions below

10
On BEST ANSWER

Notice that we want to get the equation to be of the form $y(x)e^{y(x)}$ so we can use the Lambert-$W$ function that inverts this: $W\left(y(x)e^{y(x)}\right)=y(x)$: $$ax=\left(\ln x-b\right)^c\\ a^{1/c}x^{1/c}=\ln x-b\\ e^{a^{1/c}x^{1/c}}=xe^{-b}\\ e^{(-1/c) a^{1/c}x^{1/c}}=x^{-1/c}e^{b/c}\\ x^{1/c}e^{(-1/c) a^{1/c}x^{1/c}}=e^{b/c}\\ -1/c\cdot a^{1/c}x^{1/c}e^{(-1/c) a^{1/c}x^{1/c}}=-1/c\cdot a^{1/c}e^{b/c}$$ Now, we can use $W$: $$-1/c\cdot a^{1/c}x^{1/c}=W\left(-1/c\cdot a^{1/c}e^{b/c}\right)\\ x=\frac{(-c)^c}{a}W^c\left(-1/c\cdot a^{1/c}e^{b/c}\right) $$ You can use WolframAlpha to compute $W$ but write "product log of" instead of "Lambert-$W$ of."

1
On

$$ \left(\frac{a}{b}\right)^{1/c}x^{1/c} = \ln x - b $$ let $x^{1/c} = y$ we have $$ \left(\frac{a}{b}\right)^{1/c} y = \ln y^c - b = c\ln y - b $$ we then have $$ \frac{1}{c}\left(\frac{a}{b}\right)^{1/c} y = z $$ we have $$ z = \ln \left[\frac{c}{\left(\frac{a}{b}\right)^{1/c}}z\right] - \frac{b}{c} $$ or $$ z = \ln (\lambda z) - \frac{b}{c} = \ln z + \ln \lambda - \frac{b}{c} = \ln z + \lambda_1 $$ which is $$ \mathrm{e}^{z} = \mathrm{e}^{\lambda_1}z = \lambda_2 z $$ which is $$ -z\mathrm{e}^{-z} = -\frac{1}{\lambda_2} $$ which is $$ -z = \mathrm{W}\left[-\frac{1}{\lambda_2}\right] $$ or $$ z = -\mathrm{W}\left[-\frac{1}{\lambda_2}\right] $$ where $\mathrm{W}$ is the lambert function.

$$ \frac{1}{c}\left(\frac{a}{b}\right)^{1/c} x^{1/c} = -\mathrm{W}\left[-\mathrm{e}^{\frac{b}{c} - \ln \left(\frac{c}{\left(\frac{a}{b}\right)^{1/c}}\right)}\right] $$

you can compare with this post on lambert solution which solves $\ln x = x- 2$ which is equivalent to a few steps above.