SOD for multidimensional scaling.