The MDS algorithm pseudo-code looks like this:
Question Description: If you know the distance between several cities in the United States, how can we characterize the relative position of several cities by these distances?
The MDS algorithm is a way to reduce the dimensions of a multidimensional problem to simplify the complexity of the problem so that the problem is resolved in an effective time.
Solution to the problem: the original distance matrix is needed through the steps x->b->d; now need to d->b->x ' method to get a low-dimensional X '.
Algorithm Description:
Input: The distance matrix D is a m*m matrix whose element Distij is the distance between the sample XI to XJ, the original problem dimension is D, and the target dimension is d ' (d ' <d);
- Calculate B Matrix;
- Eigenvalue decomposition of B-matrices to obtain eigenvalues and eigenvectors
- The maximum eigenvalues of the number below D constitute the diagonal matrix A, and the corresponding eigenvectors form the eigenvector Matrix V
Output: The matrix VA0.5 is a matrix of m*d ', each line is a required low-dimensional coordinate.
Related principles introduction and related examples See blog:
http://blog.csdn.net/Dark_Scope/article/details/53229427
MDS (multiple dimensional scalling) algorithm