Commit 5a7f27c
committed
feat(geometry): add Bentley-Ottmann line segment intersection algorithm
- Implement sweep-line algorithm for finding all intersection points
- Time complexity: O((n + k) log n) where n is segments, k is intersections
- Uses event queue (PriorityQueue) and status structure (TreeSet)
- Handles vertical/horizontal segments, collinear overlaps, and touching endpoints
- Includes comprehensive Javadoc with examples and references1 parent d5289b9 commit 5a7f27c
File tree
1 file changed
+409
-0
lines changed- src/main/java/com/thealgorithms/geometry
1 file changed
+409
-0
lines changed
0 commit comments