diff --git a/label_inscribed_600cell.js b/label_inscribed_600cell.js index 600fc11..d2b3910 100644 --- a/label_inscribed_600cell.js +++ b/label_inscribed_600cell.js @@ -134,6 +134,21 @@ export function face_vertices(shape, f1, f2, f3) { return ns; } + +export function shared_neighbours(shape, nodes) { + // for f1/f2/f3 forming a triangular face, return the two vertices of the + // adjacent tetrahedra + + let ns = shape.nodes.map((n) => n.id); + for( const n of nodes ) { + ns = neighbours_in_subset(shape, ns, n); + } + + return ns; +} + + + export function layer_neighbours(cell600, layer) { console.log("Layer neighbours"); for( const n of layer ) {