cdm/src/main/java/ucar/ma2/MAMath.java
public static double sumDouble(Array a) {
    double sum = 0;
    IndexIterator iterA = a.getIndexIterator();
    while (iterA.hasNext()) {
      sum += iterA.getDoubleNext();
    }
    return sum;
  }
public static double sumDouble(Array a) {
    double sum = 0;
    IndexIterator iterA = a.getIndexIterator();
    while (iterA.hasNext()) {
      sum += iterA.getDoubleNext();
    }
    return sum;
  }
sum all of the elements of array a as doubles.
The values from the array a are converted to double (if needed).
@param a read values from this Array
@return sum of elements