g.add(e);
edges.put(e.id(), e);
	public Graph subset(Set graphelements) {		// filter for those edges which contain only the vertices we want		DGraph g = new DGraph();		Iterator i = graphelements.iterator();		while(i.hasNext()) {			Object o = i.next();			if(o instanceof Vertex) {				g.add((Vertex) o);			} else if(o instanceof Edge) {				g.add((Vertex) ((Edge) o).getEnds().car());				g.add((Vertex) ((Edge) o).getEnds().cdr());				g.add((Edge) o);			}		}		// add any additional edges for the vertices which were not		// included		i = getEdges().iterator();		while(i.hasNext()) {			Edge e = (Edge) i.next();			if(graphelements.contains(e.getEnds().car()) && graphelements.contains(e.getEnds().cdr())) {				g.add(e);			}		}		return g;	}