# SuanShu, a Java numerical and statistical library

com.numericalmethod.suanshu.number.doublearray

## Interface DoubleArrayOperation

• ### Method Summary

All Methods
Modifier and Type Method and Description
double[] add(double[] arr1, double[] arr2)
Add two double arrays, entry-by-entry.
double[] divide(double[] arr1, double[] arr2)
Divide one double array by another, entry-by-entry.
double[] minus(double[] arr1, double[] arr2)
Subtract one double array from another, entry-by-entry.
double[] multiply(double[] arr1, double[] arr2)
Multiply one double array to another, entry-by-entry.
double[] scaled(double[] arr, double c)
Scale each entry of a double array.
• ### Method Detail

double[] add(double[] arr1,
double[] arr2)
Add two double arrays, entry-by-entry.
Parameters:
arr1 - an array double[]
arr2 - an array double[]
Returns:
the sum of the two arrays
• #### minus

double[] minus(double[] arr1,
double[] arr2)
Subtract one double array from another, entry-by-entry.
Parameters:
arr1 - an array double[]
arr2 - an array double[]
Returns:
the difference of the two arrays
• #### multiply

double[] multiply(double[] arr1,
double[] arr2)
Multiply one double array to another, entry-by-entry.
Parameters:
arr1 - an array double[]
arr2 - an array double[]
Returns:
the product of the two arrays
• #### divide

double[] divide(double[] arr1,
double[] arr2)
Divide one double array by another, entry-by-entry.
Parameters:
arr1 - an array double[]
arr2 - an array double[]
Returns:
the quotient array
• #### scaled

double[] scaled(double[] arr,
double c)
Scale each entry of a double array.
Parameters:
arr - an array double[]
c - a scaling constant
Returns:
the scaled array