I read a very large number of point coordinates x, y and z and store them in a vector of Point structures to do further processing.
struct Point{
double x,y,z;
Point (double x0, double y0, double z0): x(x0), y(y0), z(z0) {}
}
vector<Point> pv;
pv.push_back (Point(x,y,z));
I also have a hash function that maps all the points with the same coordinates together with their vector index to an unordered_multimap for some other processing.
the problem is there are many duplicate points that I read from the file and I have to get rid of those elements. I have seen solutions on how to remove duplicate elements from a vector of primitive types but that does not apply to my case. In addition many of the proposed methods, requires sorting that is not applicable to a Point structure.