update triangles