what does A(~A) mean?

조회 수: 17 (최근 30일)
Hussein Dadashi
Hussein Dadashi 2016년 11월 9일
댓글: Hussein Dadashi 2016년 11월 9일
Hi
could someone tell me what does following code mean please?
A(~A)=inf; %A is a vector with zero and non-zero numbers.
Best,

채택된 답변

Walter Roberson
Walter Roberson 2016년 11월 9일
It works out the same as
A(A~=0) =inf
Which is to say that it replaces all nonzero entries with infinity.
  댓글 수: 1
Hussein Dadashi
Hussein Dadashi 2016년 11월 9일
Thank you so much

댓글을 달려면 로그인하십시오.

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Logical에 대해 자세히 알아보기

태그

Community Treasure Hunt

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

Start Hunting!

Translated by