Complex number maths in polar notation

Complex number maths in polar notation - 消息

#1 已发布: 2023/7/6 22:28:35
flammobammo

flammobammo

0个赞,共3个帖子。

组: User

Hi all, I am new to SMath because I'm looking for a nice elegant solution for some standard formulas and problems that I do for my work relating to electrical engineering.

I love the idea of the nice and elegant solution to presenting these maths equations, and ability to work with complex numbers. In electricity, it is always in polar form. I seem to be able to add, subtract, multiply and divide complex numbers after entering them in polar notation, i.e. magnitude with degrees. However, I cannot display the angle of a complex number. I'd like to be able to write Answer = Mag < Angle(deg). But I can only get Answer = Mag. Is this possible to do, without having to use other trigonometry inbetween? In which case, I may as well stick with Excel.

Thankyou in advance.
#2 已发布: 2023/7/6 22:42:36
Lee Curtis Snook

Lee Curtis Snook

0个赞,共13个帖子。

组: User

Try; arg()

Angle_radians=arg(1+1*i)=0.7854

Angle_degrees:180/π*arg(1+1*i)=45
#3 已发布: 2023/7/6 23:07:19
flammobammo

flammobammo

0个赞,共3个帖子。

组: User

Thankyou, but, sorry... I must be doing something wrong here?

2023-07-07 11_34_30 SMath Solver - [CurrentSplits.sm_].jpg

I can't understand why I'm getting zero values, perhaps I'm entering the angles incorrectly?
#4 已发布: 2023/7/6 23:20:39
Lupus the Canine

Lupus the Canine

0个赞,共7个帖子。

组: User

Wrote

Thankyou, but, sorry... I must be doing something wrong here?

2023-07-07 11_34_30 SMath Solver - [CurrentSplits.sm_].jpg

I can't understand why I'm getting zero values, perhaps I'm entering the angles incorrectly?



Indeed, you do.

You are adding radians to degrees not real and imaginary components.
you would need to make a function to convert polar representation to cartesian representation and back.
#5 已发布: 2023/7/6 23:23:54
flammobammo

flammobammo

0个赞,共3个帖子。

组: User

Thanks Lupus. I think in which case I'll use Octave instead. It's not quite as elegant looking as SMath and neat for copying into reports, but simpler for entering complex numbers in polar form, etc.
  • 有新帖
  • 无新帖