Skip to content

Commit 69056d1

Browse files
author
Matthias Koeppe
committed
sage.matroids: ./sage -fixdoctests --long --distribution 'sagemath-graphs[modules]' --only-tags --probe=sage.rings.finite_rings --overwrite
1 parent 6ffbe47 commit 69056d1

File tree

5 files changed

+34
-34
lines changed

5 files changed

+34
-34
lines changed

src/sage/matroids/basis_exchange_matroid.pyx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1715,7 +1715,7 @@ cdef class BasisExchangeMatroid(Matroid):
17151715
EXAMPLES::
17161716
17171717
sage: M = matroids.named_matroids.N1()
1718-
sage: binomial(M.size(), M.full_rank())-M.bases_count()
1718+
sage: binomial(M.size(), M.full_rank())-M.bases_count() # optional - sage.symbolic
17191719
68
17201720
sage: len([B for B in M.nonbases()])
17211721
68

src/sage/matroids/catalog.py

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -143,7 +143,7 @@ def R6():
143143
True
144144
sage: M.is_connected()
145145
True
146-
sage: M.is_3connected() # optional - sage.rings.finite_rings
146+
sage: M.is_3connected()
147147
False
148148
"""
149149
A = Matrix(GF(3), [
@@ -175,7 +175,7 @@ def Fano():
175175
sage: setprint(sorted(M.nonspanning_circuits()))
176176
[{'a', 'b', 'f'}, {'a', 'c', 'e'}, {'a', 'd', 'g'}, {'b', 'c', 'd'},
177177
{'b', 'e', 'g'}, {'c', 'f', 'g'}, {'d', 'e', 'f'}]
178-
sage: M.delete(M.groundset_list()[randrange(0, # optional - sage.rings.finite_rings
178+
sage: M.delete(M.groundset_list()[randrange(0,
179179
....: 7)]).is_isomorphic(matroids.CompleteGraphic(4))
180180
True
181181
"""
@@ -206,9 +206,9 @@ def NonFano():
206206
sage: setprint(M.nonbases())
207207
[{'a', 'b', 'f'}, {'a', 'c', 'e'}, {'a', 'd', 'g'}, {'b', 'c', 'd'},
208208
{'b', 'e', 'g'}, {'c', 'f', 'g'}]
209-
sage: M.delete('f').is_isomorphic(matroids.CompleteGraphic(4)) # optional - sage.rings.finite_rings
209+
sage: M.delete('f').is_isomorphic(matroids.CompleteGraphic(4))
210210
True
211-
sage: M.delete('g').is_isomorphic(matroids.CompleteGraphic(4)) # optional - sage.rings.finite_rings
211+
sage: M.delete('g').is_isomorphic(matroids.CompleteGraphic(4))
212212
False
213213
"""
214214
A = Matrix(GF(3), [
@@ -235,7 +235,7 @@ def O7():
235235
236236
sage: M = matroids.named_matroids.O7(); M
237237
O7: Ternary matroid of rank 3 on 7 elements, type 0+
238-
sage: M.delete('e').is_isomorphic(matroids.CompleteGraphic(4)) # optional - sage.rings.finite_rings
238+
sage: M.delete('e').is_isomorphic(matroids.CompleteGraphic(4))
239239
True
240240
sage: M.tutte_polynomial()
241241
y^4 + x^3 + x*y^2 + 3*y^3 + 4*x^2 + 5*x*y + 5*y^2 + 4*x + 4*y
@@ -266,7 +266,7 @@ def P7():
266266
P7: Ternary matroid of rank 3 on 7 elements, type 1+
267267
sage: M.f_vector()
268268
[1, 7, 11, 1]
269-
sage: M.has_minor(matroids.CompleteGraphic(4)) # optional - sage.rings.finite_rings
269+
sage: M.has_minor(matroids.CompleteGraphic(4))
270270
False
271271
sage: M.is_valid()
272272
True
@@ -594,7 +594,7 @@ def J():
594594
[{'a', 'b', 'f'}, {'a', 'c', 'g'}, {'a', 'd', 'h'}]
595595
sage: M.is_isomorphic(M.dual())
596596
True
597-
sage: M.has_minor(matroids.CompleteGraphic(4)) # optional - sage.rings.finite_rings
597+
sage: M.has_minor(matroids.CompleteGraphic(4))
598598
False
599599
sage: M.is_valid()
600600
True
@@ -866,7 +866,7 @@ def Whirl(n):
866866
sage: M.is_isomorphic(matroids.Wheel(5))
867867
False
868868
sage: M = matroids.Whirl(3)
869-
sage: M.is_isomorphic(matroids.CompleteGraphic(4)) # optional - sage.rings.finite_rings
869+
sage: M.is_isomorphic(matroids.CompleteGraphic(4))
870870
False
871871
872872
.. TODO::

src/sage/matroids/constructor.py

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -434,7 +434,7 @@ def Matroid(groundset=None, data=None, **kwds):
434434
....: [0, 1, 0, 1, 0, 1],
435435
....: [0, 0, 1, 0, 1, 1]])
436436
sage: M = Matroid(matrix=A)
437-
sage: M.is_isomorphic(matroids.CompleteGraphic(4)) # optional - sage.graphs sage.rings.finite_rings
437+
sage: M.is_isomorphic(matroids.CompleteGraphic(4)) # optional - sage.graphs
438438
True
439439
440440
Various shortcuts are possible::
@@ -491,7 +491,7 @@ def Matroid(groundset=None, data=None, **kwds):
491491
....: matrix=[[1, 1, 0], [1, 0, 1], [0, 1, 1]],
492492
....: field=GF(4, 'x'))
493493
Quaternary matroid of rank 3 on 6 elements
494-
sage: Matroid([0, 1, 2, 3, 4, 5], # optional - sage.rings.finite_rings
494+
sage: Matroid([0, 1, 2, 3, 4, 5],
495495
....: matrix=[[1, 1, 0], [1, 0, 1], [0, 1, 1]],
496496
....: field=GF(2), regular=True)
497497
Regular matroid of rank 3 on 6 elements with 16 bases
@@ -627,21 +627,21 @@ def Matroid(groundset=None, data=None, **kwds):
627627
increase speed, this check can be skipped::
628628
629629
sage: M = matroids.named_matroids.Fano()
630-
sage: N = Matroid(M, regular=True) # optional - sage.rings.finite_rings
630+
sage: N = Matroid(M, regular=True)
631631
Traceback (most recent call last):
632632
...
633633
ValueError: input is not a valid regular matroid
634-
sage: N = Matroid(M, regular=True, check=False); N # optional - sage.rings.finite_rings
634+
sage: N = Matroid(M, regular=True, check=False); N
635635
Regular matroid of rank 3 on 7 elements with 32 bases
636636
637-
sage: N.is_valid() # optional - sage.rings.finite_rings
637+
sage: N.is_valid()
638638
False
639639
640640
Sometimes the output is regular, but represents a different matroid
641641
from the one you intended::
642642
643643
sage: M = Matroid(Matrix(GF(3), [[1, 0, 1, 1], [0, 1, 1, 2]]))
644-
sage: N = Matroid(Matrix(GF(3), [[1, 0, 1, 1], [0, 1, 1, 2]]), # optional - sage.rings.finite_rings
644+
sage: N = Matroid(Matrix(GF(3), [[1, 0, 1, 1], [0, 1, 1, 2]]),
645645
....: regular=True)
646646
sage: N.is_valid()
647647
True

src/sage/matroids/linear_matroid.pyx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2751,7 +2751,7 @@ cdef class LinearMatroid(BasisExchangeMatroid):
27512751
....: [0,0,1,1,0,0,1,1,0,1,0,1],
27522752
....: [0,0,0,0,1,1,1,1,0,0,1,1],
27532753
....: [0,0,0,0,0,0,0,0,1,1,1,1]])
2754-
sage: M._is_4connected_shifting() # optional - sage.graphs sage.rings.finite_rings
2754+
sage: M._is_4connected_shifting() # optional - sage.graphs
27552755
True
27562756
"""
27572757
if self.rank()>self.size()-self.rank():

src/sage/matroids/matroid.pyx

Lines changed: 18 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -2859,7 +2859,7 @@ cdef class Matroid(SageObject):
28592859
EXAMPLES::
28602860
28612861
sage: M = matroids.named_matroids.Fano()
2862-
sage: M.lattice_of_flats() # optional - sage.rings.finite_rings
2862+
sage: M.lattice_of_flats()
28632863
Finite lattice containing 16 elements
28642864
"""
28652865
from sage.combinat.posets.lattices import LatticePoset
@@ -5083,7 +5083,7 @@ cdef class Matroid(SageObject):
50835083
sage: matroids.AG(5,2).is_kconnected(4)
50845084
True
50855085
sage: M = matroids.named_matroids.R6()
5086-
sage: M.is_kconnected(3) # optional - sage.rings.finite_rings
5086+
sage: M.is_kconnected(3)
50875087
False
50885088
sage: B, X = M.is_kconnected(3,True)
50895089
sage: M.connectivity(X)<3
@@ -5225,7 +5225,7 @@ cdef class Matroid(SageObject):
52255225
sage: matroids.named_matroids.BetsyRoss().is_3connected()
52265226
True
52275227
sage: M = matroids.named_matroids.R6()
5228-
sage: M.is_3connected() # optional - sage.rings.finite_rings
5228+
sage: M.is_3connected()
52295229
False
52305230
sage: B, X = M.is_3connected(True)
52315231
sage: M.connectivity(X)
@@ -5285,7 +5285,7 @@ cdef class Matroid(SageObject):
52855285
....: [0,0,1,1,0,0,1,1,0,1,0,1],
52865286
....: [0,0,0,0,1,1,1,1,0,0,1,1],
52875287
....: [0,0,0,0,0,0,0,0,1,1,1,1]])
5288-
sage: M.is_4connected() == M.is_4connected(algorithm="shifting") # optional - sage.rings.finite_rings
5288+
sage: M.is_4connected() == M.is_4connected(algorithm="shifting")
52895289
True
52905290
sage: M.is_4connected() == M.is_4connected(algorithm="intersection")
52915291
True
@@ -5460,10 +5460,10 @@ cdef class Matroid(SageObject):
54605460
sage: matroids.named_matroids.BetsyRoss()._is_3connected_shifting()
54615461
True
54625462
sage: M = matroids.named_matroids.R6()
5463-
sage: M._is_3connected_shifting() # optional - sage.graphs sage.rings.finite_rings
5463+
sage: M._is_3connected_shifting() # optional - sage.graphs
54645464
False
5465-
sage: B, X = M._is_3connected_shifting(True)
5466-
sage: M.connectivity(X)
5465+
sage: B, X = M._is_3connected_shifting(True) # optional - sage.graphs
5466+
sage: M.connectivity(X) # optional - sage.graphs
54675467
1
54685468
"""
54695469
if not self.is_connected():
@@ -5534,7 +5534,7 @@ cdef class Matroid(SageObject):
55345534
....: [0,0,1,1,0,0,1,1,0,1,0,1],
55355535
....: [0,0,0,0,1,1,1,1,0,0,1,1],
55365536
....: [0,0,0,0,0,0,0,0,1,1,1,1]])
5537-
sage: M._is_4connected_shifting() # optional - sage.rings.finite_rings
5537+
sage: M._is_4connected_shifting() # optional - sage.graphs
55385538
True
55395539
"""
55405540
if self.rank()>self.size()-self.rank():
@@ -5794,7 +5794,7 @@ cdef class Matroid(SageObject):
57945794
sage: matroids.named_matroids.BetsyRoss()._is_3connected_BC()
57955795
True
57965796
sage: M = matroids.named_matroids.R6()
5797-
sage: M._is_3connected_BC() # optional - sage.rings.finite_rings
5797+
sage: M._is_3connected_BC()
57985798
False
57995799
"""
58005800
# The 5 stages of the algorithm
@@ -5841,7 +5841,7 @@ cdef class Matroid(SageObject):
58415841
True
58425842
sage: M = matroids.named_matroids.R6()
58435843
sage: B = M.basis()
5844-
sage: M._is_3connected_BC_recursion(B, # optional - sage.rings.finite_rings
5844+
sage: M._is_3connected_BC_recursion(B,
58455845
....: [M.fundamental_cocircuit(B, e) for e in B])
58465846
False
58475847
@@ -6083,12 +6083,12 @@ cdef class Matroid(SageObject):
60836083
EXAMPLES::
60846084
60856085
sage: N = matroids.named_matroids.Fano()
6086-
sage: M = N._local_ternary_matroid() # optional - sage.rings.finite_rings
6087-
sage: N.is_isomorphism(M, {e:e for e in N.groundset()}) # optional - sage.rings.finite_rings
6086+
sage: M = N._local_ternary_matroid()
6087+
sage: N.is_isomorphism(M, {e:e for e in N.groundset()})
60886088
False
60896089
sage: N = matroids.named_matroids.NonFano()
6090-
sage: M = N._local_ternary_matroid() # optional - sage.rings.finite_rings
6091-
sage: N.is_isomorphism(M, {e:e for e in N.groundset()}) # optional - sage.rings.finite_rings
6090+
sage: M = N._local_ternary_matroid()
6091+
sage: N.is_isomorphism(M, {e:e for e in N.groundset()})
60926092
True
60936093
"""
60946094
if basis is None:
@@ -6175,7 +6175,7 @@ cdef class Matroid(SageObject):
61756175
EXAMPLES::
61766176
61776177
sage: M = matroids.named_matroids.Fano()
6178-
sage: M.ternary_matroid() is None # optional - sage.rings.finite_rings
6178+
sage: M.ternary_matroid() is None
61796179
True
61806180
sage: N = matroids.named_matroids.NonFano()
61816181
sage: N.ternary_matroid()
@@ -6227,7 +6227,7 @@ cdef class Matroid(SageObject):
62276227
EXAMPLES::
62286228
62296229
sage: N = matroids.named_matroids.Fano()
6230-
sage: N.is_ternary() # optional - sage.rings.finite_rings
6230+
sage: N.is_ternary()
62316231
False
62326232
sage: N = matroids.named_matroids.NonFano()
62336233
sage: N.is_ternary()
@@ -7886,7 +7886,7 @@ cdef class Matroid(SageObject):
78867886
EXAMPLES::
78877887
78887888
sage: M = matroids.named_matroids.Fano()
7889-
sage: B = M.bergman_complex(); B # optional - sage.rings.finite_rings
7889+
sage: B = M.bergman_complex(); B
78907890
Simplicial complex with 14 vertices and 21 facets
78917891
78927892
.. SEEALSO::
@@ -7925,7 +7925,7 @@ cdef class Matroid(SageObject):
79257925
EXAMPLES::
79267926
79277927
sage: M = matroids.named_matroids.Fano()
7928-
sage: A = M.augmented_bergman_complex(); A # optional - sage.graphs sage.rings.finite_rings
7928+
sage: A = M.augmented_bergman_complex(); A # optional - sage.graphs
79297929
Simplicial complex with 22 vertices and 91 facets
79307930
79317931
sage: M = matroids.Uniform(2,3)

0 commit comments

Comments
 (0)