removing a complex infinity

1 回表示 (過去 30 日間)
Tom
Tom 2013 年 11 月 13 日
コメント済み: Tom 2013 年 11 月 13 日
If I have elements in a matrix which are 0 + Infi, what is the best way to delete these elements?
I have tried
x(x==0+infi) = [];
but this doesn't seem to work.
kind regards,
Tom

回答 (1 件)

Andrei Bobrov
Andrei Bobrov 2013 年 11 月 13 日
x(real(x)==0&isinf(imag(x))) = [];
  1 件のコメント
Tom
Tom 2013 年 11 月 13 日
Thanks, but this seems to be deleting every element in the matrix...

サインインしてコメントする。

カテゴリ

Help Center および File ExchangeCreating and Concatenating Matrices についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by