@Test
public void testClusteringMultipleRuns() {

  for (int i = 1; i <= 10; ++i) {
    BallKMeans clusterer = new BallKMeans(new BruteSearch(new SquaredEuclideanDistanceMeasure()),
        1 << NUM_DIMENSIONS, NUM_ITERATIONS, true, i);
    clusterer.cluster(syntheticData.getFirst());
    double costKMeansPlusPlus = ClusteringUtils.totalClusterCost(syntheticData.getFirst(), clusterer);
    clusterer = new BallKMeans(new BruteSearch(new SquaredEuclideanDistanceMeasure()),
        1 << NUM_DIMENSIONS, NUM_ITERATIONS, false, i);
    clusterer.cluster(syntheticData.getFirst());
    double costKMeansRandom = ClusteringUtils.totalClusterCost(syntheticData.getFirst(), clusterer);
    System.out.printf("%d runs; kmeans++: %f; random: %f\n", i, costKMeansPlusPlus, costKMeansRandom);
    assertTrue("kmeans++ cost should be less than random cost", costKMeansPlusPlus < costKMeansRandom);
  }
}