Backward Loop Question- Help
이전 댓글 표시
I am trying to get the code to start at a certain value lets say 80 and start counting down from there. But I am struggling to see where to put this information into my code to make this happen.
xdt3 = 5;
xt03 = 0;
xtf3 = 60;
xt3 = xtf3:-xdt3:xt03;
x3 = zeros(1,13);
for i = length(xt3):-1:2
x3(i-1) = x3(i) - ((5 - (4 /50)*x3(i)))*xdt3;
end
채택된 답변
추가 답변 (0개)
카테고리
도움말 센터 및 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!