ExtendedKSAlgorithm