The Motley Fool Discussion Boards

Previous Page

Fun & Games / Math Recreations & Puzzles


Subject:  Re: A (complex) puzzle Date:  9/23/2011  3:06 PM
Author:  rmhj Number:  5785 of 5887

LorenCobb: Not in Gnu Fortran, I believe. The Fortran call log(x), where x is complex, generates a complex answer (the principal value of the complex logarithm). These doc files

say as much, though they do not specify what would happen if the log function is called on a negative constant.

That is what I'd expect, FORTRAN having had COMPLEX data types since day IV (if not earlier). However, the argument is a REAL (or integer?), and I've long s