Your error is here :
dist.push_back(
qPow( (clusterMeanCoordinate[t].at(i) - hash_notClustered[t].at(point) ), 2) +
qPow( (clusterMeanCoordinate[w] - hash_notClustered[w].at(point)), 2));
// ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Here you are making a substraction between a QVector
and a const float
:
clusterMeanCoordinate[w] - hash_notClustered[w].at(point)
// QVector - const float
You can solve it by doing :
clusterMeanCoordinate[w].at(i) - hash_notClustered[w].at(point)
// ^^^^^^