# Geometry

This is a pretty interesting topic that I see often in hard math / competitive programming contests. However, I never seem to to be able to solve them.

Learning this more in the context of competitive programming.

In geometric problems, it is often challenging to find a way to approach the problem so that the solution to the problem can be conveniently implemented and the number of special cases is small.

General formula for area of quadrilateral whose: $x_{1}y_{2}−x_{2}y_{1}+x_{2}y_{3}−x_{3}y_{2}+x_{3}y_{4}−x_{4}y_{3}+x_{4}y_{1}−x_{1}y_{4}$

### Topics

Actually, you use complex numbers to solve geometry problems??

### Detecting Line Segment Intersection

This is where your cross product formulas, and Linear Algebra is super helpful.

### How do you determine if a point is inside a polygon or outside a polygon? (Pre-req: determine line intersection)

Omg that is such an interesting idea, just send arbitrary rays from the point. If the number of interesctions is odd, then the point is inside the polygon. Else, if it is even, then it is outside the polygon.