replace convexHull with monotone chain