Monday, 15 July 2013

calculus - Approximation of the solution n to the equation nlogn=100,000





How can I find an approximation value for the value of n for which nlog(n)=100000

or each numeric value?


Answer



The solution of equation xlog(x)=a

is given in terms of Lambert function x=aW(a)
In the Wikipedia page, you will find quite simple formulas for the approximation of Lambert function.



For example, for very large values of a W(a)L1L2+L2L1+L2(L22)2L21+

where L1=log(a) and L2=log(L1).




For the case of a=100000, L1=11.5129, L2=2.44347 and the above formula would give W(100000)9.28337

so x10772.0 while the exact solution would be x10770.6. Adding more terms would improve the result.



Another way would be to consider f(x)=xlog(x)a

f(x)=1+log(x)
and use Newton method which, starting from a guess x0 will update it according to xk+1=xkf(xk)f(xk)
which would write xk+1=a+xklog(xk)+1
Let us consider again the case where a=100000 and let us be very lazy starting with x0=1. Then the successive iterates of Newton method will be x1=100001.
x2=15983.5
x3=10860.6
x4=10770.6
which is the solution for six significant figures.



For sure, starting with a better estimate such as x0=alog(a)

will make Newton method converging in less iterations as shown below x0=8685.89
x1=10793.6
x2=10770.6



Edit



Using values 103a107, I found, using a simple linear regression, than a good approximation is given by log(x)=0.933231log(a)1.52287

which will give as estimate x0=10110.7.


No comments:

Post a Comment

real analysis - How to find limhrightarrow0fracsin(ha)h

How to find limh0sin(ha)h without lhopital rule? I know when I use lhopital I easy get $$ \lim_{h\rightarrow 0}...