if (faceTwin.references(nodeA)) { Node nodeD = nodeC.edgeAfter().nodeB(); assert nodeD.isOnBoundary(); else if (faceTwin.references(nodeB)) { Node nodeD = nodeC.edgeBefore().nodeA(); assert nodeD.isOnBoundary();
if (face.references(node2)) return face; Face face1 = face; face = node1.faceNext(face1); while (face!=face1 && face!=null) { if (face.references(node2)) return face; face = node1.faceNext(face); face = node1.facePrev(face1); while (face!=face1 && face!=null) { if (face.references(node2)) return face; face = node1.facePrev(face);
/** * Returns a face that references the specified nodes. * @param node1 a node. * @param node2 a node. * @param node3 a node. * @return a face that references the specified nodes; or null, * if a node is not in the surface or the surface has no faces. */ public synchronized Face findFace(Node node1, Node node2, Node node3) { Face face = findFace(node1,node2); // if (face!=null) { // clearFaceMarks(); // face = findFace(face,node1,node2,node3); // } if (face!=null) { if (face.references(node3)) return face; face = face.faceNabor(node3); if (face!=null && face.references(node3)) return face; } return null; }
private void validate() { assert _meshNode!=null; assert _face==null || _face.references(this); if (_edgeBefore==null) { assert _edgeAfter==null; } else { assert this==_edgeBefore.nodeB(); assert this==_edgeAfter.nodeA(); assert this==_edgeBefore.nodeA().edgeAfter().nodeB(); assert this==_edgeAfter.nodeB().edgeBefore().nodeA(); } assert _edgeBefore==null && _edgeAfter==null || _edgeBefore!=null && this==_edgeBefore.nodeB() && _edgeAfter!=null && this==_edgeAfter.nodeA(); } private void init() {
private void validate() { assert _meshEdge!=null; assert _faceLeft==null || _faceLeft.references(nodeA(),nodeB()); assert _faceRight==null || _faceRight.references(nodeA(),nodeB()); } private Edge(TetMesh.Edge meshEdge, Face face) {