Based on the paper "Performance guarantees for hierarchical clustering" by Sanjoy Dasgupta and Philip M. Long Download PDF here
Straight forward implementation of the Algorithm for points in R^4 with the Euclidian norm.
Only depends on STL and CMake (for building)
mkdir build
cd build
cmake ..
make
See the file test_hcluster.cc for a usage example.