Skip to content
This repository has been archived by the owner on Jan 30, 2023. It is now read-only.

Commit

Permalink
trac #13917: A misnamed function
Browse files Browse the repository at this point in the history
  • Loading branch information
nathanncohen committed Mar 13, 2014
1 parent 825f8f6 commit 5aeaccf
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions src/sage/graphs/independent_sets.pyx
Expand Up @@ -162,22 +162,22 @@ cdef class IndependentSets:
sage: for i in range(30):
... check_matching(graphs.RandomGNP(11,.3))
Compare the result with the output of subgraph_search::
Compare the result with the output of :meth:`subgraph_search`::
sage: from sage.sets.set import Set
sage: def check_matching(G):
sage: def check_with_subgraph_search(G):
... IS = set(map(Set,list(IndependentSets(G))))
... if not all(G.subgraph(l).is_independent_set() for l in IS):
... print "Gloops"
... omega = max(map(len,IS))
... alpha = max(map(len,IS))
... IS2 = [Set([x]) for x in range(G.order())] + [Set([])]
... for n in range(2,omega+1):
... for n in range(2,alpha+1):
... IS2.extend(map(Set,list(G.subgraph_search_iterator(Graph(n), induced = True))))
... if len(IS) != len(set(IS2)):
... print "Oops"
... print len(IS), len(set(IS2))
sage: for i in range(5):
... check_matching(graphs.RandomGNP(11,.3))
... check_with_subgraph_search(graphs.RandomGNP(11,.3))
Empty graph::
Expand Down

0 comments on commit 5aeaccf

Please sign in to comment.