private void quicksort(int low, int high)
	{
		incrementRekursionDepth();

		// if the given part of the array is already sorted, we're done here
		if (!isSorted(array, low, high))
		{
			int i = low, j = high;

			// comparision element x
			int x = array[countStep((low + high) / 2)];

			// splitting
			while (i <= j)
			{
				while (array[countStep(i)] < x)
					i++;
				while (array[countStep(j)] > x)
					j--;
				if (i <= j)
				{
					exchange(i, j);
					i++;
					j--;
				}
			}
			// if (lo<j) quicksort(lo, j);
			// if (i<hi) quicksort(i, hi);
			// insertionsort(lo, hi);
			// recursion; if length <= 20 => insertionsort
			if (low < j)
				if (j - low <= 20)
					insertionsort(low, j);
				else
					quicksort(low, j);
			if (i < high)
				if (high - i <= 20)
					insertionsort(i, high);
				else
					quicksort(i, high);
		}
	}