(28/48/50) Lambert W Function
|
03-27-2023, 04:45 PM
Post: #13
|
|||
|
|||
RE: (28/48/50) Lambert W Function
Hi Albert,
I am still having problems with your Lua program. This line, h = x/(1+x) * s(x) returns zero or a very small number (usually 10^-12 or less) and thus no correction occurs in the line x = x - h. This may be caused by the difference between the 64-bit binary floats used by Lua and the 12-digit BCD floats used by HP calculators. It is also possible that I made an error in translating the program although I have checked carefully. I was careful to sum the values in this line s = function(x) return (x+1) + log1p((x*err-(a+r)+r*(1+x))/a) in the proper order as suggested in your post. I have also seen several mentions of using Taylor series rather than iteration for values close to -1/e. This may also be worth exploring. |
|||
« Next Oldest | Next Newest »
|
User(s) browsing this thread: 6 Guest(s)