From 5f012a164ef7c4b643ebc86fe0d953284bbc2339 Mon Sep 17 00:00:00 2001 From: jgarnek Date: Mon, 23 Aug 2021 14:55:37 +0200 Subject: [PATCH] macierz froba prawie dziala; problem z najstarszym wspol --- deRhamComputation.ipynb | 34 +++- superelliptic.ipynb | 353 ++++++++++++++++++++++++++++++++++------ 2 files changed, 336 insertions(+), 51 deletions(-) diff --git a/deRhamComputation.ipynb b/deRhamComputation.ipynb index 77ad051..c9c250d 100644 --- a/deRhamComputation.ipynb +++ b/deRhamComputation.ipynb @@ -22,7 +22,7 @@ }, { "cell_type": "code", - "execution_count": 169, + "execution_count": 2, "metadata": {}, "outputs": [], "source": [ @@ -46,7 +46,7 @@ }, { "cell_type": "code", - "execution_count": 170, + "execution_count": 3, "metadata": {}, "outputs": [], "source": [ @@ -79,7 +79,7 @@ }, { "cell_type": "code", - "execution_count": 208, + "execution_count": 4, "metadata": {}, "outputs": [], "source": [ @@ -213,7 +213,7 @@ }, { "cell_type": "code", - "execution_count": 209, + "execution_count": 5, "metadata": {}, "outputs": [], "source": [ @@ -261,7 +261,7 @@ }, { "cell_type": "code", - "execution_count": 242, + "execution_count": 6, "metadata": {}, "outputs": [], "source": [ @@ -456,6 +456,30 @@ "baza_dr(m, f, 0, p)" ] }, + { + "cell_type": "code", + "execution_count": 8, + "metadata": {}, + "outputs": [ + { + "data": { + "text/plain": [ + "{0: [1, 0, 3], 1: [0, 2/x, 3]}" + ] + }, + "execution_count": 8, + "metadata": {}, + "output_type": "execute_result" + } + ], + "source": [ + "p = 5\n", + "R. = PolynomialRing(GF(p))\n", + "f = x^3 + x + 2\n", + "m = 7\n", + "baza_dr(m, f, 3, p)" + ] + }, { "cell_type": "code", "execution_count": null, diff --git a/superelliptic.ipynb b/superelliptic.ipynb index 1d92c3b..cf5fcb9 100644 --- a/superelliptic.ipynb +++ b/superelliptic.ipynb @@ -2,7 +2,7 @@ "cells": [ { "cell_type": "code", - "execution_count": 115, + "execution_count": 118, "metadata": {}, "outputs": [], "source": [ @@ -75,7 +75,7 @@ " if (r*(m-j) - m*i >= delta):\n", " s = Rx(m-j)*Rx(x)*Rx(f.derivative()) - Rx(m)*Rx(i)*f\n", " psi = Rx(cut(s, i))\n", - " basis[t] = superelliptic_cech(self, superelliptic_form(self, Fxy(psi/y^j)), superelliptic_function(self, Fxy(m*y^j/x^i)))\n", + " basis[t] = superelliptic_cech(self, superelliptic_form(self, Fxy(psi/y^j)), superelliptic_function(self, Fxy(m*y^(m-j)/x^i)))\n", " degrees0[t] = (psi.degree(), j)\n", " degrees1[t] = (-i, j)\n", " t += 1\n", @@ -92,6 +92,27 @@ " def basis_de_rham(self, j = 'all'): \n", " basis, degrees0, degrees1 = self.degree_and_basis_de_rham(j)\n", " return basis\n", + " \n", + " def verschiebung_matrix(self):\n", + " basis = self.basis_de_rham()\n", + " g = self.genus()\n", + " p = self.characteristic\n", + " M = matrix(GF(p), 2*g, 2*g)\n", + " for i, w in basis.items():\n", + " v = w.verschiebung().coordinates()\n", + " M[i, :] = v\n", + " return M\n", + " \n", + " def frobenius_matrix(self):\n", + " basis = self.basis_de_rham()\n", + " g = self.genus()\n", + " p = self.characteristic\n", + " M = matrix(GF(p), 2*g, 2*g)\n", + " for i, w in basis.items():\n", + " print('w', w)\n", + " v = w.frobenius().coordinates()\n", + " M[i, :] = v\n", + " return M\n", " \n", "def reduction(C, g):\n", " p = C.characteristic\n", @@ -238,6 +259,27 @@ " return str(g) + ' dx'\n", " return '('+str(g) + ') dx'\n", " \n", + " def cartier(self):\n", + " C = self.curve\n", + " m = C.exponent\n", + " p = C.characteristic\n", + " f = C.polynomial\n", + " Rx. = PolynomialRing(GF(p))\n", + " Fx = FractionField(Rx)\n", + " FxRy. = PolynomialRing(Fx)\n", + " Fxy = FractionField(FxRy)\n", + " result = superelliptic_form(C, FxRy(0))\n", + " mult_order = Integers(m)(p).multiplicative_order()\n", + " M = Integer((p^(mult_order)-1)/m)\n", + " \n", + " for j in range(1, m):\n", + " fct_j = self.jth_component(j)\n", + " h = Rx(fct_j*f^(M*j))\n", + " j1 = (p^(mult_order-1)*j)%m\n", + " B = floor(p^(mult_order-1)*j/m)\n", + " result += superelliptic_form(C, polynomial_part(p, h)/(f^B*y^(j1)))\n", + " return result\n", + " \n", " def jth_component(self, j):\n", " g = self.form\n", " C = self.curve\n", @@ -276,6 +318,7 @@ " A = self.jth_component(j)\n", " d = degree_of_rational_fctn(A)\n", " if(-d*M + j*R -(M+1)<0):\n", + " print('not', d, j, r, m, -d*M + j*R -(M+1))\n", " return 0\n", " return 1\n", " \n", @@ -306,13 +349,22 @@ " def __repr__(self):\n", " return \"(\" + str(self.omega0) + \", \" + str(self.f) + \", \" + str(self.omega8) + \")\" \n", " \n", - " def basis_coeffs(self):\n", + " def verschiebung(self):\n", " C = self.curve\n", - " g = self.f\n", - " basis = C.basis_de_rham()\n", + " omega = self.omega0\n", + " p = C.characteristic\n", + " Rx. = PolynomialRing(GF(p))\n", + " return superelliptic_cech(C, omega.cartier(), superelliptic_function(C, Rx(0)))\n", + " \n", + " def frobenius(self):\n", + " C = self.curve\n", + " fct = self.f.function\n", + " p = C.characteristic\n", + " Rx. = PolynomialRing(GF(p))\n", + " return superelliptic_cech(C, superelliptic_form(C, Rx(0)), superelliptic_function(C, fct^p))\n", "\n", " def coordinates(self):\n", - " print(self)\n", + " print(self, self.is_cocycle())\n", " C = self.curve\n", " p = C.characteristic\n", " m = C.exponent\n", @@ -329,41 +381,63 @@ " omega = self.omega0\n", " fct = self.f\n", " \n", - " if fct.function == Rx(0) and omega.form == Rx(0):\n", + " if fct.function == Rx(0) and omega.form != Rx(0):\n", + " print('c1')\n", " for j in range(1, m):\n", " omega_j = Fx(omega.jth_component(j))\n", " if omega_j != Fx(0):\n", - " d = d = degree_of_rational_fctn(omega_j)\n", + " d = degree_of_rational_fctn(omega_j)\n", " index = degrees0_inv[(d, j)]\n", + " print('baza', basis[index])\n", " a = coeff_of_rational_fctn(omega_j)\n", " a1 = coeff_of_rational_fctn(basis[index].omega0.jth_component(j))\n", " elt = self - basis[index].mult(a/a1)\n", " return elt.coordinates() + a/a1*vector([GF(p)(i == index) for i in range(0, 2*g)])\n", " \n", " for j in range(1, m):\n", + " print('c2')\n", " fct_j = Fx(fct.jth_component(j))\n", " if (fct_j != Rx(0)):\n", " d = degree_of_rational_fctn(fct_j)\n", " \n", " if (d, j) in degrees1.values():\n", + " print('c2a')\n", " index = degrees1_inv[(d, j)]\n", " a = coeff_of_rational_fctn(fct_j)\n", " a1 = coeff_of_rational_fctn(basis[index].f.jth_component(j))\n", + " print(a, a1, index, basis[index].is_cocycle())\n", " elt = self - basis[index].mult(a/a1)\n", " return elt.coordinates() + a/a1*vector([GF(p)(i == index) for i in range(0, 2*g)])\n", " \n", " if d<0:\n", + " print('c2b')\n", " a = coeff_of_rational_fctn(fct_j)\n", - " elt =- superelliptic_cech(C, elt.omega0, elt.f - FxRy(y^j*x^d)).mult(a)\n", + " h = superelliptic_function(C, FxRy(a*y^j*x^d))\n", + " elt = superelliptic_cech(C, self.omega0, self.f - h)\n", " return elt.coordinates()\n", " \n", " if (fct_j != Rx(0)):\n", + " print('c2c')\n", " G = superelliptic_function(C, y^j*x^d)\n", " a = coeff_of_rational_fctn(fct_j)\n", - " elt =-superelliptic_cech(diffn(G), G).mult(a)\n", + " elt =self - superelliptic_cech(C, diffn(G), G).mult(a)\n", " return elt.coordinates()\n", "\n", " return vector(2*g*[0])\n", + " \n", + " def is_cocycle(self):\n", + " w0 = self.omega0\n", + " w8 = self.omega8\n", + " fct = self.f\n", + " if not w0.is_regular_on_U0() and not w8.is_regular_on_Uinfty():\n", + " return('w0 & w8')\n", + " if not w0.is_regular_on_U0():\n", + " return('w0')\n", + " if not w8.is_regular_on_Uinfty():\n", + " return('w8')\n", + " if w0.is_regular_on_U0() and w8.is_regular_on_Uinfty():\n", + " return 1\n", + " return 0\n", " \n", "def degree_of_rational_fctn(f):\n", " Rx. = PolynomialRing(GF(p))\n", @@ -376,9 +450,12 @@ " return(d1 - d2)\n", "\n", "def coeff_of_rational_fctn(f):\n", + " print('coeff', f)\n", " Rx. = PolynomialRing(GF(p))\n", " Fx = FractionField(Rx)\n", " f = Fx(f)\n", + " if f == Rx(0):\n", + " return 0\n", " f1 = f.numerator()\n", " f2 = f.denominator()\n", " d1 = f1.degree()\n", @@ -396,58 +473,192 @@ "def cut(f, i):\n", " R = f.parent()\n", " coeff = f.coefficients(sparse = false)\n", - " return sum(R(x^(j-i-1)) * coeff[j] for j in range(i+1, f.degree() + 1))" + " return sum(R(x^(j-i-1)) * coeff[j] for j in range(i+1, f.degree() + 1))\n", + "\n", + "def polynomial_part(p, h):\n", + " Rx. = PolynomialRing(GF(p))\n", + " h = Rx(h)\n", + " result = Rx(0)\n", + " for i in range(0, h.degree()+1):\n", + " if (i%p) == p-1:\n", + " power = Integer((i-(p-1))/p)\n", + " result += Integer(h[i]) * x^(power) \n", + " return result" ] }, { "cell_type": "code", - "execution_count": 116, + "execution_count": 119, "metadata": {}, - "outputs": [ - { - "data": { - "text/plain": [ - "{0: ((x/y) dx, 2/x*y, ((x^3*y^5 - x^3 + x - 1)/(x^2*y^6)) dx),\n", - " 1: (((-1)/y) dx, 2/x^2*y, ((-x^3*y^5 + x^3 - 2*x - 2)/(x^3*y^6)) dx),\n", - " 2: (((-2*x)/y^2) dx, 2/x*y^2, ((-2*x^3*y^3 + x^3 - 1)/(x^2*y^5)) dx),\n", - " 3: ((1/y^2) dx, 2/x^2*y^2, ((x^3*y^3 - 2*x^3 + 2*x - 2)/(x^3*y^5)) dx),\n", - " 4: ((1/y^3) dx, 0, (1/y^3) dx),\n", - " 5: (0 dx, 2/x*y^3, ((-2*x^3 - x - 1)/(x^2*y^4)) dx),\n", - " 6: ((1/y^4) dx, 0, (1/y^4) dx),\n", - " 7: ((2*x/y^4) dx, 2/x*y^4, ((2*x^3 - 2*x*y - y)/(x^2*y^4)) dx),\n", - " 8: ((1/y^5) dx, 0, (1/y^5) dx),\n", - " 9: ((x/y^5) dx, 0, (x/y^5) dx),\n", - " 10: ((1/y^6) dx, 0, (1/y^6) dx),\n", - " 11: ((x/y^6) dx, 0, (x/y^6) dx)}" - ] - }, - "execution_count": 116, - "metadata": {}, - "output_type": "execute_result" - } - ], + "outputs": [], "source": [ "p = 5\n", "C = superelliptic(x^3 + x + 2, 7, p)\n", - "C.basis_de_rham()\n", + "baza = C.basis_de_rham()\n", "#C.basis_holomorphic_differentials()" ] }, { "cell_type": "code", - "execution_count": 117, + "execution_count": 120, "metadata": {}, - "outputs": [], + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "((x/y) dx, 2/x*y^6, ((x - 1)/(x^2*y)) dx) 1\n", + "(((-1)/y) dx, 2/x^2*y^6, ((-2*x - 2)/(x^3*y)) dx) 1\n", + "(((-2*x)/y^2) dx, 2/x*y^5, ((2*x - 1)/(x^2*y^2)) dx) 1\n", + "((1/y^2) dx, 2/x^2*y^5, ((-x - 2)/(x^3*y^2)) dx) 1\n", + "((1/y^3) dx, 0, (1/y^3) dx) 1\n", + "(0 dx, 2/x*y^4, ((-2*x - 1)/(x^2*y^3)) dx) 1\n", + "((1/y^4) dx, 0, (1/y^4) dx) 1\n", + "((2*x/y^4) dx, 2/x*y^3, ((-x - 1)/(x^2*y^4)) dx) 1\n", + "((1/y^5) dx, 0, (1/y^5) dx) 1\n", + "((x/y^5) dx, 0, (x/y^5) dx) 1\n", + "((1/y^6) dx, 0, (1/y^6) dx) 1\n", + "((x/y^6) dx, 0, (x/y^6) dx) 1\n" + ] + } + ], "source": [ - "RxRy. = PolynomialRing(GF(p), 2)\n", - "w1 = superelliptic_cech(C, superelliptic_form(C, (1/y^5)), superelliptic_function(C, 0))\n", - "w2 = superelliptic_cech(C, superelliptic_form(C,2*x/y^4), superelliptic_function(C, 2/x*y^4))\n", - "w = w1+w2+w2" + "for w in baza.values():\n", + " print(w, w.is_cocycle())" ] }, { "cell_type": "code", - "execution_count": 118, + "execution_count": 75, + "metadata": {}, + "outputs": [ + { + "data": { + "text/plain": [ + "({0: ((x/y) dx, 2/x*y, ((x^3*y^5 - x^3 + x - 1)/(x^2*y^6)) dx),\n", + " 1: (((-1)/y) dx, 2/x^2*y, ((-x^3*y^5 + x^3 - 2*x - 2)/(x^3*y^6)) dx),\n", + " 2: (((-2*x)/y^2) dx, 2/x*y^2, ((-2*x^3*y^3 + x^3 - 1)/(x^2*y^5)) dx),\n", + " 3: ((1/y^2) dx, 2/x^2*y^2, ((x^3*y^3 - 2*x^3 + 2*x - 2)/(x^3*y^5)) dx),\n", + " 4: ((1/y^3) dx, 0, (1/y^3) dx),\n", + " 5: (0 dx, 2/x*y^3, ((-2*x^3 - x - 1)/(x^2*y^4)) dx),\n", + " 6: ((1/y^4) dx, 0, (1/y^4) dx),\n", + " 7: ((2*x/y^4) dx, 2/x*y^4, ((2*x^3 - 2*x*y - y)/(x^2*y^4)) dx),\n", + " 8: ((1/y^5) dx, 0, (1/y^5) dx),\n", + " 9: ((x/y^5) dx, 0, (x/y^5) dx),\n", + " 10: ((1/y^6) dx, 0, (1/y^6) dx),\n", + " 11: ((x/y^6) dx, 0, (x/y^6) dx)},\n", + " {0: (1, 1),\n", + " 1: (0, 1),\n", + " 2: (1, 2),\n", + " 3: (0, 2),\n", + " 4: (0, 3),\n", + " 5: (-1, 3),\n", + " 6: (0, 4),\n", + " 7: (1, 4),\n", + " 8: (0, 5),\n", + " 9: (1, 5),\n", + " 10: (0, 6),\n", + " 11: (1, 6)},\n", + " {0: (-1, 1), 1: (-2, 1), 2: (-1, 2), 3: (-2, 2), 5: (-1, 3), 7: (-1, 4)})" + ] + }, + "execution_count": 75, + "metadata": {}, + "output_type": "execute_result" + } + ], + "source": [ + "C.degree_and_basis_de_rham()" + ] + }, + { + "cell_type": "code", + "execution_count": 121, + "metadata": { + "scrolled": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "w ((x/y) dx, 2/x*y^6, ((x - 1)/(x^2*y)) dx)\n", + "(0 dx, ((2*x^12 + 3*x^10 + x^9 + 2*x^8 + 3*x^7 + x^6 + 3*x^5 + 3*x^4 + 3*x^2 + 4*x + 2)/x^5)*y^2, 0 dx) 1\n", + "c2\n", + "c2\n", + "c2c\n", + "coeff (2*x^12 + 3*x^10 + x^9 + 2*x^8 + 3*x^7 + x^6 + 3*x^5 + 3*x^4 + 3*x^2 + 4*x + 2)/x^5\n", + "(((-x^7 + 2*x^6)/y^5) dx, ((3*x^10 + x^9 + 2*x^8 + 3*x^7 + x^6 + 3*x^5 + 3*x^4 + 3*x^2 + 4*x + 2)/x^5)*y^2, 0 dx) 1\n", + "c2\n", + "c2\n", + "c2c\n", + "coeff (3*x^10 + x^9 + 2*x^8 + 3*x^7 + x^6 + 3*x^5 + 3*x^4 + 3*x^2 + 4*x + 2)/x^5\n", + "(((2*x^6 + 2*x^5)/y^5) dx, ((x^9 + 2*x^8 + 3*x^7 + x^6 + 3*x^5 + 3*x^4 + 3*x^2 + 4*x + 2)/x^5)*y^2, 0 dx) 1\n", + "c2\n", + "c2\n", + "c2c\n", + "coeff (x^9 + 2*x^8 + 3*x^7 + x^6 + 3*x^5 + 3*x^4 + 3*x^2 + 4*x + 2)/x^5\n", + "(((2*x^5 + 2*x^3)/y^5) dx, ((2*x^8 + 3*x^7 + x^6 + 3*x^5 + 3*x^4 + 3*x^2 + 4*x + 2)/x^5)*y^2, 0 dx) 1\n", + "c2\n", + "c2\n", + "c2c\n", + "coeff (2*x^8 + 3*x^7 + x^6 + 3*x^5 + 3*x^4 + 3*x^2 + 4*x + 2)/x^5\n", + "(((-x^3 - 2*x^2)/y^5) dx, ((3*x^7 + x^6 + 3*x^5 + 3*x^4 + 3*x^2 + 4*x + 2)/x^5)*y^2, 0 dx) 1\n", + "c2\n", + "c2\n", + "c2c\n", + "coeff (3*x^7 + x^6 + 3*x^5 + 3*x^4 + 3*x^2 + 4*x + 2)/x^5\n", + "(((-x^3 - x^2 - 2*x)/y^5) dx, ((x^6 + 3*x^5 + 3*x^4 + 3*x^2 + 4*x + 2)/x^5)*y^2, 0 dx) 1\n", + "c2\n", + "c2\n", + "c2c\n", + "coeff (x^6 + 3*x^5 + 3*x^4 + 3*x^2 + 4*x + 2)/x^5\n", + "(((-x^2 + x - 2)/y^5) dx, ((3*x^5 + 3*x^4 + 3*x^2 + 4*x + 2)/x^5)*y^2, 0 dx) 1\n", + "c2\n", + "c2\n", + "c2c\n", + "coeff (3*x^5 + 3*x^4 + 3*x^2 + 4*x + 2)/x^5\n", + "((x/y^5) dx, ((3*x^4 + 3*x^2 + 4*x + 2)/x^5)*y^2, 0 dx) 1\n", + "c2\n", + "c2\n", + "c2a\n", + "coeff (3*x^4 + 3*x^2 + 4*x + 2)/x^5\n", + "coeff 0\n", + "3 0 2 1\n" + ] + }, + { + "ename": "ZeroDivisionError", + "evalue": "inverse of Mod(0, 5) does not exist", + "output_type": "error", + "traceback": [ + "\u001b[0;31m---------------------------------------------------------------------------\u001b[0m", + "\u001b[0;31mZeroDivisionError\u001b[0m Traceback (most recent call last)", + "\u001b[0;32m\u001b[0m in \u001b[0;36m\u001b[0;34m()\u001b[0m\n\u001b[0;32m----> 1\u001b[0;31m \u001b[0mC\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mfrobenius_matrix\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0m", + "\u001b[0;32m\u001b[0m in \u001b[0;36mfrobenius_matrix\u001b[0;34m(self)\u001b[0m\n\u001b[1;32m 103\u001b[0m \u001b[0;32mfor\u001b[0m \u001b[0mi\u001b[0m\u001b[0;34m,\u001b[0m \u001b[0mw\u001b[0m \u001b[0;32min\u001b[0m \u001b[0mbasis\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mitems\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m:\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[1;32m 104\u001b[0m \u001b[0mprint\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0;34m'w'\u001b[0m\u001b[0;34m,\u001b[0m \u001b[0mw\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0;32m--> 105\u001b[0;31m \u001b[0mv\u001b[0m \u001b[0;34m=\u001b[0m \u001b[0mw\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mfrobenius\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mcoordinates\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0m\u001b[1;32m 106\u001b[0m \u001b[0mM\u001b[0m\u001b[0;34m[\u001b[0m\u001b[0mi\u001b[0m\u001b[0;34m,\u001b[0m \u001b[0;34m:\u001b[0m\u001b[0;34m]\u001b[0m \u001b[0;34m=\u001b[0m \u001b[0mv\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[1;32m 107\u001b[0m \u001b[0;32mreturn\u001b[0m \u001b[0mM\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n", + "\u001b[0;32m\u001b[0m in \u001b[0;36mcoordinates\u001b[0;34m(self)\u001b[0m\n\u001b[1;32m 414\u001b[0m \u001b[0ma\u001b[0m \u001b[0;34m=\u001b[0m \u001b[0mcoeff_of_rational_fctn\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0mfct_j\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[1;32m 415\u001b[0m \u001b[0melt\u001b[0m \u001b[0;34m=\u001b[0m\u001b[0mself\u001b[0m \u001b[0;34m-\u001b[0m \u001b[0msuperelliptic_cech\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0mC\u001b[0m\u001b[0;34m,\u001b[0m \u001b[0mdiffn\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0mG\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m,\u001b[0m \u001b[0mG\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mmult\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0ma\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0;32m--> 416\u001b[0;31m \u001b[0;32mreturn\u001b[0m \u001b[0melt\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mcoordinates\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0m\u001b[1;32m 417\u001b[0m \u001b[0;34m\u001b[0m\u001b[0m\n\u001b[1;32m 418\u001b[0m \u001b[0;32mreturn\u001b[0m \u001b[0mvector\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0mInteger\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0;36m2\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m*\u001b[0m\u001b[0mg\u001b[0m\u001b[0;34m*\u001b[0m\u001b[0;34m[\u001b[0m\u001b[0mInteger\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0;36m0\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m]\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n", + "\u001b[0;32m\u001b[0m in \u001b[0;36mcoordinates\u001b[0;34m(self)\u001b[0m\n\u001b[1;32m 414\u001b[0m \u001b[0ma\u001b[0m \u001b[0;34m=\u001b[0m \u001b[0mcoeff_of_rational_fctn\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0mfct_j\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[1;32m 415\u001b[0m \u001b[0melt\u001b[0m \u001b[0;34m=\u001b[0m\u001b[0mself\u001b[0m \u001b[0;34m-\u001b[0m \u001b[0msuperelliptic_cech\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0mC\u001b[0m\u001b[0;34m,\u001b[0m \u001b[0mdiffn\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0mG\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m,\u001b[0m \u001b[0mG\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mmult\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0ma\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0;32m--> 416\u001b[0;31m \u001b[0;32mreturn\u001b[0m \u001b[0melt\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mcoordinates\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0m\u001b[1;32m 417\u001b[0m \u001b[0;34m\u001b[0m\u001b[0m\n\u001b[1;32m 418\u001b[0m \u001b[0;32mreturn\u001b[0m \u001b[0mvector\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0mInteger\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0;36m2\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m*\u001b[0m\u001b[0mg\u001b[0m\u001b[0;34m*\u001b[0m\u001b[0;34m[\u001b[0m\u001b[0mInteger\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0;36m0\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m]\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n", + "\u001b[0;32m\u001b[0m in \u001b[0;36mcoordinates\u001b[0;34m(self)\u001b[0m\n\u001b[1;32m 414\u001b[0m \u001b[0ma\u001b[0m \u001b[0;34m=\u001b[0m \u001b[0mcoeff_of_rational_fctn\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0mfct_j\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[1;32m 415\u001b[0m \u001b[0melt\u001b[0m \u001b[0;34m=\u001b[0m\u001b[0mself\u001b[0m \u001b[0;34m-\u001b[0m \u001b[0msuperelliptic_cech\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0mC\u001b[0m\u001b[0;34m,\u001b[0m \u001b[0mdiffn\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0mG\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m,\u001b[0m \u001b[0mG\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mmult\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0ma\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0;32m--> 416\u001b[0;31m \u001b[0;32mreturn\u001b[0m \u001b[0melt\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mcoordinates\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0m\u001b[1;32m 417\u001b[0m \u001b[0;34m\u001b[0m\u001b[0m\n\u001b[1;32m 418\u001b[0m \u001b[0;32mreturn\u001b[0m \u001b[0mvector\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0mInteger\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0;36m2\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m*\u001b[0m\u001b[0mg\u001b[0m\u001b[0;34m*\u001b[0m\u001b[0;34m[\u001b[0m\u001b[0mInteger\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0;36m0\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m]\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n", + "\u001b[0;32m\u001b[0m in \u001b[0;36mcoordinates\u001b[0;34m(self)\u001b[0m\n\u001b[1;32m 414\u001b[0m \u001b[0ma\u001b[0m \u001b[0;34m=\u001b[0m \u001b[0mcoeff_of_rational_fctn\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0mfct_j\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[1;32m 415\u001b[0m \u001b[0melt\u001b[0m \u001b[0;34m=\u001b[0m\u001b[0mself\u001b[0m \u001b[0;34m-\u001b[0m \u001b[0msuperelliptic_cech\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0mC\u001b[0m\u001b[0;34m,\u001b[0m \u001b[0mdiffn\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0mG\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m,\u001b[0m \u001b[0mG\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mmult\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0ma\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0;32m--> 416\u001b[0;31m \u001b[0;32mreturn\u001b[0m \u001b[0melt\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mcoordinates\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0m\u001b[1;32m 417\u001b[0m \u001b[0;34m\u001b[0m\u001b[0m\n\u001b[1;32m 418\u001b[0m \u001b[0;32mreturn\u001b[0m \u001b[0mvector\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0mInteger\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0;36m2\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m*\u001b[0m\u001b[0mg\u001b[0m\u001b[0;34m*\u001b[0m\u001b[0;34m[\u001b[0m\u001b[0mInteger\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0;36m0\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m]\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n", + "\u001b[0;32m\u001b[0m in \u001b[0;36mcoordinates\u001b[0;34m(self)\u001b[0m\n\u001b[1;32m 414\u001b[0m \u001b[0ma\u001b[0m \u001b[0;34m=\u001b[0m \u001b[0mcoeff_of_rational_fctn\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0mfct_j\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[1;32m 415\u001b[0m \u001b[0melt\u001b[0m \u001b[0;34m=\u001b[0m\u001b[0mself\u001b[0m \u001b[0;34m-\u001b[0m \u001b[0msuperelliptic_cech\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0mC\u001b[0m\u001b[0;34m,\u001b[0m \u001b[0mdiffn\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0mG\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m,\u001b[0m \u001b[0mG\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mmult\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0ma\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0;32m--> 416\u001b[0;31m \u001b[0;32mreturn\u001b[0m \u001b[0melt\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mcoordinates\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0m\u001b[1;32m 417\u001b[0m \u001b[0;34m\u001b[0m\u001b[0m\n\u001b[1;32m 418\u001b[0m \u001b[0;32mreturn\u001b[0m \u001b[0mvector\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0mInteger\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0;36m2\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m*\u001b[0m\u001b[0mg\u001b[0m\u001b[0;34m*\u001b[0m\u001b[0;34m[\u001b[0m\u001b[0mInteger\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0;36m0\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m]\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n", + "\u001b[0;32m\u001b[0m in \u001b[0;36mcoordinates\u001b[0;34m(self)\u001b[0m\n\u001b[1;32m 414\u001b[0m \u001b[0ma\u001b[0m \u001b[0;34m=\u001b[0m \u001b[0mcoeff_of_rational_fctn\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0mfct_j\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[1;32m 415\u001b[0m \u001b[0melt\u001b[0m \u001b[0;34m=\u001b[0m\u001b[0mself\u001b[0m \u001b[0;34m-\u001b[0m \u001b[0msuperelliptic_cech\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0mC\u001b[0m\u001b[0;34m,\u001b[0m \u001b[0mdiffn\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0mG\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m,\u001b[0m \u001b[0mG\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mmult\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0ma\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0;32m--> 416\u001b[0;31m \u001b[0;32mreturn\u001b[0m \u001b[0melt\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mcoordinates\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0m\u001b[1;32m 417\u001b[0m \u001b[0;34m\u001b[0m\u001b[0m\n\u001b[1;32m 418\u001b[0m \u001b[0;32mreturn\u001b[0m \u001b[0mvector\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0mInteger\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0;36m2\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m*\u001b[0m\u001b[0mg\u001b[0m\u001b[0;34m*\u001b[0m\u001b[0;34m[\u001b[0m\u001b[0mInteger\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0;36m0\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m]\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n", + "\u001b[0;32m\u001b[0m in \u001b[0;36mcoordinates\u001b[0;34m(self)\u001b[0m\n\u001b[1;32m 414\u001b[0m \u001b[0ma\u001b[0m \u001b[0;34m=\u001b[0m \u001b[0mcoeff_of_rational_fctn\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0mfct_j\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[1;32m 415\u001b[0m \u001b[0melt\u001b[0m \u001b[0;34m=\u001b[0m\u001b[0mself\u001b[0m \u001b[0;34m-\u001b[0m \u001b[0msuperelliptic_cech\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0mC\u001b[0m\u001b[0;34m,\u001b[0m \u001b[0mdiffn\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0mG\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m,\u001b[0m \u001b[0mG\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mmult\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0ma\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0;32m--> 416\u001b[0;31m \u001b[0;32mreturn\u001b[0m \u001b[0melt\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mcoordinates\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0m\u001b[1;32m 417\u001b[0m \u001b[0;34m\u001b[0m\u001b[0m\n\u001b[1;32m 418\u001b[0m \u001b[0;32mreturn\u001b[0m \u001b[0mvector\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0mInteger\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0;36m2\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m*\u001b[0m\u001b[0mg\u001b[0m\u001b[0;34m*\u001b[0m\u001b[0;34m[\u001b[0m\u001b[0mInteger\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0;36m0\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m]\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n", + "\u001b[0;32m\u001b[0m in \u001b[0;36mcoordinates\u001b[0;34m(self)\u001b[0m\n\u001b[1;32m 399\u001b[0m \u001b[0ma1\u001b[0m \u001b[0;34m=\u001b[0m \u001b[0mcoeff_of_rational_fctn\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0mbasis\u001b[0m\u001b[0;34m[\u001b[0m\u001b[0mindex\u001b[0m\u001b[0;34m]\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mf\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mjth_component\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0mj\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[1;32m 400\u001b[0m \u001b[0mprint\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0ma\u001b[0m\u001b[0;34m,\u001b[0m \u001b[0ma1\u001b[0m\u001b[0;34m,\u001b[0m \u001b[0mindex\u001b[0m\u001b[0;34m,\u001b[0m \u001b[0mbasis\u001b[0m\u001b[0;34m[\u001b[0m\u001b[0mindex\u001b[0m\u001b[0;34m]\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mis_cocycle\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0;32m--> 401\u001b[0;31m \u001b[0melt\u001b[0m \u001b[0;34m=\u001b[0m \u001b[0mself\u001b[0m \u001b[0;34m-\u001b[0m \u001b[0mbasis\u001b[0m\u001b[0;34m[\u001b[0m\u001b[0mindex\u001b[0m\u001b[0;34m]\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mmult\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0ma\u001b[0m\u001b[0;34m/\u001b[0m\u001b[0ma1\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0m\u001b[1;32m 402\u001b[0m \u001b[0;32mreturn\u001b[0m \u001b[0melt\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mcoordinates\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0;34m)\u001b[0m \u001b[0;34m+\u001b[0m \u001b[0ma\u001b[0m\u001b[0;34m/\u001b[0m\u001b[0ma1\u001b[0m\u001b[0;34m*\u001b[0m\u001b[0mvector\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0;34m[\u001b[0m\u001b[0mGF\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0mp\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0mi\u001b[0m \u001b[0;34m==\u001b[0m \u001b[0mindex\u001b[0m\u001b[0;34m)\u001b[0m \u001b[0;32mfor\u001b[0m \u001b[0mi\u001b[0m \u001b[0;32min\u001b[0m \u001b[0mrange\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0mInteger\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0;36m0\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m,\u001b[0m \u001b[0mInteger\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0;36m2\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m*\u001b[0m\u001b[0mg\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m]\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[1;32m 403\u001b[0m \u001b[0;34m\u001b[0m\u001b[0m\n", + "\u001b[0;32m/opt/sagemath-9.1/local/lib/python3.7/site-packages/sage/structure/element.pyx\u001b[0m in \u001b[0;36msage.structure.element.Element.__truediv__ (build/cythonized/sage/structure/element.c:12837)\u001b[0;34m()\u001b[0m\n\u001b[1;32m 1716\u001b[0m \u001b[0;32mreturn\u001b[0m \u001b[0;34m(\u001b[0m\u001b[0;34m<\u001b[0m\u001b[0mElement\u001b[0m\u001b[0;34m>\u001b[0m\u001b[0mleft\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0m_div_\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0mright\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[1;32m 1717\u001b[0m \u001b[0;32mif\u001b[0m \u001b[0mBOTH_ARE_ELEMENT\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0mcl\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m:\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0;32m-> 1718\u001b[0;31m \u001b[0;32mreturn\u001b[0m \u001b[0mcoercion_model\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mbin_op\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0mleft\u001b[0m\u001b[0;34m,\u001b[0m \u001b[0mright\u001b[0m\u001b[0;34m,\u001b[0m \u001b[0mtruediv\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0m\u001b[1;32m 1719\u001b[0m \u001b[0;34m\u001b[0m\u001b[0m\n\u001b[1;32m 1720\u001b[0m \u001b[0;32mtry\u001b[0m\u001b[0;34m:\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n", + "\u001b[0;32m/opt/sagemath-9.1/local/lib/python3.7/site-packages/sage/structure/coerce.pyx\u001b[0m in \u001b[0;36msage.structure.coerce.CoercionModel.bin_op (build/cythonized/sage/structure/coerce.c:10143)\u001b[0;34m()\u001b[0m\n\u001b[1;32m 1209\u001b[0m \u001b[0mself\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0m_record_exception\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[1;32m 1210\u001b[0m \u001b[0;32melse\u001b[0m\u001b[0;34m:\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0;32m-> 1211\u001b[0;31m \u001b[0;32mreturn\u001b[0m \u001b[0mPyObject_CallObject\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0mop\u001b[0m\u001b[0;34m,\u001b[0m \u001b[0mxy\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0m\u001b[1;32m 1212\u001b[0m \u001b[0;34m\u001b[0m\u001b[0m\n\u001b[1;32m 1213\u001b[0m \u001b[0;32mif\u001b[0m \u001b[0mop\u001b[0m \u001b[0;32mis\u001b[0m \u001b[0mmul\u001b[0m\u001b[0;34m:\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n", + "\u001b[0;32m/opt/sagemath-9.1/local/lib/python3.7/site-packages/sage/structure/element.pyx\u001b[0m in \u001b[0;36msage.structure.element.Element.__truediv__ (build/cythonized/sage/structure/element.c:12802)\u001b[0;34m()\u001b[0m\n\u001b[1;32m 1714\u001b[0m \u001b[0mcdef\u001b[0m \u001b[0mint\u001b[0m \u001b[0mcl\u001b[0m \u001b[0;34m=\u001b[0m \u001b[0mclassify_elements\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0mleft\u001b[0m\u001b[0;34m,\u001b[0m \u001b[0mright\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[1;32m 1715\u001b[0m \u001b[0;32mif\u001b[0m \u001b[0mHAVE_SAME_PARENT\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0mcl\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m:\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0;32m-> 1716\u001b[0;31m \u001b[0;32mreturn\u001b[0m \u001b[0;34m(\u001b[0m\u001b[0;34m<\u001b[0m\u001b[0mElement\u001b[0m\u001b[0;34m>\u001b[0m\u001b[0mleft\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0m_div_\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0mright\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0m\u001b[1;32m 1717\u001b[0m \u001b[0;32mif\u001b[0m \u001b[0mBOTH_ARE_ELEMENT\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0mcl\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m:\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[1;32m 1718\u001b[0m \u001b[0;32mreturn\u001b[0m \u001b[0mcoercion_model\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mbin_op\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0mleft\u001b[0m\u001b[0;34m,\u001b[0m \u001b[0mright\u001b[0m\u001b[0;34m,\u001b[0m \u001b[0mtruediv\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n", + "\u001b[0;32m/opt/sagemath-9.1/local/lib/python3.7/site-packages/sage/rings/finite_rings/integer_mod.pyx\u001b[0m in \u001b[0;36msage.rings.finite_rings.integer_mod.IntegerMod_int._div_ (build/cythonized/sage/rings/finite_rings/integer_mod.c:27689)\u001b[0;34m()\u001b[0m\n\u001b[1;32m 2540\u001b[0m \u001b[0mright_inverse\u001b[0m \u001b[0;34m=\u001b[0m \u001b[0mself\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0m__modulus\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0minverses\u001b[0m\u001b[0;34m[\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0;34m<\u001b[0m\u001b[0mIntegerMod_int\u001b[0m\u001b[0;34m>\u001b[0m\u001b[0mright\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mivalue\u001b[0m\u001b[0;34m]\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[1;32m 2541\u001b[0m \u001b[0;32mif\u001b[0m \u001b[0mright_inverse\u001b[0m \u001b[0;32mis\u001b[0m \u001b[0;32mNone\u001b[0m\u001b[0;34m:\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0;32m-> 2542\u001b[0;31m \u001b[0;32mraise\u001b[0m \u001b[0mZeroDivisionError\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0;34mf\"inverse of Mod({right}, {self.__modulus.sageInteger}) does not exist\"\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0m\u001b[1;32m 2543\u001b[0m \u001b[0;32melse\u001b[0m\u001b[0;34m:\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[1;32m 2544\u001b[0m \u001b[0;32mreturn\u001b[0m \u001b[0mself\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0m_new_c\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0mself\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mivalue\u001b[0m \u001b[0;34m*\u001b[0m \u001b[0;34m(\u001b[0m\u001b[0;34m<\u001b[0m\u001b[0mIntegerMod_int\u001b[0m\u001b[0;34m>\u001b[0m\u001b[0mright_inverse\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mivalue\u001b[0m\u001b[0;34m)\u001b[0m \u001b[0;34m%\u001b[0m \u001b[0mself\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0m__modulus\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mint32\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n", + "\u001b[0;31mZeroDivisionError\u001b[0m: inverse of Mod(0, 5) does not exist" + ] + } + ], + "source": [ + "C.frobenius_matrix()" + ] + }, + { + "cell_type": "code", + "execution_count": 4, "metadata": {}, "outputs": [ { @@ -455,16 +666,17 @@ "output_type": "stream", "text": [ "(((-x*y + 1)/y^5) dx, 4/x*y^4, ((-x^3*y + x*y^2 + x^2 - 2*y^2)/(x^2*y^5)) dx)\n", - "((1/y^5) dx, 0, (1/y^5) dx)\n" + "((1/y^5) dx, 0, (1/y^5) dx)\n", + "(0 dx, 0, 0 dx)\n" ] }, { "data": { "text/plain": [ - "(0, 0, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0)" + "(0, 0, 0, 0, 0, 0, 0, 2, 1, 0, 0, 0)" ] }, - "execution_count": 118, + "execution_count": 4, "metadata": {}, "output_type": "execute_result" } @@ -850,6 +1062,55 @@ "degrees1_inv" ] }, + { + "cell_type": "code", + "execution_count": 28, + "metadata": {}, + "outputs": [ + { + "data": { + "text/plain": [ + "Superelliptic curve with the equation y^7 = x^3 + x + 2 over finite field with 5 elements." + ] + }, + "execution_count": 28, + "metadata": {}, + "output_type": "execute_result" + } + ], + "source": [ + "C" + ] + }, + { + "cell_type": "code", + "execution_count": 29, + "metadata": {}, + "outputs": [], + "source": [ + "basis = C.basis_de_rham()" + ] + }, + { + "cell_type": "code", + "execution_count": 32, + "metadata": {}, + "outputs": [ + { + "data": { + "text/plain": [ + "dict_items([(0, ((x/y) dx, 2/x*y, ((x^3*y^5 - x^3 + x - 1)/(x^2*y^6)) dx)), (1, (((-1)/y) dx, 2/x^2*y, ((-x^3*y^5 + x^3 - 2*x - 2)/(x^3*y^6)) dx)), (2, (((-2*x)/y^2) dx, 2/x*y^2, ((-2*x^3*y^3 + x^3 - 1)/(x^2*y^5)) dx)), (3, ((1/y^2) dx, 2/x^2*y^2, ((x^3*y^3 - 2*x^3 + 2*x - 2)/(x^3*y^5)) dx)), (4, ((1/y^3) dx, 0, (1/y^3) dx)), (5, (0 dx, 2/x*y^3, ((-2*x^3 - x - 1)/(x^2*y^4)) dx)), (6, ((1/y^4) dx, 0, (1/y^4) dx)), (7, ((2*x/y^4) dx, 2/x*y^4, ((2*x^3 - 2*x*y - y)/(x^2*y^4)) dx)), (8, ((1/y^5) dx, 0, (1/y^5) dx)), (9, ((x/y^5) dx, 0, (x/y^5) dx)), (10, ((1/y^6) dx, 0, (1/y^6) dx)), (11, ((x/y^6) dx, 0, (x/y^6) dx))])" + ] + }, + "execution_count": 32, + "metadata": {}, + "output_type": "execute_result" + } + ], + "source": [ + "basis.items()" + ] + }, { "cell_type": "code", "execution_count": null,