三个自定义函数 对这其中两个函数的差值比求值并作图。
显示 更早的评论
三个自定义函数profit3,profit22和profit已经写好了,但是作图的时候,我希望的是可以出一组图,但最后运行的结果只是出现了gap1 和gap2的两个值。
Xi = 5:5:100
profit3 = calucate_profit3(Xi)
profit2 = calucate_profit2(Xi)
profit = calucate_profit(Xi)
gap1 = (profit3-profit)/profit
gap2 = (profit2-profit)/profit
plot(Xi,gap1,'--',Xi,gap2,'-')
采纳的回答
更多回答(0 个)
类别
在 帮助中心 和 File Exchange 中查找有关 二维图和三维图 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!