dziala baza dR

This commit is contained in:
jgarnek 2021-08-21 19:52:03 +02:00
parent 8e234d2c21
commit 7abda884fa

View File

@ -2,7 +2,7 @@
"cells": [
{
"cell_type": "code",
"execution_count": 48,
"execution_count": 4,
"metadata": {},
"outputs": [],
"source": [
@ -256,6 +256,7 @@
" return 0\n",
" return 1\n",
" \n",
" \n",
"class superelliptic_cech:\n",
" def __init__(self, C, omega, fct):\n",
" self.omega0 = omega\n",
@ -263,6 +264,17 @@
" self.f = fct\n",
" self.curve = C\n",
" \n",
" def __add__(self, other):\n",
" C = self.curve\n",
" return superelliptic_cech(C, self.omega0 + other.omega0, self.f + other.f)\n",
" \n",
" def __sub__(self, other):\n",
" C = self.curve\n",
" return superelliptic_cech(C, self.omega0 - other.omega0, self.f - other.f)\n",
" \n",
" def __repr__(self):\n",
" return \"(\" + str(self.omega0) + \", \" + str(self.f) + \", \" + str(self.omega8) + \")\" \n",
" \n",
"def degree_of_rational_fctn(f):\n",
" R.<x> = PolynomialRing(GF(p))\n",
" RR = FractionField(R)\n",
@ -287,17 +299,16 @@
},
{
"cell_type": "code",
"execution_count": 49,
"execution_count": 5,
"metadata": {},
"outputs": [
{
"data": {
"text/plain": [
"{0: <__main__.superelliptic_cech object at 0x6fdcefeaf60>,\n",
" 1: <__main__.superelliptic_cech object at 0x6fdcefea8d0>}"
"{0: ((1/y) dx, 0, (1/y) dx), 1: ((x/y) dx, 2/x*y, ((x - 1)/(x^2*y)) dx)}"
]
},
"execution_count": 49,
"execution_count": 5,
"metadata": {},
"output_type": "execute_result"
}