Bläddra i källkod

ec: fix small typos

zero 2 år sedan
förälder
incheckning
c9d2b280d5
1 ändrade filer med 346 tillägg och 56 borttagningar
  1. 346 56
      script/research/ec/valuation.ipynb

+ 346 - 56
script/research/ec/valuation.ipynb

@@ -9,17 +9,28 @@
     "\n",
     "We wish to compute $\\textrm{ord}_P(f)$ where $P = (2, 4)$ and $f = y - 2x$.\n",
     "\n",
-    "$$E(\\mathbb{F}_11) : y^2 = x^3 + 4x$$\n",
+    "$$E(\\mathbb{F}_{11}) : y^2 = x^3 + 4x$$\n",
     "\n",
     "Let $K[V] = K[x, y] / \\langle y^2 - x^3 - 4x \\rangle$ by the coordinate ring. $K(V)$ is the field of fractions for $K[V]$."
    ]
   },
   {
    "cell_type": "code",
-   "execution_count": null,
+   "execution_count": 2,
    "id": "5d554e0c",
    "metadata": {},
-   "outputs": [],
+   "outputs": [
+    {
+     "data": {
+      "text/plain": [
+       "Fraction Field of Quotient of Multivariate Polynomial Ring in x, y over Finite Field of size 11 by the ideal (-x^3 + y^2 - 4*x)"
+      ]
+     },
+     "execution_count": 2,
+     "metadata": {},
+     "output_type": "execute_result"
+    }
+   ],
    "source": [
     "# Define our base polynomial ring over Z_11\n",
     "K.<x, y> = GF(11)[]\n",
@@ -37,17 +48,28 @@
     "\n",
     "More formally we can see this by noting that:\n",
     "\n",
-    "$$(y - 4)(y + 4) = (x - 2)^3 - 5*(x - 2)^2 - 6(x - 2)$$\n",
+    "$$(y - 4)(y + 4) = (x - 2)^3 - 5(x - 2)^2 - 6(x - 2)$$\n",
     "\n",
     "So therefore any function on $E$ can be expressed in terms of $(x - 2)$ and $(y - 4)$."
    ]
   },
   {
    "cell_type": "code",
-   "execution_count": null,
+   "execution_count": 3,
    "id": "c430ae30",
    "metadata": {},
-   "outputs": [],
+   "outputs": [
+    {
+     "data": {
+      "text/plain": [
+       "True"
+      ]
+     },
+     "execution_count": 3,
+     "metadata": {},
+     "output_type": "execute_result"
+    }
+   ],
    "source": [
     "X, Y = S(x), S(y)\n",
     "(Y - 4)*(Y + 4) == (X - 2)^3 - 5*(X - 2)^2 - 6*(X - 2)"
@@ -69,10 +91,21 @@
   },
   {
    "cell_type": "code",
-   "execution_count": null,
+   "execution_count": 4,
    "id": "bd415ef9",
    "metadata": {},
-   "outputs": [],
+   "outputs": [
+    {
+     "data": {
+      "text/plain": [
+       "-2*x + y"
+      ]
+     },
+     "execution_count": 4,
+     "metadata": {},
+     "output_type": "execute_result"
+    }
+   ],
    "source": [
     "# Components for f\n",
     "a0, a1, a2 = -2, 1, 0\n",
@@ -100,10 +133,21 @@
   },
   {
    "cell_type": "code",
-   "execution_count": null,
+   "execution_count": 5,
    "id": "9e2be279",
    "metadata": {},
-   "outputs": [],
+   "outputs": [
+    {
+     "data": {
+      "text/plain": [
+       "True"
+      ]
+     },
+     "execution_count": 5,
+     "metadata": {},
+     "output_type": "execute_result"
+    }
+   ],
    "source": [
     "# and lets double check this\n",
     "B0 = X - 2\n",
@@ -125,20 +169,42 @@
   },
   {
    "cell_type": "code",
-   "execution_count": null,
+   "execution_count": 6,
    "id": "249b0ed0",
    "metadata": {},
-   "outputs": [],
+   "outputs": [
+    {
+     "data": {
+      "text/plain": [
+       "-2*y - 3"
+      ]
+     },
+     "execution_count": 6,
+     "metadata": {},
+     "output_type": "execute_result"
+    }
+   ],
    "source": [
     "-6 - 2*(y + 4)"
    ]
   },
   {
    "cell_type": "code",
-   "execution_count": null,
+   "execution_count": 7,
    "id": "5894ffc4",
    "metadata": {},
-   "outputs": [],
+   "outputs": [
+    {
+     "data": {
+      "text/plain": [
+       "-2*y - 3"
+      ]
+     },
+     "execution_count": 7,
+     "metadata": {},
+     "output_type": "execute_result"
+    }
+   ],
    "source": [
     "-2*(y - 4)"
    ]
@@ -160,20 +226,42 @@
   },
   {
    "cell_type": "code",
-   "execution_count": null,
+   "execution_count": 8,
    "id": "7b343008",
    "metadata": {},
-   "outputs": [],
+   "outputs": [
+    {
+     "data": {
+      "text/plain": [
+       "-5*y + 3"
+      ]
+     },
+     "execution_count": 8,
+     "metadata": {},
+     "output_type": "execute_result"
+    }
+   ],
    "source": [
     "-5*(y + 4) - 2*(-6)"
    ]
   },
   {
    "cell_type": "code",
-   "execution_count": null,
+   "execution_count": 9,
    "id": "595834a3",
    "metadata": {},
-   "outputs": [],
+   "outputs": [
+    {
+     "data": {
+      "text/plain": [
+       "-5*y - 2"
+      ]
+     },
+     "execution_count": 9,
+     "metadata": {},
+     "output_type": "execute_result"
+    }
+   ],
    "source": [
     "-5*(y - 4)"
    ]
@@ -202,20 +290,42 @@
   },
   {
    "cell_type": "code",
-   "execution_count": null,
+   "execution_count": 10,
    "id": "a0a83e30",
    "metadata": {},
-   "outputs": [],
+   "outputs": [
+    {
+     "data": {
+      "text/plain": [
+       "(x - 2, y - 4, 1)"
+      ]
+     },
+     "execution_count": 10,
+     "metadata": {},
+     "output_type": "execute_result"
+    }
+   ],
    "source": [
     "b0, b1, b2"
    ]
   },
   {
    "cell_type": "code",
-   "execution_count": null,
+   "execution_count": 11,
    "id": "d042e184",
    "metadata": {},
-   "outputs": [],
+   "outputs": [
+    {
+     "data": {
+      "text/plain": [
+       "(-2, 1, 0)"
+      ]
+     },
+     "execution_count": 11,
+     "metadata": {},
+     "output_type": "execute_result"
+    }
+   ],
    "source": [
     "# Decompose polynomial function into basis components\n",
     "def decomp(f):\n",
@@ -230,10 +340,21 @@
   },
   {
    "cell_type": "code",
-   "execution_count": null,
+   "execution_count": 12,
    "id": "c804233f",
    "metadata": {},
-   "outputs": [],
+   "outputs": [
+    {
+     "data": {
+      "text/plain": [
+       "-x^3 + y^2 - 4*x"
+      ]
+     },
+     "execution_count": 12,
+     "metadata": {},
+     "output_type": "execute_result"
+    }
+   ],
    "source": [
     "Px, Py = (2, 4)\n",
     "EC_A = 4\n",
@@ -246,10 +367,21 @@
   },
   {
    "cell_type": "code",
-   "execution_count": null,
+   "execution_count": 13,
    "id": "cbbb63c7",
    "metadata": {},
-   "outputs": [],
+   "outputs": [
+    {
+     "data": {
+      "text/plain": [
+       "(x^2 + 2*x - 2*y, y + 4)"
+      ]
+     },
+     "execution_count": 13,
+     "metadata": {},
+     "output_type": "execute_result"
+    }
+   ],
    "source": [
     "a0, a1, a2 = decomp(f)\n",
     "g = 1\n",
@@ -272,10 +404,21 @@
   },
   {
    "cell_type": "code",
-   "execution_count": null,
+   "execution_count": 14,
    "id": "d5810612",
    "metadata": {},
-   "outputs": [],
+   "outputs": [
+    {
+     "data": {
+      "text/plain": [
+       "(x + 4, -2, 0)"
+      ]
+     },
+     "execution_count": 14,
+     "metadata": {},
+     "output_type": "execute_result"
+    }
+   ],
    "source": [
     "a0, a1, a2 = decomp(a0)\n",
     "a0, a1, a2"
@@ -291,10 +434,21 @@
   },
   {
    "cell_type": "code",
-   "execution_count": null,
+   "execution_count": 15,
    "id": "22671821",
    "metadata": {},
-   "outputs": [],
+   "outputs": [
+    {
+     "data": {
+      "text/plain": [
+       "True"
+      ]
+     },
+     "execution_count": 15,
+     "metadata": {},
+     "output_type": "execute_result"
+    }
+   ],
    "source": [
     "U = (X - 2)\n",
     "F = (X + 4)*(X - 2) - 2*(Y - 4)\n",
@@ -304,10 +458,21 @@
   },
   {
    "cell_type": "code",
-   "execution_count": null,
+   "execution_count": 16,
    "id": "411c7216",
    "metadata": {},
-   "outputs": [],
+   "outputs": [
+    {
+     "data": {
+      "text/plain": [
+       "(-2*x^2 + x*y + 4*y, y^2 - 3*y + 5)"
+      ]
+     },
+     "execution_count": 16,
+     "metadata": {},
+     "output_type": "execute_result"
+    }
+   ],
    "source": [
     "# Second reduction\n",
     "a0 = Eg*a0 + Ef*a1\n",
@@ -327,10 +492,21 @@
   },
   {
    "cell_type": "code",
-   "execution_count": null,
+   "execution_count": 17,
    "id": "eceb52f7",
    "metadata": {},
-   "outputs": [],
+   "outputs": [
+    {
+     "data": {
+      "text/plain": [
+       "(-2*x + y - 4, -5, 5)"
+      ]
+     },
+     "execution_count": 17,
+     "metadata": {},
+     "output_type": "execute_result"
+    }
+   ],
    "source": [
     "a0, a1, a2 = decomp(a0)\n",
     "a0, a1, a2"
@@ -346,7 +522,7 @@
   },
   {
    "cell_type": "code",
-   "execution_count": null,
+   "execution_count": 18,
    "id": "1c654c46",
    "metadata": {},
    "outputs": [],
@@ -375,10 +551,21 @@
   },
   {
    "cell_type": "code",
-   "execution_count": null,
+   "execution_count": 19,
    "id": "ce94255a",
    "metadata": {},
-   "outputs": [],
+   "outputs": [
+    {
+     "data": {
+      "text/plain": [
+       "(True, False)"
+      ]
+     },
+     "execution_count": 19,
+     "metadata": {},
+     "output_type": "execute_result"
+    }
+   ],
    "source": [
     "R.<x> = FunctionField(GF(11)); _.<Y> = R[]\n",
     "K.<y> = R.extension(Y^2 - x^3 - 4*x)\n",
@@ -400,29 +587,56 @@
   },
   {
    "cell_type": "code",
-   "execution_count": null,
+   "execution_count": 20,
    "id": "1a218ce1",
    "metadata": {},
-   "outputs": [],
+   "outputs": [
+    {
+     "data": {
+      "text/plain": [
+       "True"
+      ]
+     },
+     "execution_count": 20,
+     "metadata": {},
+     "output_type": "execute_result"
+    }
+   ],
    "source": [
     "M.is_prime()"
    ]
   },
   {
    "cell_type": "code",
-   "execution_count": null,
+   "execution_count": 21,
    "id": "e737ac7f",
    "metadata": {
     "scrolled": true
    },
-   "outputs": [],
+   "outputs": [
+    {
+     "data": {
+      "text/plain": [
+       "[(Ideal (x + 9, y + 4) of Maximal order of Function field in y defined by y^2 + 10*x^3 + 7*x,\n",
+       "  1,\n",
+       "  1),\n",
+       " (Ideal (x + 9, y + 7) of Maximal order of Function field in y defined by y^2 + 10*x^3 + 7*x,\n",
+       "  1,\n",
+       "  1)]"
+      ]
+     },
+     "execution_count": 21,
+     "metadata": {},
+     "output_type": "execute_result"
+    }
+   ],
    "source": [
     "O.decomposition(M)"
    ]
   },
   {
    "cell_type": "code",
-   "execution_count": null,
+   "execution_count": 22,
    "id": "867a9f68",
    "metadata": {},
    "outputs": [],
@@ -434,10 +648,21 @@
   },
   {
    "cell_type": "code",
-   "execution_count": null,
+   "execution_count": 23,
    "id": "2a10bcd6",
    "metadata": {},
-   "outputs": [],
+   "outputs": [
+    {
+     "data": {
+      "text/plain": [
+       "(True, True, False)"
+      ]
+     },
+     "execution_count": 23,
+     "metadata": {},
+     "output_type": "execute_result"
+    }
+   ],
    "source": [
     "f = y - 2*x\n",
     "f in M, f in M^2, f in M^3"
@@ -445,10 +670,21 @@
   },
   {
    "cell_type": "code",
-   "execution_count": null,
+   "execution_count": 24,
    "id": "73406fd6",
    "metadata": {},
-   "outputs": [],
+   "outputs": [
+    {
+     "data": {
+      "text/plain": [
+       "2"
+      ]
+     },
+     "execution_count": 24,
+     "metadata": {},
+     "output_type": "execute_result"
+    }
+   ],
    "source": [
     "d = [i for i in range(1, 10) if f in M^i]\n",
     "max(d)"
@@ -466,10 +702,21 @@
   },
   {
    "cell_type": "code",
-   "execution_count": null,
+   "execution_count": 25,
    "id": "02ae75dc",
    "metadata": {},
-   "outputs": [],
+   "outputs": [
+    {
+     "data": {
+      "text/plain": [
+       "10*t^3 + 9*t^2"
+      ]
+     },
+     "execution_count": 25,
+     "metadata": {},
+     "output_type": "execute_result"
+    }
+   ],
    "source": [
     "K.<t> = GF(11)[]\n",
     "x = t + 2\n",
@@ -500,10 +747,31 @@
   },
   {
    "cell_type": "code",
-   "execution_count": null,
+   "execution_count": 26,
    "id": "3da404fc",
    "metadata": {},
-   "outputs": [],
+   "outputs": [
+    {
+     "data": {
+      "text/plain": [
+       "[Place (x, y),\n",
+       " Place (x + 3, y + 4),\n",
+       " Place (x + 3, y + 7),\n",
+       " Place (x + 5, y + 3),\n",
+       " Place (x + 5, y + 8),\n",
+       " Place (x + 7, y + 5),\n",
+       " Place (x + 7, y + 6),\n",
+       " Place (x + 9, y + 4),\n",
+       " Place (x + 9, y + 7),\n",
+       " Place (x + 10, y + 4),\n",
+       " Place (x + 10, y + 7)]"
+      ]
+     },
+     "execution_count": 26,
+     "metadata": {},
+     "output_type": "execute_result"
+    }
+   ],
    "source": [
     "K.<x> = FunctionField(GF(11))\n",
     "_.<Y> = K[]\n",
@@ -521,10 +789,21 @@
   },
   {
    "cell_type": "code",
-   "execution_count": null,
+   "execution_count": 27,
    "id": "f87c8b23",
    "metadata": {},
-   "outputs": [],
+   "outputs": [
+    {
+     "data": {
+      "text/plain": [
+       "Place (x + 9, y + 7)"
+      ]
+     },
+     "execution_count": 27,
+     "metadata": {},
+     "output_type": "execute_result"
+    }
+   ],
    "source": [
     "# I don't know how to actually construct this yet\n",
     "p = L.places_finite()[-3]\n",
@@ -533,10 +812,21 @@
   },
   {
    "cell_type": "code",
-   "execution_count": null,
+   "execution_count": 28,
    "id": "3d007b0b",
    "metadata": {},
-   "outputs": [],
+   "outputs": [
+    {
+     "data": {
+      "text/plain": [
+       "2"
+      ]
+     },
+     "execution_count": 28,
+     "metadata": {},
+     "output_type": "execute_result"
+    }
+   ],
    "source": [
     "(y - 2*x).valuation(p)"
    ]
@@ -552,7 +842,7 @@
  ],
  "metadata": {
   "kernelspec": {
-   "display_name": "SageMath 9.7",
+   "display_name": "SageMath 10.2",
    "language": "sage",
    "name": "sagemath"
   },
@@ -566,7 +856,7 @@
    "name": "python",
    "nbconvert_exporter": "python",
    "pygments_lexer": "ipython3",
-   "version": "3.10.7"
+   "version": "3.12.1"
   }
  },
  "nbformat": 4,