rsums integration

 avatar
unknown
matlab
2 years ago
277 B
3
Indexable
clc
close all
clear all
syms x
f=input('enter function')
a=input('enter lower limit')
b=input('enter upper limit')
n=input('number of intervals')
value=0;
dx=(b-a)/n
for k=1:n
    c=a+k*dx;
    d=subs(f,x,c);
    value=value+d;
end
ivalue=value*dx
ezplot(f,[a,b])
rsums(f,a,b)
Editor is loading...