Input array in if else statement

Hi.. actually i want to design energy controller that using if else stetment but in continuosly way.. using input array..but i dont know where to start about can somebody help me?

답변 (1개)

Walter Roberson
Walter Roberson 2016년 12월 5일

1 개 추천

You probably want to learn about logical indexing. For example,
mask = U1 < 17.82;
U2(mask)= U1(mask) * 3.8;
U2(~mask) = U1(~mask) - 1.29;

카테고리

도움말 센터File Exchange에서 MATLAB Parallel Server에 대해 자세히 알아보기

질문:

2016년 12월 5일

답변:

2016년 12월 5일

Community Treasure Hunt

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

Start Hunting!

Translated by