Clustering algorithms implemented in C++