Calculating the integral and it's 20-th term
1 回表示 (過去 30 日間)
古いコメントを表示
Dear Guys,
I want to formulate the following into a code. I want to calculate the values of I from 1 to 20. Where
I know that for
the
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/270326/image.png)
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/270327/image.png)
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/270328/image.png)
So I created the following code,
e = 2,7182818284590452353602874713527;
i(n==0)=e-1;
for n =1:20
i(n+1) = e-n*i(n)
end
I had no idea how to put the value of n=0 so I just totally improvised. Code created some values, but not the right ones. If you could spot the mistakes.
Thank you
0 件のコメント
採用された回答
その他の回答 (0 件)
参考
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!