Create cluster.c

The clustering code.