필터 지우기
필터 지우기

How to use <=, >= logic operators for imaginary part of a complex number?

조회 수: 2 (최근 30일)
Fred
Fred 2018년 5월 22일
답변: James Tursa 2018년 5월 22일
Hello,
I have a question regarding how can I apply (<= or >=) logic operators for imaginary part of a complex number. MATLAB documentation says x >= y is equal to real(x)>=real(y), if x y are complex, but I want to compare imaginary parts as well. Is there any way I can do that in MATLAB?
Thanks,

채택된 답변

James Tursa
James Tursa 2018년 5월 22일
You can do this explicitly by picking off the imag parts. E.g.,
imag(x) >= imag(y)

추가 답변 (0개)

카테고리

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

Community Treasure Hunt

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

Start Hunting!

Translated by