How to calculate area of space in Matalb
2 次查看(过去 30 天)
显示 更早的评论
Dear members, I want to calculate area of space created by 4 lines as figure. Could you help me to do that ? Thank you
4 个评论
采纳的回答
Image Analyst
2018-10-11
Try stacking the numerical row vectors of the curves vertically using a semicolon then use min() to get the lower-most curve:
bottomCurve = min([curve1; curve2; curve3; curve4; curve5; curve6], 1);
Then sum from the left index to the right index, whatever they are.
areaUnderCurve = sum(bottomCurve(index1 : index2))
更多回答(0 个)
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Curve Fitting Toolbox 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!