comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » ATAN function with two ARGS
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Switch to threaded view of this topic Create a new topic Submit Reply
ATAN function with two ARGS [message #20289] Mon, 05 June 2000 00:00 Go to next message
Ben Tupper is currently offline  Ben Tupper
Messages: 186
Registered: August 1999
Senior Member
Hello,

I have bumped into a conflict between the IDL documentation and IDL output.

From the IDL (5.2) docs, the optional argument Y is described as follows:

-------START
Y
An optional argument.

If this argument is supplied, ATAN returns the angle whose tangent

is equal to Y/X. If both arguments are zero, the result is undefined.

------END

So I tried the following...

IDL> help, ATAN(0.0,0.0)
<Expression> FLOAT = 0.00000

Uhoh! Is it me, or is it Monday morning syndrome?

Ben

--
Ben Tupper

Bigelow Laboratory for Ocean Science
tupper@seadas.bigelow.org

pemaquidriver@tidewater.net
Re: ATAN function with two ARGS [message #20374 is a reply to message #20289] Tue, 06 June 2000 00:00 Go to previous message
davidf is currently offline  davidf
Messages: 2866
Registered: September 1996
Senior Member
Paul Hick (pphick@ucsd.edu) writes:

> I presume that IDL is compiled with whatever math libraries are
> available on any particular operating system, so it will inherit
> whatever peculiarities (not necessarily the same on every OS) are in
> there.

Shoot. I liked my "technical writer's trick" theory better.
More malevolent. :-)

Cheers,

David

--
David Fanning, Ph.D.
Fanning Software Consulting
Phone: 970-221-0438 E-Mail: davidf@dfanning.com
Coyote's Guide to IDL Programming: http://www.dfanning.com/
Toll-Free IDL Book Orders: 1-888-461-0155
Re: ATAN function with two ARGS [message #20375 is a reply to message #20289] Tue, 06 June 2000 00:00 Go to previous message
Paul Hick is currently offline  Paul Hick
Messages: 9
Registered: November 1999
Junior Member
I presume that IDL is compiled with whatever math libraries are
available on any particular operating system, so it will inherit
whatever peculiarities (not necessarily the same on every OS) are in
there. Another example: raise NaN to a floating point power on a Windows
machine:

IDL> print, !values.f_nan^2.0
0.000000
% Program caused arithmetic error: Floating illegal operand
IDL> print, !version
{ x86 Win32 Windows 5.3.1 Feb 23 2000}

IDL on Linux, for instance, gives the proper response:

IDL> print, !values.f_nan^2.0
NaN
IDL> print, !version
{ x86 linux unix 5.3 Nov 11 1999}

Paul
--
____________________________________________________________ _____
| Paul Hick (pphick@ucsd.edu) |
| Office : SERF Rm. 302 Smail : UCSD/CASS/0424 |
| Phone : (858) 534-8965 9500 Gilman Drive |
| Fax : (858) 534-0177 La Jolla CA 92093-0424 |
| WWW : http://casswww.ucsd.edu/personal/Plh.html |
|___________________________________________________________ ______|
  Switch to threaded view of this topic Create a new topic Submit Reply
Previous Topic: Re: Postscript Output with Object Graphics?
Next Topic: Curvefit on PV-Wave

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Wed Oct 08 13:58:41 PDT 2025

Total time taken to generate the page: 0.00354 seconds