error when trying to calculate a limit with double variable.
Show older comments
When I execute the following code :
n=linspace(10,10e20);
un=(1+1./n).^n;
limit(un,n,inf);
It returns the following error: Undefined function 'limit' for input arguments of type 'double'.
can anyone help me get the value of the limit on matlab ?
Accepted Answer
More Answers (1)
David Hill
on 10 Nov 2020
Use symbolic for limit function.
syms n;
un = (1+1/n)^n;
limit(un,n,inf);
1 Comment
Jéssica Martins
on 10 Nov 2020
Categories
Find more on Conversion Between Symbolic and Numeric in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!