{ "cells": [ { "cell_type": "markdown", "metadata": {}, "source": [ "### Example 3.13 (Christol’s Open Question)\n", "Exploring Christol's function, studied as an explicit globally bounded D-finite function which may not be a rational diagonal. \n", "*Requirements: [ore_algebra package](https://github.com/mkauers/ore_algebra/)*" ] }, { "cell_type": "code", "execution_count": 1, "metadata": {}, "outputs": [], "source": [ "# Define the rings of differential and shift operators\n", "from ore_algebra import *\n", "Ind. = PolynomialRing(QQ); Shift. = OreAlgebra(Ind)\n", "Pols. = PolynomialRing(QQ); Diff. = OreAlgebra(Pols)" ] }, { "cell_type": "code", "execution_count": 2, "metadata": {}, "outputs": [ { "data": { "text/plain": [ "542421880/31381059609*z^4 + 3124550/129140163*z^3 + 2275/59049*z^2 + 20/243*z + 1" ] }, "execution_count": 2, "metadata": {}, "output_type": "execute_result" } ], "source": [ "# Initial series terms of Christol's function from its definition\n", "ser = add([rising_factorial(1/9,k)*rising_factorial(4/9,k)*rising_factorial(5/9,k)/rising_factorial(1/3,k)/rising_factorial(1,k) * z^k/factorial(k) for k in range(10)])\n", "ser.truncate(5)" ] }, { "cell_type": "code", "execution_count": 3, "metadata": {}, "outputs": [ { "data": { "text/html": [ "" ], "text/latex": [ "\\begin{math}\n", "\\newcommand{\\Bold}[1]{\\mathbf{#1}}\\frac{c_{n+1}}{c_n} = \\frac{(n + 1/9) (n + 4/9) (n + 5/9)}{(n + 1/3) (n + 1)^2}\n", "\\end{math}" ], "text/plain": [ "\\frac{c_{n+1}}{c_n} = \\frac{(n + 1/9) (n + 4/9) (n + 5/9)}{(n + 1/3) (n + 1)^2}" ] }, "metadata": {}, "output_type": "display_data" } ], "source": [ "# By the definition of the factorial and rising factorial, the coefficients of Christol's function satisfy\n", "show(LatexExpr(\"\\\\frac{c_{n+1}}{c_n} = \\\\frac{(n + 1/9) (n + 4/9) (n + 5/9)}{(n + 1/3) (n + 1)^2}\"))" ] }, { "cell_type": "code", "execution_count": 4, "metadata": {}, "outputs": [ { "data": { "text/plain": [ "(729*n^3 + 1701*n^2 + 1215*n + 243)*Sn - 729*n^3 - 810*n^2 - 261*n - 20" ] }, "execution_count": 4, "metadata": {}, "output_type": "execute_result" } ], "source": [ "# Thus, the coefficient sequence satisfies the recurrence defined by the operator\n", "rec = 729 * (n + 1/3) * (n + 1)^2 * Sn - 729 *(n + 1/9) * (n + 4/9) * (n + 5/9)\n", "rec" ] }, { "cell_type": "code", "execution_count": 5, "metadata": {}, "outputs": [ { "data": { "text/plain": [ "(-729*z^4 + 729*z^3)*Dz^4 + (-5913*z^3 + 3888*z^2)*Dz^3 + (-10791*z^2 + 3645*z)*Dz^2 + (-3620*z + 243)*Dz - 20" ] }, "execution_count": 5, "metadata": {}, "output_type": "execute_result" } ], "source": [ "# This implies the generating function satisfies the D-finite equation defined by the operator\n", "diff = rec.to_D(Diff)\n", "diff" ] }, { "cell_type": "code", "execution_count": 6, "metadata": {}, "outputs": [ { "data": { "text/plain": [ "(729*z^3 - 729*z^2)*Dz^3 + (2997*z^2 - 1701*z)*Dz^2 + (1800*z - 243)*Dz + 20" ] }, "execution_count": 6, "metadata": {}, "output_type": "execute_result" } ], "source": [ "# The differential equation listed in the textbook corresponds to the following operator\n", "text_diff = 729*z^2*(z-1)*Dz^3 + 81*z*(37*z-21)*Dz^2 + 9*(200*z-27)*Dz + 20\n", "text_diff" ] }, { "cell_type": "code", "execution_count": 7, "metadata": {}, "outputs": [ { "data": { "text/plain": [ "(-z*Dz - 1, 0)" ] }, "execution_count": 7, "metadata": {}, "output_type": "execute_result" } ], "source": [ "# The textbook differential equation is a right factor of the differential equation calculated here\n", "diff.quo_rem(text_diff)" ] }, { "cell_type": "code", "execution_count": 8, "metadata": {}, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "1 + 20/243*z + 2275/59049*z^2 + 3124550/129140163*z^3 + O(z^4)\n", "1 + 20/243*z + 2275/59049*z^2 + 3124550/129140163*z^3 + O(z^4)\n" ] } ], "source": [ "# Thus, Christol's function satisfies the textbook differential equation if the textbook equation\n", "# has a solution with the same 4 initial series terms as Christol's function, which it does\n", "print(text_diff.power_series_solutions(5)[0])\n", "print(diff.power_series_solutions(5)[0])" ] }, { "cell_type": "code", "execution_count": 0, "metadata": {}, "outputs": [], "source": [] } ], "metadata": { "kernelspec": { "display_name": "SageMath 9.2", "language": "sage", "name": "sagemath" }, "language_info": { "codemirror_mode": { "name": "ipython", "version": 3 }, "file_extension": ".py", "mimetype": "text/x-python", "name": "python", "nbconvert_exporter": "python", "pygments_lexer": "ipython3", "version": "3.8.5" } }, "nbformat": 4, "nbformat_minor": 4 }