if A&&B==0
does not mean if A is 0 and B is 0, it means
if A is true
if B==0
do body
end
end
MATLAB does not have any distributive tests like you thought. A&&B==0 is ((A)&&(B==0)) which is ((A~=0)&&(B==0))
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!