SSJ
V. labo.

umontreal.iro.lecuyer.util
Class HilbertCurveSort

java.lang.Object
  extended by umontreal.iro.lecuyer.util.HilbertCurveSort
All Implemented Interfaces:
MultiDimSort

public class HilbertCurveSort
extends Object
implements MultiDimSort


Constructor Summary
HilbertCurveSort(int d)
           
HilbertCurveSort(int d, int nbCubes)
          .
 
Method Summary
 int dimension()
          Returns the greatest dimension used in the sort.
 void sort(double[][] a)
          Sorts the entire array.
 void sort(double[][] a, int iMin, int iMax)
          Sorts the subarray of a made of the elements with indices from iMin to iMax-1.
<T extends MultiDimComparable<? super T>>
void
sort(T[] a)
          Sorts the entire array.
<T extends MultiDimComparable<? super T>>
void
sort(T[] a, int iMin, int iMax)
          Sorts the subarray of a made of the elements with indices from iMin to iMax-1.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

HilbertCurveSort

public HilbertCurveSort(int d)

HilbertCurveSort

public HilbertCurveSort(int d,
                        int nbCubes)
. \begin{tabb}
 Constructs a \class{HilbertCurveSort} object that will use the firs...
 ...ould be better to allow different $m_j$'s for different coordinates.}
 \end{tabb}
dmaximum dimension to use for the sort mnumber of bits used for each coordinate

Method Detail

sort

public <T extends MultiDimComparable<? super T>> void sort(T[] a,
                                                           int iMin,
                                                           int iMax)
Description copied from interface: MultiDimSort
Sorts the subarray of a made of the elements with indices from iMin to iMax-1.

Specified by:
sort in interface MultiDimSort
Parameters:
a - array to sort
iMin - index of first element to sort
iMax - index of last element to sort is iMax - 1

sort

public <T extends MultiDimComparable<? super T>> void sort(T[] a)
Description copied from interface: MultiDimSort
Sorts the entire array.

Specified by:
sort in interface MultiDimSort
Parameters:
a - array to sort

sort

public void sort(double[][] a,
                 int iMin,
                 int iMax)
Description copied from interface: MultiDimSort
Sorts the subarray of a made of the elements with indices from iMin to iMax-1.

Specified by:
sort in interface MultiDimSort
Parameters:
a - array to sort
iMin - index of first element to sort
iMax - index of last element to sort is iMax - 1

sort

public void sort(double[][] a)
Description copied from interface: MultiDimSort
Sorts the entire array.

Specified by:
sort in interface MultiDimSort
Parameters:
a - array to sort

dimension

public int dimension()
Description copied from interface: MultiDimSort
Returns the greatest dimension used in the sort.

Specified by:
dimension in interface MultiDimSort
Returns:
greatest dimension used for the sort

SSJ
V. labo.

To submit a bug or ask questions, send an e-mail to Pierre L'Ecuyer.