Display diagonal values from vector answers?
1 次查看(过去 30 天)
显示 更早的评论
%EXAMPLE
clear all
clc
t=linspace(0,5,6);
x=linspace(10,15,6);
for i=1:length(t)
vec=x*t(i)
end
Is it possible to display/calculate only the diagonal of this, i.e. vec=0 11 24 39 56 75?
Thanks
ewan
0 个评论
采纳的回答
更多回答(0 个)
另请参阅
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!