Calculate the right Riemann sum of f(x)=x^2+2x-1 on the interval I=[0,2] with 4 regular portions.

11 views (last 30 days)
I am getting this error " Execution of script riemansum as a function is not supported".Can someone help?
Walter Roberson
Walter Roberson on 21 Nov 2021
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 ?

Sign in to comment.

Accepted Answer

Shanmukha Voggu
Shanmukha Voggu on 2 Dec 2021
Hi Vansh,
The link here might be helpful.
Hope this helps!

More Answers (0)

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!