Skip to content

Commit 8ef0342

Browse files
Action renovation x3
1 parent df9ceeb commit 8ef0342

File tree

5 files changed

+336
-469
lines changed

5 files changed

+336
-469
lines changed

docs/source/_ext/libsemigroups_pybind11_extensions.py

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -60,9 +60,7 @@ def doc_only_run(self):
6060
docstring = list(node.findall(condition=desc_content))
6161

6262
if not docstring:
63-
logger.warning(
64-
f"The docstring for {self.arguments[0]} cannot be found."
65-
)
63+
logger.warning(f"The docstring for {self.arguments[0]} cannot be found.")
6664
return []
6765

6866
return docstring
@@ -108,7 +106,6 @@ def no_doc_run(self):
108106
r"libsemigroups::RepOrc": r"RepOrc",
109107
r"libsemigroups::MinimalRepOrc": r"MinimalRepOrc",
110108
(
111-
r"libsemigroups::DynamicMatrix<libsemigroups::BooleanPlus, "
112109
r"libsemigroups::BooleanProd, libsemigroups::BooleanZero, "
113110
r"libsemigroups::BooleanOne, int>"
114111
): r"Matrix",
@@ -151,7 +148,7 @@ def no_doc_run(self):
151148
# FIXME can't disable signatures in c++ for the next one because it is
152149
# overloaded, and then there are no signatures at all (and the overloads
153150
# are seemingly documented as a single function because of this)
154-
r"knuth_bendix_non_trivial_classes.*$": "",
151+
# r"knuth_bendix_non_trivial_classes.*$": "",
155152
r"pbr_one\(\*args, \*\*kwargs\)": "",
156153
r"word_graph_dot\(.*\)(\s*->\s*(\w+::)*\w*)?": "",
157154
}

docs/source/main-algorithms/action/index.rst

Lines changed: 13 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -35,40 +35,20 @@ The following helper functions are also available:
3535

3636
>>> from libsemigroups_pybind11 import RightAction, BMat8
3737
>>> from libsemigroups_pybind11.bmat8 import row_space_basis
38-
>>> o = RightAction(Element=BMat8, Point=BMat8)
39-
>>> o.add_seed(row_space_basis(
40-
... BMat8(
41-
... [[1, 1, 1, 0],
42-
... [1, 1, 0, 0],
43-
... [0, 1, 0, 1],
44-
... [0, 1, 0, 0]]))
45-
... ).add_generator(
46-
... BMat8([[1, 0, 0, 0],
47-
... [0, 1, 0, 0],
48-
... [0, 0, 1, 0],
49-
... [0, 0, 0, 1]])
50-
... ).add_generator(
51-
... BMat8([[0, 1, 0, 0],
52-
... [1, 0, 0, 0],
53-
... [0, 0, 1, 0],
54-
... [0, 0, 0, 1]])
55-
... ).add_generator(
56-
... BMat8([[0, 1, 0, 0],
57-
... [0, 0, 1, 0],
58-
... [0, 0, 0, 1],
59-
... [1, 0, 0, 0]])
60-
... ).add_generator(
61-
... BMat8([[1, 0, 0, 0],
62-
... [0, 1, 0, 0],
63-
... [0, 0, 1, 0],
64-
... [1, 0, 0, 1]])
65-
... ).add_generator(
66-
... BMat8([[1, 0, 0, 0],
67-
... [0, 1, 0, 0],
68-
... [0, 0, 1, 0],
69-
... [0, 0, 0, 0]])
38+
>>> o = RightAction(
39+
... seeds=[
40+
... row_space_basis(
41+
... BMat8([[1, 1, 1, 0], [1, 1, 0, 0], [0, 1, 0, 1], [0, 1, 0, 0]])
42+
... )
43+
... ],
44+
... generators=[
45+
... BMat8([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]),
46+
... BMat8([[0, 1, 0, 0], [1, 0, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]),
47+
... BMat8([[0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1], [1, 0, 0, 0]]),
48+
... BMat8([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [1, 0, 0, 1]]),
49+
... BMat8([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 0]]),
50+
... ],
7051
... )
71-
<incomplete right action with 5 generators, 1 points>
7252
>>> len(o)
7353
553
7454

0 commit comments

Comments
 (0)