sw_uniquetol#
Syntax#
[Mu, firstIdx] = sw_uniquetol(M,tol)
Description#
[Mu, firstIdx] = sw_uniquetol(m,tol) returns unique column vectors
within the given tol tolerance. Two column vectors are considered
unequal, if the distance between them is larger than the tolerance
(\(\delta\)):
\[\sqrt{\sum_i (V_i-U_i)^2} < \delta\]
Input Arguments#
MMatrix that contains column vectors.
tolDistance tolerance, default value is \(10^{-5}\).
Output Arguments#
MuMatrix that contains the unique column vectors.
firstIdxIndices pointing to the first occurence of the unique element.
This function is similar to the Matlab built-in
unique(M,'rows','first'), but with controllable tolerance.