why I am getting 'array indices must be positive intergers or logical value' error?
显示 更早的评论
a=1.4492;
b=-3.4497;
n=100;
h=(b-a)/n;
f(a)=integ_trape(a);
f(b)=integ_trape(b);
r=0.5*(f(a)+f(b));
for i=1:1:n-1
r=r+f(a+i*h);
break;
I=h*r;
end
采纳的回答
更多回答(0 个)
类别
在 帮助中心 和 File Exchange 中查找有关 Correlation and Convolution 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!