Some More Advanced Mathematics
Algebraic Geometry
You can define arbitrary algebraic varieties in Sage, but sometimes nontrivial functionality is limited to rings over or finite fields. For example, we compute the union of two affine plane curves, then recover the curves as the irreducible components of the union.
We can also find all points of intersection of the two curves by intersecting them and computing the irreducible components.
Thus, e.g., and are on both curves (visibly clear), as are certain (quadratic) points whose coordinates satisfy .
Sage can compute the toric ideal of the twisted cubic in projective 3 space:
Elliptic Curves
Elliptic curve functionality includes most of the elliptic curve functionality of PARI, access to the data in Cremona’s online tables (this requires an optional database package), the functionality of mwrank, i.e., 2-descents with computation of the full Mordell-Weil group, the SEA algorithm, computation of all isogenies, much new code for curves over , and some of Denis Simon’s algebraic descent software.
The command "EllipticCurve" for creating an elliptic curve has many forms:
EllipticCurve([, , , , ]): Returns the elliptic curve
where the ‘s are coerced into the parent of . If all the have parent , they are coerced into .
EllipticCurve([, ]): Same as above, but .
EllipticCurve(label): Returns the elliptic curve over from the Cremona database with the given (new!) Cremona label. The label is a string, such as ""11a"" or ""37b2"". The letter must be lower case (to distinguish it from the old labeling).
EllipticCurve(j): Returns an elliptic curve with -invariant .
EllipticCurve(R, [, , , , ]): Create the elliptic curve over a ring with given ‘s as above.
We illustrate each of these constructors:
The pair is a point on the elliptic curve defined by . To create this point in Sage type "E([0,0])". Sage can add points on such an elliptic curve (recall elliptic curves support an additive group structure where the point at infinity is the zero element and three co-linear points on the curve add to zero):
The elliptic curves over the complex numbers are parameterized by the -invariant. Sage computes -invariant as follows:
If we make a curve with the same -invariant as that of , it need not be isomorphic to . In the following example, the curves are not isomorphic because their conductors are different.
However, the twist of by 2 gives an isomorphic curve.
We can compute the coefficients of the -series or modular form attached to the elliptic curve. This computation uses the PARI C-library:
It only takes a second to compute all for :
Elliptic curves can be constructed using their Cremona labels. This pre-loads the elliptic curve with information about its rank, Tamagawa numbers, regulator, etc.
We can also access the Cremona database directly.
The objects returned from the database are not of type "EllipticCurve". They are elements of a database and have a couple of fields, and that’s it. There is a small version of Cremona’s database, which is distributed by default with Sage, and contains limited information about elliptic curves of conductor . There is also a large optional version, which contains extensive data about all curves of conductor up to (as of October 2005). There is also a huge (2GB) optional database package for Sage that contains the hundreds of millions of elliptic curves in the Stein-Watkins database.
Dirichlet Characters
A Dirichlet character is the extension of a homomorphism , for some ring , to the map obtained by sending those integers with to 0.
Having created the group, we next create an element and compute with it.
It is also possible to compute the action of the Galois group on these characters, as well as the direct product decomposition corresponding to the factorization of the modulus.
Next, we construct the group of Dirichlet characters mod 20, but with values in :
We next compute several invariants of "G":
In this example we create a Dirichlet character with values in a number field. We explicitly specify the choice of root of unity by the third argument to "DirichletGroup" below.
Here "NumberField(x^4 + 1, 'a')" tells Sage to use the symbol “a” in printing what "K" is (a Number Field in a with defining polynomial ). The name “a” is undeclared at this point. Once "a = K.0" (or equivalently "a = K.gen()") is evaluated, the symbol “a” represents a root of the generating polynomial .
Modular Forms
Sage can do some computations related to modular forms, including dimensions, computing spaces of modular symbols, Hecke operators, and decompositions.
There are several functions available for computing dimensions of spaces of modular forms. For example,
Next we illustrate computation of Hecke operators on a space of modular symbols of level and weight .
We can also create spaces for and .
Let’s compute some characteristic polynomials and -expansions.
We can even compute spaces of modular symbols with character.
Here is another example of how Sage can compute the action of Hecke operators on a space of modular forms.
Let denote the usual Hecke operators ( prime). How do the Hecke operators , , act on the space of modular symbols?