Skip to content

Commit

Permalink
Added presentation in chow_ring.py
Browse files Browse the repository at this point in the history
  • Loading branch information
25shriya committed Jan 21, 2025
1 parent 5c4c89d commit 1aabf83
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 8 deletions.
9 changes: 7 additions & 2 deletions src/sage/matroids/chow_ring.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
# https://www.gnu.org/licenses/
# ****************************************************************************

from sage.matroids.chow_ring_ideal import ChowRingIdeal_nonaug, AugmentedChowRingIdeal_fy, AugmentedChowRingIdeal_atom_free
from sage.matroids.chow_ring_ideal import ChowRingIdeal_nonaug_fy, ChowRingIdeal_nonaug_af, ChowRingIdeal_nonaug_sp, AugmentedChowRingIdeal_fy, AugmentedChowRingIdeal_atom_free
from sage.rings.quotient_ring import QuotientRing_generic
from sage.categories.kahler_algebras import KahlerAlgebras
from sage.categories.commutative_rings import CommutativeRings
Expand Down Expand Up @@ -110,7 +110,12 @@ def __init__(self, R, M, augmented, presentation=None):
elif presentation == 'atom-free':
self._ideal = AugmentedChowRingIdeal_atom_free(M, R)
else:
self._ideal = ChowRingIdeal_nonaug(M, R)
if presentation == 'fy':
self._ideal = ChowRingIdeal_nonaug_fy(M, R)
if presentation == 'atom-free':
self._ideal = ChowRingIdeal_nonaug_af(M, R)
if presentation == 'simplicial':
self._ideal = ChowRingIdeal_nonaug_sp(M, R)
C = CommutativeRings().Quotients() & KahlerAlgebras(R)
QuotientRing_generic.__init__(self, R=self._ideal.ring(),
I=self._ideal,
Expand Down
12 changes: 6 additions & 6 deletions src/sage/matroids/chow_ring_ideal.py
Original file line number Diff line number Diff line change
Expand Up @@ -99,12 +99,12 @@ def flats_to_generator_dict(self):
return dict(self._flats_generator)


class ChowRingIdeal_nonaug(ChowRingIdeal):
class ChowRingIdeal_nonaug_fy(ChowRingIdeal):
r"""
The Chow ring ideal of a matroid `M`.
The Chow ring ideal of a matroid `M` in Feitchner-Yuzvinsky presentation.
The *Chow ring ideal* for a matroid `M` is defined as the ideal
`(I_M + J_M)` of the polynomial ring
The *Chow ring ideal* for a matroid `M` in Feitchner-Yuzvinsky presentation
is defined as the ideal `(I_M + J_M)` of the polynomial ring
.. MATH::
Expand Down Expand Up @@ -224,9 +224,9 @@ def _repr_(self):
sage: ch = matroids.catalog.Fano().chow_ring(QQ, False)
sage: ch.defining_ideal()
Chow ring ideal of Fano: Binary matroid of rank 3 on 7 elements,
type (3, 0) - non augmented
type (3, 0) - non augmented in Feitchner-Yuzvinsky presentation
"""
return "Chow ring ideal of {} - non augmented".format(self._matroid)
return "Chow ring ideal of {} - non augmented in Feitchner-Yuzvinksy presentation".format(self._matroid)

def _latex_(self):
r"""
Expand Down

0 comments on commit 1aabf83

Please sign in to comment.