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

Commit

Permalink
#8829 fix docstring typos
Browse files Browse the repository at this point in the history
  • Loading branch information
JohnCremona committed Aug 7, 2017
1 parent 8c71585 commit 7b3c188
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 15 deletions.
12 changes: 7 additions & 5 deletions src/sage/schemes/elliptic_curves/ell_number_field.py
Original file line number Diff line number Diff line change
Expand Up @@ -3545,7 +3545,8 @@ def has_rational_cm(self, field=None):
def saturation(self, points, verbose=False,
max_prime=0, one_prime=0, odd_primes_only=False,
lower_ht_bound=None, reg=None, debug=False):
r""" Given a list of rational points on `E` over `K`, compute the
r"""
Given a list of rational points on `E` over `K`, compute the
saturation in `E(K)` of the subgroup they generate.
INPUT:
Expand Down Expand Up @@ -3657,11 +3658,11 @@ def saturation(self, points, verbose=False,
ALGORITHM:
For rank 1 subgroups, simply do trial divison up to the maximal
For rank 1 subgroups, simply do trial division up to the maximal
prime divisor. For higher rank subgroups, perform trial divison
on all linear combinations for small primes, and look for
projections `E(K) \rightarrow \oplus E(k) \otimes \mathbf{F}_p` which
are either full rank or provide `p`-divisble linear combinations,
are either full rank or provide `p`-divisible linear combinations,
where the `k` here are residue fields of `K`.
TESTS::
Expand Down Expand Up @@ -3752,7 +3753,8 @@ def saturation(self, points, verbose=False,


def gens_quadratic(self, **kwds):
"""Return generators for the Mordell-Weil group modulo torsion, for a
"""
Return generators for the Mordell-Weil group modulo torsion, for a
curve which is a base change from `\QQ` to a quadratic field.
EXAMPLES::
Expand Down Expand Up @@ -3787,7 +3789,7 @@ def gens_quadratic(self, **kwds):
raise ValueError("gens_quadratic() requires the base field to be quadratic")

EE = self.descend_to(QQ)
if len(EE)==0:
if not EE:
raise ValueError("gens_quadratic() requires the elliptic curve to be a base change from Q")

# In all cases there are exactly two distinct curves /Q whose
Expand Down
22 changes: 12 additions & 10 deletions src/sage/schemes/elliptic_curves/saturation.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
finitely-generated Abelian group.
The process of `p`-saturating a given set of points is implemented
here. The naive algirithm simply checks all `(p^r-1)/(p-1)`
here. The naive algorithm simply checks all `(p^r-1)/(p-1)`
projective combinations of the points, testing each to see if it can
be divided by `p`. If this occurs then we replace one of the points
and continue. The function :meth:`p_saturation` does one step of
Expand Down Expand Up @@ -54,20 +54,21 @@
from sage.rings.all import ZZ

def p_saturation(Plist, p, sieve=True, lin_combs = dict(), verbose=False):
r""" Checks whether the list of points is `p`-saturated.
r"""
Checks whether the list of points is `p`-saturated.
INPUT:
- ``Plist`` (list) - a list of independent points on one elliptic curve
- ``Plist`` (list) - a list of independent points on one elliptic curve.
- ``p`` (integer) - a prime number
- ``p`` (integer) - a prime number.
- ``sieve`` (boolean) - if True, use a sieve (when there are at
least 2 points); otherwise test all combinations.
- ``lin_combs`` (dict) - a dict, possibly empty, with keys
coefficient tuples and values the corresponding linear
combinations of the points in ``Plist``
combinations of the points in ``Plist``.
.. note::
Expand Down Expand Up @@ -101,7 +102,7 @@ def p_saturation(Plist, p, sieve=True, lin_combs = dict(), verbose=False):
sage: p_saturation([P,Q,R],3)
(True, {})
Here we see an example where 19-aturation is proved, with the
Here we see an example where 19-saturation is proved, with the
verbose flag set to True so that we can see what is going on::
sage: p_saturation([P,Q,R],19, verbose=True)
Expand Down Expand Up @@ -352,17 +353,18 @@ def a(pt,g):


def full_p_saturation(Plist, p, lin_combs = dict(), verbose=False):
r""" Full `p`-saturation of ``Plist``.
r"""
Full `p`-saturation of ``Plist``.
INPUT:
- ``Plist`` (list) - a list of independent points on one elliptic curve
- ``Plist`` (list) - a list of independent points on one elliptic curve.
- ``p`` (integer) - a prime number
- ``p`` (integer) - a prime number.
- ``lin_combs`` (dict, default null) - a dict, possibly empty,
with keys coefficient tuples and values the corresponding linear
combinations of the points in ``Plist``
combinations of the points in ``Plist``.
OUTPUT:
Expand Down

0 comments on commit 7b3c188

Please sign in to comment.