2(x + j y) = 6− j 3
I coded it like:
syms x y
a=2*(x+y*j)==6-3j;
vpasolve(a,[x,y])
ans=
x : 3.0 - 1.5i
y : 0
but the result should come out as
x = 3.0 and
y = -1.5

 채택된 답변

Torsten
Torsten 2022년 10월 9일

0 개 추천

syms x real
syms y real
a=2*(x+y*j)==6-3j;
sol = solve(a,[x,y]);
sol.x
ans = 
3
sol.y
ans = 

추가 답변 (1개)

Image Analyst
Image Analyst 2022년 10월 9일

0 개 추천

What if you just add on
x = real(x)
y = imag(x)

댓글 수: 1

Torsten
Torsten 2022년 10월 9일
It's just by chance that this works for the above example.

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

카테고리

도움말 센터File Exchange에서 Symbolic Math Toolbox에 대해 자세히 알아보기

제품

릴리스

R2020b

질문:

2022년 10월 9일

댓글:

2022년 10월 9일

Community Treasure Hunt

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

Start Hunting!

Translated by