Divide by Zero
古いコメントを表示
I am wondering, why does MATLAB give infinity for the calculation 1 / 0?
Shouldn't this throw an error, return NaN, or be a complex infinity?
Just looking for some reasoning for this invalid calculation.
Thanks!
採用された回答
その他の回答 (1 件)
Jan
2012 年 6 月 26 日
For stopping on division by zero see:
warning on MATLAB:divideByZero
dbstop if warning MATLAB:divideByZero
and
dbstop if naninf
カテゴリ
ヘルプ センター および File Exchange で Logical についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!