code stringlengths 17 6.64M |
|---|
class ProjectivePlaneCurvePoint_field(ProjectiveCurvePoint_field):
'\n Point of a projective plane curve over a field.\n '
def multiplicity(self):
'\n Return the multiplicity of this point with respect to the projective\n curve it is on.\n\n EXAMPLES::\n\n sage: ... |
class ProjectivePlaneCurvePoint_finite_field(ProjectivePlaneCurvePoint_field, SchemeMorphism_point_projective_finite_field):
'\n Point of a projective plane curve over a finite field.\n '
pass
|
class IntegralProjectiveCurvePoint(ProjectiveCurvePoint_field):
def closed_point(self):
'\n Return the closed point corresponding to this rational point.\n\n EXAMPLES::\n\n sage: P.<x,y,z> = ProjectiveSpace(GF(17), 2)\n sage: C = Curve([x^4 - 16*y^3*z], P)\n ... |
class IntegralProjectiveCurvePoint_finite_field(IntegralProjectiveCurvePoint):
'\n Point of an integral projective curve over a finite field.\n '
pass
|
class IntegralProjectivePlaneCurvePoint(IntegralProjectiveCurvePoint, ProjectivePlaneCurvePoint_field):
'\n Point of an integral projective plane curve over a field.\n '
pass
|
class IntegralProjectivePlaneCurvePoint_finite_field(ProjectivePlaneCurvePoint_finite_field, IntegralProjectiveCurvePoint_finite_field):
'\n Point of an integral projective plane curve over a finite field.\n '
pass
|
class AffineCurvePoint_field(SchemeMorphism_point_affine_field):
def is_singular(self):
'\n Return whether this point is a singular point of the affine curve it is on.\n\n EXAMPLES::\n\n sage: # needs sage.rings.number_field\n sage: K = QuadraticField(-1)\n ... |
class AffinePlaneCurvePoint_field(AffineCurvePoint_field):
'\n Point of an affine plane curve over a field.\n '
def multiplicity(self):
'\n Return the multiplicity of this point with respect to the affine curve it is on.\n\n EXAMPLES::\n\n sage: A.<x,y> = AffineSpace(QQ... |
class AffinePlaneCurvePoint_finite_field(AffinePlaneCurvePoint_field, SchemeMorphism_point_affine_finite_field):
'\n Point of an affine plane curve over a finite field.\n '
pass
|
class IntegralAffineCurvePoint(AffineCurvePoint_field):
'\n Point of an integral affine curve.\n '
def closed_point(self):
'\n Return the closed point that corresponds to this rational point.\n\n EXAMPLES::\n\n sage: # needs sage.rings.finite_rings\n sage: A.... |
class IntegralAffineCurvePoint_finite_field(IntegralAffineCurvePoint):
'\n Point of an integral affine curve over a finite field.\n '
pass
|
class IntegralAffinePlaneCurvePoint(IntegralAffineCurvePoint, AffinePlaneCurvePoint_field):
'\n Point of an integral affine plane curve over a finite field.\n '
pass
|
class IntegralAffinePlaneCurvePoint_finite_field(AffinePlaneCurvePoint_finite_field, IntegralAffineCurvePoint_finite_field):
'\n Point of an integral affine plane curve over a finite field.\n '
pass
|
class ProjectiveCurve(Curve_generic, AlgebraicScheme_subscheme_projective):
'\n Curves in projective spaces.\n\n INPUT:\n\n - ``A`` -- ambient projective space\n\n - ``X`` -- list of multivariate polynomials; defining equations of the curve\n\n EXAMPLES::\n\n sage: P.<x,y,z,w,u> = Projective... |
class ProjectivePlaneCurve(ProjectiveCurve):
"\n Curves in projective planes.\n\n INPUT:\n\n - ``A`` -- projective plane\n\n - ``f`` -- homogeneous polynomial in the homogeneous coordinate ring of the plane\n\n EXAMPLES:\n\n A projective plane curve defined over an algebraic closure of `\\QQ`::\... |
class ProjectiveCurve_field(ProjectiveCurve, AlgebraicScheme_subscheme_projective_field):
'\n Projective curves over fields.\n '
_point = ProjectiveCurvePoint_field
def __init__(self, A, X):
'\n Initialize.\n\n EXAMPLES::\n\n sage: P.<x,y,z> = ProjectiveSpace(QQ, 2)... |
class ProjectivePlaneCurve_field(ProjectivePlaneCurve, ProjectiveCurve_field):
'\n Projective plane curves over fields.\n '
_point = ProjectivePlaneCurvePoint_field
def arithmetic_genus(self):
"\n Return the arithmetic genus of this projective curve.\n\n This is the arithmetic... |
class ProjectivePlaneCurve_finite_field(ProjectivePlaneCurve_field):
'\n Projective plane curves over finite fields\n '
_point = ProjectivePlaneCurvePoint_finite_field
def rational_points_iterator(self):
"\n Return a generator object for the rational points on this curve.\n\n ... |
class IntegralProjectiveCurve(ProjectiveCurve_field):
'\n Integral projective curve.\n '
_point = IntegralProjectiveCurvePoint
_closed_point = IntegralProjectiveCurveClosedPoint
def __init__(self, A, f):
'\n Initialize.\n\n TESTS::\n\n sage: P.<x,y,z> = Projecti... |
class IntegralProjectiveCurve_finite_field(IntegralProjectiveCurve):
'\n Integral projective curve over a finite field.\n\n INPUT:\n\n - ``A`` -- an ambient projective space\n\n - ``f`` -- homogeneous polynomials defining the curve\n\n EXAMPLES::\n\n sage: P.<x,y,z> = ProjectiveSpace(GF(5), ... |
class IntegralProjectivePlaneCurve(IntegralProjectiveCurve, ProjectivePlaneCurve_field):
_point = IntegralProjectivePlaneCurvePoint
|
class IntegralProjectivePlaneCurve_finite_field(IntegralProjectiveCurve_finite_field, ProjectivePlaneCurve_finite_field):
'\n Integral projective plane curve over a finite field.\n\n INPUT:\n\n - ``A`` -- ambient projective plane\n\n - ``f`` -- a homogeneous equation that defines the curve\n\n EXAM... |
def Hasse_bounds(q, genus=1):
'\n Return the Hasse-Weil bounds for the cardinality of a nonsingular\n curve defined over `\\GF{q}` of given ``genus``.\n\n INPUT:\n\n - ``q`` (int) -- a prime power\n\n - ``genus`` (int, default 1) -- a non-negative integer,\n\n OUTPUT: A tuple. The Hasse bounds (... |
def braid_from_piecewise(strands):
'\n Compute the braid corresponding to the piecewise linear curves strands.\n\n INPUT:\n\n - ``strands`` -- a list of lists of tuples ``(t, c1, c2)``, where ``t``\n is a number between 0 and 1, and ``c1`` and ``c2`` are rationals\n or algebraic reals.\n\n O... |
def discrim(pols):
'\n Return the points in the discriminant of the product of the polynomials\n of a list or tuple ``pols``.\n\n The result is the set of values of the first variable for which\n two roots in the second variable coincide.\n\n INPUT:\n\n - ``pols`` -- a list or tuple of polynomia... |
@cached_function
def corrected_voronoi_diagram(points):
'\n Compute a Voronoi diagram of a set of points with rational coordinates.\n The given points are granted to lie one in each bounded region.\n\n INPUT:\n\n - ``points`` -- a list of complex numbers\n\n OUTPUT:\n\n A Voronoi diagram constru... |
def orient_circuit(circuit, convex=False, precision=53, verbose=False):
'\n Reverse a circuit if it goes clockwise; otherwise leave it unchanged.\n\n INPUT:\n\n - ``circuit`` -- a circuit in the graph of a Voronoi Diagram, given\n by a list of edges\n\n - ``convex`` -- boolean (default: `False`)... |
def voronoi_cells(V):
'\n Compute the graph, the boundary graph, a base point, a positive orientation\n of the boundary graph, and the dual graph of a corrected Voronoi diagram.\n\n INPUT:\n\n - ``V`` -- a corrected Voronoi diagram\n\n OUTPUT:\n\n - ``G`` -- the graph of the 1-skeleton of ``V``\... |
def followstrand(f, factors, x0, x1, y0a, prec=53):
'\n Return a piecewise linear approximation of the homotopy continuation\n of the root ``y0a`` from ``x0`` to ``x1``.\n\n INPUT:\n\n - ``f`` -- an irreducible polynomial in two variables\n - ``factors`` -- a list of irreducible polynomials in two ... |
def newton(f, x0, i0):
"\n Return the interval Newton operator.\n\n INPUT:\n\n - ``f`` -- a univariate polynomial\n - ``x0`` -- a number\n - ``I0`` -- an interval\n\n OUTPUT:\n\n The interval `x_0-\\frac{f(x_0)}{f'(I_0)}`\n\n EXAMPLES::\n\n sage: from sage.schemes.curves.zariski_van... |
def fieldI(field):
'\n Return the (either double or trivial) extension of a number field which contains ``I``.\n\n INPUT:\n\n - ``field`` -- a number field with an embedding in ``QQbar``.\n\n OUTPUT:\n\n The extension ``F`` of ``field`` containing ``I`` with an embedding in ``QQbar``.\n\n EXAM... |
@parallel
def roots_interval(f, x0):
'\n Find disjoint intervals that isolate the roots of a polynomial for a fixed\n value of the first variable.\n\n INPUT:\n\n - ``f`` -- a bivariate squarefree polynomial\n - ``x0`` -- a Gauss rational number corresponding to the first coordinate\n\n The inter... |
def roots_interval_cached(f, x0):
'\n Cached version of :func:`roots_interval`.\n\n TESTS::\n\n sage: from sage.schemes.curves.zariski_vankampen import roots_interval, roots_interval_cached, roots_interval_cache, fieldI\n sage: R.<x, y> = QQ[]\n sage: K = fieldI(QQ)\n sage: f = y... |
def populate_roots_interval_cache(inputs):
'\n Call :func:`roots_interval` to the inputs that have not been\n computed previously, and cache them.\n\n INPUT:\n\n - ``inputs`` -- a list of tuples ``(f, x0)``\n\n EXAMPLES::\n\n sage: from sage.schemes.curves.zariski_vankampen import populate_r... |
@parallel
def braid_in_segment(glist, x0, x1, precision={}):
"\n Return the braid formed by the `y` roots of ``f`` when `x` moves\n from ``x0`` to ``x1``.\n\n INPUT:\n\n - ``glist`` -- a tuple of polynomials in two variables\n - ``x0`` -- a Gauss rational\n - ``x1`` -- a Gauss rational\n - ``... |
def geometric_basis(G, E, EC0, p, dual_graph):
'\n Return a geometric basis, based on a vertex.\n\n INPUT:\n\n - ``G`` -- a graph with the bounded edges of a Voronoi Diagram\n\n - ``E`` -- a subgraph of ``G`` which is a cycle containing the bounded\n edges touching an unbounded region of a Vorono... |
def strand_components(f, flist, p1):
'\n Compute only the assignment from strands to elements of ``flist``.\n\n INPUT:\n\n - ``f`` -- a reduced polynomial with two variables, over a number field\n with an embedding in the complex numbers\n\n - ``flist`` -- a list of polynomials with two variabl... |
def braid_monodromy(f, arrangement=()):
'\n Compute the braid monodromy of a projection of the curve defined by\n a polynomial.\n\n INPUT:\n\n - ``f`` -- a polynomial with two variables, over a number field\n with an embedding in the complex numbers\n\n - ``arrangement`` -- an optional tuple o... |
def conjugate_positive_form(braid):
'\n For a ``braid`` which is conjugate to a product of *disjoint* positive\n braids a list of such decompositions is given.\n\n INPUT:\n\n - ``braid`` -- a braid ``\\sigma``.\n\n OUTPUT:\n\n A list of `r` lists. Each such list is another list with two elements... |
@parallel
def conjugate_positive_form_p(braid):
return conjugate_positive_form(braid)
|
def braid2rels(L):
'\n Return a minimal set of relations of the group\n ``F / [(b * F([j])) / F([j]) for j in (1..d)]`` where ``F = FreeGroup(d)``\n and ``b`` is a conjugate of a positive braid . One starts from the\n non-trivial relations determined by the positive braid and transform\n them in re... |
@parallel
def braid2rels_p(L):
return braid2rels(L)
|
@parallel
def relation(x, b):
return ((x * b) / x)
|
def fundamental_group_from_braid_mon(bm, degree=None, simplified=True, projective=False, puiseux=False, vertical=[]):
'\n Return a presentation of the fundamental group computed from\n a braid monodromy.\n\n INPUT:\n\n - ``bm`` -- a list of braids\n\n - ``degree`` -- integer (default: ``None``); on... |
def fundamental_group(f, simplified=True, projective=False, puiseux=False):
"\n Return a presentation of the fundamental group of the complement of\n the algebraic set defined by the polynomial ``f``.\n\n INPUT:\n\n - ``f`` -- a polynomial in two variables, with coefficients in either\n the ratio... |
def fundamental_group_arrangement(flist, simplified=True, projective=False, puiseux=False):
'\n Compute the fundamental group of the complement of a curve\n defined by a list of polynomials with the extra information\n about the correspondence of the generators\n and meridians of the elements of the l... |
def charpoly_frobenius(frob_matrix, charpoly_prec, p, weight, a=1, known_factor=[1]):
"\n Return the characteristic polynomial of the given Frobenius matrix.\n\n INPUT:\n\n - ``frob_matrix`` -- a matrix representing the Frobenius matrix up to some precision\n\n - ``charpoly_prec`` -- a vector ai, such... |
def CyclicCover(r, f, names=None, check_smooth=True):
'\n Return the cyclic cover of the projective line given by `y^r = f`, for\n a univariate polynomial `f`.\n\n INPUT:\n\n - ``r`` - the order of the cover\n\n - ``f`` - univariate polynomial if not given, then it defaults to 0.\n\n - ``names``... |
class CyclicCover_generic(AffinePlaneCurve):
def __init__(self, AA, r, f, names=None):
'\n Cyclic covers over a general ring\n\n INPUT:\n\n - ``A`` - ambient affine space\n\n - ``r`` - degree of the cover\n\n - ``f`` - univariate polynomial\n\n - ``names`` (de... |
class BSD_data():
"\n Helper class used to keep track of information in proving BSD.\n\n EXAMPLES::\n\n sage: from sage.schemes.elliptic_curves.BSD import BSD_data\n sage: D = BSD_data()\n sage: D.Sha is None\n True\n sage: D.curve=EllipticCurve('11a')\n sage: D.upd... |
def simon_two_descent_work(E, two_tor_rk):
'\n Prepare the output from Simon two-descent.\n\n INPUT:\n\n - ``E`` -- an elliptic curve\n\n - ``two_tor_rk`` -- its two-torsion rank\n\n OUTPUT:\n\n - a lower bound on the rank\n\n - an upper bound on the rank\n\n - a lower bound on the rank of... |
def mwrank_two_descent_work(E, two_tor_rk):
"\n Prepare the output from mwrank two-descent.\n\n INPUT:\n\n - ``E`` -- an elliptic curve\n\n - ``two_tor_rk`` -- its two-torsion rank\n\n OUTPUT:\n\n - a lower bound on the rank\n\n - an upper bound on the rank\n\n - a lower bound on the rank ... |
def pari_two_descent_work(E):
"\n Prepare the output from pari by two-isogeny.\n\n INPUT:\n\n - ``E`` -- an elliptic curve\n\n OUTPUT: A tuple of 5 elements with the first 4 being integers.\n\n - a lower bound on the rank\n\n - an upper bound on the rank\n\n - a lower bound on the rank of Sha... |
def native_two_isogeny_descent_work(E, two_tor_rk):
"\n Prepare the output from two-descent by two-isogeny.\n\n INPUT:\n\n - ``E`` -- an elliptic curve\n\n - ``two_tor_rk`` -- its two-torsion rank\n\n OUTPUT:\n\n - a lower bound on the rank\n\n - an upper bound on the rank\n\n - a lower bo... |
def heegner_index_work(E):
"\n Prepare the input and output for computing the heegner index.\n\n INPUT:\n\n - ``E`` -- an elliptic curve\n\n OUTPUT:\n\n - a Heegner index\n\n - the discriminant used\n\n EXAMPLES::\n\n sage: from sage.schemes.elliptic_curves.BSD import heegner_index_wor... |
def prove_BSD(E, verbosity=0, two_desc='mwrank', proof=None, secs_hi=5, return_BSD=False):
'\n Attempt to prove the Birch and Swinnerton-Dyer conjectural\n formula for `E`, returning a list of primes `p` for which this\n function fails to prove BSD(E,p).\n\n Here, BSD(E,p) is the\n statement: "the ... |
def is_Q_curve(E, maxp=100, certificate=False, verbose=False):
'\n Return whether ``E`` is a `\\QQ`-curve, with optional certificate.\n\n INPUT:\n\n - ``E`` (elliptic curve) -- an elliptic curve over a number field.\n\n - ``maxp`` (int, default 100): bound on primes used for checking\n necessary ... |
def Step4Test(E, B, oldB=0, verbose=False):
"\n Apply local Q-curve test to E at all primes up to B.\n\n INPUT:\n\n - `E` (elliptic curve): an elliptic curve defined over a number field\n\n - `B` (integer): upper bound on primes to test\n\n - ``oldB`` (integer, default 0): lower bound on primes to ... |
def conjugacy_test(jlist, verbose=False):
'\n Test whether a list of algebraic numbers contains a complete\n conjugacy class of 2-power degree.\n\n INPUT:\n\n - ``jlist`` (list): a list of algebraic numbers in the same field\n\n - ``verbose`` (boolean, default ``False``): verbosity flag\n\n OUTP... |
def _cardinality_with_j_invariant_1728(self):
"\n Special function to compute cardinality when j=1728.\n\n EXAMPLES::\n\n sage: from sage.schemes.elliptic_curves.cardinality import _cardinality_with_j_invariant_1728\n\n An example with q=p=1 (mod 4)::\n\n sage: F = GF(10009)\n sage: ... |
def _cardinality_with_j_invariant_0(self):
"\n Special function to compute cardinality when j=0.\n\n EXAMPLES::\n\n sage: from sage.schemes.elliptic_curves.cardinality import _cardinality_with_j_invariant_0\n\n An example with q=p=1 (mod 6)::\n\n sage: F = GF(1009)\n sage: [_cardinal... |
def cardinality_exhaustive(self):
"\n Return the cardinality of ``self`` over the base field.\n\n This simply adds up the number of points with each x-coordinate:\n only used for small field sizes!\n\n EXAMPLES::\n\n sage: p = next_prime(10^3)\n sage: E = EllipticCurve(GF(p), [3,4])\n ... |
def cardinality_bsgs(self, verbose=False):
'\n Return the cardinality of ``self`` over the base field.\n\n ALGORITHM: A variant of "Mestre\'s trick" extended to all finite\n fields by Cremona and Sutherland, 2008.\n\n .. NOTE::\n\n 1. The Mestre-Schoof-Cremona-Sutherland algorithm may fail for\... |
def _cardinality_subfield(self, jpol):
'\n Count the number of points on the elliptic curve ``self``, assuming\n that the j-invariant lies in a subfield.\n\n INPUT:\n\n - ``jpol`` -- minimal polynomial (over the prime field) of the\n j-invariant of ``self``\n\n EXAMPLES::\n\n sage: from... |
@cached_function
def hilbert_class_polynomial(D, algorithm=None):
'\n Return the Hilbert class polynomial for discriminant `D`.\n\n INPUT:\n\n - ``D`` (int) -- a negative integer congruent to 0 or 1 modulo 4.\n\n - ``algorithm`` (string, default None).\n\n OUTPUT:\n\n (integer polynomial) The Hi... |
def is_HCP(f, check_monic_irreducible=True):
'\n Determine whether a polynomial is a Hilbert Class Polynomial.\n\n INPUT:\n\n - ``f`` -- a polynomial in `\\ZZ[X]`.\n - ``check_monic_irreducible`` (boolean, default ``True``) -- if\n ``True``, check that ``f`` is a monic, irreducible, integer\n ... |
def OrderClassNumber(D0, h0, f):
'\n Return the class number h(f**2 * D0), given h(D0)=h0.\n\n INPUT:\n\n - ``D0`` (integer) -- a negative fundamental discriminant\n - ``h0`` (integer) -- the class number of the (maximal) imaginary quadratic order of discriminant ``D0``\n - ``f`` (integer) -- a pos... |
@cached_function
def cm_j_invariants(K, proof=None):
"\n Return a list of all CM `j`-invariants in the field `K`.\n\n INPUT:\n\n - ``K`` -- a number field\n - ``proof`` -- (default: proof.number_field())\n\n OUTPUT:\n\n (list) -- A list of CM `j`-invariants in the field `K`.\n\n EXAMPLES::\n\... |
@cached_function
def cm_j_invariants_and_orders(K, proof=None):
"\n Return a list of all CM `j`-invariants in the field `K`, together with the associated orders.\n\n INPUT:\n\n - ``K`` -- a number field\n - ``proof`` -- (default: proof.number_field())\n\n OUTPUT:\n\n (list) A list of 3-tuples `(... |
@cached_function
def cm_orders(h, proof=None):
"\n Return a list of all pairs `(D,f)` where there is a CM order of\n discriminant `D f^2` with class number h, with `D` a fundamental\n discriminant.\n\n INPUT:\n\n - `h` -- positive integer\n - ``proof`` -- (default: proof.number_field())\n\n O... |
def largest_fundamental_disc_with_class_number(h):
'\n Return largest absolute value of any fundamental negative discriminant with\n class number `h`, and the number of fundamental negative discriminants with\n that class number. This is known (unconditionally) for `h` up to 100,\n by work of Mark Wa... |
def largest_disc_with_class_number(h):
'\n Return largest absolute value of any negative discriminant with\n class number `h`, and the number of fundamental negative\n discriminants with that class number. This is known\n (unconditionally) for `h` up to 100, by work of Mark Watkins\n [Watkins2004]... |
def discriminants_with_bounded_class_number(hmax, B=None, proof=None):
'Return a dictionary with keys class numbers `h\\le hmax` and values the\n list of all pairs `(D_0, f)`, with `D_0<0` a fundamental discriminant such\n that `D=D_0f^2` has class number `h`. If the optional bound `B` is given,\n retur... |
@cached_function
def is_cm_j_invariant(j, algorithm='CremonaSutherland', method=None):
"Return whether or not this is a CM `j`-invariant, and the CM discriminant if it is.\n\n INPUT:\n\n - ``j`` -- an element of a number field `K`\n\n - ``algorithm`` (string, default 'CremonaSutherland') -- the algorithm... |
class EllipticCurveFactory(UniqueFactory):
'\n Construct an elliptic curve.\n\n In Sage, an elliptic curve is always specified by\n (the coefficients of) a long Weierstrass equation\n\n .. MATH::\n\n y^2 + a_1 xy + a_3 y = x^3 + a_2 x^2 + a_4 x + a_6.\n\n INPUT:\n\n There are several ways... |
def EllipticCurve_from_Weierstrass_polynomial(f):
'\n Return the elliptic curve defined by a cubic in (long) Weierstrass\n form.\n\n INPUT:\n\n - ``f`` -- a inhomogeneous cubic polynomial in long Weierstrass\n form.\n\n OUTPUT: The elliptic curve defined by it.\n\n EXAMPLES::\n\n sag... |
def coefficients_from_Weierstrass_polynomial(f):
'\n Return the coefficients `[a_1, a_2, a_3, a_4, a_6]` of a cubic in\n Weierstrass form.\n\n EXAMPLES::\n\n sage: from sage.schemes.elliptic_curves.constructor import coefficients_from_Weierstrass_polynomial\n sage: R.<w,z> = QQ[]\n s... |
def EllipticCurve_from_c4c6(c4, c6):
'\n Return an elliptic curve with given `c_4` and\n `c_6` invariants.\n\n EXAMPLES::\n\n sage: E = EllipticCurve_from_c4c6(17, -2005)\n sage: E\n Elliptic Curve defined by y^2 = x^3 - 17/48*x + 2005/864 over Rational Field\n sage: E.c_inva... |
def EllipticCurve_from_j(j, minimal_twist=True):
"\n Return an elliptic curve with given `j`-invariant.\n\n INPUT:\n\n - ``j`` -- an element of some field.\n\n - ``minimal_twist`` (boolean, default True) -- If True and ``j``\n is in `\\QQ`, the curve returned is a minimal twist, i.e. has\n m... |
def coefficients_from_j(j, minimal_twist=True):
'\n Return Weierstrass coefficients `(a_1, a_2, a_3, a_4, a_6)` for an\n elliptic curve with given `j`-invariant.\n\n INPUT: See :func:`EllipticCurve_from_j`.\n\n EXAMPLES::\n\n sage: from sage.schemes.elliptic_curves.constructor import coefficien... |
def EllipticCurve_from_cubic(F, P=None, morphism=True):
"\n Construct an elliptic curve from a ternary cubic with a rational point.\n\n If you just want the Weierstrass form and are not interested in\n the morphism then it is easier to use the function\n :func:`~sage.schemes.elliptic_curves.jacobian.J... |
def tangent_at_smooth_point(C, P):
'Return the tangent at the smooth point `P` of projective curve `C`.\n\n INPUT:\n\n - ``C`` -- a projective plane curve.\n\n - ``P`` -- a 3-tuple `(x,y,z)` defining a projective point on `C`.\n\n OUTPUT:\n\n The linear form defining the tangent at `P` to `C`.\n\n ... |
def chord_and_tangent(F, P):
"Return the third point of intersection of a cubic with the tangent at one point.\n\n INPUT:\n\n - ``F`` -- a homogeneous cubic in three variables with rational\n coefficients, as a polynomial ring element, defining a smooth\n plane cubic curve.\n\n - ``P`` -- a 3-t... |
def projective_point(p):
'\n Return equivalent point with denominators removed\n\n INPUT:\n\n - ``P``, ``Q`` -- list/tuple of projective coordinates.\n\n OUTPUT:\n\n List of projective coordinates.\n\n EXAMPLES::\n\n sage: from sage.schemes.elliptic_curves.constructor import projective_po... |
def are_projectively_equivalent(P, Q, base_ring):
'\n Test whether ``P`` and ``Q`` are projectively equivalent.\n\n INPUT:\n\n - ``P``, ``Q`` -- list/tuple of projective coordinates.\n\n - ``base_ring`` -- the base ring.\n\n OUTPUT: A boolean.\n\n EXAMPLES::\n\n sage: from sage.schemes.el... |
def EllipticCurves_with_good_reduction_outside_S(S=[], proof=None, verbose=False):
"\n Return a sorted list of all elliptic curves defined over `\\QQ`\n with good reduction outside the set `S` of primes.\n\n INPUT:\n\n - ``S`` -- list of primes (default: empty list)\n\n - ``proof`` -- boolean (defa... |
class EllipticCurves():
def rank(self, rank, tors=0, n=10, labels=False):
"\n Return a list of at most `n` curves with given\n rank and torsion order.\n\n INPUT:\n\n - ``rank`` (int) -- the desired rank\n\n - ``tors`` (int, default 0) -- the desired torsion order (ignor... |
def _isogeny_determine_algorithm(E, kernel):
'\n Helper function to infer the algorithm to be used from the\n parameters passed to the various isogeny functions.\n\n If ``kernel`` is a list of points on the elliptic curve `E`,\n we will try to use Vélu\'s algorithm.\n\n If ``kernel`` is a list of c... |
def isogeny_codomain_from_kernel(E, kernel):
'\n Compute the isogeny codomain given a kernel.\n\n INPUT:\n\n - ``E`` -- domain elliptic curve\n\n - ``kernel`` -- either a list of points in the kernel of the isogeny,\n or a kernel polynomial (specified as either a\n ... |
def compute_codomain_formula(E, v, w):
'\n Compute the codomain curve given parameters `v` and `w` (as in\n Vélu/Kohel/etc. formulas).\n\n INPUT:\n\n - ``E`` -- an elliptic curve\n\n - ``v``, ``w`` -- elements of the base field of ``E``\n\n OUTPUT:\n\n The elliptic curve with invariants\n ... |
def compute_vw_kohel_even_deg1(x0, y0, a1, a2, a4):
"\n Compute Vélu's `(v,w)` using Kohel's formulas for isogenies of\n degree exactly divisible by `2`.\n\n INPUT:\n\n - ``x0``, ``y0`` -- coordinates of a 2-torsion point on an elliptic curve `E`\n\n - ``a1``, ``a2``, ``a4`` -- invariants of `E`\n\... |
def compute_vw_kohel_even_deg3(b2, b4, s1, s2, s3):
"\n Compute Vélu's `(v,w)` using Kohel's formulas for isogenies of\n degree divisible by `4`.\n\n INPUT:\n\n - ``b2``, ``b4`` -- invariants of an elliptic curve `E`\n\n - ``s1``, ``s2``, ``s3`` -- signed coefficients of the 2-division\n polyn... |
def compute_vw_kohel_odd(b2, b4, b6, s1, s2, s3, n):
"\n Compute Vélu's `(v,w)` using Kohel's formulas for isogenies of odd\n degree.\n\n INPUT:\n\n - ``b2``, ``b4``, ``b6`` -- invariants of an elliptic curve `E`\n\n - ``s1``, ``s2``, ``s3`` -- signed coefficients of lowest powers\n of `x` in ... |
def compute_codomain_kohel(E, kernel):
"\n Compute the codomain from the kernel polynomial using Kohel's\n formulas.\n\n INPUT:\n\n - ``E`` -- domain elliptic curve\n\n - ``kernel`` (polynomial or list) -- the kernel polynomial, or a\n list of its coefficients\n\n OUTPUT:\n\n (elliptic c... |
def two_torsion_part(E, psi):
"\n Return the greatest common divisor of ``psi`` and the 2-torsion\n polynomial of `E`.\n\n INPUT:\n\n - ``E`` -- an elliptic curve\n\n - ``psi`` -- a univariate polynomial over the base field of ``E``\n\n OUTPUT:\n\n (polynomial) The `\\gcd` of ``psi`` and the ... |
class EllipticCurveIsogeny(EllipticCurveHom):
'\n This class implements separable isogenies of elliptic curves.\n\n Several different algorithms for computing isogenies are\n available. These include:\n\n - Vélu\'s Formulas: Vélu\'s original formulas for computing\n isogenies. This algorithm is... |
def compute_isogeny_bmss(E1, E2, l):
"\n Compute the kernel polynomial of the unique normalized isogeny\n of degree ``l`` between ``E1`` and ``E2``.\n\n Both curves must be given in short Weierstrass form, and the\n characteristic must be either `0` or no smaller than `4l+4`.\n\n ALGORITHM: [BMSS20... |
def compute_isogeny_stark(E1, E2, ell):
"\n Return the kernel polynomial of an isogeny of degree ``ell``\n from ``E1`` to ``E2``.\n\n INPUT:\n\n - ``E1`` -- domain elliptic curve in short Weierstrass form\n\n - ``E2`` -- codomain elliptic curve in short Weierstrass form\n\n - ``ell`` -- the de... |
def compute_isogeny_kernel_polynomial(E1, E2, ell, algorithm=None):
'\n Return the kernel polynomial of a cyclic, separable, normalized\n isogeny of degree ``ell`` from ``E1`` to ``E2``.\n\n INPUT:\n\n - ``E1`` -- domain elliptic curve in short Weierstrass form\n\n - ``E2`` -- codomai... |
def compute_intermediate_curves(E1, E2):
'\n Return intermediate curves and isomorphisms.\n\n .. NOTE::\n\n This is used to compute `\\wp` functions from the short\n Weierstrass model more easily.\n\n .. WARNING::\n\n The base field must be of characteristic not equal to `2` or `3`.\... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.