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

Commit

Permalink
Working on galois group revisions
Browse files Browse the repository at this point in the history
  • Loading branch information
roed314 committed Nov 24, 2019
1 parent 2346140 commit 3efc05e
Show file tree
Hide file tree
Showing 6 changed files with 414 additions and 123 deletions.
19 changes: 18 additions & 1 deletion src/sage/groups/pari_group.py
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ def __pari__(self):

def degree(self):
"""
Return the degree of ``self``.
Return the degree of this group.
EXAMPLES::
Expand All @@ -88,6 +88,23 @@ def degree(self):
"""
return self.__degree

def signature(self):
"""
Return 1 if contained in the alternating group, -1 otherwise
"""
return Integer(self.__x[1])

def transitive_number(self):
"""
If the transitive label is nTk, return `k`.
"""
return Integer(self.__x[2])

def label(self):
"""
"""
return str(self.__x[3])

def order(self):
"""
Return the order of ``self``.
Expand Down
2 changes: 1 addition & 1 deletion src/sage/groups/perm_gps/permgroup.py
Original file line number Diff line number Diff line change
Expand Up @@ -2104,7 +2104,7 @@ def order(self):

subgroup_order = self._order()
if subgroup_order is not None:
return subgroup_order
return subgroup_order

return Integer(self.gap().Size())

Expand Down
12 changes: 8 additions & 4 deletions src/sage/groups/perm_gps/permgroup_named.py
Original file line number Diff line number Diff line change
Expand Up @@ -1823,8 +1823,8 @@ def __init__(self, d, n):
...
ValueError: Index n must be in {1,..,1}
"""
d = Integer(d)
n = Integer(n)
self._d = d = Integer(d)
self._n = n = Integer(n)
if d < 0:
raise ValueError("Degree d must not be negative")
max_n = TransitiveGroups(d).cardinality()
Expand All @@ -1836,8 +1836,12 @@ def __init__(self, d, n):
gap_group = libgap.TransitiveGroup(d, n)
PermutationGroup_generic.__init__(self, gap_group=gap_group)

self._d = d
self._n = n

def transitive_number(self):
return self._n

def degree(self):
return self._d

def _repr_(self):
"""
Expand Down
Loading

0 comments on commit 3efc05e

Please sign in to comment.