필터 지우기
필터 지우기

Subscript indices must either be real positive integers or logicals.

조회 수: 2 (최근 30일)
Luigi Stragapede
Luigi Stragapede 2020년 5월 13일
답변: Tommy 2020년 5월 13일
I need to consider this for end loop:
for thetat=0:0.012566:0.6283 %I need 50 points
...
...
end
How can I do if I cannot take decimal indices?

채택된 답변

Tommy
Tommy 2020년 5월 13일
thetat=0:0.012566:0.6283;
for idx = 1:numel(thetat)
% use thetat(idx) to access the appropriate theta value in any iteration of the loop
...
...
end

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Pulse width modulation (PWM)에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by