I need to find an algorithm which computes a convex hull from a given set of points S
of size n
.
I know that there are exactly 6 points from S
which form the convex hull.
What is the best and most efficient way to compute this?
I thought about generating all possible combinations of points from S
(which would be n choose 6 points) which would take O(n^6) and then check if this is a convex hull, which would take O(n) but lead into a very bad total runtime. There must be a better way. Any hints?