public class Utilities
extends java.lang.Object
Collection of auxiliar methods.
Constructor and Description |
---|
Utilities() |
Modifier and Type | Method and Description |
---|---|
static double |
log2(double a)
Returns the logarithm of a for base 2.
|
static void |
mergeSort(double[] theArray,
int nElems)
Mergesort algorithm for an array of long integers.
|
static void |
mergeSort(long[] theArray,
int nElems)
Mergesort algorithm for an array of long integers.
|
public static void mergeSort(long[] theArray, int nElems)
theArray
- long[] the Array to sortnElems
- int size of theArraypublic static void mergeSort(double[] theArray, int nElems)
theArray
- double[] the Array to sortnElems
- int size of theArraypublic static double log2(double a)
a
- a double