C++ (Qt)bool CMatrix::operator < ( const CMatrix & sec ) const{ for (size_t i = 0; i < 16; ++i) { double delta = m[i] - sec.m[i]; if (delta < -epsilon) return true; if (delta > epsilon) return false; } return false;}
C++ (Qt)struct unusual_pred { bool operator()(const CMatrix & m1, const CMatrix &m2) const { for (size_t i = 0; i < 16; ++i) { double delta = m1[i] - m2[i]; if (delta < -epsilon) return true; if (delta > epsilon) return false; } return false; }}; ... std::map<CMatrix, Data, unusual_pred> my_strange_map;