Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-4243980

(1.1) java.lang.Math.atan2() does not conform to java specs

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Won't Fix
    • Icon: P4 P4
    • None
    • 1.1.8
    • core-libs
    • generic
    • generic



      Name: inC81039 Date: 06/04/99



      According to "Java Language Specification" for Math.atan2()
         "If first argument is positive zero
          and the second argument is negative
          then the result is the double value closest to PI."
      and
         "If first argument is negative zero
          and the second argument is negative
          then the result is the double value closest to -PI."

      However, actual results are different:
      Math.atan2( 0, -0) = 0
      Math.atan2(-0, -0) = 0

      ======================================================================

            mmcclosksunw Michael Mccloskey (Inactive)
            duke J. Duke
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: