필터 지우기
필터 지우기

How can I store 3 values of a sequence and iterate?

조회 수: 2 (최근 30일)
Mariana
Mariana 2020년 2월 14일
댓글: darova 2020년 2월 14일
Input = [1,2,3,4,5,6,7,8,9,10,11,12];
Buffer= zeros(min(4,10000),1);
first = 1;
last = 4;
Buff_size = 3;
step = 1;
keeplooking = true;
while keeplooking == true %infinite loop
% Buffer= zeros(min(4,10000),1);
Buffer(1:4)= Input(first:last);
start = step + last;
last = start + Buff_size;
end
Why I am not able to continue the while loop?
I have the following error: In an assignment A(:) = B, the number of elements in A and B must be the same.
when Buffer(1:4)= Input(first:last); are from the same size....
  댓글 수: 4
Mariana
Mariana 2020년 2월 14일
Why if I try to do the same method in simulink it doesnt works?
darova
darova 2020년 2월 14일
I don't know how to use Simulink

댓글을 달려면 로그인하십시오.

답변 (0개)

카테고리

Help CenterFile Exchange에서 Simulink Functions에 대해 자세히 알아보기

제품

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by