Cálculo da área de interseção entre um círculo e um triângul
Como calcular a área de interseção entre um triângulo (especificado como três pares (X, Y)) e um círculo (X, Y, R)? Eu fiz algumas pesquisas sem sucesso. Isto é para o trabalho, não para a escola. :)
Seria algo parecido com isto em C #:
struct { PointF vert[3]; } Triangle;
struct { PointF center; float radius; } Circle;
// returns the area of intersection, e.g.:
// if the circle contains the triangle, return area of triangle
// if the triangle contains the circle, return area of circle
// if partial intersection, figure that out
// if no intersection, return 0
double AreaOfIntersection(Triangle t, Circle c)
{
...
}