Skip to content

Commit

Permalink
Reviewer changes.
Browse files Browse the repository at this point in the history
  • Loading branch information
tscrim committed May 28, 2024
1 parent 5214127 commit 361a36b
Show file tree
Hide file tree
Showing 3 changed files with 22 additions and 16 deletions.
17 changes: 9 additions & 8 deletions src/sage/categories/modules_with_basis.py
Original file line number Diff line number Diff line change
Expand Up @@ -729,7 +729,7 @@ def echelon_form(self, elements, row_reduced=False, order=None):

def submodule(self, gens, check=True, already_echelonized=False,
unitriangular=False, support_order=None, category=None,
parent_class=None, *args, **opts):
submodule_class=None, *args, **opts):
r"""
The submodule spanned by a finite set of elements.
Expand All @@ -746,7 +746,8 @@ def submodule(self, gens, check=True, already_echelonized=False,
- ``support_order`` -- (optional) either something that can
be converted into a tuple or a key function
- ``category`` -- (optional) the category of the submodule
- ``parent_class`` -- (optional) the class of the parent to return
- ``submodule_class`` -- (optional) the class of the submodule
to return
If ``already_echelonized`` is ``False``, then the
generators are put in reduced echelon form using
Expand Down Expand Up @@ -909,12 +910,12 @@ def submodule(self, gens, check=True, already_echelonized=False,
if not already_echelonized:
gens = self.echelon_form(gens, unitriangular, order=support_order)

if parent_class is None:
from sage.modules.with_basis.subquotient import SubmoduleWithBasis as parent_class
return parent_class(gens, ambient=self,
support_order=support_order,
unitriangular=unitriangular,
category=category, *args, **opts)
if submodule_class is None:
from sage.modules.with_basis.subquotient import SubmoduleWithBasis as submodule_class
return submodule_class(gens, ambient=self,
support_order=support_order,
unitriangular=unitriangular,
category=category, *args, **opts)

def quotient_module(self, submodule, check=True, already_echelonized=False, category=None):
r"""
Expand Down
6 changes: 3 additions & 3 deletions src/sage/combinat/symmetric_group_representations.py
Original file line number Diff line number Diff line change
Expand Up @@ -1464,11 +1464,11 @@ def _acted_upon_(self, scalar, self_on_left=True):
-gp1 - gp2 - gp3
sage: g = SGA.group().an_element(); g
[4, 1, 2, 3]
sage: g * v
sage: g * v # indirect doctest
gp3
sage: x * v
sage: x * v # indirect doctest
gp3
sage: 2 * v
sage: 2 * v # indirect doctest
gp1 + gp2 + gp3
"""
P = self.parent()
Expand Down
15 changes: 10 additions & 5 deletions src/sage/modules/with_basis/representation.py
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,10 @@ class Representation_abstract:
INPUT:
- ``semigroup`` -- a semigroup
- ``base_ring`` -- a commutative ring
- ``side`` -- (default: ``"left"``) whether this is a
``"left"`` or ``"right"`` representation
- ``algebra`` -- (default: ``semigroup.algebra(self.base_ring())``)
the semigroup algebra
.. NOTE::
Expand All @@ -50,7 +53,7 @@ def __init__(self, semigroup, side, algebra=None):
sage: T = G.trivial_representation()
sage: TestSuite(T).run()
Verify that the dynamic mixin classes works::
Verify that the dynamic mixin classes work::
sage: SGA = SymmetricGroupAlgebra(QQ, 3)
sage: S21 = SGA.specht_module([2,1])
Expand Down Expand Up @@ -652,7 +655,9 @@ def subrepresentation(self, gens, check=True, already_echelonized=False,
- ``gens`` -- the generators of the submodule
- ``check`` -- ignored
- ``already_echelonized`` --
- ``already_echelonized`` -- (default: ``False``) whether
the elements of ``gens`` are already in (not necessarily
reduced) echelon form
- ``is_closed`` -- (keyword only; default: ``False``) whether ``gens``
already spans the subspace closed under the semigroup action
Expand Down Expand Up @@ -780,8 +785,8 @@ def _composition_series_data(self):
S_basis = [self.element_class(self, linear_combination((V._basis[i]._monomial_coefficients, coeff)
for i, coeff in b._monomial_coefficients.items()))
for b in S._basis]
# Lift the basis of W', which is W as a subrepr of ``self ``
# This is equivanlent to [b.lift() for b in series[cur+1].basis()]
# Lift the basis of W', which is W as a subrepresentation of ``self``
# This is equivalent to [b.lift() for b in series[cur+1].basis()]
Wp_basis = list(series[cur+1]._basis)
Wp = self.subrepresentation(S_basis + Wp_basis, is_closed=True)
series.insert(cur+1, Wp)
Expand Down

0 comments on commit 361a36b

Please sign in to comment.