Hacker News new | past | comments | ask | show | jobs | submit login

Yes, I get that. It seems like Wolfram|Alpha thinks 10^100 is too large of a number for it to have to care about, and is rounding it to infinity internally somewhere, hoping it doesn't change the final result. But, of course, it does matter in this case.



You asked WA for the result with 100 digits of precision. It probably is 1 to that precision.


There is no need to guess. First of all:

    (1 + 1/n)^n = e^(log(1 + 1/n) * n)
Now from the Taylor series approximation:

    log(1 + t) = t - t^2/2 + t^3/3 - t^4/4 + ...
Substitute that in and we get:

    e^(log(1 + 1/n) * n)
        = e^((1/n - 1/(2 n^2) + 1/(3 n^3) - ...) n)
        = e^(1 - 1/(2n) + 1/(3n^2) - ...)
And now you can apply the tangent line approximation to find that this is:

    e - e/(2n) + O(1/n^2)
So if n = 10^N, then the first error should be around the N'th digit.


I don't think it is. Try N[((1+10^-n)^(10^n))/e, n] for smaller values of n. At first it approaches e faster than the precision can "catch up", and up until around n=50 it will result in 1. But at 10^60 and above it will return 1.0000000…




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: