[Patches] [ python-Patches-544909 ] addition of cmath.arg function

noreply@sourceforge.net noreply@sourceforge.net
Fri, 19 Apr 2002 10:38:16 -0700


Patches item #544909, was opened at 2002-04-16 18:11
You can respond by visiting: 
http://sourceforge.net/tracker/?func=detail&atid=305470&aid=544909&group_id=5470

Category: Modules
Group: None
Status: Open
Resolution: None
Priority: 5
Submitted By: John Williams (johnw42)
Assigned to: Nobody/Anonymous (nobody)
Summary: addition of cmath.arg function

Initial Comment:
This patch adds the familiar "Arg" function from
complex analysis to the cmath module, though it's
called "arg" here for consistency with the other names.
Along with the built-in abs function this makes
polar/rectangular coordinate conversions trivial:

  z = complex(x,y)
  r, theta = abs(z), arg(z)
  
  z = r * exp(1j * theta)
  x, y = z.real, z.imag

----------------------------------------------------------------------

>Comment By: John Williams (johnw42)
Date: 2002-04-19 12:38

Message:
Logged In: YES 
user_id=44174

I forgot to mention this patch is relative to version 2.2.1.

----------------------------------------------------------------------

You can respond by visiting: 
http://sourceforge.net/tracker/?func=detail&atid=305470&aid=544909&group_id=5470