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

ResizableDoubleArray does not work with double array of size 1

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 3.4, 3.4.1, 3.5
    • 4.0, 3.6
    • None
    • None

    Description

      When attempting to create a ResizableDoubleArray with an array of a single value (e.g.

      {4.0}

      ), the constructor creates an internal array with 16 entries that are all 0.0

      Bug looks like it might be on line 414 of ResizableDoubleArray.java:

      if (data != null && data.length > 1) {

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              johnbay John Bay
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Time Tracking

                  Estimated:
                  Original Estimate - 10m
                  10m
                  Remaining:
                  Remaining Estimate - 10m
                  10m
                  Logged:
                  Time Spent - Not Specified
                  Not Specified