採用された回答

Walter Roberson
Walter Roberson 2013 年 6 月 6 日

0 投票

~any(M(:))
will be true if M is entirely 0
I am not sure if your (sum) is intended to convey anything? Are you asking whether the sum over M is 0? If so then,
if ~sum(M(:))
Note, though, that this would be subject to round-off and cancellation problems; there are other techniques to use if you need to be concerned about those.

その他の回答 (1 件)

Matt J
Matt J 2013 年 6 月 6 日

0 投票

any(M(:))

カテゴリ

ヘルプ センター および File Exchange で Simulink Check についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by