Skip to content

Commit 1e75afd

Browse files
committed
is_ordinary/is_supersingular + more doctests
1 parent f87597c commit 1e75afd

File tree

4 files changed

+91
-36
lines changed

4 files changed

+91
-36
lines changed

src/sage/rings/function_field/drinfeld_modules/drinfeld_module.py

Lines changed: 0 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -1341,27 +1341,6 @@ def is_isomorphic(self, other, absolutely=False):
13411341
raise NotImplementedError(f"cannot solve the equation u^{e} == {ue}")
13421342
return True
13431343

1344-
def is_supersingular(self):
1345-
r"""
1346-
Return ``True`` if the Drinfeld module is supersingular.
1347-
1348-
A Drinfeld module is supersingular if and only if its
1349-
height equals its rank.
1350-
1351-
EXAMPLES::
1352-
1353-
sage: Fq = GF(343)
1354-
sage: A.<T> = Fq[]
1355-
sage: K.<z6> = Fq.extension(2)
1356-
sage: phi = DrinfeldModule(A, [1, 0, z6])
1357-
sage: phi.is_supersingular()
1358-
True
1359-
sage: phi(phi.characteristic()) # Purely inseparable
1360-
z6*t^2
1361-
1362-
"""
1363-
return self.height() == self.rank()
1364-
13651344
def is_finite(self) -> bool:
13661345
r"""
13671346
Return ``True`` if this Drinfeld module is finite,

src/sage/rings/function_field/drinfeld_modules/finite_drinfeld_module.py

Lines changed: 42 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -487,13 +487,43 @@ def invert(self, ore_pol):
487487
pass
488488
raise ValueError('input must be in the image of the Drinfeld module')
489489

490+
def is_supersingular(self):
491+
r"""
492+
Return ``True`` if this Drinfeld module is supersingular.
493+
494+
A Drinfeld module is supersingular if and only if its
495+
height equals its rank.
496+
497+
EXAMPLES::
498+
499+
sage: Fq = GF(343)
500+
sage: A.<T> = Fq[]
501+
sage: K.<z6> = Fq.extension(2)
502+
sage: phi = DrinfeldModule(A, [1, 0, z6])
503+
sage: phi.is_supersingular()
504+
True
505+
sage: phi(phi.characteristic()) # Purely inseparable
506+
z6*t^2
507+
508+
In rank two, a Drinfeld module is either ordinary or
509+
supersinguler. In higher ranks, it could be neither of
510+
the two::
511+
512+
sage: psi = DrinfeldModule(A, [1, 0, z6, z6])
513+
sage: psi.is_ordinary()
514+
False
515+
sage: psi.is_supersingular()
516+
False
517+
518+
"""
519+
return self.height() == self.rank()
520+
490521
def is_ordinary(self):
491522
r"""
492-
Return ``True`` if the Drinfeld module is ordinary; raise a
493-
NotImplementedError if the rank is not two.
523+
Return ``True`` if this Drinfeld module is ordinary.
494524
495-
A rank two Drinfeld module is *ordinary* if and only if it is
496-
not supersingular; see :meth:`is_supersingular`.
525+
A Drinfeld module is supersingular if and only if its
526+
height is one.
497527
498528
EXAMPLES::
499529
@@ -503,9 +533,12 @@ def is_ordinary(self):
503533
sage: phi = DrinfeldModule(A, [1, 0, z6])
504534
sage: phi.is_ordinary()
505535
False
506-
sage: phi_p = phi(phi.characteristic())
507-
sage: phi_p # Purely inseparable
508-
z6*t^2
536+
537+
::
538+
539+
sage: phi = DrinfeldModule(A, [1, z6, 0, z6])
540+
sage: phi.is_ordinary()
541+
True
542+
509543
"""
510-
self._check_rank_two()
511-
return not self.is_supersingular()
544+
return self.height() == 1

src/sage/rings/function_field/drinfeld_modules/homset.py

Lines changed: 39 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -33,8 +33,39 @@
3333
class DrinfeldModuleMorphismAction(Action):
3434
r"""
3535
Action of the function ring on the homset of a Drinfeld module.
36-
"""
3736
37+
EXAMPLES::
38+
39+
sage: Fq = GF(5)
40+
sage: A.<T> = Fq[]
41+
sage: K.<z> = Fq.extension(3)
42+
sage: phi = DrinfeldModule(A, [z, 1, z])
43+
sage: psi = DrinfeldModule(A, [z, z^2 + 4*z + 3, 2*z^2 + 4*z + 4])
44+
sage: H = Hom(phi, psi)
45+
sage: t = phi.ore_variable()
46+
sage: f = H(t + 2)
47+
48+
Left action::
49+
50+
sage: (T + 1) * f
51+
Drinfeld Module morphism:
52+
From: Drinfeld module defined by T |--> z*t^2 + t + z
53+
To: Drinfeld module defined by T |--> (2*z^2 + 4*z + 4)*t^2 + (z^2 + 4*z + 3)*t + z
54+
Defn: (2*z^2 + 4*z + 4)*t^3 + (2*z + 1)*t^2 + (2*z^2 + 4*z + 2)*t + 2*z + 2
55+
56+
Right action currently does not work (it is a known bug, due to an
57+
incompatibility between multiplication of morphisms and the coercion
58+
system)::
59+
60+
sage: f * (T + 1)
61+
Traceback (most recent call last):
62+
...
63+
TypeError: right (=T + 1) must be a map to multiply it by Drinfeld Module morphism:
64+
From: Drinfeld module defined by T |--> z*t^2 + t + z
65+
To: Drinfeld module defined by T |--> (2*z^2 + 4*z + 4)*t^2 + (z^2 + 4*z + 3)*t + z
66+
Defn: t + 2
67+
68+
"""
3869
def __init__(self, A, H, is_left, op):
3970
r"""
4071
Initialize this action.
@@ -349,8 +380,6 @@ def _element_constructor_(self, *args, **kwds):
349380
Return the Drinfeld module morphism defined by the given Ore
350381
polynomial.
351382
352-
INPUT: an Ore polynomial
353-
354383
EXAMPLES::
355384
356385
sage: Fq = GF(27)
@@ -365,6 +394,13 @@ def _element_constructor_(self, *args, **kwds):
365394
sage: identity_morphism
366395
Identity morphism of Drinfeld module defined by T |--> 2*t^2 + z6*t + z6
367396
397+
::
398+
399+
sage: scalar_multiplication = E(T)
400+
sage: scalar_multiplication
401+
Endomorphism of Drinfeld module defined by T |--> 2*t^2 + z6*t + z6
402+
Defn: 2*t^2 + z6*t + z6
403+
368404
::
369405
370406
sage: frobenius_endomorphism = E(t^6)

src/sage/rings/function_field/drinfeld_modules/morphism.py

Lines changed: 10 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -135,17 +135,24 @@ def __classcall_private__(cls, parent, x):
135135
136136
- ``parent`` -- the Drinfeld module homset
137137
138-
- ``x`` -- the Ore polynomial defining the morphism or a
139-
DrinfeldModuleMorphism
138+
- ``x`` -- a morphism of Drinfeld modules or an element
139+
(either an Ore polynomial or an element in the base
140+
ring) defining it
140141
141142
TESTS::
142143
143144
sage: Fq = GF(2)
144145
sage: A.<T> = Fq[]
145146
sage: K.<z6> = Fq.extension(6)
146147
sage: phi = DrinfeldModule(A, [z6, 1, 1])
147-
sage: psi = DrinfeldModule(A, [z6, z6^4 + z6^2 + 1, 1])
148+
sage: End(phi)(T + 1)
149+
Endomorphism of Drinfeld module defined by T |--> t^2 + t + z6
150+
Defn: t^2 + t + z6 + 1
151+
152+
::
153+
148154
sage: t = phi.ore_polring().gen()
155+
sage: psi = DrinfeldModule(A, [z6, z6^4 + z6^2 + 1, 1])
149156
sage: morphism = Hom(phi, psi)(t + z6^5 + z6^2 + 1)
150157
sage: morphism is Hom(phi, psi)(morphism)
151158
True

0 commit comments

Comments
 (0)