home *** CD-ROM | disk | FTP | other *** search
- Newsgroups: comp.lang.fortran
- Path: sparky!uunet!spool.mu.edu!sol.ctr.columbia.edu!destroyer!cs.ubc.ca!fs1.ee.ubc.ca!davem
- From: davem@ee.ubc.ca (david michelson)
- Subject: Re: a question on ATAN function
- Message-ID: <1992Nov24.034002.29695@ee.ubc.ca>
- Organization: University of BC, Electrical Engineering
- References: <dedmunds.722548228@sfu.ca> <By6v1E.LsB@news.cso.uiuc.edu>
- Date: Tue, 24 Nov 1992 03:40:02 GMT
- Lines: 18
-
- In article <By6v1E.LsB@news.cso.uiuc.edu> ercolessi@uimrl3.mrl.uiuc.edu (furio ercolessi) writes:
- >In article <dedmunds.722548228@sfu.ca>, dedmunds@selkirk.sfu.ca (Darran Edmundson) writes:
- >|>I'd like to pose a neophyte question on using the arctan function to
- >|>calculate the phase angle of a complex variable (i.e. \theta = atan(v/u)
- >|>where u and v are the real and complex parts of my imaginary number
- >|>respectively).
- >
- >atan2, which takes u and v as two separate arguments, is what
- >you want!
-
- However, ATAN2(,) is undefined if both arguments are 0.0 so you'll
- have to test for that and assign an arbitrary value if it occurs.
-
- --
- Dave Michelson
- davem@ee.ubc.ca
-
-
-