Skip to content

Commit e087e70

Browse files
author
Release Manager
committed
gh-37557: Modified quaternion algebra documentation Updated details for John Voight's book "Quaternion Algebras" in the list of references and modified some docstrings in `quaternion_algebra.py`. Split off from #37173. URL: #37557 Reported by: Sebastian A. Spindler Reviewer(s): Travis Scrimshaw
2 parents 8af3c37 + 3564537 commit e087e70

File tree

2 files changed

+20
-20
lines changed

2 files changed

+20
-20
lines changed

src/doc/en/reference/references/index.rst

+2-1
Original file line numberDiff line numberDiff line change
@@ -6395,7 +6395,8 @@ REFERENCES:
63956395
.. [Voi2012] \J. Voight. Identifying the matrix ring: algorithms for
63966396
quaternion algebras and quadratic forms, to appear.
63976397
6398-
.. [Voi2021] \J. Voight. Quaternion algebras, Springer Nature (2021).
6398+
.. [Voi2021] \J. Voight. Quaternion Algebras. Graduate Texts in
6399+
Mathematics 288. Springer Cham, 2021.
63996400
64006401
.. [VS06] \G.D. Villa Salvador. Topics in the Theory of Algebraic Function
64016402
Fields. Birkh\"auser, 2006.

src/sage/algebras/quatalg/quaternion_algebra.py

+18-19
Original file line numberDiff line numberDiff line change
@@ -1903,13 +1903,12 @@ def discriminant(self):
19031903

19041904
return (MatrixSpace(QQ, 4, 4)(L)).determinant().sqrt()
19051905

1906-
def is_maximal(self):
1906+
def is_maximal(self) -> bool:
19071907
r"""
19081908
Check whether the order of ``self`` is maximal in the ambient quaternion algebra.
19091909
1910-
Only works in quaternion algebras over number fields
1911-
1912-
OUTPUT: Boolean
1910+
Only implemented for quaternion algebras over number fields; for reference,
1911+
see Theorem 15.5.5 in [Voi2021]_.
19131912
19141913
EXAMPLES::
19151914
@@ -2781,8 +2780,7 @@ def random_element(self, *args, **kwds):
27812780
27822781
sage: B.<i,j,k> = QuaternionAlgebra(211)
27832782
sage: I = B.ideal([1, 1/4*j, 20*(i+k), 2/3*i])
2784-
sage: x = I.random_element() # random
2785-
sage: x in I
2783+
sage: I.random_element() in I
27862784
True
27872785
"""
27882786
return sum(ZZ.random_element(*args, **kwds) * g for g in self.gens())
@@ -3664,14 +3662,14 @@ def cyclic_right_subideals(self, p, alpha=None):
36643662
ans.append(J)
36653663
return ans
36663664

3667-
def is_integral(self):
3665+
def is_integral(self) -> bool:
36683666
r"""
3669-
Check if a quaternion fractional ideal is integral. An ideal in a quaternion algebra is
3670-
said integral if it is contained in its left order. If the left order is already defined it just
3671-
check the definition, otherwise it uses one of the alternative definition of Lemma 16.2.8 of
3672-
[Voi2021]_.
3667+
Check whether the quaternion fractional ideal ``self`` is integral.
36733668
3674-
OUTPUT: a boolean.
3669+
An ideal in a quaternion algebra is integral if and only if it is
3670+
contained in its left order. If the left order is already defined
3671+
this method just checks this definition, otherwise it uses one
3672+
of the alternative definitions from Lemma 16.2.8 of [Voi2021]_.
36753673
36763674
EXAMPLES::
36773675
@@ -3700,7 +3698,8 @@ def primitive_decomposition(self):
37003698
Let `I` = ``self``. If `I` is an integral left `\mathcal{O}`-ideal return its decomposition
37013699
as an equivalent primitive ideal and an integer such that their product is the initial ideal.
37023700
3703-
OUTPUTS: and quivalent primitive ideal to `I`, i.e. equivalent ideal not contained in `n\mathcal{O}` for any `n>0`, and the smallest integer such that `I \subset g\mathcal{O}`.
3701+
OUTPUTS: A primitive ideal equivalent to `I`, i.e. an equivalent ideal not contained
3702+
in `n\mathcal{O}` for any `n>0`, and the smallest integer `g` such that `I \subset g\mathcal{O}`.
37043703
37053704
EXAMPLES::
37063705
@@ -3717,7 +3716,7 @@ def primitive_decomposition(self):
37173716
37183717
TESTS:
37193718
3720-
Checks on random crafted ideals that they decompose as expected::
3719+
Check that randomly generated ideals decompose as expected::
37213720
37223721
sage: for d in ( m for m in range(400, 750) if is_squarefree(m) ):
37233722
....: A = QuaternionAlgebra(d)
@@ -3749,13 +3748,13 @@ def primitive_decomposition(self):
37493748

37503749
return J, g
37513750

3752-
def is_primitive(self):
3751+
def is_primitive(self) -> bool:
37533752
r"""
3754-
Check if the quaternion fractional ideal is primitive. An integral left
3755-
$O$-ideal for some order $O$ is said primitive if for all integers $n > 1$
3756-
$I$ is not contained in $nO$.
3753+
Check whether the quaternion fractional ideal ``self`` is primitive.
37573754
3758-
OUTPUT: a boolean.
3755+
An integral left `\mathcal{O}`-ideal for some order `\mathcal{O}`
3756+
is called primitive if for all integers `n > 1` it is not
3757+
contained in `n\mathcal{O}`.
37593758
37603759
EXAMPLES::
37613760

0 commit comments

Comments
 (0)