# Collision Detection
📗 Objects are usually represented by a collection of convex polytopes (convex polygon in 2D). Checking if two convex polytopes collides can be done by check if each vertex of one polytope is inside the other polytope.
📗 A polytope can be represented by the intersection of half-spaces, for example, a convex polygon in 2D with \(n\) edges or a convex polytope in 3D with \(n\) faces is a set of points \(x\) that satisfies \(A x \leq b\).
📗 In computer graphics, polytopes are usually represented by a collection of lines (edges in 2D) or triangles (faces in 3D, each face can have multiple triangles). There are more efficient collision detection algorithms for polytopes represented this way.