File tree Expand file tree Collapse file tree 1 file changed +10
-3
lines changed Expand file tree Collapse file tree 1 file changed +10
-3
lines changed Original file line number Diff line number Diff line change @@ -1371,7 +1371,7 @@ def is_trivial(self):
1371
1371
1372
1372
A permutation group is trivial, if it consists only of the
1373
1373
identity element, that is, if it has no generators or only
1374
- the trivial generator .
1374
+ trivial generators .
1375
1375
1376
1376
EXAMPLES::
1377
1377
@@ -1387,9 +1387,16 @@ def is_trivial(self):
1387
1387
sage: DihedralGroup(1).is_trivial()
1388
1388
False
1389
1389
1390
+ TESTS::
1391
+
1392
+ sage: G = PermutationGroup([[], []], canonicalize=False)
1393
+ sage: G.ngens()
1394
+ 2
1395
+ sage: G.is_trivial()
1396
+ True
1390
1397
"""
1391
- return not self . _gens or ( len ( self . _gens ) == 1 and self ._gens [ 0 ]. is_one () )
1392
-
1398
+ return all ( g . is_one () for g in self ._gens )
1399
+
1393
1400
@cached_method
1394
1401
def one (self ):
1395
1402
"""
You can’t perform that action at this time.
0 commit comments