Class Sorts

java.lang.Object
com.softsynth.jmsl.util.Sorts

public class Sorts
extends java.lang.Object
Sort array of double. Comb sort found here, variant of bubble sort
Author:
Nick Didkovsky
  • Constructor Summary

    Constructors
    Constructor Description
    Sorts()  
  • Method Summary

    Modifier and Type Method Description
    static void combSort​(double[] arr, int n)
    A variant of bubble sort which is very fast, roughly n*logn From Stephen Lacy & Richard Box "A Fast Easy Sort" BYTE April 1991, p315
    static void combSort​(int[] arr, int n)  
    static void combSort​(java.lang.String[] arr, int n)  
    static void main​(java.lang.String[] args)  

    Methods inherited from class java.lang.Object

    equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • Sorts

      public Sorts()
  • Method Details

    • combSort

      public static void combSort​(double[] arr, int n)
      A variant of bubble sort which is very fast, roughly n*logn From Stephen Lacy & Richard Box "A Fast Easy Sort" BYTE April 1991, p315
    • combSort

      public static void combSort​(int[] arr, int n)
    • combSort

      public static void combSort​(java.lang.String[] arr, int n)
    • main

      public static void main​(java.lang.String[] args)