Exemple #1
0
 def time_is_semistable(self):
     R = PolynomialRing(QQ, 'x')
     x = R.gen()
     Y = SuperellipticCurve(x**4 - 1, 3)
     v_2 = QQ.valuation(2)
     Y2 = SemistableModel(Y, v_2)
     return Y2.is_semistable()
Exemple #2
0
 def _test(self):
     from sage.all import QQ, PolynomialRing, GaussValuation
     R = PolynomialRing(QQ, 'x')
     x = R.gen()
     v = QQ.valuation(2)
     v = GaussValuation(R, v).augmentation(x + 1, QQ(1) / 2)
     f = x**4 - 30 * x**2 - 75
     v.mac_lane_step(f)
Exemple #3
0
 def _test(self):
     from sage.all import QQ, PolynomialRing, GaussValuation, FunctionField
     R = PolynomialRing(QQ, 'x')
     x = R.gen()
     v = GaussValuation(R, QQ.valuation(2))
     K = FunctionField(QQ, 'x')
     x = K.gen()
     v = K.valuation(v)
     K.valuation((v, K.hom(x/2), K.hom(2*x)))
Exemple #4
0
 def time_is_semistable(self):
     K = FunctionField(QQ, 'x')
     x = K.gen()
     R = PolynomialRing(K, 'T')
     T = R.gen()
     f = 64 * x**3 * T - 64 * x**3 + 36 * x**2 * T**2 + 208 * x**2 * T + 192 * x**2 + 9 * x * T**3 + 72 * x * T**2 + 240 * x * T + 64 * x + T**4 + 9 * T**3 + 52 * T**2 + 48 * T
     L = K.extension(f, 'y')
     Y = SmoothProjectiveCurve(L)
     v = QQ.valuation(13)
     M = SemistableModel(Y, v)
     return M.is_semistable()
 def __init__(self, K0, vK):
     assert K0.is_absolute(), "K0 must be an absolute number field"
     assert vK.domain() == K0, "K0 must be the domain of vK"
     p = vK.p()
     # we want vK to be normalized such that vK(p)=1
     vK = vK / vK(p)
     assert vK(p) == 1
     R = PolynomialRing(K0, 'x')
     x = R.gen()
     n = K0.degree()
     if n > 1:
         piK = K0.gen()
         e = ZZ(1 / vK(vK.uniformizer()))
         F = vK.residue_field()  # should be a finite field, therefore:
         f = F.cardinality().log(
             F.characteristic())  # should be the absolute degree of F
         assert vK(
             piK
         ) == 1 / e, "the generator of K must be a uniformizer for vK"
         P = K0.polynomial()
         G = P(x + piK).shift(-1)
         S = matrix(QQ, n)
         for i in range(n):
             S[i, i] = p**(i / e).floor()
             # the matrix S has the property that S^(-1)*a.matrix()*S is p-integral,
             # for an element a in O_K; this follows from the fact that
             # pi^i/p^(i/e).floor(), i=0,..,n-1, is a p-integral basis
         is_Qp = False
     else:
         K0 = QQ
         piK = K0(1)
         e = ZZ(1)
         f = ZZ(1)
         P = x - 1
         G = R(1)
         S = matrix(K0, 1, [1])
         is_Qp = True
     assert n == e * f
     assert n == P.degree()
     self._number_field = K0
     self._v_p = QQ.valuation(p)
     self._valuation = vK
     self._p = p
     self._uniformizer = piK
     self._degree = n
     self._ramification_degree = e
     self._inertia_degree = f
     self._polynomial = P
     self._G = G
     self._S = S
     self._is_Qp = is_Qp
Exemple #6
0
    def extension(self, f, embedding=False):
        r"""
        Return a `p`-adic extension such that ``f`` has a root in an unramified
        extension of it.

        INPUT:

        - ``f`` -- a monic univariate polynomial over the number field `K_0`
          underlying this p-adic extension `K`, which is irreducible over `K`.
        - ``embedding`` -- a boolean (default: ``False``)

        OUTPUT:

        A `p`-adic extension `L` of `K` such that ``f`` has a root
        in an unramified extension of `L`, or (if ``embedding`` is ``True``)
        the pair `(L,\phi)`, where `\phi` is the canonical embedding of
        `K` into `L`.

        If `K_0` is the underlying number field, then `f\in K_0[x]` is irreducible
        over the completion `K`; the resulting finite extension `L/K`
        is a subextension of the extension of `K`

        .. MATH::

                K[x]/(f).

        However, the number field `L_0` underlying `L` is in general not
        equal to `K_0[x]/(f)`, and there may not exist any embedding of `K_0`
        into `L_0`.

        """
        # print("entering extension with ")
        # print("K = ", self)
        # print("f = ", f)
        # print()

        K0 = self.number_field()
        assert K0.has_coerce_map_from(f.parent().base_ring())
        f = f.change_ring(K0)

        vK = self.valuation()
        if embedding:
            raise NotImplementedError

        V = vK.mac_lane_approximants(f)
        assert len(V) == 1, "f is not irreducible"
        v = LimitValuation(V[0], f)
        pix = v.uniformizer()
        r = v(pix)
        for m in range(2,10):
            pix1 = pix.map_coefficients(lambda c:self.reduce(c, m))
            if v(pix1) == r:
                break
        assert m < 9, "m too small"
        # now pix1 is a polynomial over `K_0` which maps to a uniformizer for the
        # unique extension of vK to the relative extension L=K[x]/(f)/K
        g = self.characteristic_polynomial(f, pix1)
        # now g is the relative characteristic polynomial of the image pi of pix1 in L
        # we need the minimal polynomial, so we do a square free factorization
        g = g.squarefree_decomposition()[0][0]
        # now we compute the absolute characteristic polynomial of a root
        # of g

        done = False
        N = m+5
        while not done:
            Pmod = self.characteristic_polynomial_mod(g, N)
            # this is very heuristic; there should be a conclusive test whether
            # the result is correct, or the choice of the precision should be made correctly and
            # optimal from the start
            P = Pmod.map_coefficients(lambda c:c.lift(), QQ)
            P = P.squarefree_decomposition()[0][0]
            L0 = NumberField(P, 'pi%s'%P.degree())
            V = QQ.valuation(self.p()).extensions(L0)
            vL = V[0]
            e = ZZ(1/vL(vL.uniformizer()))
            f = vL.residue_field().degree()
            if 1/e == r:
                if len(V) == 1:
                    return FakepAdicCompletion(L0, vL)
                else:
                    QQp = FakepAdicCompletion(QQ, self.base_valuation())
                    g = QQp.approximate_irreducible_factor(P)
                    return QQp.extension(g)
            N = N + 5