How do i determine the highest values of my for loop?
2 次查看(过去 30 天)
显示 更早的评论
for x = 3:0.2:9
y=(cos(x+1)/(pi*x-1));
disp(['x = ',num2str(x)])
disp(['y = ',num2str(y)])
end
I need to find the highest values (x and y) of the results of this for loop, which i know are "x = 9" and "y = 0.065282" by looking into the results.
But i can't think of a command that'll do it without the need of eye analysis...
Thanks in advance.
0 个评论
采纳的回答
更多回答(0 个)
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Loops and Conditional Statements 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!