Calculate the right Riemann sum of f(x)=x^2+2x-1 on the interval I=[0,2] with 4 regular portions.
5 ビュー (過去 30 日間)
古いコメントを表示
I am getting this error " Execution of script riemansum as a function is not supported".Can someone help?
2 件のコメント
Yusuf Suer Erdem
2021 年 11 月 21 日
編集済み: Yusuf Suer Erdem
2021 年 11 月 21 日
I used it with this way. It was working properly but I was not able to select 4 regular points.
syms x
rsums(x^2+2*x-1,0,2)
Walter Roberson
2021 年 11 月 21 日
The first executable word of file riemansum.m is not "function", so MATLAB considers the file to be a script that can be executed but not called.
What is the first non-comment non-blank line of riemansum.m ?
採用された回答
その他の回答 (0 件)
参考
カテゴリ
Help Center および File Exchange で Numerical Integration and Differential Equations についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!