Beispiel #1
0
 /**
  * True iff simplices are neighbors. Two simplices are neighbors if they are the same dimension
  * and they share a facet.
  *
  * @param simplex the other Simplex
  * @return true iff this Simplex is a neighbor of simplex
  */
 public boolean isNeighbor(final Simplex<V> simplex) {
   final HashSet<V> h = new HashSet<V>(this);
   h.removeAll(simplex);
   return (this.size() == simplex.size()) && (h.size() == 1);
 }