for i=0.1:0.1:1 for j=0.1:0.1:1 if(i+j>0.3) if(i*j<0.5) x(i,j)=i.^2+y.^2; end end end end
MATLAB: How to define an array within a loop. I am trying to calculate and store some variables provided some conditions are true.Can someone please tell me how to correctly define array x(i,j) for this
arrayfor loopif statementMATLAB
Best Answer