# triangles

## Name

triangles — The triangles forming a 2-manifold triangulation

## Synopsis

Content Model

    triangles ::= (triangle*)

Attributes
Name | Type
`ntriangles` | NUMBER (required)

## Description

A `triangles` element stores the entire set of triangles forming a 2-manifold triangulation.

The total number of triangles must be specified by the `ntriangles` attribute. The individual triangles are numbered 0, 1, 2, etc., and their edge gluings are described by the corresponding child `triangle` elements. There must be precisely `ntriangles` child `triangle` elements in total.

### Parents

The following elements contain `triangles`: `packet` (2-manifold triangulation).

### Children

The following elements occur in `triangles`: `triangle`.

## Attributes

`ntriangles`

  The total number of triangles in this set. Note that there must be precisely this many child `triangle` elements.

## Example

The following XML snippet represents a triangulation of the Klein bottle with two triangles.

    <triangles ntriangles="2">
      <triangle> 1 1 1 5 1 0 </triangle>
      <triangle> 0 1 0 5 0 0 </triangle>
    </triangles>