macierz froba chyba dziala

This commit is contained in:
jgarnek 2021-08-23 15:14:55 +02:00
parent 5f012a164e
commit 891996e1af

View File

@ -2,7 +2,7 @@
"cells": [
{
"cell_type": "code",
"execution_count": 118,
"execution_count": 132,
"metadata": {},
"outputs": [],
"source": [
@ -77,7 +77,7 @@
" psi = Rx(cut(s, 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",
" degrees1[t] = (-i, m-j)\n",
" t += 1\n",
" return basis, degrees0, degrees1\n",
" \n",
@ -395,29 +395,23 @@
" 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",
" elt = self - basis[index].mult(a/m)\n",
" return elt.coordinates() + a/m*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",
" 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 =self - superelliptic_cech(C, diffn(G), G).mult(a)\n",
@ -450,7 +444,6 @@
" return(d1 - d2)\n",
"\n",
"def coeff_of_rational_fctn(f):\n",
" print('coeff', f)\n",
" Rx.<x> = PolynomialRing(GF(p))\n",
" Fx = FractionField(Rx)\n",
" f = Fx(f)\n",
@ -488,7 +481,7 @@
},
{
"cell_type": "code",
"execution_count": 119,
"execution_count": 133,
"metadata": {},
"outputs": [],
"source": [
@ -500,80 +493,7 @@
},
{
"cell_type": "code",
"execution_count": 120,
"metadata": {},
"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": [
"for w in baza.values():\n",
" print(w, w.is_cocycle())"
]
},
{
"cell_type": "code",
"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,
"execution_count": 134,
"metadata": {
"scrolled": false
},
@ -621,35 +541,447 @@
"((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",
"c2b\n",
"coeff (3*x^4 + 3*x^2 + 4*x + 2)/x^5\n",
"coeff 0\n",
"3 0 2 1\n"
"((x/y^5) dx, ((3*x^2 + 4*x + 2)/x^5)*y^2, ((x^3 - 1)/(x^2*y^5)) dx) 1\n",
"c2\n",
"c2\n",
"c2b\n",
"coeff (3*x^2 + 4*x + 2)/x^5\n",
"((x/y^5) dx, ((4*x + 2)/x^5)*y^2, ((x^5 - x^2 - x + 2)/(x^4*y^5)) dx) 1\n",
"c2\n",
"c2\n",
"c2b\n",
"coeff (4*x + 2)/x^5\n",
"((x/y^5) dx, 2/x^5*y^2, ((x^6 - x^2 - 2)/(x^5*y^5)) dx) 1\n",
"c2\n",
"c2\n",
"c2b\n",
"coeff 2/x^5\n",
"((x/y^5) dx, 0, (x/y^5) dx) 1\n",
"c1\n",
"baza ((x/y^5) dx, 0, (x/y^5) dx)\n",
"coeff x\n",
"coeff x\n",
"(0 dx, 0, 0 dx) 1\n",
"c2\n",
"c2\n",
"c2\n",
"c2\n",
"c2\n",
"c2\n",
"w (((-1)/y) dx, 2/x^2*y^6, ((-2*x - 2)/(x^3*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^10)*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^10\n",
"(((-x^2 + 2*x)/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^10)*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^10\n",
"(((2*x + 2)/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^10)*y^2, 0 dx) 1\n",
"c2\n",
"c2\n",
"c2b\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^10\n",
"(((2*x + 2)/y^5) dx, ((2*x^8 + 3*x^7 + x^6 + 3*x^5 + 3*x^4 + 3*x^2 + 4*x + 2)/x^10)*y^2, ((2*x^3 - 2)/(x^2*y^5)) dx) 1\n",
"c2\n",
"c2\n",
"c2b\n",
"coeff (2*x^8 + 3*x^7 + x^6 + 3*x^5 + 3*x^4 + 3*x^2 + 4*x + 2)/x^10\n",
"(((2*x + 2)/y^5) dx, ((3*x^7 + x^6 + 3*x^5 + 3*x^4 + 3*x^2 + 4*x + 2)/x^10)*y^2, ((2*x^4 + 2*x^3 + x + 2)/(x^3*y^5)) dx) 1\n",
"c2\n",
"c2\n",
"c2b\n",
"coeff (3*x^7 + x^6 + 3*x^5 + 3*x^4 + 3*x^2 + 4*x + 2)/x^10\n",
"(((2*x + 2)/y^5) dx, ((x^6 + 3*x^5 + 3*x^4 + 3*x^2 + 4*x + 2)/x^10)*y^2, ((2*x^5 + 2*x^4 + x^2 + x + 2)/(x^4*y^5)) dx) 1\n",
"c2\n",
"c2\n",
"c2b\n",
"coeff (x^6 + 3*x^5 + 3*x^4 + 3*x^2 + 4*x + 2)/x^10\n",
"(((2*x + 2)/y^5) dx, ((3*x^5 + 3*x^4 + 3*x^2 + 4*x + 2)/x^10)*y^2, ((2*x^6 + 2*x^5 + x^2 - x + 2)/(x^5*y^5)) dx) 1\n",
"c2\n",
"c2\n",
"c2b\n",
"coeff (3*x^5 + 3*x^4 + 3*x^2 + 4*x + 2)/x^10\n",
"(((2*x + 2)/y^5) dx, ((3*x^4 + 3*x^2 + 4*x + 2)/x^10)*y^2, ((2*x^5 + 2*x^4 - 1)/(x^4*y^5)) dx) 1\n",
"c2\n",
"c2\n",
"c2b\n",
"coeff (3*x^4 + 3*x^2 + 4*x + 2)/x^10\n",
"(((2*x + 2)/y^5) dx, ((3*x^2 + 4*x + 2)/x^10)*y^2, ((2*x^8 + 2*x^7 - 1)/(x^7*y^5)) dx) 1\n",
"c2\n",
"c2\n",
"c2b\n",
"coeff (3*x^2 + 4*x + 2)/x^10\n",
"(((2*x + 2)/y^5) dx, ((4*x + 2)/x^10)*y^2, ((2*x^10 + 2*x^9 - x^2 - x + 2)/(x^9*y^5)) dx) 1\n",
"c2\n",
"c2\n",
"c2b\n",
"coeff (4*x + 2)/x^10\n",
"(((2*x + 2)/y^5) dx, 2/x^10*y^2, ((2*x^11 + 2*x^10 - x^2 - 2)/(x^10*y^5)) dx) 1\n",
"c2\n",
"c2\n",
"c2b\n",
"coeff 2/x^10\n",
"(((2*x + 2)/y^5) dx, 0, ((2*x + 2)/y^5) dx) 1\n",
"c1\n",
"baza ((x/y^5) dx, 0, (x/y^5) dx)\n",
"coeff 2*x + 2\n",
"coeff x\n",
"((2/y^5) dx, 0, (2/y^5) dx) 1\n",
"c1\n",
"baza ((1/y^5) dx, 0, (1/y^5) dx)\n",
"coeff 2\n",
"coeff 1\n",
"(0 dx, 0, 0 dx) 1\n",
"c2\n",
"c2\n",
"c2\n",
"c2\n",
"c2\n",
"c2\n",
"w (((-2*x)/y^2) dx, 2/x*y^5, ((2*x - 1)/(x^2*y^2)) dx)\n",
"(0 dx, ((2*x^9 + x^7 + 2*x^6 + x^5 + 4*x^4 + x^3 + 2*x^2 + 4*x + 1)/x^5)*y^4, 0 dx) 1\n",
"c2\n",
"c2\n",
"c2\n",
"c2\n",
"c2c\n",
"coeff (2*x^9 + x^7 + 2*x^6 + x^5 + 4*x^4 + x^3 + 2*x^2 + 4*x + 1)/x^5\n",
"(((-2*x^4 - x^3)/y^3) dx, ((x^7 + 2*x^6 + x^5 + 4*x^4 + x^3 + 2*x^2 + 4*x + 1)/x^5)*y^4, 0 dx) 1\n",
"c2\n",
"c2\n",
"c2\n",
"c2\n",
"c2c\n",
"coeff (x^7 + 2*x^6 + x^5 + 4*x^4 + x^3 + 2*x^2 + 4*x + 1)/x^5\n",
"(((-x^3 + x^2 + x)/y^3) dx, ((2*x^6 + x^5 + 4*x^4 + x^3 + 2*x^2 + 4*x + 1)/x^5)*y^4, 0 dx) 1\n",
"c2\n",
"c2\n",
"c2\n",
"c2\n",
"c2c\n",
"coeff (2*x^6 + x^5 + 4*x^4 + x^3 + 2*x^2 + 4*x + 1)/x^5\n",
"(((x^2 + 1)/y^3) dx, ((x^5 + 4*x^4 + x^3 + 2*x^2 + 4*x + 1)/x^5)*y^4, 0 dx) 1\n",
"c2\n",
"c2\n",
"c2\n",
"c2\n",
"c2c\n",
"coeff (x^5 + 4*x^4 + x^3 + 2*x^2 + 4*x + 1)/x^5\n",
"(((-1)/y^3) dx, ((4*x^4 + x^3 + 2*x^2 + 4*x + 1)/x^5)*y^4, 0 dx) 1\n",
"c2\n",
"c2\n",
"c2\n",
"c2\n",
"c2a\n",
"coeff (4*x^4 + x^3 + 2*x^2 + 4*x + 1)/x^5\n",
"2 5 (0 dx, 2/x*y^4, ((-2*x - 1)/(x^2*y^3)) dx)\n",
"przed d -1 j 4 (((-1)/y^3) dx, ((4*x^4 + x^3 + 2*x^2 + 4*x + 1)/x^5)*y^4, 0 dx) (0 dx, 4/x*y^4, ((x - 2)/(x^2*y^3)) dx)\n",
"po (((-1)/y^3) dx, ((x^3 + 2*x^2 + 4*x + 1)/x^5)*y^4, ((-x + 2)/(x^2*y^3)) dx)\n",
"(((-1)/y^3) dx, ((x^3 + 2*x^2 + 4*x + 1)/x^5)*y^4, ((-x + 2)/(x^2*y^3)) dx) 1\n",
"c2\n",
"c2\n",
"c2\n",
"c2\n",
"c2b\n",
"coeff (x^3 + 2*x^2 + 4*x + 1)/x^5\n",
"(((-1)/y^3) dx, ((2*x^2 + 4*x + 1)/x^5)*y^4, ((-x^3 - x^2 + 2*x + 1)/(x^3*y^3)) dx) 1\n",
"c2\n",
"c2\n",
"c2\n",
"c2\n",
"c2b\n",
"coeff (2*x^2 + 4*x + 1)/x^5\n",
"(((-1)/y^3) dx, ((4*x + 1)/x^5)*y^4, ((-x^4 + 2*x^2 - x - 2)/(x^4*y^3)) dx) 1\n",
"c2\n",
"c2\n",
"c2\n",
"c2\n",
"c2b\n",
"coeff (4*x + 1)/x^5\n",
"(((-1)/y^3) dx, 1/x^5*y^4, ((-x^5 - x^2 - 2)/(x^5*y^3)) dx) 1\n",
"c2\n",
"c2\n",
"c2\n",
"c2\n",
"c2b\n",
"coeff 1/x^5\n",
"(((-1)/y^3) dx, 0, ((-1)/y^3) dx) 1\n",
"c1\n",
"baza ((1/y^3) dx, 0, (1/y^3) dx)\n",
"coeff 4\n",
"coeff 1\n",
"(0 dx, 0, 0 dx) 1\n",
"c2\n",
"c2\n",
"c2\n",
"c2\n",
"c2\n",
"c2\n",
"w ((1/y^2) dx, 2/x^2*y^5, ((-x - 2)/(x^3*y^2)) dx)\n",
"(0 dx, ((2*x^9 + x^7 + 2*x^6 + x^5 + 4*x^4 + x^3 + 2*x^2 + 4*x + 1)/x^10)*y^4, 0 dx) 1\n",
"c2\n",
"c2\n",
"c2\n",
"c2\n",
"c2a\n",
"coeff (2*x^9 + x^7 + 2*x^6 + x^5 + 4*x^4 + x^3 + 2*x^2 + 4*x + 1)/x^10\n",
"1 5 (0 dx, 2/x*y^4, ((-2*x - 1)/(x^2*y^3)) dx)\n",
"przed d -1 j 4 (0 dx, ((2*x^9 + x^7 + 2*x^6 + x^5 + 4*x^4 + x^3 + 2*x^2 + 4*x + 1)/x^10)*y^4, 0 dx) (0 dx, 2/x*y^4, ((-2*x - 1)/(x^2*y^3)) dx)\n",
"po (0 dx, ((x^7 + 2*x^6 + x^5 + 4*x^4 + x^3 + 2*x^2 + 4*x + 1)/x^10)*y^4, ((2*x + 1)/(x^2*y^3)) dx)\n",
"(0 dx, ((x^7 + 2*x^6 + x^5 + 4*x^4 + x^3 + 2*x^2 + 4*x + 1)/x^10)*y^4, ((2*x + 1)/(x^2*y^3)) dx) 1\n",
"c2\n",
"c2\n",
"c2\n",
"c2\n",
"c2b\n",
"coeff (x^7 + 2*x^6 + x^5 + 4*x^4 + x^3 + 2*x^2 + 4*x + 1)/x^10\n",
"(0 dx, ((2*x^6 + x^5 + 4*x^4 + x^3 + 2*x^2 + 4*x + 1)/x^10)*y^4, ((x^2 - x - 1)/(x^4*y^3)) dx) 1\n",
"c2\n",
"c2\n",
"c2\n",
"c2\n",
"c2b\n",
"coeff (2*x^6 + x^5 + 4*x^4 + x^3 + 2*x^2 + 4*x + 1)/x^10\n",
"(0 dx, ((x^5 + 4*x^4 + x^3 + 2*x^2 + 4*x + 1)/x^10)*y^4, ((-x^2 - 1)/(x^5*y^3)) dx) 1\n",
"c2\n",
"c2\n",
"c2\n",
"c2\n",
"c2b\n",
"coeff (x^5 + 4*x^4 + x^3 + 2*x^2 + 4*x + 1)/x^10\n",
"(0 dx, ((4*x^4 + x^3 + 2*x^2 + 4*x + 1)/x^10)*y^4, (1/(x^5*y^3)) dx) 1\n",
"c2\n",
"c2\n",
"c2\n",
"c2\n",
"c2b\n",
"coeff (4*x^4 + x^3 + 2*x^2 + 4*x + 1)/x^10\n",
"(0 dx, ((x^3 + 2*x^2 + 4*x + 1)/x^10)*y^4, ((x^2 - x + 2)/(x^7*y^3)) dx) 1\n",
"c2\n",
"c2\n",
"c2\n",
"c2\n",
"c2b\n",
"coeff (x^3 + 2*x^2 + 4*x + 1)/x^10\n",
"(0 dx, ((2*x^2 + 4*x + 1)/x^10)*y^4, ((-x^2 + 2*x + 1)/(x^8*y^3)) dx) 1\n",
"c2\n",
"c2\n",
"c2\n",
"c2\n",
"c2b\n",
"coeff (2*x^2 + 4*x + 1)/x^10\n",
"(0 dx, ((4*x + 1)/x^10)*y^4, ((2*x^2 - x - 2)/(x^9*y^3)) dx) 1\n",
"c2\n",
"c2\n",
"c2\n",
"c2\n",
"c2b\n",
"coeff (4*x + 1)/x^10\n",
"(0 dx, 1/x^10*y^4, ((-x^2 - 2)/(x^10*y^3)) dx) 1\n",
"c2\n",
"c2\n",
"c2\n",
"c2\n",
"c2b\n",
"coeff 1/x^10\n",
"(0 dx, 0, 0 dx) 1\n",
"c2\n",
"c2\n",
"c2\n",
"c2\n",
"c2\n",
"c2\n",
"w ((1/y^3) dx, 0, (1/y^3) dx)\n",
"(0 dx, 0, 0 dx) 1\n",
"c2\n",
"c2\n",
"c2\n",
"c2\n",
"c2\n",
"c2\n",
"w (0 dx, 2/x*y^4, ((-2*x - 1)/(x^2*y^3)) dx)\n",
"(0 dx, ((2*x^6 + 4*x^4 + 3*x^3 + 2*x^2 + 3*x + 3)/x^5)*y^6, 0 dx) 1\n",
"c2\n",
"c2\n",
"c2\n",
"c2\n",
"c2\n",
"c2\n",
"c2c\n",
"coeff (2*x^6 + 4*x^4 + 3*x^3 + 2*x^2 + 3*x + 3)/x^5\n",
"(((2*x + 1)/y) dx, ((4*x^4 + 3*x^3 + 2*x^2 + 3*x + 3)/x^5)*y^6, 0 dx) 1\n",
"c2\n",
"c2\n",
"c2\n",
"c2\n",
"c2\n",
"c2\n",
"c2a\n",
"coeff (4*x^4 + 3*x^3 + 2*x^2 + 3*x + 3)/x^5\n",
"2 0 ((x/y) dx, 2/x*y^6, ((x - 1)/(x^2*y)) dx)\n",
"przed d -1 j 6 (((2*x + 1)/y) dx, ((4*x^4 + 3*x^3 + 2*x^2 + 3*x + 3)/x^5)*y^6, 0 dx) ((2*x/y) dx, 4/x*y^6, ((2*x - 2)/(x^2*y)) dx)\n",
"po ((1/y) dx, ((3*x^3 + 2*x^2 + 3*x + 3)/x^5)*y^6, ((-2*x + 2)/(x^2*y)) dx)\n",
"((1/y) dx, ((3*x^3 + 2*x^2 + 3*x + 3)/x^5)*y^6, ((-2*x + 2)/(x^2*y)) dx) 1\n",
"c2\n",
"c2\n",
"c2\n",
"c2\n",
"c2\n",
"c2\n",
"c2a\n",
"coeff (3*x^3 + 2*x^2 + 3*x + 3)/x^5\n",
"4 1 (((-1)/y) dx, 2/x^2*y^6, ((-2*x - 2)/(x^3*y)) dx)\n",
"przed d -2 j 6 ((1/y) dx, ((3*x^3 + 2*x^2 + 3*x + 3)/x^5)*y^6, ((-2*x + 2)/(x^2*y)) dx) ((1/y) dx, 3/x^2*y^6, ((2*x + 2)/(x^3*y)) dx)\n",
"po (0 dx, ((2*x^2 + 3*x + 3)/x^5)*y^6, ((-2*x^2 - 2)/(x^3*y)) dx)\n",
"(0 dx, ((2*x^2 + 3*x + 3)/x^5)*y^6, ((-2*x^2 - 2)/(x^3*y)) dx) 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<ipython-input-121-e1ff68010d76>\u001b[0m in \u001b[0;36m<module>\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<ipython-input-118-ac653a450b02>\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<ipython-input-118-ac653a450b02>\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<ipython-input-118-ac653a450b02>\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<ipython-input-118-ac653a450b02>\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<ipython-input-118-ac653a450b02>\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<ipython-input-118-ac653a450b02>\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<ipython-input-118-ac653a450b02>\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<ipython-input-118-ac653a450b02>\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<ipython-input-118-ac653a450b02>\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"
"name": "stdout",
"output_type": "stream",
"text": [
"c2\n",
"c2\n",
"c2\n",
"c2\n",
"c2\n",
"c2\n",
"c2b\n",
"coeff (2*x^2 + 3*x + 3)/x^5\n",
"(0 dx, ((3*x + 3)/x^5)*y^6, ((-2*x - 2)/(x^4*y)) dx) 1\n",
"c2\n",
"c2\n",
"c2\n",
"c2\n",
"c2\n",
"c2\n",
"c2b\n",
"coeff (3*x + 3)/x^5\n",
"(0 dx, 3/x^5*y^6, ((-2*x^2 + 1)/(x^5*y)) dx) 1\n",
"c2\n",
"c2\n",
"c2\n",
"c2\n",
"c2\n",
"c2\n",
"c2b\n",
"coeff 3/x^5\n",
"(0 dx, 0, 0 dx) 1\n",
"c2\n",
"c2\n",
"c2\n",
"c2\n",
"c2\n",
"c2\n",
"w ((1/y^4) dx, 0, (1/y^4) dx)\n",
"(0 dx, 0, 0 dx) 1\n",
"c2\n",
"c2\n",
"c2\n",
"c2\n",
"c2\n",
"c2\n",
"w ((2*x/y^4) dx, 2/x*y^3, ((-x - 1)/(x^2*y^4)) dx)\n",
"(0 dx, ((2*x^6 + 4*x^4 + 3*x^3 + 2*x^2 + 3*x + 3)/x^5)*y, 0 dx) 1\n",
"c2\n",
"c2c\n",
"coeff (2*x^6 + 4*x^4 + 3*x^3 + 2*x^2 + 3*x + 3)/x^5\n",
"(((2*x + 1)/y^6) dx, ((4*x^4 + 3*x^3 + 2*x^2 + 3*x + 3)/x^5)*y, 0 dx) 1\n",
"c2\n",
"c2b\n",
"coeff (4*x^4 + 3*x^3 + 2*x^2 + 3*x + 3)/x^5\n",
"(((2*x + 1)/y^6) dx, ((3*x^3 + 2*x^2 + 3*x + 3)/x^5)*y, ((2*x^3 - 2*x + 2)/(x^2*y^6)) dx) 1\n",
"c2\n",
"c2b\n",
"coeff (3*x^3 + 2*x^2 + 3*x + 3)/x^5\n",
"(((2*x + 1)/y^6) dx, ((2*x^2 + 3*x + 3)/x^5)*y, ((2*x^4 + x^3 - 2*x^2 - 2)/(x^3*y^6)) dx) 1\n",
"c2\n",
"c2b\n",
"coeff (2*x^2 + 3*x + 3)/x^5\n",
"(((2*x + 1)/y^6) dx, ((3*x + 3)/x^5)*y, ((2*x^5 + x^4 - 2*x - 2)/(x^4*y^6)) dx) 1\n",
"c2\n",
"c2b\n",
"coeff (3*x + 3)/x^5\n",
"(((2*x + 1)/y^6) dx, 3/x^5*y, ((2*x^6 + x^5 - 2*x^2 + 1)/(x^5*y^6)) dx) 1\n",
"c2\n",
"c2b\n",
"coeff 3/x^5\n",
"(((2*x + 1)/y^6) dx, 0, ((2*x + 1)/y^6) dx) 1\n",
"c1\n",
"baza ((x/y^6) dx, 0, (x/y^6) dx)\n",
"coeff 2*x + 1\n",
"coeff x\n",
"((1/y^6) dx, 0, (1/y^6) dx) 1\n",
"c1\n",
"baza ((1/y^6) dx, 0, (1/y^6) dx)\n",
"coeff 1\n",
"coeff 1\n",
"(0 dx, 0, 0 dx) 1\n",
"c2\n",
"c2\n",
"c2\n",
"c2\n",
"c2\n",
"c2\n",
"w ((1/y^5) dx, 0, (1/y^5) dx)\n",
"(0 dx, 0, 0 dx) 1\n",
"c2\n",
"c2\n",
"c2\n",
"c2\n",
"c2\n",
"c2\n",
"w ((x/y^5) dx, 0, (x/y^5) dx)\n",
"(0 dx, 0, 0 dx) 1\n",
"c2\n",
"c2\n",
"c2\n",
"c2\n",
"c2\n",
"c2\n",
"w ((1/y^6) dx, 0, (1/y^6) dx)\n",
"(0 dx, 0, 0 dx) 1\n",
"c2\n",
"c2\n",
"c2\n",
"c2\n",
"c2\n",
"c2\n",
"w ((x/y^6) dx, 0, (x/y^6) dx)\n",
"(0 dx, 0, 0 dx) 1\n",
"c2\n",
"c2\n",
"c2\n",
"c2\n",
"c2\n",
"c2\n"
]
},
{
"data": {
"text/plain": [
"[0 0 0 0 0 0 0 0 0 1 0 0]\n",
"[0 0 0 0 0 0 0 0 2 2 0 0]\n",
"[0 0 0 0 4 2 0 0 0 0 0 0]\n",
"[0 0 0 0 0 1 0 0 0 0 0 0]\n",
"[0 0 0 0 0 0 0 0 0 0 0 0]\n",
"[2 4 0 0 0 0 0 0 0 0 0 0]\n",
"[0 0 0 0 0 0 0 0 0 0 0 0]\n",
"[0 0 0 0 0 0 0 0 0 0 1 2]\n",
"[0 0 0 0 0 0 0 0 0 0 0 0]\n",
"[0 0 0 0 0 0 0 0 0 0 0 0]\n",
"[0 0 0 0 0 0 0 0 0 0 0 0]\n",
"[0 0 0 0 0 0 0 0 0 0 0 0]"
]
},
"execution_count": 134,
"metadata": {},
"output_type": "execute_result"
}
],
"source": [