Uploaded image for project: 'Commons Math'
  1. Commons Math
  2. MATH-945

add log10 to RealFieldElement interface

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Resolved
    • Trivial
    • Resolution: Fixed
    • 3.2
    • 4.0
    • None
    • None

    Description

      When the RealFieldElement interface has been set up for 3.2, it appeared the log10 method could not be declared properly. Its return type should have been T (the parameter type for the interface), and indeed this is what Decimal64.log10() and DerivativeStructure.log10() return. However, the Dfp class already had a log10 method that returned an int and not a Dfp.

      So declaring this method at the interface level would have lead to change the return type for the Dfp.log10() method from int to Dfp, and this was an incompatible change, which could not be done in a minor release like 3.2. It had to wait until 4.0.

      Everything is already in place in the classes, with TODO comments and commented out code.

      Attachments

        Activity

          People

            Unassigned Unassigned
            luc Luc Maisonobe
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: