Abstract structure of triangles