Function pol2xy does not work correctly

Function pol2xy does not work correctly - Messages

#1 Posted: 3/8/2012 5:07:40 PM
olik

olik

3 likes in 27 posts.

Group: User

Hello.

The function pol2xy(r;fi) works only if the Options/Answer is set to Auto, or Standard. And it returns a complex result !!

regards Olik



#2 Posted: 3/12/2012 7:28:19 AM
Radovan Omorjan

Radovan Omorjan

325 likes in 2052 posts.

Group: Moderator

Hello,

The only answer I can give you is that you can ignore the imaginary parts of the results (rather small values).

[MATH=eng]a:asin(3/5)[/MATH]
[MATH=eng]pol2xy(5,a)=sys(4-2.01761263306198*10^{-15}*i,3+3.13994492395312*10^{-15}*i,2,1)[/MATH]
[MATH=eng]Re(pol2xy(5,a))=sys(4,3,2,1)[/MATH]
[MATH=eng]el(Re(pol2xy(5,a)),1)=4[/MATH]
[MATH=eng]el(Re(pol2xy(5,a)),2)=3[/MATH]

Regards,
Radovan
When Sisyphus climbed to the top of a hill, they said: "Wrong boulder!"
#3 Posted: 3/12/2012 11:18:03 AM
olik

olik

3 likes in 27 posts.

Group: User

Hello.

Also we can simply use the definition formulas:
x:= r.cos(α)
y:= r.sin(α)

& it works even for Option/Answer set to "Real".
(for Answer=Complex you will get two results for x = -4, 4 ... -4 is imho wrong)
[ we can solve this by using the function eval . . . a:=eval(asin(3/5)) ]

But the funcion pol2xy() does not work correctly - this is the essence of my bug report.

regards Olik

btw:
I do not see the difference betwen the Option Answer = auto/standard
What is the difference?
  • New Posts New Posts
  • No New Posts No New Posts