Dynamic Array update without for loop
조회 수: 3 (최근 30일)
이전 댓글 표시
Dear All,
Is there any possibilty to run below mentioned code without using FOR loop as run time is higher with loops,
A=rand(100000,1);B=rand(100000,1);
Out=zeros(length(A),1);
for i=2:length(A)
Out(i)=0.1*Out(i-1)+(0.9*(A(i-1)-B(i)));
end
댓글 수: 2
채택된 답변
추가 답변 (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!