\documentclass[11pt,a4paper]{article} \usepackage{amssymb,amsmath,amsthm} \usepackage{mathrsfs} \usepackage[T1]{fontenc} \usepackage{lmodern,microtype} \usepackage[unicode,hidelinks,bookmarksnumbered]{hyperref} \hypersetup{ pdftitle={Atkin--Swinnerton-Dyer congruences for Kummer twists of Hauptmoduln}, pdfauthor={Matija Kazalicki and Sini\v{s}a Slijep\v{c}evi\'{c}} } \setlength{\emergencystretch}{1em} \topmargin=0cm \oddsidemargin0mm \textheight23.5cm \textwidth16cm \headsep0mm \headheight0mm \parskip 2pt \numberwithin{equation}{section} \newtheorem{thm}{Theorem}[section] \newtheorem{prop}[thm]{Proposition} \newtheorem{lemma}[thm]{Lemma} \newtheorem{corollary}[thm]{Corollary} \newtheorem{conjecture}[thm]{Conjecture} \newtheorem{introthm}{Theorem} \renewcommand{\theintrothm}{\Alph{introthm}} \theoremstyle{definition} \newtheorem{definition}[thm]{Definition} \newtheorem{assumption}[thm]{Assumption} \newtheorem{convention}[thm]{Convention} \begin{document} \title{Atkin--Swinnerton-Dyer congruences for Kummer twists of Hauptmoduln} \author{Matija Kazalicki and Sini\v{s}a Slijep\v{c}evi\'{c}} \date{} \maketitle \begin{abstract} We prove that the coefficients of $h=\sqrt{\Delta/E_4}=\sum_{n\geq1}b(n)q^{n/2}$ satisfy the Atkin--Swinnerton-Dyer congruence \[ b(mp^r)-a_p(g)b(mp^{r-1})+p^3 b(mp^{r-2})\equiv0\pmod{p^{3r}} \] for every prime $p\geq5$, $m\geq1$ prime to $p$, and $r\geq1$, with $b(x)=0$ for nonintegral $x$. Here $a_p(g)$ is the $p$th Hecke eigenvalue of the unique normalised newform $g$ of weight four and level $24$ with trivial character. Since $h$ branches at the elliptic point $\rho=e^{2\pi i/3}$, it is not a modular form. In a local uniformising chart of the double cover $s^2=1/j$ above $\rho$, the associated differential extends holomorphically across the ramification point. It defines a parabolic cohomology class with coefficients in the symmetric square of the elliptic local system. More generally, we study modular differentials twisted by rational powers of a Hauptmodul. When the differential is nonzero and square-integrable on the Kummer cover and the twisted parabolic cohomology consists of two lines of types $(k-1,0)$ and $(0,k-1)$, we prove three-term congruences modulo $p^{(k-1)r}$ at good primes of residue degree one. A comparison of crystalline and \'etale Frobenius identifies the polynomial of the recurrence with the Frobenius polynomial of a two-dimensional Galois representation. Our local criteria produce further examples, including $E_4j^{-a}$ for every rational $a$ with $1/35$, \[ \sum_{n=0}^{p-1} \frac{(\tfrac12)_n^2(\tfrac16)_n(\tfrac56)_n}{(n!)^4} \equiv \chi_{-3}(p)\,b(p)\pmod{p^3}, \] where $\chi_{-3}(p)=\bigl(\frac{-3}{p}\bigr)$, $(x)_n=x(x+1)\cdots(x+n-1)$ and $(x)_0=1$. For related congruences for Ap\'ery-like sequences, see \cite{locbib:Beukers1987,bib:kazalicki2019}. The three-term recurrence for $b(m),b(mp),b(mp^2),\ldots$ in Theorem~\ref{thm:introA} is the analogue of the congruences that Atkin and Swinnerton-Dyer \cite{locbib:AtkinSwinnertonDyer1971} observed for the Fourier coefficients of cusp forms on noncongruence subgroups. Scholl \cite{locbib:Scholl1985} used de Rham cohomology to prove a common $(2D+1)$-term congruence for a $D$-dimensional space of cusp forms. At good primes its coefficients are those of the Frobenius polynomial of the associated Galois representation. For three-term congruences in higher dimension and their relation to modularity, see \cite{bib:li2003i,bib:atkin2005,bib:long2007a} and the survey \cite{bib:li2013j}. Kazalicki and Scholl \cite{bib:kazalicki2013a} allowed poles at the cusps. Their description of de Rham cohomology by weakly holomorphic forms gives congruences under an integrality condition on the principal parts. More recently, Allen, Long and Saad \cite{bib:allen2025e} treated meromorphic modular forms with poles in the upper half-plane. The elliptic curves at the poles contribute additional Frobenius factors to the recurrence. Related congruences appear in work of Zhang \cite{Zhang} and in Bordignon's rigid cohomological treatment \cite{bib:bordignon2026a}. To see what happens to the differential at $\rho$, pull the double cover $s^2=1/j$ back to a small disc about $\rho$ in the upper half-plane. On the normalisation of this pullback we may choose a coordinate $u$ with $\tau-\rho=u^2$. The simple zero of $d\tau=2u\,du$ cancels the simple pole of $h$ in $u$. To vary this example, put $t=1/j$. The identities $h=E_4\sqrt t$ and $q\,d\log t/dq=E_6/E_4$ give \[ h\,\frac{dq}{q}=\frac{E_4^2}{E_6}\,t^{1/2}\frac{dt}{t}. \] The factor $t^{1/2}$ accounts for the change of sign around $\rho$. We may therefore vary the branching by replacing the square root with a rational power $t^a$ of a Hauptmodul. The modular form $E_4^2/E_6$ is replaced by a form $f$ of weight $k-2$. A rational factor $R(t)$ allows us to prescribe additional zeros or poles without changing the monodromy of $t^a$. \begin{definition}\label{def:introdatum} A \emph{Kummer twist datum} of integer weight $k\geq3$ is a tuple $(\Gamma,t,f,a,R)$ with the following properties. The group $\Gamma\subset\mathrm{PSL}_2(\mathbb R)$ is commensurable with $\mathrm{PSL}_2(\mathbb Z)$, contains a principal congruence subgroup, and has genus zero and a cusp of width one at infinity. The function $t$ is a Hauptmodul for $\Gamma$, and $f$ is a meromorphic modular form of weight $k-2$ on $\Gamma$ with a finite-order multiplier trivial on $\Gamma\cap\Gamma(n)$ for some $n$. The rational number $a=j/d$ lies in $(0,1)$ and is written in lowest terms, and $R\in\mathbb Q(t)$ is regular at $t=0$. There is an integer $M\ge1$ such that, writing $A=\mathbb Z[1/M]$, one has \[ t\in q+q^2A[[q]],\qquad f=F(t)\ \text{with }F\in1+tA[[t]],\qquad R(t)\in A[[t]] . \] \end{definition} The normalisation $t=q+O(q^2)$ determines a preferred branch of $t^a$ at the cusp. With $Q=q^{1/d}$, take $t^a=Q^{j}(t/q)^a$, where the last factor has constant term one. The coefficients in our congruences are those of the resulting differential in the cusp parameter, \[ \Phi=f\,R(t)\,t^a\frac{dt}{t} =f_\Phi(Q)\frac{dq}{q},\qquad f_\Phi(Q)=\sum_{N\geq1}c(N)Q^N. \] For the datum above, $f_\Phi=h$ and $c(N)=b(N)$. In the opening example the involution of the double cover sends the differential to its negative. To find a Frobenius relation for its coefficients, it therefore suffices to consider the part of cohomology on which this involution acts by $-1$. For a general exponent $a$, we describe the corresponding space on the $t$-line by first writing down the periods before twisting. On $E_\tau=\mathbb C/(\mathbb Z+\tau\mathbb Z)$, the invariant differential $dz$ has periods $1$ and $\tau$ along the standard cycles. Choose a local inverse $\tau=\tau(t)$ and write $F(t)=f(\tau(t))$. Evaluating $f(\tau)[dz]^{\otimes(k-2)}$ on symmetric products of these cycles gives the periods \[ F(t),\quad \tau(t)F(t),\quad\ldots,\quad \tau(t)^{k-2}F(t). \] These functions form a basis of solutions of a linear differential equation in $t$ of order $k-1$ with coefficients in $\mathbb Q(t)$. This is the Picard--Fuchs equation associated with $(t,f)$. Analytic continuation of its solutions defines a local system $\mathbb V_f$ on $U=\mathbb P^1\setminus S$, where $S$ consists of the singularities of the equation together with $0$ and $\infty$. Multiplying the solutions by a branch of $t^a$ gives the twisted local system $\mathbb W=\mathbb V_f\otimes\mathbb L_a$, where $\mathbb L_a$ is the line of branches of $t^a$. Its parabolic cohomology is \[ H_a=\operatorname{im}\bigl(H^1_c(U,\mathbb W)\longrightarrow H^1(U,\mathbb W)\bigr). \] These are precisely the classes whose restrictions to punctured neighbourhoods of the points of $S$ vanish. When $\dim H_a=2$, the Frobenius polynomial is quadratic, as in Theorem~\ref{thm:introA}. The next definition also specifies the Hodge types of the two lines and the behaviour of $\Phi$ at branch points and cusps. \begin{definition}\label{def:introadmissible} A Kummer twist datum is \emph{admissible} if $\Phi$ is nonzero and square-integrable on $s^d=t$, and \[ H_a=H_a^{k-1,0}\oplus H_a^{0,k-1},\qquad \dim_{\mathbb C}H_a^{k-1,0}=\dim_{\mathbb C}H_a^{0,k-1}=1 . \] \end{definition} In the examples, these conditions can be checked from local data. Square-integrability means that the coefficient of $d\tau$ has order greater than $-1$ at each interior point and the coefficient of $dq_c/q_c$ has positive order in a parameter $q_c$ at each cusp. Thus the order $-1/2$ at $\rho$ in Theorem~\ref{thm:introA} is allowed. The local monodromies determine $\dim H_a$. When the multiplier is real and $\dim H_a=2$, the two extreme Hodge types follow if the differentials for $a$ and $1-a$ are both nonzero and square-integrable (Proposition~\ref{prop:v5_hod_typ_win}). Let $L$ be the field generated over $\mathbb Q$ by the $d$th roots of unity and the multiplier values of $f$, adjoining also, for odd $k$, the square roots of the determinants of primitive integral matrices representing elements of $\Gamma$. We consider primes $\mathfrak P$ of $L$ of residue degree one over rational primes $p$ outside the explicit finite set $\Sigma$ of Definition~\ref{def:v5_exc_set_kum}. At such a prime Frobenius fixes the $d$th roots of unity and hence the Kummer character determined by $a$. In Theorem~\ref{thm:introA}, $L=\mathbb Q$ and $\Sigma=\{2,3\}$. \begin{introthm}\label{thm:introB} Let $(\Gamma,t,f,a,R)$ be an admissible Kummer twist datum of weight $k$. For every prime $\mathfrak P$ as above there are coefficients $A_{\mathfrak P}\in\mathcal O_L$ and $B_{\mathfrak P}\in L$ such that, for all $m\geq1$ prime to $p$ and $r\geq1$, \[ c(mp^r)-A_{\mathfrak P} c(mp^{r-1})+B_{\mathfrak P} c(mp^{r-2}) \equiv0\pmod{p^{(k-1)r}} . \] Here $c(x)=0$ for nonintegral $x$, and the congruence is read in $L_{\mathfrak P}=\mathbb Q_p$. There is a system of two-dimensional representations of $\operatorname{Gal}(\overline L/L)$ for which $X^2-A_{\mathfrak P} X+B_{\mathfrak P}$ is the characteristic polynomial of geometric Frobenius at $\mathfrak P$ in every $\lambda$-adic realisation with $\lambda\nmid p$. These realisations are unramified at $\mathfrak P$, and $B_{\mathfrak P}=\varepsilon(\mathfrak P)p^{k-1}$ for a single algebraic Hecke character $\varepsilon$ of $L$. If $L=\mathbb Q$, there is a normalised newform of weight $k$ whose Hecke polynomial equals $X^2-A_p X+B_p$ at every $p\notin\Sigma$. \end{introthm} Theorem~\ref{thm:introA} is the case $a=1/2$ of the family $h_a=E_4j^{-a}$, to which Theorem~\ref{thm:introB} applies for every rational $1/3-1$ at every $\tau_0\in\mathbb H$, where the order is taken in $\tau-\tau_0$ and may be fractional, and $\operatorname{ord}_c\Phi>0$ at every cusp $c$, in the local parameter of $\Gamma$ at $c$. \end{description} \end{definition} \subsection{Local criteria} \label{subsec:criteria} Local monodromy determines the rank in (R), and local orders of $\Phi$ determine square-integrability in (F). When the multiplier is real and the rank is two, the two lines in (P) follow if the differentials for $a$ and $1-a$ are both nonzero and square-integrable. We use the local exponents computed in Lemma~\ref{lem:v5_pic_fuc_loc}. Write $H_\Phi$ for the untwisted factor in the coefficient of $dq/q$. On a local branch of $t^a$ we have \[ H_\Phi(\tau)=\frac{1}{2\pi i}\,f(\tau)R(t(\tau))\frac{t'(\tau)}{t(\tau)}, \qquad f_\Phi(\tau)=H_\Phi(\tau)t(\tau)^a, \qquad \Phi=2\pi i\,f_\Phi(\tau)\,d\tau . \] Here $f_\Phi(\tau)$ denotes the local analytic coefficient. On the preferred branch at infinity its expansion in $Q=e^{2\pi i\tau/d}$ is the series $f_\Phi(Q)$ of Definition~\ref{def:v5_kum_twi_dat}. The function $H_\Phi$ is meromorphic of weight $k$ with multiplier $\chi_f$, and $|f_\Phi|=|H_\Phi|\,|t|^a$ is independent of the branch. \begin{lemma}\label{lem:v5_twi_par_rnk} Let $(\Gamma,t,f,a,R)$ be a Kummer twist datum, with singular set $S$, local systems $\mathbb V_f$, $\mathbb L_a$ and twisted parabolic cohomology $H_a$. Put $\mathbb W=\mathbb V_f\otimes\mathbb L_a$ and $U=\mathbb P^1\setminus S$. For $s\in S$ let $T_s$ be the local monodromy of $\mathbb W$ at $s$, acting on the stalk at a point near $s$, and $\mathbb W^{I_s}=\ker(T_s-1)$; define $\mathbb V_f^{I_s}$ in the same way. \begin{enumerate} \item The local monodromy of $\mathbb V_f$ at $t=0$ is unipotent, and $T_0$ has $e^{2\pi ia}\neq1$ as its only eigenvalue. In particular $\mathbb W^{I_0}=0$ and $H^0(U,\mathbb W)=0$. \item $\dim_{\mathbb C}H_a=(|S|-2)(k-1)-\sum_{s\in S}\dim\mathbb W^{I_s}$. \item For $s\in S\setminus\{0,\infty\}$, $\mathbb W^{I_s}\cong\mathbb V_f^{I_s}$. If moreover $\mathbb W^{I_\infty}=0$, then \[ \dim H_a=\sum_{s\in S\setminus\{0,\infty\}}\bigl(k-1-\dim\mathbb V_f^{I_s}\bigr). \] \end{enumerate} \end{lemma} \begin{proof} Item (2) is the dimension formula of Dettweiler and Wewers for parabolic cohomology on a punctured sphere \cite{bib:dettweiler2003a}, \S1.3. It is stated there under the vanishing of the invariants only; its proof also needs the vanishing of the coinvariants, and both hold here by (1). Items (1) and (3) are local. \emph{Proof of (1).} The cusp $\infty$ has width one and $t$ has a simple zero there, so $q$ is a holomorphic function of $t$ near $t=0$ with $q=t\,(1+O(t))$, and near $t=0$ \[ \tau=\frac1{2\pi i}\log t+\frac1{2\pi i}\log\frac qt , \] where the second term is holomorphic at $t=0$. The functions $f\tau^i=F(t)\tau^i$, $0\le i\le k-2$, are linearly independent, since a linear relation would make a nonzero polynomial in $\tau$ vanish on an open set; so they form a basis of the solutions on a slit punctured disc around $t=0$. Continuation once around $t=0$ in the positive sense fixes $F(t)$ and replaces $\tau$ by $\tau+1$. So the monodromy of $\mathbb V_f$ at $0$ is $F\tau^i\mapsto F(\tau+1)^i$, which is unipotent. Tensoring with $\mathbb L_a$, $T_0$ is $e^{2\pi ia}$ times a unipotent map, and $e^{2\pi ia}\neq1$ as $0-1$ if and only if $a<\nu_P/e_P+r_\infty=\rho_P+r_\infty$, by (1). For $\gamma$ in the preimage $\bar\Gamma$ of $\Gamma$ in $\mathrm{SL}_2(\mathbb R)$ the order at $\gamma\tau_P$ is the same, because $|f_\Phi(\gamma\tau)|=|\gamma_{21}\tau+\gamma_{22}|^k|f_\Phi(\tau)|$, the factor $\gamma_{21}\tau+\gamma_{22}$ has no zero near $\tau_P$, and $\gamma\tau-\gamma\tau_P$ vanishes to order one at $\tau_P$. Suppose now that $P=\sigma\infty$ is a cusp, with local parameter $q_P$. As $t$ has a simple pole at $P$ and $q_P$ is a local coordinate there, $t(\sigma\tau')=q_P^{-1}E(q_P)$ with $E$ holomorphic and $E(0)\neq0$. The four factors of \[ f_\Phi|_k\sigma=(f|_{k-2}\sigma)\cdot R(t\circ\sigma)\cdot(t\circ\sigma)^a\cdot\frac1{2\pi i}\frac{d}{d\tau'}\log t(\sigma\tau') \] have orders $\nu_P$, $r_\infty$, $-a$ and $0$ in $q_P$, the last because $\frac1{2\pi i}\frac d{d\tau'}\log t(\sigma\tau')=\frac1{h_P}q_P\frac{d}{dq_P}\log t(\sigma\tau')=\frac1{h_P}(-1+O(q_P))$. So $\operatorname{ord}_P\Phi=\nu_P+r_\infty-a$, and (F) at $P$ holds if and only if $a<\rho_P+r_\infty$, by (1). \emph{Proof of (4).} At $\tau_0\in\mathbb H\setminus\Gamma\tau_P$, $t$ is holomorphic and nonzero near $\tau_0$, so $t^a$ has a holomorphic branch without zeros there, and $\operatorname{ord}_{\tau_0}\Phi=\operatorname{ord}_{\tau_0}H_\Phi$ does not depend on $a$. At a cusp $c=\sigma\infty\notin\{\infty,P\}$, $t(c)\in\mathbb C^\times$, so $(t\circ\sigma)^a$ has a holomorphic branch near $q_c=0$ which is a unit there, and the order of $\Phi$ at $c$ is that of $H_\Phi|_k\sigma$. At the cusp $\infty$ write $t=q\,E(q)$ with $E(0)=1$: then $f=F(t)$ has order $0$, $\frac1{2\pi i}t'/t=q\frac{d}{dq}\log t=1+O(q)$, $R(t)$ has order $\operatorname{ord}_{t=0}R\geq0$, and $t^a=Q^jE^a$ has order $a$ in $q$; so $\operatorname{ord}_\infty\Phi=a+\operatorname{ord}_{t=0}R>0$. For the datum $(\Gamma,t,f,1-a,R)$, $\Phi\neq0$ still holds since $R\neq0$; its orders at the points of $\mathbb H$ not over $P$ and at the cusps other than $\infty,P$ are those of the original datum, it satisfies (F) at $\infty$, and by (3) it satisfies (F) at the points over $P$ when $1-a<\rho_P+r_\infty$. \end{proof} \begin{lemma}\label{lem:v5_hod_cls_twi} Let $(\Gamma,t,f,a,R)$ be a Kummer twist datum satisfying (F). Then $H_a^{0,k-1}\neq0$. If moreover $\chi_f$ takes real values, then $H_{1-a}^{k-1,0}\neq0$, where $H_{1-a}$ is the twisted parabolic cohomology of the datum $(\Gamma,t,f,1-a,R)$. \end{lemma} \begin{proof} The twisted differential, paired with the evaluation of germs of $\mathbb V_f\otimes\mathbb L_a$, is a square-integrable holomorphic $1$-form with values in the top Hodge bundle of the dual variation; by Lemma~\ref{lem:v5_com_var_zuc}(3) it is harmonic of extreme type, and conjugation carries its class into $H_a^{0,k-1}$. Throughout, $U=\mathbb P^1\setminus S$, $o:U\hookrightarrow\mathbb P^1$ is the inclusion, $\mathbb W=\mathbb V_f\otimes\mathbb L_a$ carries the polarised complex variation of weight $k-2$ of Lemma~\ref{lem:v5_hod_str_twi}(2), with $\mathcal P_{k-2}$, $\mathcal H^{p,q}_\tau$ and $h$ as there, and $H_a=H^1(\mathbb P^1,o_*\mathbb W)$ carries the Hodge decomposition of that item. \emph{The dual variation.} The dual $\mathbb W^\vee$ carries the dual variation, of weight $2-k$: $(\mathbb W^\vee)^{-p,-q}$ is the annihilator of $\bigoplus_{(p',q')\neq(p,q)}\mathbb W^{p',q'}$, and its form $h^\vee$ is transported from $h$ by the antilinear isomorphism $w\mapsto h(\,\cdot\,,w)$, which maps $\mathbb W^{p,q}$ onto $(\mathbb W^\vee)^{-p,-q}$. It is again polarised, its Hodge metric is the dual of that of $\mathbb W$, and its top piece is $F^0\mathbb W^\vee=(F^1\mathbb W)^\perp=(\mathbb W^\vee)^{0,2-k}$. \emph{(F) forces $R$ to be holomorphic on $U$,} which makes the form below holomorphic. Let $t_1\in U$ and suppose $R$ has a pole of order $r\geq1$ at $t_1$. Since the cusps map into $S$ by Lemma~\ref{lem:v5_pic_fuc_loc}(3), $t_1=t(\tau_1)$ with $\tau_1\in\mathbb H$, of stabiliser order $e_1$. Then $f$ has order $0$ at $\tau_1$ by Lemma~\ref{lem:v5_pic_fuc_loc}(3), $t-t_1$ has order $e_1$ and $t'/t$ order $e_1-1$, and $t^a$ is a unit near $\tau_1$; so $\operatorname{ord}_{\tau_1}\Phi=e_1(1-r)-1\le-1$, against (F). \emph{The form.} For $t_0\in U$ let $\mathrm{ev}_{t_0}\in\mathbb W_{t_0}^\vee$ be evaluation at $t_0$ of germs of $\mathbb W$, which are germs of holomorphic functions $t^ay$. In a flat frame $w_1,\dots,w_n$ of $\mathbb W$ on a disc, $\mathrm{ev}=\sum_iw_i(t)\,w_i^\vee$ with holomorphic coefficients, so $\mathrm{ev}$ is a holomorphic section of $\mathbb W^\vee\otimes\mathcal O_U$. It is nonzero, and it kills $F^1\mathbb W_{t_0}$, whose elements vanish at $t_0$; so it is a section of the top Hodge bundle $F^0\mathbb W^\vee$. Put \[ \omega_\Phi^{\mathrm{an}}=\frac1{2\pi i}\,R(t)\,\frac{dt}{t}\otimes\mathrm{ev}, \] a holomorphic section of $\Omega^1_U\otimes F^0\mathbb W^\vee$, nonzero because $R\neq0$ ($\Phi\neq0$ is part of (F)). For the germ $t^af$ of $\mathbb W$ near $t=0$, $\langle\omega_\Phi^{\mathrm{an}},t^af\rangle=\frac1{2\pi i}\Phi$. \emph{Square-integrability.} For $t_0=t(\tau_0)\in U$, the orthogonal complement of $F^1\mathbb W_{t_0}$ is the line $\mathcal H^{0,k-2}$ spanned by the germ $v_0=t^a f(\tau)(\tau-\bar\tau_0)^{k-2}$, of norm $(2\operatorname{Im}\tau_0)^{(k-2)/2}$, and $\mathrm{ev}_{t_0}(v_0)=t(\tau_0)^af(\tau_0)(\tau_0-\bar\tau_0)^{k-2}$. Hence \[ \|\mathrm{ev}_{t_0}\|^2=|t(\tau_0)|^{2a}|f(\tau_0)|^2(2\operatorname{Im}\tau_0)^{k-2} . \] The $L^2$ norm of a $(1,0)$-form does not depend on the conformal metric on $U$: for $\omega=\phi\,dt$ it is $\int\|\phi\|^2\,dA$, with $dA$ Lebesgue measure in the coordinate $t$. Pulling back by $t$, $\|\omega_\Phi^{\mathrm{an}}\|^2dA$ becomes $2^{k-2}|f_\Phi(\tau)|^2(\operatorname{Im}\tau)^{k-2}\,d\operatorname{Re}\tau\,d\operatorname{Im}\tau$, a $\Gamma$-invariant measure since $|f_\Phi(\gamma\tau)|=|\gamma_{21}\tau+\gamma_{22}|^k|f_\Phi(\tau)|$. As $\mathbb P^1$ is compact, $\|\omega_\Phi^{\mathrm{an}}\|_{L^2}<\infty$ if and only if the integral is finite near each point $t_1\in\mathbb P^1$. If $t_1=t(\tau_1)$ with $\tau_1\in\mathbb H$, a small disc $B$ around $\tau_1$ covers a punctured neighbourhood of $t_1$ exactly $e_1$ times, and $|f_\Phi|^2=|\tau-\tau_1|^{2\alpha}\times$(a positive continuous function) with $\alpha=\operatorname{ord}_{\tau_1}\Phi$; so the integral is finite if and only if $\alpha>-1$. If $t_1=t(c)$ for a cusp $c=\sigma\infty$ of width $h_c$, then $q_c$ is a local coordinate at $c$, a neighbourhood of $t_1$ is the image of $\{\sigma\tau':0\le\operatorname{Re}\tau'Y\}$, and the integral becomes $2^{k-2}\int|(f_\Phi|_k\sigma)(\tau')|^2(\operatorname{Im}\tau')^{k-2}d\operatorname{Re}\tau'\,d\operatorname{Im}\tau'$, with $|(f_\Phi|_k\sigma)(\tau')|=|b|e^{-2\pi\beta\operatorname{Im}\tau'/h_c}(1+o(1))$, $b\neq0$, $\beta=\operatorname{ord}_c\Phi$; it is finite if and only if $\beta>0$, since $k\geq2$. So (F) gives $\omega_\Phi^{\mathrm{an}}\in L^2$. \emph{Harmonicity.} We apply Lemma~\ref{lem:v5_com_var_zuc}(3) to $\mathbb W^\vee$, a polarised complex variation of weight $2-k$ whose local monodromies have roots of unity as eigenvalues (the inverses of those of $\mathbb W$), with $p_0=0$, and to $\omega_\Phi^{\mathrm{an}}$, a nonzero holomorphic section of $\Omega^1_U\otimes F^0\mathbb W^\vee$ which is square-integrable by the previous step. So $\omega_\Phi^{\mathrm{an}}$ is harmonic of type $(0+1,2-k+0)=(1,2-k)$, and its class is a nonzero element of $H^1(\mathbb P^1,o_*\mathbb W^\vee)^{1,2-k}$. \emph{Transfer to $H_a$.} Give $\overline{\mathbb W}$ the conjugate variation. The map $\overline{\mathbb W}\to\mathbb W^\vee$, $\bar w\mapsto h(\,\cdot\,,w)$, is a flat $\mathbb C$-linear isomorphism and an isometry for the Hodge metrics, and it maps $\overline{\mathbb W}^{q,p}=\overline{\mathbb W^{p,q}}$ onto $(\mathbb W^\vee)^{-p,-q}=(\mathbb W^\vee)^{q-k+2,p-k+2}$. By Lemma~\ref{lem:v5_com_var_zuc}(4) with $n=2-k$, $H^1(\mathbb P^1,o_*\overline{\mathbb W})^{k-1,0}$ is isomorphic to $H^1(\mathbb P^1,o_*\mathbb W^\vee)^{1,2-k}\neq0$. By Lemma~\ref{lem:v5_com_var_zuc}(2), complex conjugation of forms maps $H_a^{0,k-1}$ onto $H^1(\mathbb P^1,o_*\overline{\mathbb W})^{k-1,0}$. Hence $H_a^{0,k-1}\neq0$. \emph{The second assertion.} If $\chi_f$ is real-valued, then $\overline{\mathbb W}\cong\mathbb V_f\otimes\mathbb L_{1-a}$, preserving types and Hodge metrics, by Lemma~\ref{lem:v5_hod_str_twi}(3). So Lemma~\ref{lem:v5_com_var_zuc}(4) with $n=0$, together with the conjugation in Lemma~\ref{lem:v5_com_var_zuc}(2), gives $H_{1-a}^{k-1,0}\cong H^1(\mathbb P^1,o_*\overline{\mathbb W})^{k-1,0}=\overline{H_a^{0,k-1}}\neq0$, the Hodge decomposition of $H_{1-a}$ being that of Lemma~\ref{lem:v5_hod_str_twi}(2) for the datum $(\Gamma,t,f,1-a,R)$. \end{proof} \begin{prop}\label{prop:v5_hod_typ_win} Let $(\Gamma,t,f,a,R)$ be a Kummer twist datum such that $\chi_f$ takes real values, (R) holds, and both $(\Gamma,t,f,a,R)$ and $(\Gamma,t,f,1-a,R)$ satisfy (F). Then (P) holds: $H_a=H_a^{k-1,0}\oplus H_a^{0,k-1}$ with both summands of dimension one. \end{prop} \begin{proof} By Lemma~\ref{lem:v5_hod_cls_twi}, applied to $(\Gamma,t,f,a,R)$, which satisfies (F), $H_a^{0,k-1}\neq0$. The datum $(\Gamma,t,f,1-a,R)$ also satisfies (F), and $\chi_f$ is real-valued, so the second assertion of Lemma~\ref{lem:v5_hod_cls_twi}, applied to it, gives $H_{1-(1-a)}^{k-1,0}=H_a^{k-1,0}\neq0$. By Lemma~\ref{lem:v5_hod_str_twi}(2), $H_a=\bigoplus_{p+q=k-1}H_a^{p,q}$. Since $k\geq2$, the types $(k-1,0)$ and $(0,k-1)$ are distinct, so $\dim H_a^{k-1,0}+\dim H_a^{0,k-1}\geq2=\dim H_a$ by (R). Hence both have dimension one and all other $H_a^{p,q}$ vanish, which is (P). \end{proof} \subsection{When the expansion is modular} \label{subsec:non_modular} Since $t$ has no zeros in $\mathbb H$, the only possible interior branch points of $t^a$ lie over its pole $P$. At a lift of an interior $P$, the order of $t$ is $-e_P$, so the local exponent of $t^a$ is $-je_P/d$. This gives the following criterion for the modularity of $f_\Phi$. \begin{prop}\label{prop:v5_kum_ser_mod} Let $(\Gamma,t,f,a,R)$ be a Kummer twist datum with $\Phi\neq0$, write $a=j/d$ in lowest terms, and let $\bar\Gamma\subset\mathrm{SL}_2(\mathbb R)$ be the preimage of $\Gamma$. There is $y_0>0$ such that $f_\Phi(Q)$ converges for $|Q|y_0\}$. \begin{enumerate} \item If $P$ is not a cusp and $d\nmid e_P$, then for no $\lambda>0$ is there a meromorphic function on $\mathbb H$ which agrees with $\tau\mapsto f_\Phi(\lambda\tau)$ on a nonempty open subset of $\lambda^{-1}\mathcal H_{y_0}$. In particular $f_\Phi$ is not the restriction to $\mathcal H_{y_0}$ of a single-valued meromorphic function on $\mathbb H$, and it is not a meromorphic modular form, of any weight and multiplier system, for any subgroup of finite index in $\mathrm{SL}_2(\mathbb Z)$. \item If $P$ is a cusp or $d\mid e_P$, then $f_\Phi$ extends to a meromorphic function $G$ on $\mathbb H$, and there is a surjective character $\chi_a:\bar\Gamma\to\mu_d$ with $\chi_a(-1)=1$ and $\chi_a\bigl(\begin{smallmatrix}1&1\\0&1\end{smallmatrix}\bigr)=e^{2\pi ia}$ such that \[ G(\gamma\tau)=\chi_f(\gamma)\,\chi_a(\gamma)\,(\gamma_{21}\tau+\gamma_{22})^k\,G(\tau)\qquad\bigl(\gamma=(\gamma_{mn})\in\bar\Gamma\bigr). \] If moreover the datum satisfies (F), then $G$ is a cusp form of weight $k$ with trivial multiplier on the subgroup $\ker(\chi_f\chi_a)$ of finite index in $\bar\Gamma$; equivalently, a cusp form of weight $k$ and multiplier system $\chi_f$ on the subgroup $\ker\chi_a$, whose image in $\Gamma$ has index $d$. \end{enumerate} \end{prop} \begin{proof} The untwisted factor $H_\Phi$ is meromorphic on $\mathbb H$. It remains to determine when the preferred branch of $t^a$ at infinity extends to $\mathbb H$. \emph{The branch at infinity.} Since the cusp $\infty$ has width one, $q$ is a local coordinate of $X_\Gamma$ at $\infty$; as $t$ has a simple zero there, $t=q\,E(q)$ with $E$ holomorphic on a disc $|q|0$, and suppose that a meromorphic function $G_\lambda$ on $\mathbb H$ agrees with $f_\Phi(\lambda\,\cdot)$ on a nonempty open set $V\subset\lambda^{-1}\mathcal H_{y_0}$. Then $G(\tau)=G_\lambda(\tau/\lambda)$ is meromorphic on $\mathbb H$ and agrees with $f_\Phi$ on the nonempty open set $\lambda V\subset\mathcal H_{y_0}$. The function $u=G/H_\Phi$ is meromorphic on $\mathbb H$ and equals $\ell_a$ on $\lambda V$ minus the discrete zero set of $H_\Phi$. Hence $u^d-t^j$ is a meromorphic function on the connected set $\mathbb H$ vanishing on a nonempty open set, so $u^d=t^j$ on $\mathbb H$. Taking orders at $\tau_P$ gives \[ d\cdot\operatorname{ord}_{\tau_P}u=j\cdot\operatorname{ord}_{\tau_P}t=-je_P . \] So $d\mid je_P$, and since $\gcd(j,d)=1$, $d\mid e_P$, a contradiction. The case $\lambda=1$ is the statement about the restriction to $\mathcal H_{y_0}$. A meromorphic modular form for a subgroup of finite index in $\mathrm{SL}_2(\mathbb Z)$ is in particular a meromorphic function on $\mathbb H$, so $f_\Phi$ is not one. \emph{Proof of (2): a global branch of $t^a$.} Let $Z=\Gamma\tau_P$ if $P$ is not a cusp and $Z=\emptyset$ if $P$ is a cusp. Then $Z$ is closed and discrete in $\mathbb H$, and $t$ is holomorphic without zeros on $\mathbb H\setminus Z$. For a closed piecewise smooth path $\beta$ in $\mathbb H\setminus Z$, the argument principle in the simply connected domain $\mathbb H$ gives \[ \frac1{2\pi i}\oint_\beta\frac{t'}{t}\,d\tau=\sum_{z\in Z}n(\beta,z)\operatorname{ord}_zt=-e_P\sum_{z\in Z}n(\beta,z) \] (a finite sum; it is $0$ if $Z=\emptyset$), where $n(\beta,z)$ is the winding number. If $d\mid e_P$ then $ae_P\in\mathbb Z$, so $a\oint_\beta t'/t\,d\tau\in2\pi i\mathbb Z$ for every such $\beta$. Fix $\tau_1\in\mathcal H_{y_0}$ and a logarithm $L_1$ of $\ell_a(\tau_1)$. Then \[ \tilde\ell(\tau)=\exp\Bigl(L_1+a\int_{\tau_1}^{\tau}\frac{t'(\sigma)}{t(\sigma)}\,d\sigma\Bigr), \] integrated along any path in $\mathbb H\setminus Z$, is a well-defined holomorphic function without zeros on $\mathbb H\setminus Z$, with $\tilde\ell'/\tilde\ell=a\,t'/t$. On the connected set $\mathcal H_{y_0}$ also $\ell_a'/\ell_a=a\,t'/t$ (differentiate $\ell_a^d=t^j$), and $\tilde\ell(\tau_1)=\ell_a(\tau_1)$; so $\tilde\ell=\ell_a$ on $\mathcal H_{y_0}$, and $\tilde\ell^d=t^j$ on the connected set $\mathbb H\setminus Z$. Near $z\in Z$, $|\tilde\ell|=|t|^a$ is bounded by a constant times $|\tau-z|^{-ae_P}$ with $ae_P\in\mathbb Z$, so by Riemann's removable singularity theorem $\tilde\ell$ is meromorphic at $z$, with $\operatorname{ord}_z\tilde\ell=-ae_P$. Write $t^a:=\tilde\ell$, a meromorphic function on $\mathbb H$. Then $G:=H_\Phi\,t^a$ is meromorphic on $\mathbb H$ and $G=f_\Phi$ on $\mathcal H_{y_0}$. \emph{Proof of (2): the transformation law.} Let $\gamma\in\bar\Gamma$. Since $(t^a\circ\gamma)^d=t^j\circ\gamma=t^j=(t^a)^d$, the meromorphic function $(t^a\circ\gamma)/t^a$ takes values in $\mu_d$ on the connected set $\mathbb H\setminus(Z\cup\gamma^{-1}Z)$, hence is a constant $\chi_a(\gamma)\in\mu_d$. From $t^a\circ(\gamma\delta)=(t^a\circ\gamma)\circ\delta=\chi_a(\gamma)\,t^a\circ\delta=\chi_a(\gamma)\chi_a(\delta)\,t^a$, $\chi_a$ is a character; $\chi_a(-1)=1$ because $-1$ acts trivially on $\mathbb H$. For $T=\bigl(\begin{smallmatrix}1&1\\0&1\end{smallmatrix}\bigr)$, $\ell_a(\tau+1)=e^{2\pi ij/d}\ell_a(\tau)$, since $Q\mapsto e^{2\pi i/d}Q$ and $q$ is unchanged; so $\chi_a(T)=e^{2\pi ia}$ is a primitive $d$-th root of unity, $\chi_a$ is onto $\mu_d$, and the image of $\ker\chi_a$ in $\Gamma$ has index $d$. Differentiating $t(\gamma\tau)=t(\tau)$ gives $t'(\gamma\tau)=(\gamma_{21}\tau+\gamma_{22})^2t'(\tau)$; together with the transformation laws of $f$, $R(t)$ and $t^a$ this gives \[ G(\gamma\tau)=\chi_f(\gamma)\chi_a(\gamma)(\gamma_{21}\tau+\gamma_{22})^kG(\tau). \] As $\chi_f$ has finite order, $\Gamma_\Phi:=\ker(\chi_f\chi_a)$ has finite index in $\bar\Gamma$, and $G$ is invariant under the weight-$k$ slash action of $\Gamma_\Phi$. \emph{Proof of (2): cusp form under (F).} At $\tau_0\in\mathbb H$ the order of $G$ is an integer; (F) makes it $>-1$, hence $\geq0$, so $G$ is holomorphic on $\mathbb H$. Let $c=\sigma\infty$ be a cusp of $\Gamma$. The group $\sigma^{-1}\Gamma_\Phi\sigma$ has finite index in $\sigma^{-1}\bar\Gamma\sigma$, so it contains $\pm\bigl(\begin{smallmatrix}1&h'\\0&1\end{smallmatrix}\bigr)$ for some $h'>0$; hence $G|_k\sigma$ has period $2h'$ and a Laurent expansion in $e^{2\pi i\tau/(2h')}$ on a half-plane $\operatorname{Im}\tau>y_1$. This expansion has only finitely many negative terms: $H_\Phi$ is meromorphic at $c$, and $|t^a|=|t|^a$ grows at most like a power of $|e^{2\pi i\sigma^{-1}\tau/h_c}|^{-1}$ near $c$, because $t$ is meromorphic at $c$. By (F) all exponents in this expansion are positive, so $G|_k\sigma(\tau)\to0$ as $\operatorname{Im}\tau\to\infty$. The cusps of $\Gamma_\Phi$ are those of $\Gamma$, since the index is finite. Hence $G$ is a cusp form of weight $k$ with trivial multiplier on $\Gamma_\Phi$. The equivalent formulation follows from the transformation law, since $\chi_a$ is trivial on $\ker\chi_a$. \end{proof} \section{Integral models and the Kummer lattice} \label{sec:models} To apply Frobenius to $\Phi$ we need an integral model of the cover $s^d=t$, together with the elliptic family supplying its coefficients. Elements of $\Gamma$ may act on this family through isogenies. A modular model records the resulting action on the symmetric power, its normalisation with respect to the Weil pairing, and a cusp at which to recover $f_\Phi$. We construct such a model at every residue-degree-one prime above $p\notin\Sigma$. \subsection{Modular models} \label{subsec:modular_models} \begin{definition}\label{def:v5_mod_mod_kum} Let $(\Gamma,t,f,a,R)$ be a Kummer twist datum (Definition~\ref{def:v5_kum_twi_dat}) with field $L$ (Definition~\ref{def:v5_exc_set_kum}). Let $\mathfrak P$ be an unramified prime of $L$ of residue degree one over $p$. Then $L_{\mathfrak P}=\mathbb Q_p$. We write $\iota_{\mathfrak P}:L\hookrightarrow\mathbb Q_p$ for the corresponding embedding and $\mathcal O=\mathcal O_{L,(\mathfrak P)}\subset\mathbb Z_p$ for the localisation of $\mathcal O_L$ at $\mathfrak P$. The given inclusion $L\subset\mathbb C$ also defines $X'_{\mathbb C}=X'\otimes_{\mathcal O}\mathbb C$ for any $\mathcal O$-scheme $X'$. A \textbf{modular model} of the datum at $\mathfrak P$ is a tuple $(X',Z',E,G,\chi_G)$ with the following properties. \begin{description} \item[(M1)] $X'$ is a smooth proper curve over $\mathcal O$, whose fibres need not be geometrically connected; $Z'\subset X'$ is a closed subscheme \'etale over $\mathcal O$; and $E\to X'$ is a generalised elliptic curve, smooth over $Y'=X'\setminus Z'$, with Hodge bundle $\omega$, whose Kodaira--Spencer map $\omega^{\otimes2}\to\Omega^1_{X'/\mathcal O}(\log Z')$ is an isomorphism. For every finite unramified extension $W$ of $\mathbb Z_p$ and every $z\in Z'(W)$ there are a formal parameter $q_z$ of $X'_W$ along $z$, an element $\delta_z\in W^\times$ and an integer $m_z\geq1$ prime to $p$ such that the pull-back of $E$ to $\operatorname{Spf}W[[q_z]]$ is the Tate curve $\mathrm{Tate}(\delta_zq_z^{m_z})$. We write $H=H^1_{\mathrm{dR}}(E/X')(\log Z')$ for the canonical extension of the relative de Rham cohomology of $E|_{Y'}$, with its Gauss--Manin connection, Hodge filtration $\omega\subset H$ and structure of logarithmic $F$-crystal. \item[(M2)] $G$ is a finite group acting on $X'$ over $\mathcal O$, not necessarily faithfully, and preserving $Z'$. For each $g\in G$ there are an isogeny $\pi_g:E|_{Y'}\to g^*E|_{Y'}$ of elliptic curves over $Y'$, of degree prime to $p$, and $c_g\in L$ with $c_g^2=(\deg\pi_g)^{-(k-2)}$, such that the maps $c_g\operatorname{Sym}^{k-2}(\pi_g^*)$ extend to $g^*\operatorname{Sym}^{k-2}H\to\operatorname{Sym}^{k-2}H$ and form an action of $G$ on $\operatorname{Sym}^{k-2}H$ lifting the action on $X'$. This action is compatible with the connection, the Hodge filtration and the Frobenius, and preserves the pairing induced by the Weil pairing. The stabiliser in $G$ of every geometric point of $X'_{\mathbb F_p}$ has order prime to $p$. \item[(M3)] The Hauptmodul $t$ extends to a $G$-invariant morphism $t:X'\to\mathbb P^1_{\mathcal O}$ that induces an isomorphism $X'_L/G\cong\mathbb P^1_L$, whose divisor of zeros is supported on $Z'$, and whose reduction is non-constant on every connected component of $X'_{\mathbb F_p}$. \item[(M4)] For some connected component $X'_0$ of $X'_{\mathbb C}$, with stabiliser $G_0\subset G$, there are a torsion-free normal subgroup $\Gamma'\subset\Gamma$ of finite index, contained in $\ker\chi_f$ and in $\Gamma(n)$ for some $n\geq3$ or in $\Gamma_1(n)$ for some $n\geq5$, a surjection $G_0\to\Gamma/\Gamma'$, and an isomorphism $X'_0\cong\Gamma'\backslash\mathbb H^*$ carrying $t$ to the Hauptmodul, the action of $g\in G_0$ to $\tau\mapsto\gamma\tau$ for the image $\gamma\Gamma'$ of $g$, and $E|_{X'_0}$ to the universal generalised elliptic curve. Moreover $\chi_G:G\to L^\times$ is a character of finite order, and there is a rational section $f\omega^{\otimes(k-2)}$ of $\omega^{\otimes(k-2)}$ over $X'_L$, equal on $X'_0$ to $f(\tau)\,(2\pi i\,dz)^{\otimes(k-2)}$, with $g^*(f\omega^{\otimes(k-2)})=\chi_G(g)\,f\omega^{\otimes(k-2)}$ for all $g\in G$, where $g^*$ is the action of (M2) on $\omega^{\otimes(k-2)}=\operatorname{Fil}^{k-2}\operatorname{Sym}^{k-2}H$. \item[(M5)] There are a finite unramified extension $W$ of $\mathbb Z_p$, a point $\infty'\in Z'(W)$ with $t(\infty')=0$, a formal parameter $q'$ of $X'_W$ along $\infty'$ and an integer $w\geq1$ prime to $p$, such that over $\operatorname{Spf}W[[q']]$ one has $E=\mathrm{Tate}(q)$ with $q=q'^{\,w}$, the function $t$ is the $q$-expansion of the Hauptmodul (Definition~\ref{def:v5_kum_twi_dat}), and $f\omega^{\otimes(k-2)}=F(t)\,\omega_{\mathrm{can}}^{\otimes(k-2)}$. \end{description} \end{definition} We state existence first; the three lemmas behind it supply a Galois closure of modular function fields, a smooth integral model and prime-to-$p$ isogenies on that model. \begin{prop}\label{prop:v5_exi_mod_mod} Let $(\Gamma,t,f,a,R)$ be a Kummer twist datum, and let $\mathfrak P$ be a prime of $L$ of residue degree one over a prime $p\notin\Sigma$. Then the datum has a modular model at $\mathfrak P$. \end{prop} \begin{proof} The model is cut out of the curve of Lemma~\ref{lem:v5_smo_int_mod} by the constants in $L$; the substance is (M4), where the section $f\omega^{\otimes(k-2)}$ is shown to be rational and an eigensection of all of $G$. From $p\notin\Sigma$ we use only: $p\neq2,3$, $p\nmid Mn_\Gamma n_f$, and $p$ unramified in $L$. Then $\mathcal O=\mathcal O_{L,(\mathfrak P)}$ is a discrete valuation ring, unramified over $\mathbb Z_{(p)}$, with residue field $\mathbb F_p$. Fix an integer $m\geq3$ prime to $pn_\Gamma$, and let $n_1$, $\mathfrak F_n$, $\mathcal K$, $\kappa_0$, $\Gamma'$, $n_2$, $G^\flat$, $G^\flat_0$ and $D$ be as in Lemma~\ref{lem:v5_gal_clo_the}; $X''$, $Z''$, $E''$, $\alpha$, $X''_0$, $\infty''$, $w$ as in Lemma~\ref{lem:v5_smo_int_mod}; and $\pi_g$, $e_g$, $B_g$, $\hat G$ as in Lemma~\ref{lem:v5_iso_and_tam}. \emph{The model.} Let $\kappa_1=\kappa_0\cap L$, a subfield of $\mathbb C$ unramified at $p$, Galois over $\mathbb Q$. As $X''$ is smooth and proper with $H^0(X''_{\mathbb Q},\mathcal O)=\kappa_0$, $H^0(X''_{\mathcal O},\mathcal O)$ is the base change to $\mathcal O$ of the integral closure of $\mathbb Z_{(p)}$ in $\kappa_0$; it contains $\mathcal O_{\kappa_1,(p)}\otimes_{\mathbb Z_{(p)}}\mathcal O$, which is \'etale over $\mathcal O$ and split, as $\kappa_1\subset L$ is unramified at $p$. Let $e_1$ be its idempotent belonging to the identity of $\kappa_1$ (the multiplication map $\kappa_1\otimes_{\mathbb Q}L\to L$), and put $X'=e_1X''_{\mathcal O}$, open and closed in $X''_{\mathcal O}$; $Z'=Z''_{\mathcal O}\cap X'$, $E=E''|_{X'}$. The components of $X'_{\mathbb C}$ are those components of $X''_{\mathbb C}$ whose embedding $\kappa_0\to\mathbb C$ is the inclusion on $\kappa_1$; they include $X''_0$. Let $G\subset\hat G$ be the subgroup of $(g,\pi)$ with $g$ trivial on $\kappa_1$; it is the stabiliser of $X'$, and $G^\flat_0$ acts trivially on $\kappa_0$, so $G$ contains $G_0=\{(g,\pi):g\in G^\flat_0\}$. \emph{(M1)--(M3).} Smoothness, the cusp divisor, the Tate descriptions and the Kodaira--Spencer isomorphism follow from Lemma~\ref{lem:v5_smo_int_mod}(1) by flat base change. The action preserves $Z'$ by part (3) of that lemma. For $(g,\pi)\in G$, write $g=g_0d$ as in Lemma~\ref{lem:v5_gal_clo_the}(4). By Lemma~\ref{lem:v5_iso_and_tam}(1), $\deg\pi=e_{g_0}$ is the determinant of a primitive matrix representing an element of $\Gamma$, hence is prime to $p$. Its normalising factor $c=e_{g_0}^{-(k-2)/2}$ lies in $L$ by Definition~\ref{def:v5_exc_set_kum} and is a unit of $\mathcal O$. Part (2) of the isogeny lemma gives the action, its compatibility with the connection, filtration and Frobenius, and preservation of the Weil pairing; part (3) gives tame stabilisers, since $p\geq5$. This proves (M2). The properties of $t$ in (M3) follow from Lemma~\ref{lem:v5_smo_int_mod}(3), except for the quotient description. The surjection $G^\flat\to\operatorname{Gal}(\kappa_1/\mathbb Q)$ permutes the subschemes $e_\iota X''_L$ transitively; the stabiliser of $X'_L$ is the image of $G$, whose central elements $(1,\pm\mathrm{id})$ act trivially. Hence \[ X'_L/G\cong X''_L/G^\flat\cong\mathbb P^1_L. \] \emph{(M4), the analytic data.} Take $X'_0=X''_0$. Its stabiliser in $G$ is $G_0$, because $G^\flat$ acts on the components of $X''_{\mathbb C}$ through $\operatorname{Gal}(\kappa_0/\mathbb Q)$ simply transitively; and $G_0\to G^\flat_0\cong\Gamma/\Gamma'$ is onto (Lemma~\ref{lem:v5_gal_clo_the}(3)). By Lemma~\ref{lem:v5_gal_clo_the}(1), $\Gamma'$ is torsion-free, normal of finite index in $\Gamma$, and contained in $\ker\chi_f$ and in $\Gamma(m)$, $m\geq3$; by Lemma~\ref{lem:v5_smo_int_mod}(2) the isomorphism $X'_0\cong\Gamma'\backslash\mathbb H^*$ has the required properties. \emph{The section on $X'_0$ and the character on $G_0$.} Let $s_0=f(\tau)(2\pi i\,dz)^{\otimes(k-2)}$ on $X'_0$, a meromorphic, hence rational, section of $\omega^{\otimes(k-2)}$, since $f$ is a meromorphic form of weight $k-2$ invariant under $\Gamma'\subset\ker\chi_f$ (the elements of $\Gamma'\subset\Gamma(m)$ lift to matrices $\equiv I$ mod $m$). Let $(g,\pi)\in G_0$, with $g$ the image of $\gamma$ represented by the primitive $A=(A_{ij})$ of determinant $e$, and $\pi=\epsilon\pi_g$, $\epsilon=\pm1$, with $\pi_g$ as in Lemma~\ref{lem:v5_iso_and_tam}(1). Then $\pi^*(dz_{\gamma\tau})=\epsilon e\,(A_{21}\tau+A_{22})^{-1}dz_\tau$, so \[ \begin{aligned} (g,\pi)^*s_0&=e^{-\frac{k-2}2}\Bigl(\frac{\epsilon e}{A_{21}\tau+A_{22}}\Bigr)^{k-2}f(\gamma\tau)\,(2\pi i\,dz)^{\otimes(k-2)}\\ &=(f|_{k-2}\tilde\gamma)(\tau)\,(2\pi i\,dz)^{\otimes(k-2)}=\chi_f(\tilde\gamma)\,s_0, \end{aligned} \] where $\tilde\gamma=\epsilon A/\sqrt e\in\mathrm{SL}_2(\mathbb R)$ and $\chi_f$ is the multiplier system of $f$; its values lie in $L$ by Definition~\ref{def:v5_exc_set_kum}. Put $\chi(g,\pi)=\chi_f(\tilde\gamma)$; this is the eigenvalue of $(g,\pi)$ on $s_0$, so $\chi$ is a character of $G_0$. \emph{Transport by $D$.} For $d\in D$ let $\pi_d$ be the isomorphism of Lemma~\ref{lem:v5_iso_and_tam}(1) with $B_d=\delta_d$, where $\delta_d=\mathrm{diag}(1,u)$ is the element of $\mathrm{GL}_2(\mathbb Z/m)$ acting on $\mathfrak F_m$ as $d$ does (Lemma~\ref{lem:v5_gal_clo_the}, fact (c), in the normalisation of \cite{locbib:Shimura1971}); then $\hat D=\{(d,\pi_d)\}$ is a subgroup of $\hat G$, as $d\mapsto\delta_d$ is multiplicative. If $d\in D\cap G^\flat_0$, then $d$ is the image of some $\gamma\in\Gamma(n_1)$ (Lemma~\ref{lem:v5_gal_clo_the}(4)), represented by a matrix $\equiv I$ mod $n_1$, and $d$ fixes $\zeta_m\in \kappa_0$, so $\delta_d=I$; by uniqueness in Lemma~\ref{lem:v5_iso_and_tam}(1), $(d,\pi_d)=(g,\pi_g)$ with $\tilde\gamma\equiv I$ mod $n_f$, and $\chi(d,\pi_d)=1$ because $\chi_f$ is trivial on $\Gamma\cap\Gamma(n_f)$. Hence there is a unique section $s$ over $X''_{\mathbb C}$ with $s|_{X'_0}=s_0$ and $(d,\pi_d)^*s=s$ for all $d\in D$, as $D$ permutes the components transitively. \emph{$s$ is defined over $\mathbb Q$.} Near $\infty''$, under $\mathbb C/(\mathbb Z\tau+\mathbb Z)\cong\mathbb C^\times/q^{\mathbb Z}$, $z\mapsto e^{2\pi iz}$, one has $2\pi i\,dz=\omega_{\mathrm{can}}$, so $s=f(q)\,\omega_{\mathrm{can}}^{\otimes(k-2)}$ with $f(q)=F(t(q))\in\mathbb Q[[q]]$. Let $\varsigma\in\operatorname{Aut}(\mathbb C)$ and $\sigma=\varsigma|_{\mathbb Q(\zeta_{n_2})}$. For $h\in\mathcal K$, the expansion of $h$ at $\varsigma(\infty'')$ in $\varsigma(q'')$ is $\varsigma$ applied to its expansion at $\infty''$, which is the expansion of $d_\sigma(h)=h\circ d_\sigma^{-1}$ at $\infty''$; so $\varsigma(\infty'')=d_\sigma^{-1}(\infty'')$, with matching formal parameters. As $E''$ and $\pi_d$ come from $X(m)$, where $\pi_d$ is the identity on the underlying curves, the Tate curve $\mathrm{Tate}(q)$ and $\omega_{\mathrm{can}}$ are matched too. Hence $\varsigma(s)$ and $s$ have the same expansion $f(q)\omega_{\mathrm{can}}^{\otimes(k-2)}$ at $\varsigma(\infty'')$. Both are $\hat D$-invariant, the $(d,\pi_d)$ being defined over $\mathbb Q$; so $\varsigma(s)=s$ on the component of $\varsigma(\infty'')$ and then everywhere. So $s$ is a rational section of $\omega^{\otimes(k-2)}$ over $X''_{\mathbb Q}$. \emph{The character $\chi_G$.} Let $(g,\pi)\in G_0$ and write its action as $c\,\Pi$, with $c=e_g^{-(k-2)/2}$ and $\Pi=\operatorname{Sym}^{k-2}(\pi^*)\circ g^*$ defined over $\mathbb Q$. Regard $X''_{\mathbb Q}$ as a curve over $\kappa_0$; then $X'_0$ is its base change along $\kappa_0\subset\mathbb C$, $s$ is $\kappa_0$-rational, and $\Pi$ is $\kappa_0$-linear since $g$ fixes $\kappa_0$. So $\lambda=c^{-1}\chi(g,\pi)$, the eigenvalue of $\Pi$ on $s|_{X'_0}$, lies in $\kappa_0$, and also in $L$; so $\lambda\in \kappa_1$. Every component of $X'_{\mathbb C}$ is $\varsigma(X'_0)$ for some $\varsigma\in\operatorname{Aut}(\mathbb C)$ trivial on $\kappa_1$, and there $\Pi(s)=\varsigma(\lambda)s=\lambda s$. So $(g,\pi)^*s=\chi(g,\pi)s$ on $X'$. The elements $(d,\pi_d)$ with $d$ trivial on $\kappa_1$ fix $s$, and together with $G_0$ they generate $G$, by $G^\flat=G^\flat_0D$. Hence $f\omega^{\otimes(k-2)}:=s|_{X'_L}$ is an eigensection for all of $G$, and its eigenvalues define a character $\chi_G:G\to L^\times$ of finite order, extending $\chi$. This completes (M4). \emph{(M5).} Choose the embedding $\mathbb Z[\zeta_{n_2}]\to W$ of Lemma~\ref{lem:v5_smo_int_mod}(4) so that its restriction to $\mathcal O_{\kappa_1}$ factors through $\mathfrak P$. Then $\infty''$ is a point $\infty'\in Z'(W)$, $q'=q''$ and $w$ are as required with $p\nmid w$, $E=\mathrm{Tate}(q)$ with $q=q'^{\,w}$, $t$ is its $q$-expansion, and $f\omega^{\otimes(k-2)}=f(q)\omega_{\mathrm{can}}^{\otimes(k-2)}=F(t)\,\omega_{\mathrm{can}}^{\otimes(k-2)}$ by Definition~\ref{def:v5_kum_twi_dat}. \end{proof} \begin{lemma}\label{lem:v5_gal_clo_the} Let $(\Gamma,t,f,a,R)$ be a Kummer twist datum and $p$ a prime with $p\nmid n_\Gamma n_f$. Fix an integer $m\geq3$ prime to $pn_\Gamma$ and put $n_1=\operatorname{lcm}(m,n_\Gamma,n_f)$. For $n\geq1$ let $\mathfrak F_n$ be the field of meromorphic functions $h$ on $\mathbb H$ that are invariant under $\Gamma(n)$, meromorphic at the cusps, and have Fourier expansion at $\infty$ in $\mathbb Q(\zeta_n)((q^{1/n}))$, $\zeta_n=e^{2\pi i/n}$. Let $\mathcal K$ be the field generated by the functions $h\circ\gamma$ with $h\in\mathfrak F_{n_1}$ and $\gamma\in\Gamma$, let $\kappa_0$ be the algebraic closure of $\mathbb Q$ in $\mathcal K$, and put $\Gamma'=\bigcap_{\gamma\in\Gamma}\gamma\,\Gamma(n_1)\gamma^{-1}$. \begin{enumerate} \item $\Gamma'$ is a torsion-free normal subgroup of finite index in $\Gamma$, contained in $\Gamma(n_1)$, hence in $\Gamma(m)$ and in $\ker\chi_f$. There is an integer $n_2$, prime to $p$ and divisible by $n_1$, with $\Gamma(n_2)\subset\Gamma'$ and $\mathcal K\subset\mathfrak F_{n_2}$; in particular $\kappa_0\subset\mathbb Q(\zeta_{n_2})$. \item $\mathbb Q(t)\subset\mathfrak F_{n_1}\subset\mathcal K$, and $\mathcal K$ is a finite Galois extension of $\mathbb Q(t)$, namely the Galois closure of $\mathfrak F_{n_1}$ over $\mathbb Q(t)$. Put $G^\flat=\operatorname{Gal}(\mathcal K/\mathbb Q(t))$ and $G^\flat_0=\operatorname{Gal}(\mathcal K/\kappa_0(t))$. \item $[\mathcal K:\kappa_0(t)]=[\Gamma:\Gamma']$, and the compositum $\mathbb C\mathcal K$ is the field $\mathcal A(\Gamma')$ of $\Gamma'$-invariant meromorphic functions on $\mathbb H$ that are meromorphic at the cusps. The rule $\gamma\mapsto(u\mapsto u\circ\gamma^{-1})$ induces an isomorphism $\Gamma/\Gamma'\cong G^\flat_0$. \item For every $\sigma\in\operatorname{Gal}(\mathbb Q(\zeta_{n_2})/\mathbb Q)$, applying $\sigma$ to Fourier coefficients maps $\mathcal K$ onto itself and defines an element $d_\sigma\in G^\flat$. The group $D=\{d_\sigma\}$ satisfies $G^\flat=G^\flat_0D$, and $D\cap G^\flat_0$ is contained in the image of $\Gamma(n_1)$. \end{enumerate} \end{lemma} \begin{proof} \emph{Classical facts used.} For every $n\geq1$ \cite{locbib:Shimura1971}, \S\S6.1--6.2 (Theorem 6.6): (a) $\mathfrak F_n$ is a finite Galois extension of $\mathbb Q(j)$, $\mathbb Q(\zeta_n)$ is algebraically closed in $\mathfrak F_n$, and the compositum $\mathbb C\mathfrak F_n$ is $\mathcal A(\Gamma(n))$; (b) $h\circ\sigma\in\mathfrak F_n$ for $h\in\mathfrak F_n$ and $\sigma\in\mathrm{SL}_2(\mathbb Z)$, and applying $\sigma\in\operatorname{Gal}(\mathbb Q(\zeta_n)/\mathbb Q)$ to Fourier coefficients is an automorphism $h\mapsto h^\sigma$ of $\mathfrak F_n$; (c) $\operatorname{Gal}(\mathfrak F_n/\mathbb Q(j))\cong\mathrm{GL}_2(\mathbb Z/n)/\{\pm1\}$, where the class of $\sigma\in\mathrm{SL}_2(\mathbb Z)$ acts by $h\mapsto h\circ\sigma$ (up to the inversion fixed in loc. cit.) and $\mathrm{diag}(1,s)$ by $\zeta_n\mapsto\zeta_n^s$ on coefficients; in particular this action is faithful. We also use the Galois theory of branched coverings of compact Riemann surfaces: for a normal subgroup $\Delta$ of finite index in $\Gamma$, $\mathcal A(\Delta)$ is Galois over $\mathcal A(\Gamma)=\mathbb C(t)$ with group $\Gamma/\Delta$ acting by $u\mapsto u\circ\gamma^{-1}$, and an element $g\in\mathrm{PSL}_2(\mathbb R)$ with $u\circ g=u$ for all $u\in\mathcal A(\Delta)$ lies in $\Delta$ (these functions separate the points of $\Delta\backslash\mathbb H$, so $g\tau\in\Delta\tau$ for all $\tau$, and by a Baire argument $g\in\Delta$). Since $\Gamma(n_\Gamma)\subset\Gamma$ and $n_\Gamma\mid n_1$, we have $\Gamma(n_1)\subset\Gamma$, of finite index. \emph{Proof of (1).} The group $\Gamma'$ is normal in $\Gamma$ and contained in $\Gamma(n_1)$, which is torsion-free as $n_1\geq3$; since $n_f\mid n_1$ and $\chi_f$ is trivial on $\Gamma\cap\Gamma(n_f)$ (Definition~\ref{def:v5_kum_twi_dat}), $\Gamma'\subset\ker\chi_f$. We bound its level. By Lemma~\ref{lem:v5_pri_det_com}, applied to the prime $p\nmid n_\Gamma$, every $\gamma\in\Gamma$ is the image of $A/\sqrt e$ with $A\in M_2(\mathbb Z)$ primitive and $e=\det A>0$ prime to $p$. If $\delta=I+n_1eX\in\Gamma(n_1e)$ with $X\in M_2(\mathbb Z)$, then $\gamma^{-1}\delta\gamma=A^{-1}\delta A=I+n_1A^{\mathrm{adj}}XA\in\Gamma(n_1)$; so \[ \Gamma(n_1e)\subset\gamma\,\Gamma(n_1)\gamma^{-1}. \] The subgroup $\Gamma_{\mathbb Z}=\Gamma\cap\mathrm{PSL}_2(\mathbb Z)$ contains $\Gamma(n_\Gamma)$, hence has finite index in $\Gamma$, and it normalises $\Gamma(n_1)$. With representatives $\gamma_1,\dots,\gamma_r$ of $\Gamma/\Gamma_{\mathbb Z}$ and $e_i$ the corresponding determinants, $\Gamma'=\bigcap_i\gamma_i\Gamma(n_1)\gamma_i^{-1}$ has finite index in $\Gamma$ and contains $\Gamma(n_2)$ for $n_2=n_1e_1\cdots e_r$, which is prime to $p$. We show $\mathcal K\subset\mathfrak F_{n_2}$. Let $h\in\mathfrak F_{n_1}$ and $\gamma=\gamma_i\sigma$ with $\sigma\in\Gamma_{\mathbb Z}$. Write $A_i=\sigma_iB$ with $\sigma_i\in\mathrm{SL}_2(\mathbb Z)$ and $B=\bigl(\begin{smallmatrix}a&b\\0&d\end{smallmatrix}\bigr)$, $ad=e_i$ (Hermite normal form). By (b), $h_1=h\circ\sigma_i\in\mathfrak F_{n_1}$, say $h_1=\sum_kc_kq^{k/n_1}$ with $c_k\in\mathbb Q(\zeta_{n_1})$. Then \[ h\circ\gamma_i=h_1\circ B=\sum_kc_k\,\zeta_{n_1d}^{\,kb}\,q^{ka/(n_1d)}, \] whose coefficients lie in $\mathbb Q(\zeta_{n_1e_i})$ and whose exponents lie in $\frac1{n_1e_i}\mathbb Z$. As above $B\Gamma(n_1e_i)B^{-1}\subset\Gamma(n_1)$, so $h_1\circ B$ is invariant under $\Gamma(n_1e_i)$; it is meromorphic at the cusps, since $B$ permutes $\mathbb P^1(\mathbb Q)$. Hence $h\circ\gamma_i\in\mathfrak F_{n_1e_i}$, and by (b) $h\circ\gamma=(h\circ\gamma_i)\circ\sigma\in\mathfrak F_{n_1e_i}\subset\mathfrak F_{n_2}$. So $\mathcal K\subset\mathfrak F_{n_2}$, and $\kappa_0\subset\mathbb Q(\zeta_{n_2})$ by (a). \emph{Proof of (2).} $t$ is invariant under $\Gamma(n_\Gamma)\supset\Gamma(n_1)$, meromorphic at the cusps, and $t\in q+q^2\mathbb Z[\frac1M][[q]]$; so $t\in\mathfrak F_{n_1}$. The field $\mathfrak F_{n_2}$ is finite over $\mathbb Q(j)$ by (a), so it has transcendence degree one, $j$ is algebraic over $\mathbb Q(t)$, and $\mathfrak F_{n_2}\supset\mathcal K$ is finite over $\mathbb Q(t)$. For $\sigma\in\operatorname{Gal}(\mathbb Q(\zeta_{n_1})/\mathbb Q)$ and $\gamma\in\Gamma$, the map $\epsilon_{\sigma,\gamma}:h\mapsto h^\sigma\circ\gamma$ is a field embedding $\mathfrak F_{n_1}\to\mathcal K$ fixing $t$, by (b) and because $t^\sigma=t=t\circ\gamma$. These embeddings are pairwise distinct for distinct $(\sigma,\Gamma(n_1)\gamma)$: on $\zeta_{n_1}$ the embedding $\epsilon_{\sigma,\gamma}$ is $\sigma$, and if $h^\sigma\circ\gamma=h^\sigma\circ\gamma'$ for all $h$, then $u\circ\gamma'\gamma^{-1}=u$ for all $u\in\mathfrak F_{n_1}$, hence for all $u\in\mathcal A(\Gamma(n_1))=\mathbb C\mathfrak F_{n_1}$, so $\gamma'\gamma^{-1}\in\Gamma(n_1)$. Their number is $\varphi(n_1)[\Gamma:\Gamma(n_1)]$. On the other hand $[\mathbb Q(\zeta_{n_1})(t):\mathbb Q(t)]=\varphi(n_1)$ and, since $\mathbb Q(\zeta_{n_1})$ is algebraically closed in $\mathfrak F_{n_1}$ and we are in characteristic zero, $\mathfrak F_{n_1}$ and $\mathbb C$ are linearly disjoint over $\mathbb Q(\zeta_{n_1})$, so $[\mathfrak F_{n_1}:\mathbb Q(\zeta_{n_1})(t)]=[\mathcal A(\Gamma(n_1)):\mathbb C(t)]=[\Gamma:\Gamma(n_1)]$. Hence the $\epsilon_{\sigma,\gamma}$ are all the $\mathbb Q(t)$-embeddings of $\mathfrak F_{n_1}$ into an algebraic closure of $\mathbb Q(t)$ containing $\mathcal K$, and the Galois closure of $\mathfrak F_{n_1}$ is the compositum of their images $\mathfrak F_{n_1}^\sigma\circ\gamma=\mathfrak F_{n_1}\circ\gamma$, which is $\mathcal K$. \emph{Proof of (3).} For $\gamma\in\Gamma$ we have $\mathbb C(\mathfrak F_{n_1}\circ\gamma)=\mathcal A(\gamma^{-1}\Gamma(n_1)\gamma)$, and all these groups contain the normal subgroup $\Gamma'$. In the Galois extension $\mathcal A(\Gamma')/\mathbb C(t)$ with group $\Gamma/\Gamma'$, the compositum of the fixed fields $\mathcal A(\gamma^{-1}\Gamma(n_1)\gamma)$ is the fixed field of their intersection $\Gamma'$; so $\mathbb C\mathcal K=\mathcal A(\Gamma')$. As $\kappa_0$ is algebraically closed in $\mathcal K$, $[\mathcal K:\kappa_0(t)]=[\mathbb C\mathcal K:\mathbb C(t)]=[\Gamma:\Gamma']$. Each $\gamma\in\Gamma$ maps the generators $h\circ\gamma'$ of $\mathcal K$ to $h\circ(\gamma'\gamma^{-1})$, so $u\mapsto u\circ\gamma^{-1}$ is an automorphism of $\mathcal K$ fixing $\kappa_0(t)$. This gives a homomorphism $\Gamma\to G^\flat_0$, with kernel $\{\gamma:u\circ\gamma=u\text{ for all }u\in\mathcal A(\Gamma')\}=\Gamma'$, and it is onto because $|G^\flat_0|=[\mathcal K:\kappa_0(t)]=[\Gamma:\Gamma']$. \emph{Proof of (4).} By (b), $h\mapsto h^\sigma$ is an automorphism of $\mathfrak F_{n_2}$ fixing $t$; it maps $\mathcal K$ onto a $\mathbb Q(t)$-conjugate of $\mathcal K$ inside the algebraic extension $\mathfrak F_{n_2}$ of $\mathbb Q(t)$, which is $\mathcal K$ because $\mathcal K/\mathbb Q(t)$ is normal. So $d_\sigma\in G^\flat$, and $D$, the image of $\operatorname{Gal}(\mathbb Q(\zeta_{n_2})/\mathbb Q)$, is a subgroup. Restriction to $\kappa_0$ maps $G^\flat$ onto $\operatorname{Gal}(\kappa_0/\mathbb Q)$ with kernel $G^\flat_0$, and it maps $D$ onto $\operatorname{Gal}(\kappa_0/\mathbb Q)$, as $\kappa_0\subset\mathbb Q(\zeta_{n_2})$; so $G^\flat=G^\flat_0D$. Finally let $d_\sigma\in G^\flat_0$ be the image of $\gamma\in\Gamma$. Since $j$ has rational Fourier coefficients, $j\circ\gamma^{-1}=j^\sigma=j$, so $\gamma\in\mathrm{PSL}_2(\mathbb Z)$. On $\mathfrak F_{n_1}$ the element $\gamma^{-1}$ of $\mathrm{SL}_2(\mathbb Z/n_1)$ and the element $\mathrm{diag}(1,s)$, where $\sigma(\zeta_{n_1})=\zeta_{n_1}^s$, then act in the same way, so by (c) they agree in $\mathrm{GL}_2(\mathbb Z/n_1)/\{\pm1\}$; comparing determinants, $s\equiv1$ and $\gamma\in\Gamma(n_1)$. \end{proof} \begin{lemma}\label{lem:v5_smo_int_mod} Let $(\Gamma,t,f,a,R)$ be a Kummer twist datum and $p$ a prime with $p\nmid Mn_\Gamma n_f$, and let $m$, $n_2$, $\mathfrak F_n$, $\mathcal K$, $\kappa_0$, $\Gamma'$, $G^\flat$, $G^\flat_0$ and $D$ be as in Lemma~\ref{lem:v5_gal_clo_the}. Let $X(m)$ be the compactified moduli scheme over $\mathbb Z[\frac1m]$ of generalised elliptic curves with full level-$m$ structure, with cuspidal subscheme $Z(m)$, $Y(m)=X(m)\setminus Z(m)$, universal generalised elliptic curve $E_m$ and universal level structure $\alpha:(\mathbb Z/m)^2\xrightarrow{\sim}E_m[m]$ over $Y(m)$. Let $X''$ be the normalisation of $X(m)_{\mathbb Z_{(p)}}$ in $\mathcal K$ (via $\mathfrak F_m\subset\mathcal K$), $\phi:X''\to X(m)_{\mathbb Z_{(p)}}$, $Z''=\phi^{-1}(Z(m))_{\mathrm{red}}$, $Y''=X''\setminus Z''$ and $E''=\phi^*E_m$. \begin{enumerate} \item $X''$ is smooth and proper over $\mathbb Z_{(p)}$, $\phi$ is finite and \'etale over $Y(m)$, $Z''$ is \'etale over $\mathbb Z_{(p)}$, and $(X'',Z'',E'')$ satisfies (M1) with $\mathbb Z_{(p)}$ in place of $\mathcal O$. \item The connected components of $X''_{\mathbb C}$ correspond to the embeddings $\kappa_0\to\mathbb C$. On the component $X''_0$ belonging to the inclusion $\kappa_0\subset\mathbb C$ there is an isomorphism $X''_0\cong\Gamma'\backslash\mathbb H^*$ carrying $t$ to the Hauptmodul, $(E'',\alpha)$ to $\tau\mapsto(\mathbb C/(\mathbb Z\tau+\mathbb Z),\alpha_\tau)$ with $\alpha_\tau(x,y)=(x\tau+y)/m$, and the action of the image of $\gamma\in\Gamma$ in $G^\flat_0$ to $\tau\mapsto\gamma\tau$; an automorphism $g$ acts on functions by $u\mapsto u\circ g^{-1}$. \item $t$ extends to a finite morphism $t:X''\to\mathbb P^1_{\mathbb Z_{(p)}}$ whose divisor of zeros is supported on $Z''$ and whose reduction is non-constant on every connected component of $X''_{\mathbb F_p}$. Hence $X''$ is the normalisation of $\mathbb P^1_{\mathbb Z_{(p)}}$ in $\mathcal K$, $G^\flat$ acts on $X''$ over $\mathbb Z_{(p)}$ preserving $Z''$, and $t$ induces $X''_{\mathbb Q}/G^\flat\cong\mathbb P^1_{\mathbb Q}$. The group $D$ acts by automorphisms lying over automorphisms of $X(m)_{\mathbb Z_{(p)}}$. \item Let $\infty''$ be the image of $\infty$ on $X''_0$, $w$ the width of $\Gamma'$ at $\infty$, and $W$ the ring of Witt vectors of $\mathbb F_p(\zeta_{n_2})$, with $\mathbb Z[\zeta_{n_2}]\to W$ fixed. Then $p\nmid w$, $\infty''\in Z''(W)$, $q''=q^{1/w}$ is a formal parameter of $X''_W$ along $\infty''$, and over $\operatorname{Spf}W[[q'']]$ one has $E''=\mathrm{Tate}(q)$ with $q=q''^{\,w}$ and $t$ equal to its $q$-expansion. \end{enumerate} \end{lemma} \begin{proof} \emph{Facts on full level structures.} For $n\geq3$, $X(n)$ is smooth and proper over $\mathbb Z[\frac1n]$, $Y(n)$ is a fine moduli scheme, $E_n$ is a generalised elliptic curve, the cusps are finite \'etale over $\mathbb Z[\frac1n]$, each a spectrum of a cyclotomic extension, and at a cusp the formal parameter can be taken as $q^{1/n}$ with $E_n$ the Tate curve $\mathrm{Tate}(q)$; the Kodaira--Spencer map is an isomorphism $\omega^{\otimes2}\cong\Omega^1(\log Z(n))$ \cite{locbib:DeligneRapoport1973}, IV and VII; \cite{locbib:KatzMazur1985}, Ch.~4, 8 and 10; \cite{bib:kazalicki2013a}, \S2. For $m\mid n$ the forgetful map $X(n)\to X(m)$ is finite, and \'etale and Galois over $Y(m)$ with group $K_{n,m}=\ker(\mathrm{GL}_2(\mathbb Z/n)\to\mathrm{GL}_2(\mathbb Z/m))$ acting by $\alpha\mapsto\alpha\circ g$ (rigidity of level-$m$ structures, $m\geq3$; loc. cit.). Over $\mathbb C$, the standard component of $X(n)$ is $\Gamma(n)\backslash\mathbb H^*$ via $\tau\mapsto(\mathbb C/(\mathbb Z\tau+\mathbb Z),\alpha_\tau)$, the function field of $X(n)_{\mathbb Q}$ restricted to it is $\mathfrak F_n$, so that $X(n)_{\mathbb Q}$ is the normalisation of the $j$-line in $\mathfrak F_n$ and $\operatorname{Gal}(\mathfrak F_n/\mathfrak F_m)$ acts on $X(n)$ through $K_{n,m}$; and at the cusp $\sigma\infty$, $\sigma\in\mathrm{SL}_2(\mathbb Z)$, of the standard component the expansion of $h\in\mathfrak F_n$ in $q^{1/n}$ is the Fourier expansion of $h\circ\sigma$ (loc. cit., and \cite{locbib:Shimura1971}, \S6.1). \emph{Proof of (1).} By Lemma~\ref{lem:v5_gal_clo_the}(1), $\mathfrak F_m\subset\mathcal K\subset\mathfrak F_{n_2}$ with $m\mid n_2$ and $p\nmid n_2$. Let $\Delta=\operatorname{Gal}(\mathfrak F_{n_2}/\mathcal K)\subset K_{n_2,m}$. The normalisation of $X(m)_{\mathbb Z_{(p)}}$ in $\mathcal K=\mathfrak F_{n_2}^{\Delta}$ is the quotient $X''=X(n_2)_{\mathbb Z_{(p)}}/\Delta$. As $\Delta$ acts freely on $Y(n_2)$, $Y''=Y(n_2)/\Delta$ is finite \'etale over $Y(m)$, hence smooth over $\mathbb Z_{(p)}$. Let $\bar c$ be a geometric cusp of $X(n_2)$ over $\bar{\mathbb F}_p$ and $c\in X(n_2)(W')$, $W'=W(\bar{\mathbb F}_p)$, its unique lift. The stabiliser $S$ of $\bar c$ in $\Delta$ fixes $c$ and acts $W'$-linearly on $\widehat{\mathcal O}_{X(n_2)_{W'},\bar c}=W'[[u]]$, where $\delta u^{n_2}=q$ with $\delta\in W'^\times$; it fixes $j$, hence $q=1/j+744/j^2+\cdots$, hence $u^{n_2}$, and a $W'$-automorphism of $W'[[u]]$ fixing $u^{n_2}$ sends $u$ to $\zeta u$ with $\zeta\in\mu_{n_2}(W')$, because $p\nmid n_2$ and $1+uW'[[u]]$ has no prime-to-$p$ torsion. Elements acting trivially on $W'[[u]]$ act trivially on the component through $\bar c$, hence are trivial since $\Delta$ acts freely on $Y(n_2)$. So $S$ is cyclic of order $r\mid n_2$, and the completed local ring of $X''$ at the image of $\bar c$ is $W'[[u]]^S=W'[[u^r]]$. Hence $X''$ is smooth, $Z''=\{u^r=0\}$ locally, \'etale over $\mathbb Z_{(p)}$, and $E''=\mathrm{Tate}(q)$ with $q=\delta(u^r)^{n_2/r}$ and $p\nmid n_2/r$. Over the cusp $\phi(c)$ of $X(m)$ with parameter $q_m$, $\delta'q_m^m=q$, the map $\phi$ is $q_m\mapsto\varepsilon\,(u^r)^{n_2/(rm)}$ with $\varepsilon\in W'[[u^r]]^\times$, tamely ramified, so $\phi^*\Omega^1_{X(m)}(\log Z(m))=\Omega^1_{X''}(\log Z'')$, and the Kodaira--Spencer isomorphism pulls back, as in \cite{bib:kazalicki2013a}, \S2. $X''$ is proper, being finite over $X(m)$. This proves (1). \emph{Proof of (2).} $X''_{\mathbb Q}$ is normal and connected with function field $\mathcal K$, so $H^0(X''_{\mathbb Q},\mathcal O)=\kappa_0$ and the components of $X''_{\mathbb C}$ correspond to the embeddings of $\kappa_0$. The component for $\kappa_0\subset\mathbb C$ has function field $\mathcal K\otimes_{\kappa_0}\mathbb C$, whose image in the meromorphic functions on $\mathbb H$ is $\mathbb C\mathcal K=\mathcal A(\Gamma')$ by Lemma~\ref{lem:v5_gal_clo_the}(3); so it is $\Gamma'\backslash\mathbb H^*$, $t$ being the Hauptmodul. On it, $\phi$ is induced by $\mathfrak F_m\subset\mathcal K$, that is $\Gamma'\backslash\mathbb H^*\to\Gamma(m)\backslash\mathbb H^*$, $\tau\mapsto\tau$, which gives $(E'',\alpha)$. The image of $\gamma$ acts on $\mathcal K$ by $u\mapsto u\circ\gamma^{-1}$, so it induces $\tau\mapsto\gamma\tau$. \emph{Proof of (4).} The stabiliser of $\infty$ in $\Gamma'$ is generated by $\tau\mapsto\tau+w$, and $\Gamma(n_2)\subset\Gamma'$ gives $w\mid n_2$, so $p\nmid w$. The standard cusp of $X(n_2)$ lies over $W$, with formal neighbourhood $\operatorname{Spf}W[[q^{1/n_2}]]$ and $E_{n_2}=\mathrm{Tate}(q)$; its stabiliser in $\Delta$ corresponds to $\langle\tau\mapsto\tau+w\rangle/\langle\tau\mapsto\tau+n_2\rangle$ and acts by $q^{1/n_2}\mapsto\zeta q^{1/n_2}$, so the quotient is $\operatorname{Spf}W[[q^{1/w}]]$. The expansion of $t$ there is its Fourier expansion, by the facts above. \emph{Proof of (3).} Write $\operatorname{div}(t)=V+Z_0-Z_\infty$ on the regular two-dimensional scheme $X''$, with $V$ supported on $X''_{\mathbb F_p}$ and $Z_0$, $Z_\infty$ the closures of the zero and pole divisors of $t$ on $X''_{\mathbb Q}$. The elements $d_\sigma\in D$ of Lemma~\ref{lem:v5_gal_clo_the}(4) map $\mathfrak F_m$ to itself and fix $j$, so they induce automorphisms of $X(m)_{\mathbb Z_{(p)}}$ (normalisation of the $j$-line in $\mathfrak F_m$) and of $X''$ over them; they fix $t$, and they permute the components of $X''_{\mathbb C}$ transitively, because $D$ maps onto $\operatorname{Gal}(\kappa_0/\mathbb Q)$. Since $X''$ is smooth and proper over $\mathbb Z_{(p)}$, $H^0(X'',\mathcal O)$ is finite \'etale over $\mathbb Z_{(p)}$ and the components of the geometric special and generic fibres correspond to each other; so $D$ also permutes the components of $X''_{\mathbb F_p}$ transitively, and all multiplicities in $V$ are equal. On the component through $\infty''_{\mathbb F_p}$ the multiplicity is $0$: by (4), $t=q''^{\,w}\cdot v$ with $v\in W[[q'']]^\times$, because $t\in q+q^2\mathbb Z[\frac1M][[q]]$ and $p\nmid M$. Hence $V=0$. The zeros of $t$ on $X''_0$ are the cusps $\gamma\infty$, $\gamma\in\Gamma$, and on the other components their $D$-translates; so $Z_0\subset Z''$. We show $Z_0\cap Z_\infty=\emptyset$. Since $D$ acts over $\mathbb Z_{(p)}$ and fixes $t$, it suffices to show that $t$ is regular near the reduction of each cusp $c=\gamma\infty$ of $X''_0$. Choose $\sigma\in\mathrm{SL}_2(\mathbb Z)$ with $\sigma\infty=\gamma\infty$. Then $\beta=\gamma^{-1}\sigma$ fixes $\infty$ and is represented by $\bigl(\begin{smallmatrix}a&b\\0&d\end{smallmatrix}\bigr)$ with $ad$ dividing the determinant of the primitive integral matrix of $\gamma^{-1}$, hence prime to $p$ (Lemma~\ref{lem:v5_pri_det_com}). With $t=\sum_kc_kq^k$, $c_k\in\mathbb Z[\frac1M]$, \[ t\circ\sigma=t\circ\beta=\sum_kc_k\,\zeta_d^{\,kb}\,q^{ka/d}, \] which has $p$-integral coefficients. By the facts above this is the expansion of $t$ at the cusp $\sigma\infty$ of $X(n_2)$, so $t$ is regular near its reduction on $X(n_2)$, hence on the quotient $X''$. So $c\notin Z_\infty$ and its reduction is not on $Z_\infty$. At every point of the regular scheme $X''$ one of $t$, $1/t$ is therefore regular, so $t$ is a morphism to $\mathbb P^1_{\mathbb Z_{(p)}}$. Its reduction is non-constant on the component through $\infty''_{\mathbb F_p}$, as $t\equiv q''^{\,w}\bar v$, and hence on every component, by transitivity of $D$. So $t$ is proper and quasi-finite, hence finite. Being normal and finite over $\mathbb P^1_{\mathbb Z_{(p)}}$ with function field $\mathcal K$, $X''$ is the normalisation of $\mathbb P^1_{\mathbb Z_{(p)}}$ in $\mathcal K$, so $G^\flat=\operatorname{Gal}(\mathcal K/\mathbb Q(t))$ acts on it over $\mathbb P^1_{\mathbb Z_{(p)}}$. It preserves $Z''$: $G^\flat=G^\flat_0D$, $G^\flat_0$ acts on $X''_0$ through $\Gamma$, which permutes the cusps, $D$ preserves $\phi^{-1}(Z(m))$, and $Z''$ is the closure of the set of cusps of the generic fibre. Finally $X''_{\mathbb Q}$ is the normalisation of $\mathbb P^1_{\mathbb Q}$ in $\mathcal K$ and $\mathcal K^{G^\flat}=\mathbb Q(t)$, so $X''_{\mathbb Q}/G^\flat\cong\mathbb P^1_{\mathbb Q}$. \end{proof} \begin{lemma}\label{lem:v5_iso_and_tam} Let $X''$, $Y''$, $Z''$, $E''$ and $\alpha$ be as in Lemma~\ref{lem:v5_smo_int_mod}, for a Kummer twist datum $(\Gamma,t,f,a,R)$, a prime $p\nmid Mn_\Gamma n_f$ and the data $m$, $n_2$, $\Gamma'$, $G^\flat$, $G^\flat_0$ and $D$ of Lemma~\ref{lem:v5_gal_clo_the}; let $H''$ be the canonical extension of the relative de Rham cohomology of $E''|_{Y''}$, and for $g\in G^\flat$ put $\mathcal H_g=\operatorname{Hom}_{Y''}(E''|_{Y''},g^*E''|_{Y''})$. \begin{enumerate} \item For every $g\in G^\flat$, $\mathcal H_g$ is free of rank one, generated by an isogeny $\pi_g$, unique up to sign, of degree $e_g$ prime to $p$; there is $B_g\in\mathrm{GL}_2(\mathbb Z/m)$ with $\pi_g\circ\alpha=g^*\alpha\circ B_g$. If $g$ is the image of $\gamma\in\Gamma$, represented by a primitive $A=(A_{ij})\in M_2(\mathbb Z)$ of determinant $e$, then on $X''_0$ one may take $\pi_g$ to be $z\mapsto ez/(A_{21}\tau+A_{22})$, from $\mathbb C/(\mathbb Z\tau+\mathbb Z)$ to $\mathbb C/(\mathbb Z\gamma\tau+\mathbb Z)$, and $e_g=e$; for $g\in D$, $\pi_g$ is an isomorphism. \item Let $\hat G$ be the set of pairs $(g,\pi)$ with $g\in G^\flat$ and $\pi=\pm\pi_g$, with product $(g,\pi)(h,\pi')=(gh,\mu^{-1}\,h^*\pi\circ\pi')$, where $\mu>0$ is the integer making $\mu^{-1}h^*\pi\circ\pi'$ a generator of $\mathcal H_{gh}$. Then $\hat G$ is a central extension of $G^\flat$ by $\{(1,\pm\mathrm{id})\}$. Each $\pi^*$ extends to a map $g^*H''\to H''$ over $X''$, invertible over $\mathbb Z_{(p)}$, compatible with the connection, the Hodge filtration and the logarithmic $F$-crystal structure, with $\langle\pi^*x,\pi^*y\rangle=e_g\langle x,y\rangle$ for the Weil pairing; and $(g,\pi)\mapsto e_g^{-(k-2)/2}\operatorname{Sym}^{k-2}(\pi^*)$, with the positive square root, satisfies the cocycle rule of an action of $\hat G$ on $\operatorname{Sym}^{k-2}H''\otimes\mathbb Z_{(p)}[e_g^{1/2}:g\in G^\flat]$ lifting the action on $X''$. \item Assume $p\geq5$. For every geometric point $\bar x$ of $X''_{\mathbb F_p}$, the stabiliser of $\bar x$ in $\hat G$ has order prime to $p$: it divides $48$ if $\bar x\notin Z''$, and it divides $2n_2r$ for some $r$ prime to $p$ if $\bar x\in Z''$. \end{enumerate} \end{lemma} \begin{proof} \emph{Rank one.} $Y''_{\mathbb Q}$ is connected with function field $\mathcal K$, over which $E''$ has transcendental $j$-invariant, hence no complex multiplication; so $\operatorname{Hom}$ over the generic point, and a fortiori $\mathcal H_g$, is $0$ or free of rank one. Restriction from $Y''$ to $Y''_{\mathbb Q}$ is injective on $\mathcal H_g$, as $Y''$ is flat over $\mathbb Z_{(p)}$. \emph{Proof of (1) for $g\in G^\flat_0$.} Let $g$ be the image of $\gamma$, with $A$ and $e$ as stated; $p\nmid e$ by Lemma~\ref{lem:v5_pri_det_com}, and $\gcd(e,m)=1$ since the primes dividing $e$ divide $n_\Gamma$ (Lemma~\ref{lem:v5_pri_det_com} at primes $\ell\nmid n_\Gamma$). On $X''_0$, with $\Lambda_\tau=\mathbb Z\tau+\mathbb Z$ and $\Lambda_A=\mathbb Z(A_{11}\tau+A_{12})+\mathbb Z(A_{21}\tau+A_{22})$, we have $\Lambda_{\gamma\tau}=(A_{21}\tau+A_{22})^{-1}\Lambda_A$ and $e\Lambda_\tau\subset\Lambda_A$ of index $e$, so $z\mapsto ez/(A_{21}\tau+A_{22})$ is an isogeny $E''_\tau\to E''_{\gamma\tau}=(g^*E'')_\tau$ of degree $e$ with cyclic kernel (Lemma~\ref{lem:v5_smo_int_mod}(2)). It depends holomorphically on $\tau$ and is compatible with $\Gamma'$, as $\gamma\Gamma'\gamma^{-1}=\Gamma'$. For $v\in(\mathbb Z/m)^2$ (row vectors), $\pi(\alpha_\tau(v))=\alpha_{\gamma\tau}(vA^{\mathrm{adj}})$, because $(x',y')A=(x'A_{11}+y'A_{21},x'A_{12}+y'A_{22})$ gives $\alpha_{\gamma\tau}(v')=(A_{21}\tau+A_{22})^{-1}\cdot\frac1m\,\eta_\tau(v'A)$ with $\eta_\tau(x,y)=x\tau+y$, and $eA^{-1}=A^{\mathrm{adj}}$. So $\pi\circ\alpha=g^*\alpha\circ B_g$ with $B_g:v\mapsto vA^{\mathrm{adj}}$, invertible modulo $m$. The kernel of $\pi$ is a union of connected components of the finite \'etale group $E''[e]$ over $Y''_0$, so it is algebraic and defined over $\bar{\mathbb Q}$ (connected components of finite \'etale covers do not change from $\bar{\mathbb Q}$ to $\mathbb C$); let $C$ be it. The pairs $(E''/C,\bar\pi\circ\alpha\circ B_g^{-1})$, with $\bar\pi:E''\to E''/C$ the quotient, and $(g^*E'',g^*\alpha)$ are elliptic curves with level-$m$ structure over $Y''_{0,\bar{\mathbb Q}}$; their classifying morphisms to the fine moduli scheme $Y(m)$ agree on $\mathbb C$-points, hence agree, and the resulting unique isomorphism of pairs composed with $\bar\pi$ is $\pi$. So $\pi$ is algebraic over $\bar{\mathbb Q}$. For $\varsigma\in\operatorname{Gal}(\bar{\mathbb Q}/\mathbb Q)$, $\varsigma(\pi)$ is an isogeny of degree $e$ over $\varsigma(Y''_0)$ inducing the same $B_g$, since $E''$, $\alpha$ and $g$ are defined over $\mathbb Q$. On a connected component an isogeny of degree $e$ inducing $B_g$ is unique, by rank one and $-B_g\neq B_g$ ($m\geq3$). As the components of $Y''_{\bar{\mathbb Q}}$ are the conjugates of $Y''_0$, the conjugates of $\pi$ glue to a Galois-equivariant isogeny over $Y''_{\bar{\mathbb Q}}$, which descends to $Y''_{\mathbb Q}$. \emph{For $g\in D$.} By Lemma~\ref{lem:v5_smo_int_mod}(3), $g$ lies over an automorphism of $X(m)_{\mathbb Z_{(p)}}$ fixing $j$, that is (Lemma~\ref{lem:v5_gal_clo_the}, fact (c), at level $m$) the moduli automorphism $(E,\alpha)\mapsto(E,\alpha\circ\delta)$ for some $\delta\in\mathrm{GL}_2(\mathbb Z/m)$. So $g^*(E'',\alpha)\cong(E'',\alpha\circ\delta)$ canonically, which gives an isomorphism $\pi_g$ over $Y''$ with $B_g=\delta^{-1}$. For general $g=g_0d$ with $g_0\in G^\flat_0$, $d\in D$ (Lemma~\ref{lem:v5_gal_clo_the}(4)), the composite $d^*\pi_{g_0}\circ\pi_d$ lies in $\mathcal H_g$, has cyclic kernel of order $e_{g_0}$, and induces $B_{g_0}B_d$ on $m$-torsion. \emph{Extension over $Y''$ and generators.} Let $\pi$ be one of the isogenies above over $Y''_{\mathbb Q}$, of degree $e$ prime to $p$. Its kernel is a union of connected components of $E''[e]_{\mathbb Q}$; since $Y''$ is normal and $E''[e]$ is finite \'etale over $Y''$, its closure $\bar C$ is a finite \'etale subgroup. The pairs $(E''/\bar C,\bar\pi\circ\alpha\circ B^{-1})$ and $(g^*E'',g^*\alpha)$ over $Y''$ have classifying morphisms to $Y(m)_{\mathbb Z_{(p)}}$ that agree on the dense open $Y''_{\mathbb Q}$; as $Y''$ is reduced and $Y(m)$ separated, they agree, and $\pi$ extends to $Y''$. Its kernel is cyclic, so $\pi$ is not a multiple of another isogeny, and it generates $\mathcal H_g$. This proves (1). \emph{Proof of (2).} By rank one, $h^*\pi\circ\pi'=\lambda\pi_{gh}$ with $\lambda\in\mathbb Z\setminus\{0\}$, $\lambda^2e_{gh}=e_ge_h$, so $\mu=|\lambda|$ is well defined; associativity follows from that of composition, and $(1,-\mathrm{id})$ is central. Over $Y''$, $\pi^*$ on de Rham cohomology is horizontal, preserves the Hodge filtration $\omega$, commutes with the crystalline Frobenius by functoriality of crystalline cohomology for morphisms of abelian schemes \cite{locbib:BerthelotOgus1978}, and satisfies $\langle\pi^*x,\pi^*y\rangle=\deg(\pi)\langle x,y\rangle$ since $\hat\pi\pi=[\deg\pi]$. At a cusp, over $\operatorname{Spf}W'[[u]]$ both curves are Tate curves $\mathrm{Tate}(q_1)$, $\mathrm{Tate}(q_2)$, and over the complete field $\operatorname{Frac}(W')((u))$ every homomorphism is induced by $x\mapsto x^{a}$ on $\mathbb G_m$ with $q_1^{a}=q_2^{c}$, $ac=\pm\deg\pi$ (Tate's uniformisation; \cite{locbib:DeligneRapoport1973}, VII). Then $\pi^*\omega_{\mathrm{can}}=a\,\omega_{\mathrm{can}}$, and horizontality with $\nabla\omega_{\mathrm{can}}=\xi_{\mathrm{can}}\otimes dq_i/q_i$ gives $\pi^*\xi_{\mathrm{can}}=c\,\xi_{\mathrm{can}}$; as $a,c$ divide $\deg\pi$, which is prime to $p$, $\pi^*$ maps the lattice spanned by $\omega_{\mathrm{can}},\xi_{\mathrm{can}}$, which is the canonical extension \cite{bib:kazalicki2013a}, \S2, isomorphically onto the corresponding lattice. So $\pi^*$ extends over $X''$, invertibly over $\mathbb Z_{(p)}$, and the compatibilities extend by density of $Y''$. Finally, for $(g,\pi)(h,\pi')=(gh,\pi'')$ with $\pi''=\mu^{-1}h^*\pi\circ\pi'$, the scalars satisfy $e_{gh}^{-(k-2)/2}\mu^{-(k-2)}=(e_ge_h)^{-(k-2)/2}$ because $\mu^2e_{gh}=e_ge_h$; hence $e_{gh}^{-(k-2)/2}\operatorname{Sym}^{k-2}(\pi''^*)=e_h^{-(k-2)/2}\operatorname{Sym}^{k-2}(\pi'^*)\circ h^*\bigl(e_g^{-(k-2)/2}\operatorname{Sym}^{k-2}(\pi^*)\bigr)$, the cocycle rule. \emph{Proof of (3).} Let $(g,\pi)$ fix $\bar x$. The components of $X''_{\bar{\mathbb F}_p}$ correspond to those of $X''_{\bar{\mathbb Q}_p}$, on which $G^\flat$ acts through $\operatorname{Gal}(\kappa_0/\mathbb Q)$ simply transitively; so $g\in G^\flat_0$. If $\bar x\in Z''$, its unique lift $x\in Z''(W')$ has the same stabiliser; after transport by $D$ and an embedding $W'\to\mathbb C$, $x$ is a cusp of $X''_0=\Gamma'\backslash\mathbb H^*$, and its stabiliser in $G^\flat_0\cong\Gamma/\Gamma'$ is generated by the image of a parabolic $P\in\Gamma$. Write $P=\sigma\bigl(\begin{smallmatrix}1&u/r\\0&1\end{smallmatrix}\bigr)\sigma^{-1}$ with $\sigma\in\mathrm{SL}_2(\mathbb Z)$ and $\gcd(u,r)=1$; then $r^2$ is the determinant of the primitive matrix of $P$, prime to $p$, and $P^{n_2r}\in\Gamma(n_2)\subset\Gamma'$. So the stabiliser in $\hat G$ has order dividing $2n_2r$. If $\bar x\notin Z''$, let $\bar E=E''_{\bar x}$; then $\pi_{\bar x}$ is an isogeny $\bar E\to E''_{g\bar x}=\bar E$, and $\theta:(g,\pi)\mapsto[\pi_{\bar x}]$ is a homomorphism from the stabiliser to $B^\times/\mathbb Q^\times$, $B=\operatorname{End}(\bar E)\otimes\mathbb Q$. Every element of $B^\times/\mathbb Q^\times$ of finite order $r$ comes from $x\in B^\times$ generating a quadratic field $F$, and $x/\bar x$ is then a root of unity of order $r$ in $F$, so $r\in\{1,2,3,4,6\}$. As $B$ is $\mathbb Q$, an imaginary quadratic field or a definite quaternion algebra, $B^\times/\mathbb Q^\times$ embeds in $(B\otimes\mathbb R)^\times/\mathbb R^\times\subset\mathrm{SO}(3)$, whose finite subgroups are cyclic, dihedral, $A_4$, $S_4$ or $A_5$; with element orders in $\{1,2,3,4,6\}$ the order divides $24$. If $\theta(g,\pi)=1$, then $\pi_{\bar x}=[\lambda]$ with $\lambda\in\mathbb Z$, and $\lambda\alpha_{\bar x}=\alpha_{\bar x}B_g$, so $B_g=\lambda$. Over $\widehat{\mathcal O}=\widehat{\mathcal O}_{X''_{W'},\bar x}$ the kernel of $\pi$ is the unique finite \'etale subgroup lifting $\bar E[\lambda]$, namely $E''[\lambda]$, so $\pi=u\circ[\lambda]$ for an isomorphism $u:E''\to g^*E''$ reducing to the identity, and $u\circ\alpha=g^*\alpha$. As $\phi$ is \'etale and $Y(m)$ is a fine moduli scheme, $\widehat{\mathcal O}$ pro-represents deformations of $(\bar E,\alpha_{\bar x})$, and the deformations $(E'',\alpha)$ and $g^*(E'',\alpha)$ are isomorphic; so $g$ induces the identity on $\widehat{\mathcal O}$, hence on the component of $X''_{W'}$ through $\bar x$. As $G^\flat_0\cong\Gamma/\Gamma'$ acts faithfully on each component, $g=1$, and the kernel of $\theta$ is $\{(1,\pm\mathrm{id})\}$. So the stabiliser has order dividing $48$. \end{proof} \subsection{The cover and the eigenlattice} \label{subsec:crystal} On the Kummer cover the twist becomes single-valued. Its differential transforms under the deck group by $\zeta\mapsto\zeta^j$. Together with the multiplier of $f$, this action singles out the integral lattice used in the Frobenius calculation. We fix one modular model for Sections~\ref{sec:models}--\ref{sec:trace}. \begin{definition}\label{def:v5_kum_cov_mod} Let $(X',Z',E,G,\chi_G)$ be a modular model, at a prime $\mathfrak P$ of $L$ of residue degree one over $p\notin\Sigma$, of a Kummer twist datum $(\Gamma,t,f,a,R)$ with $a=j/d$, with $\mathcal O=\mathcal O_{L,(\mathfrak P)}\subset\mathbb Z_p$, Hodge bundle $\omega$, $H$ as in (M1) and section $f\omega^{\otimes(k-2)}$ as in (M4). \begin{enumerate} \item The \textbf{Kummer cover} of the model is the normalisation $\rho:C\to X'$ of $X'$ in the \'etale $L(X')$-algebra $L(X')[s]/(s^d-t)$, where $L(X')$ is the ring of rational functions on $X'_L$. We put $D_C=\rho^{-1}(Z')_{\mathrm{red}}$, $Z_\infty=t^{-1}(\infty)_{\mathrm{red}}$, $P_C=\rho^{-1}(Z_\infty\setminus Z')_{\mathrm{red}}$ and $C_{\mathbb Z_p}=C\otimes_{\mathcal O}\mathbb Z_p$. \item The group $\tilde G=G\times\mu_d(L)$ acts on $C$: an element $g\in G$ through its action on $X'$ and fixing $s$, and $\zeta\in\mu_d(L)$ by $s\mapsto\zeta s$ over $X'$. The \textbf{twist character} is $\chi_\Phi:\tilde G\to L^\times$, $\chi_\Phi(g,\zeta)=\chi_G(g)\,\zeta^j$; through $\mathcal O\subset\mathbb Z_p$ it takes values in $\mathbb Z_p^\times$. \item $M_k=\operatorname{Sym}^{k-2}\rho^*H$, with the connection, the Hodge filtration $\operatorname{Fil}^iM_k=(\rho^*\omega)^{i}\cdot\operatorname{Sym}^{k-2-i}\rho^*H$ and the logarithmic $F$-crystal structure induced from $H$. The \textbf{twisted crystal} of the model is \[ H_{\mathbb Z}=\mathbb H^1\bigl(C_{\mathbb Z_p},\,M_k\xrightarrow{\ \nabla\ }M_k\otimes\Omega^1_{C/\mathbb Z_p}(\log D_C)\bigr). \] \item The \textbf{twisted differential on $C$} is the rational section \[ \omega_\Phi=\rho^*\bigl(f\omega^{\otimes(k-2)}\bigr)\otimes R(t)\,s^{j-1}\,ds \] of $\rho^*\omega^{\otimes(k-2)}\otimes\Omega^1_{C/\mathcal O}$. The normalisation $s^{j-1}\,ds=d^{-1}s^j\,dt/t$ makes its coefficient relative to $dQ/Q$ equal to $f_\Phi(Q)$, since $dq/q=d\,dQ/Q$. \end{enumerate} \end{definition} From here to the end of Section~\ref{sec:trace}, fix a Kummer twist datum $(\Gamma,t,f,a,R)$, a prime $\mathfrak P$ of $L$ of residue degree one over $p\notin\Sigma$, and a modular model $(X',Z',E,G,\chi_G)$ at $\mathfrak P$. Put $\mathcal O=\mathcal O_{L,(\mathfrak P)}$ and let $\iota_{\mathfrak P}:L\to\mathbb Q_p$ be the embedding defined by $\mathfrak P$. Let $\rho:C\to X'$ be its Kummer cover, with $D_C$, $P_C$, $M_k$, $H_{\mathbb Z}$, $\widetilde G$ and $\chi_\Phi$ as in its definition. Admissibility is assumed only where stated. \begin{lemma}\label{lem:v5_smo_kum_cov} \begin{enumerate} \item $Z_\infty$ is finite and \'etale over $\mathcal O_{L,(\mathfrak P)}$, and every branch point of $X'_{\mathbb C}\to\mathbb P^1_{\mathbb C}$ lies over $S$. \item $C$ is smooth and proper over $\mathcal O_{L,(\mathfrak P)}$, and $D_C\cup P_C$ is \'etale over $\mathcal O_{L,(\mathfrak P)}$. The ramification index of $\rho$ at every point of $D_C\cup P_C$ divides $d$, and $\rho$ is \'etale elsewhere. \end{enumerate} \end{lemma} \begin{proof} Item (1) rests on the tame stabilisers of (M2) and the collision clause of $\Sigma$ (distinct points of $S$ have distinct reductions at every prime above $p$); item (2) then follows from a local computation of the Kummer extension, which is tame as $p\nmid d$. We use (M1)--(M4) of Definition~\ref{def:v5_mod_mod_kum}, and from $p\notin\Sigma$ only $p\neq2,3$, $p\nmid d$ and the collision clause. \emph{Branch points lie over $S$.} Since $X'_L/G\cong\mathbb P^1_L$ is geometrically connected, $G$ permutes the connected components of $X'_{\mathbb C}$ transitively, so the branch points of $X'_{\mathbb C}\to\mathbb P^1_{\mathbb C}$ are those of $X'_0\to X'_0/G_0$. By (M4) this map is $\Gamma'\backslash\mathbb H^*\to\Gamma\backslash\mathbb H^*$, $t$ being the coordinate on the target. As $\Gamma'$ is torsion-free, a point of $\Gamma'\backslash\mathbb H$ has nontrivial stabiliser in $\Gamma/\Gamma'$ only if it lies over an elliptic point of $\Gamma$; so the branch points lie over elliptic points and cusps of $\Gamma$. We show that their $t$-values are in $S$. By Definition~\ref{def:v5_twi_par_coh}, $\mathbb V_f$ is spanned by $f,\tau f,\dots,\tau^{k-2}f$, and continuation along the loop around $t(\tau_1)$ attached to $\gamma=\pm(\gamma_{ij})\in\Gamma$ fixing $\tau_1$ sends $\tau^if$ to $\chi_f(\gamma)(\gamma_{11}\tau+\gamma_{12})^i(\gamma_{21}\tau+\gamma_{22})^{k-2-i}f$; so the local monodromy is $\chi_f(\gamma)\operatorname{Sym}^{k-2}$ of a matrix representing $\gamma$, up to transposition. If $\tau_1$ is elliptic of order $e\geq2$, the matrix has eigenvalues $\varepsilon^{\pm1}$ with $\varepsilon^2\neq1$, and $\operatorname{Sym}^{k-2}$ has the distinct eigenvalues $\varepsilon^{k-2}$, $\varepsilon^{k-4}$ (as $k\geq3$), so the monodromy is not the identity. At a cusp the matrix is unipotent and $\neq\pm1$, so $\operatorname{Sym}^{k-2}$ of it is a nontrivial unipotent ($k\geq3$) and its product with a scalar is not the identity. Hence these points are singular points of $\mathbb V_f$ and their $t$-values lie in $S$. \emph{Proof of (1).} The reduction of $t$ is non-constant on every component of $X'_{\mathbb F_p}$ (M3), so $t$ is a unit at the generic points of $X'_{\mathbb F_p}$, its divisor has no vertical component, and $Z_\infty$ is the closure in $X'$ of the finite set $t^{-1}(\infty)_L$. Thus $Z_\infty$ is finite and flat over $\mathcal O_{L,(\mathfrak P)}$, with reduced generic fibre, and it is \'etale if and only if no two distinct points of $Z_\infty(\bar{\mathbb Q}_p)$ have the same reduction in $X'(\bar{\mathbb F}_p)$ (reduction is defined because $X'$ is proper). Suppose $x_1\neq x_2$ in $Z_\infty(\bar{\mathbb Q}_p)$ reduce to the same point $\bar x$. As $X'_{\bar{\mathbb Q}_p}\to\mathbb P^1_{\bar{\mathbb Q}_p}$ is the quotient by $G$, there is $g\in G$ with $gx_1=x_2$. Reduction commutes with $G$, which acts over $\mathcal O_{L,(\mathfrak P)}$, so $g\bar x=\bar x$. Let $\bar S$ be the stabiliser of $\bar x$; then $\mathrm{Stab}(x_1)\subsetneq\bar S$, since $g\in\bar S$, and $|\bar S|$ is prime to $p$ by (M2). Next, $\bar x$ lifts to a point fixed by $\bar S$. Let $W=W(\bar{\mathbb F}_p)$. The completed local ring of $X'_W$ at $\bar x$ is $W[[\pi]]$, on which $\bar S$ acts $W$-linearly. It acts on the line $\mathfrak m/(\mathfrak m^2+p)$ through a character, which lifts to $\chi:\bar S\to W^\times$ by Teichm\"uller lifting; as $|\bar S|$ is invertible, $\pi'=|\bar S|^{-1}\sum_{h\in\bar S}\chi(h)^{-1}h(\pi)$ is again a parameter, $W[[\pi]]=W[[\pi']]$, and $h(\pi')=\chi(h)\pi'$. The ideal $(\pi')$ is $\bar S$-stable, so it defines $y\in X'(W)$ with reduction $\bar x$ and $\bar S\subset\mathrm{Stab}(y)$; conversely $\mathrm{Stab}(y)\subset\bar S$, so $\mathrm{Stab}(y)=\bar S$. Let $K=W[1/p]$. The points $y$ and $x_1$ reduce to the same point $\bar x$ of the smooth special fibre, so they lie on the same connected component $X'_1$ of $X'_{\bar K}$. Let $G_1$ be the stabiliser of $X'_1$ in $G$ and $N_1$ the kernel of its action on $X'_1$; since $\mathrm{Stab}(y)$ and $\mathrm{Stab}(x_1)$ lie in $G_1$, the ramification indices of $X'_1\to X'_1/G_1=\mathbb P^1_{\bar K}$ at $y$ and at $x_1$ are $|\bar S|/|N_1|$ and $|\mathrm{Stab}(x_1)|/|N_1|$, and the first is the larger. So $y$ is a ramification point of $X'_{K}\to\mathbb P^1_K$; the ramification points are defined over $\bar{\mathbb Q}$, so $t(y)\in\bar{\mathbb Q}$, and by the first step $t(y)\in S$. Moreover $t(y)\neq\infty$: the points over $\infty$ form one $G$-orbit, whose stabilisers are conjugate to $\mathrm{Stab}(x_1)$ and so have fewer than $|\bar S|$ elements. But $t(y)$ and $\infty$ have the same reduction $t(\bar x)$. So two points of $S$ have the same reduction at a prime above $p$, and $p\in\Sigma$, a contradiction. Hence $Z_\infty$ is \'etale. \emph{Proof of (2).} Let $Z_0=t^{-1}(0)_{\mathrm{red}}$. By (M3) and the absence of vertical components, $Z_0$ is a union of connected components of $Z'$, hence \'etale, and $Z_0\cap Z_\infty=\emptyset$ because $t$ is a morphism. So $B=Z_0\cup Z_\infty$ is \'etale over $\mathcal O_{L,(\mathfrak P)}$. Let $\bar x$ be a closed point of $X'_{\mathbb F_p}$ and $\mathcal O$ its local ring, regular of dimension $2$. If $\bar x\notin B$, then $t\in\mathcal O^\times$, $p\nmid d$, and $\mathcal O[s]/(s^d-t)$ is \'etale over $\mathcal O$, so $C$ is \'etale over $X'$ above $\bar x$. If $\bar x\in B$, the ideal of $B$ at $\bar x$ is principal, $=(\pi)$, since $\mathcal O$ is factorial and $B$ is a reduced divisor; $\mathcal O/\pi$ is a discrete valuation ring \'etale over $\mathcal O_{L,(\mathfrak P)}$, so $(\pi,p)$ is a regular system of parameters, and $t=\pi^e v$ with $e\in\mathbb Z\setminus\{0\}$ and $v\in\mathcal O^\times$. Put $g=\gcd(d,e)$, $d=gd'$, $e=ge'$, and choose integers $\alpha,\beta$ with $\alpha d'+\beta e'=1$. After the \'etale extension $\mathcal O'$ of $\mathcal O$ obtained by adjoining $v^{1/d}$ and $\mu_g$ and localising at a point over $\bar x$ (\'etale as $p\nmid d$), the $\operatorname{Frac}(\mathcal O')$-algebra $\operatorname{Frac}(\mathcal O')[s]/(s^d-t)$ is the product over $\zeta\in\mu_g$ of the fields $\operatorname{Frac}(\mathcal O')[y]/(y^{d'}-\zeta\pi^{e'})$, $y=s\,v^{-1/d}$. In each factor, $w=y^\beta\pi^\alpha$ satisfies $w^{d'}=\zeta^\beta\pi$ and $y=\zeta^\alpha w^{e'}$. The ring $\mathcal O'[w]/(w^{d'}-\zeta^\beta\pi)$ is finite over $\mathcal O'$, local with maximal ideal $(w,p)$ (as $\pi=\zeta^{-\beta}w^{d'}$), hence regular of dimension $2$, so it is the normalisation of the factor. Modulo $p$ it is an Eisenstein extension of the discrete valuation ring $\mathcal O'/p$, hence regular. Normalisation commutes with \'etale base change, so $C$ is regular with regular special fibre above $\bar x$; as $C$ is flat over $\mathcal O_{L,(\mathfrak P)}$, it is smooth there. Its ramification index over $\pi=0$ is $d'$, which divides $d$, and $\rho^{-1}(B)$ is $\{w=0\}$, \'etale over $\mathcal O/\pi$ and hence over $\mathcal O_{L,(\mathfrak P)}$. So $C$ is smooth, and proper as it is finite over $X'$. Finally, $Z'\cup Z_\infty$ is \'etale. If $P$ is a cusp, the points of $X'_L$ over $t=\infty$ are cusps, so $Z_\infty\subset Z'$. If $P$ is not a cusp, $Z'\cap Z_\infty=\emptyset$: a common point $\bar x$ would be the reduction of a point of $Z_\infty$ and of a point $c$ of $Z'$, which lies over a cusp of $\Gamma$ by (M4), so $t(c)\neq\infty$ and $t(c)\in S$ by the first step; then $t(c)$ and $\infty$ are distinct points of $S$ with the same reduction $t(\bar x)$, and $p\in\Sigma$. In both cases $Z'\cup Z_\infty$ is \'etale, and $D_C\cup P_C=\rho^{-1}(Z'\cup Z_\infty)_{\mathrm{red}}$. Over $Z'\setminus B$ the map $\rho$ is \'etale, and over $B$ we have seen that $\rho^{-1}(B)$ is \'etale; so $D_C\cup P_C$ is \'etale over $\mathcal O_{L,(\mathfrak P)}$. \end{proof} The local Tate calculation gives the expansion map and its Frobenius action. These are local cusp statements, so they remain available when the cover is ramified in the interior; the corresponding global statement in \cite[Theorem~3.6]{locbib:Scholl1985} assumes an \'etale cover over the open modular curve. \begin{lemma}\label{lem:v5_tat_cur_loc} Let $p$ be an odd prime, $k\geq2$ an integer with $p>k-2$, and $m\geq1$ an integer prime to $p$. Let $W$ be the ring of Witt vectors of a perfect field of characteristic $p$, with Frobenius automorphism $\sigma$. Let $\mathcal A=W((u))$ be the $p$-adic completion of $W[[u]][u^{-1}]$ and $\theta=u\,d/du$. Fix $\delta\in W^\times$, put $q=\delta u^m$, and let $\gamma\in1+pW$ be the unique element with $\gamma^m=\delta^p/\sigma(\delta)$. Let $\omega=\omega_{\mathrm{can}}$ be the canonical differential of the Tate curve $\mathrm{Tate}(q)$ over $\mathcal A$ and $\xi=\nabla_{q\,d/dq}\,\omega$, so that $\nabla_\theta\omega=m\,\xi$ and $\nabla_\theta\xi=0$. Let $M_{\mathcal A}=\operatorname{Sym}^{k-2}H^1_{\mathrm{dR}}(\mathrm{Tate}(q)/\mathcal A)$, free with basis $e_i=\omega^{k-2-i}\xi^i$ $(0\leq i\leq k-2)$, and let $H^1_{\mathrm{loc}}$ be the cokernel of $\nabla_\theta:M_{\mathcal A}\to M_{\mathcal A}$, whose elements we write as classes of forms $x\otimes du/u$. \begin{enumerate} \item The map $g\mapsto[g\,e_0]$ induces an isomorphism $\iota:\mathcal A/\theta^{k-1}\mathcal A\to H^1_{\mathrm{loc}}$, with inverse \[ \psi\Bigl[\sum_{i=0}^{k-2}a_ie_i\Bigr]=\sum_{i=0}^{k-2}(-1)^i\,\frac{(k-2-i)!}{(k-2)!\,m^i}\,\theta^ia_i . \] \item Let $V:\mathcal A\to\mathcal A$ be the $\sigma$-semilinear ring endomorphism with $V(u)=\gamma u^p$, that is $V(\sum_Na_Nu^N)=\sum_N\sigma(a_N)\gamma^Nu^{pN}$; it satisfies $V(q)=q^p$. Let $F:V^*M_{\mathcal A}\to M_{\mathcal A}$ be the map induced on de Rham cohomology by the isogeny $\mathrm{Tate}(q)\to V^*\mathrm{Tate}(q)=\mathrm{Tate}(q^p)$, $x\mapsto x^p$. Then \[ F\bigl(V^*(g\,e_0)\bigr)\otimes V^*\frac{du}u=p^{k-1}\,V(g)\,e_0\otimes\frac{du}u\qquad(g\in\mathcal A), \] and $x\otimes\frac{du}u\mapsto F(V^*x)\otimes V^*\frac{du}u$ induces $p^{k-1}V$ on $\mathcal A/\theta^{k-1}\mathcal A$ through $\iota$. \end{enumerate} \end{lemma} \begin{proof} For power series and cusp forms, (1) is \cite[Theorems 2.7(ii) and 2.12(ii)]{locbib:Scholl1985} and (2) is \cite[(3.2.1), (3.3.1), (3.3.2)]{locbib:Scholl1985} (the weight $k+2$ there is our $k$), in the normalisation of \cite[\S4]{bib:kazalicki2013a}, for a cusp of width $m$. \emph{Proof of (1).} From $\nabla_\theta\omega=m\xi$, $\nabla_\theta\xi=0$ and the Leibniz rule, $\nabla_\theta e_i=(k-2-i)\,m\,e_{i+1}$, with $e_{k-1}:=0$. Hence, for $a_0,\dots,a_{k-2}\in\mathcal A$ and $a_{-1}:=0$, \begin{equation} \nabla_\theta\Bigl(\sum_{i=0}^{k-2}a_ie_i\Bigr)=\sum_{i=0}^{k-2}\bigl(\theta a_i+(k-1-i)\,m\,a_{i-1}\bigr)e_i .\tag{$\ast$} \end{equation} The map $\psi$ vanishes on coboundaries modulo $\theta^{k-1}\mathcal A$. Put $c_i=(k-2-i)!/((k-2)!\,m^i)$. Since $p>k-2$ and $p\nmid m$, each $c_i$ is a unit of $\mathbb Z_{(p)}$, and $c_i\,(k-1-i)\,m=c_{i-1}$ for $1\leq i\leq k-2$. Applying $\psi$ to ($\ast$) and shifting the index in the second sum, \[ \begin{aligned} &\sum_{i=0}^{k-2}(-1)^ic_i\theta^{i+1}a_i +\sum_{i=1}^{k-2}(-1)^ic_i(k-1-i)m\,\theta^ia_{i-1}\\ &\qquad=\sum_{i=0}^{k-2}(-1)^ic_i\theta^{i+1}a_i -\sum_{i=0}^{k-3}(-1)^{i}c_i\theta^{i+1}a_i\\ &\qquad=(-1)^{k-2}c_{k-2}\,\theta^{k-1}a_{k-2}. \end{aligned} \] So $\psi$ induces a map $H^1_{\mathrm{loc}}\to\mathcal A/\theta^{k-1}\mathcal A$. That $\theta^{k-1}c\cdot e_0$ is a coboundary for every $c\in\mathcal A$, and that every class has a representative $a\,e_0$, is the computation in the proof of \cite[Theorem 2.7(ii)]{locbib:Scholl1985}, pp.~58--59, which uses only ($\ast$) and the invertibility of $(k-2)!\,m^{k-2}$, and holds verbatim over $\mathcal A$. Since $c_0=1$, $\psi\circ\iota$ is the identity; hence $\iota$ is bijective, with inverse $\psi$. \emph{Proof of (2).} The isogeny $x\mapsto x^p$ of multiplicative uniformisations pulls back $dx/x$ to $p\,dx/x$, so $F(V^*\omega)=p\,\omega$ \cite[(3.2.1)]{locbib:Scholl1985}. Since $\gamma\in W$ is a constant, $V^*\frac{du}u=\frac{d(\gamma u^p)}{\gamma u^p}=p\,\frac{du}u$. Hence \[ F\bigl(V^*(g\,e_0)\bigr)\otimes V^*\frac{du}u=V(g)\,(p\,\omega)^{k-2}\otimes p\,\frac{du}u=p^{k-1}\,V(g)\,e_0\otimes\frac{du}u . \] The map $F$ is induced by a morphism of abelian schemes lying over $V$, so it is horizontal: $\nabla_\theta F(V^*x)=p\,F(V^*\nabla_\theta x)$ for $x\in M_{\mathcal A}$, the factor $p$ coming from $V^*\frac{du}u=p\frac{du}u$. Therefore $F(V^*\nabla_\theta x)\otimes V^*\frac{du}u=\nabla_\theta F(V^*x)\otimes\frac{du}u$, so the map on forms carries coboundaries to coboundaries and induces an endomorphism of $H^1_{\mathrm{loc}}$. By (1) every class is $\iota(g)$, and by the display this endomorphism sends $\iota(g)$ to $\iota(p^{k-1}V(g))$. It is well defined on $\mathcal A/\theta^{k-1}\mathcal A$ because $\theta\circ V=p\,V\circ\theta$, so $p^{k-1}V(\theta^{k-1}c)=\theta^{k-1}V(c)$. \end{proof} \begin{lemma}\label{lem:v5_exp_cus_fro} Let $p$ be an odd prime, $k\geq2$ an integer with $p>k-2$, and $W$ the ring of Witt vectors of a perfect field of characteristic $p$, with Frobenius $\sigma$. Let $X'$ be a smooth proper curve over $W$, $Z'\subset X'$ a divisor \'etale over $W$, and $E\to X'$ a generalised elliptic curve, smooth over $X'\setminus Z'$; let $H$ be its logarithmic de Rham cohomology, with Gauss--Manin connection, Hodge filtration and structure of logarithmic $F$-crystal. Let $\rho:C\to X'$ be a finite morphism of smooth proper curves over $W$ such that $D_C=\rho^{-1}(Z')_{\mathrm{red}}$ is \'etale over $W$. Put $M_k=\operatorname{Sym}^{k-2}\rho^*H$ and \[ H_{\mathbb Z}=\mathbb H^1\bigl(C,\ M_k\xrightarrow{\ \nabla\ }M_k\otimes\Omega^1_{C/W}(\log D_C)\bigr), \] with its crystalline Frobenius $\varphi$, which is $\sigma$-semilinear. Let $x_\infty\in D_C(W)$, let $u$ be a formal parameter of $C$ along $x_\infty$, and assume that the pull-back of $E$ to $\operatorname{Spf}W[[u]]$ is the Tate curve $\mathrm{Tate}(q)$ with $q=\delta u^m$, $\delta\in W^\times$ and $p\nmid m$. Let $\mathcal A$, $\theta$, $\gamma$, $V$, $\iota$, $\psi$ be as in Lemma~\ref{lem:v5_tat_cur_loc}, and let $\sigma_{\mathrm{can}}$ be the Frobenius lift of $W[[u]]$ with $\sigma_{\mathrm{can}}(u)=\gamma u^p$. \begin{enumerate} \item Let $x\in H_{\mathbb Z}$ be represented by a \v{C}ech--de Rham cocycle on an affine open cover of $C$, and let $\eta$ be its component on a member $U$ of the cover containing $x_\infty$. Then $\mathcal E(x)=\psi[\eta|_{\operatorname{Spf}\mathcal A}]\in\mathcal A/\theta^{k-1}\mathcal A$ depends only on $x$, and $\mathcal E:H_{\mathbb Z}\to\mathcal A/\theta^{k-1}\mathcal A$ is $W$-linear. \item $\mathcal E\circ\varphi=p^{k-1}V\circ\mathcal E$. \item Let $\sigma_U$ be a Frobenius lift on the $p$-adic completion of $U$, logarithmic along $D_C$, and $F_{\sigma_U}$, $F_{\sigma_{\mathrm{can}}}$ the induced Frobenius maps on $M_k\otimes\Omega^1_C(\log D_C)$. Put $\delta_U=\log\bigl(\sigma_U(u)/\sigma_{\mathrm{can}}(u)\bigr)$. Then $\delta_U\in pW[[u]]$, and for every section $\eta$ of $M_k\otimes\Omega^1_C(\log D_C)$ over $U$, written $\eta|_{W[[u]]}=y\otimes\frac{du}u$ with $y\in M_k\otimes W[[u]]$, \[ \begin{aligned} F_{\sigma_U}(\eta)\big|_{W[[u]]}&=F_{\sigma_{\mathrm{can}}}\bigl(\eta|_{W[[u]]}\bigr)+\nabla h(y),\\ h(y)&=\sum_{n\geq1}\frac{\delta_U^{\,n}}{n!}\,F_{\sigma_{\mathrm{can}}}\bigl(\sigma_{\mathrm{can}}^*\nabla_\theta^{\,n-1}y\bigr)\in M_k\otimes W[[u]] . \end{aligned} \] \end{enumerate} \end{lemma} \begin{proof} For (1) and (2) we follow \cite[Theorem 3.6]{locbib:Scholl1985}, in the form of \cite[\S4]{bib:kazalicki2013a}; only the formal disc at $x_\infty$ enters. The Frobenius $\varphi$ is computed as follows. By the comparison between logarithmic crystalline and logarithmic de Rham cohomology \cite{locbib:Kato1989}, Thm.~6.4, $H_{\mathbb Z}$ is the logarithmic crystalline cohomology of the special fibre of $(C,D_C)$ with coefficients in the logarithmic $F$-crystal $M_k=\operatorname{Sym}^{k-2}\rho^*H$, and $\varphi$ is the Frobenius it induces. It is computed on \v{C}ech--de Rham cocycles as in \cite[2.3]{locbib:Scholl1985Trace}. Cover $C$ by finitely many affine opens $U_i$ such that each $U_i$ meeting $D_C$ has an \'etale coordinate $u_i$ with $D_C\cap U_i=\{u_i=0\}$. On the $p$-adic completion $\widehat U_i$ the lift $u_i\mapsto u_i^p$ of $\operatorname{Spf}W\langle u_i\rangle$ (semilinear over $\sigma$) extends uniquely, by \'etaleness, to a Frobenius lift $\sigma_i$, which is logarithmic along $D_C$; on the $U_i$ not meeting $D_C$ any Frobenius lift will do. Each $\sigma_i$ induces $F_{\sigma_i}$ on the de Rham complex of $M_k$ over $\widehat U_i$, with $F_{\sigma_i}(y\otimes\eta_0)=F_{\sigma_i}(\sigma_i^*y)\otimes\sigma_i^*\eta_0$. These maps make $M_k$ an $F$-crystal with logarithmic singularities along $D_C$ in the sense of \cite[1.5]{locbib:Scholl1985Trace}: over $C\setminus D_C$ they are the Frobenius of the crystalline cohomology of the elliptic curve $\rho^*E$, an $F$-crystal in the usual sense, and they extend across $D_C$, which suffices by \cite[1.6]{locbib:Scholl1985Trace}. So on overlaps $F_{\sigma_i}$ and $F_{\sigma_j}$ are homotopic through the homotopies of \cite[2.1, Proposition 2.2]{locbib:Scholl1985Trace}. If $x$ is the class of a cocycle $(\eta_i,m_{ij})$, then $\varphi(x)$ is the class of a cocycle whose component on $U_i$ is $F_{\sigma_i}(\eta_i)$. This is the only feature of the \v{C}ech formula used below. The cohomology of the scheme $C$ and of its $p$-adic completion agree, as $C$ is proper over $W$. \emph{Proof of (3).} This is \cite[Proposition 2.2(ii)]{locbib:Scholl1985Trace} on the formal disc $\operatorname{Spf}W[[u]]$ at $x_\infty$, a pair of type 1.2(ii) there, for the lifts $\sigma_{\mathrm{can}}$ and $\sigma'$, the lift of $W[[u]]$ induced by $\sigma_U$. Both are admissible, that is, logarithmic along $D_C$, $\sigma_{\mathrm{can}}$ because $\gamma\in W^\times$. By (2.1.2) loc.\ cit., with the parameter $u$, $h(y)$ is the value at $y\otimes\frac{du}u$ of the homotopy of 2.1 loc.\ cit.\ between the two lifts, and $\delta_U\in pW[[u]]$ by (1.4.3) loc.\ cit. \emph{Proof of (1).} Changing the cocycle by the coboundary of $(g_i)$, $g_i\in M_k(U_i)$, replaces $\eta$ by $\eta+\nabla g$ with $g$ regular at $x_\infty$, whose restriction $\nabla_\theta(g|_{W[[u]]})\otimes\frac{du}u$ is zero in $H^1_{\mathrm{loc}}$. If $U'$ is another member of the cover containing $x_\infty$, with component $\eta'$, the cocycle condition gives $\eta'-\eta=\nabla y$ with $y\in M_k(U\cap U')$, and $U\cap U'$ contains $x_\infty$, so again the difference restricts to a coboundary. Two covers have a common refinement, and passing to a refinement replaces $\eta$ by its restriction to a smaller open containing $x_\infty$. Hence $\mathcal E$ is well defined, and it is $W$-linear because $\psi$ is. \emph{Proof of (2).} Let $x$ be the class of $(\eta_i,m_{ij})$ and let $U=U_{i_0}$ contain $x_\infty$, with $\sigma_U=\sigma_{i_0}$ and $\eta=\eta_{i_0}$. The component of $\varphi(x)$ on $U$ is $F_{\sigma_U}(\eta)$. By (3) its restriction to $\operatorname{Spf}W[[u]]$ is $F_{\sigma_{\mathrm{can}}}(\eta|_{W[[u]]})$ plus the coboundary $\nabla h(y)$, so $\mathcal E(\varphi x)=\psi[F_{\sigma_{\mathrm{can}}}(\eta|_{W[[u]]})]$. Since $\sigma_{\mathrm{can}}(q)=\sigma(\delta)\gamma^mu^{pm}=q^p$, the Frobenius of the restriction of $\rho^*H$ to $\operatorname{Spf}W[[u]]$ with respect to $\sigma_{\mathrm{can}}$ is the map induced by the isogeny $\mathrm{Tate}(q)\to\mathrm{Tate}(q^p)$, $x\mapsto x^p$, which lifts the relative Frobenius \cite[Proposition 3.2, (3.2.1)]{locbib:Scholl1985}. Hence $F_{\sigma_{\mathrm{can}}}$ on $M_k\otimes\frac{du}u$ is the map $F$ of Lemma~\ref{lem:v5_tat_cur_loc}(2), and that lemma gives $\psi[F_{\sigma_{\mathrm{can}}}(\eta|_{W[[u]]})]=p^{k-1}V\bigl(\psi[\eta|_{W[[u]]}]\bigr)=p^{k-1}V\mathcal E(x)$. \end{proof} The eigenlattice is obtained by imposing both the character condition and vanishing residues at the cusps. The latter condition is needed when the twisted local system has cusp invariants. The differential then lies in its top Hodge line. \begin{lemma}\label{lem:v5_par_eig_the} For $z\in D_C(W)$, $W=W(\bar{\mathbb F}_p)$, let $\operatorname{Res}_z(x)\in W$ be the constant term of the expansion of $x\in H_{\mathbb Z}$ at $z$ (Lemma~\ref{lem:v5_exp_cus_fro}(1)). \begin{enumerate} \item $H_{\mathbb Z}$ is a free $\mathbb Z_p$-module of finite rank, with a $\mathbb Z_p$-linear crystalline Frobenius $\varphi$, the Hodge filtration $\operatorname{Fil}^iH_{\mathbb Z}=\operatorname{im}\bigl(\mathbb H^1(\operatorname{Fil}^iK)\to\mathbb H^1(K)\bigr)$, where $K=[M_k\to M_k\otimes\Omega^1(\log D_C)]$ and $\operatorname{Fil}^iK=[\operatorname{Fil}^iM_k\to\operatorname{Fil}^{i-1}M_k\otimes\Omega^1(\log D_C)]$, and an action $x\mapsto g^*x$ of $\tilde G$ commuting with $\varphi$ and preserving $\operatorname{Fil}^\bullet$. \item The submodule \[ H_{a,p}=\bigl\{x\in H_{\mathbb Z}:\ \operatorname{Res}_z(x)=0\ \text{for all }z\in D_C(W),\ \ g^*x=\chi_\Phi(g)\,x\ \text{for all }g\in\tilde G\bigr\} \] is saturated in $H_{\mathbb Z}$ and stable under $\varphi$; in particular it is free. We call $H_{a,p}$ the \emph{eigenlattice} of the model. \item Let $\iota:\mathbb Q_p\to\mathbb C$ be a field embedding that is the identity on $L\subset\mathbb C$. Then $H_{a,p}\otimes_{\mathbb Z_p,\iota}\mathbb C\cong H^1_{\mathrm{par}}(\mathbb P^1\setminus S,\mathbb W_\Phi)$, compatibly with Hodge filtrations, where $\mathbb W_\Phi$ is the $\chi_\Phi$-eigensheaf of $(t\circ\rho)_*\operatorname{Sym}^{k-2}R^1\pi_*\mathbb C$ on $\mathbb P^1\setminus S$, with $\pi$ the pull-back of the elliptic curve to $C\setminus D_C$. The variation $\mathbb W_\Phi$ has weight $k-2$, and there are isomorphisms of complex variations of Hodge structure \[ \mathbb V_f\otimes\mathbb L_a \ \cong\ \mathbb W_\Phi^\vee(2-k) \ \cong\ \overline{\mathbb W_\Phi}, \] where the left-hand side carries the variation of Lemma~\ref{lem:v5_hod_str_twi}. Consequently $H_{a,p}\otimes_\iota\mathbb C$ is the complex conjugate of $H_a$, with the two Hodge indices exchanged. In particular, if the datum is admissible, then $H_{a,p}$ is free of rank $2$ and $\operatorname{Fil}^1(H_{a,p}\otimes\mathbb Q_p)=\operatorname{Fil}^{k-1}(H_{a,p}\otimes\mathbb Q_p)$ is a line. \end{enumerate} \end{lemma} \begin{proof} \emph{Proof of (1).} The complex $K=[M_k\to M_k\otimes\Omega^1(\log D_C)]$ consists of locally free sheaves on the proper smooth $\mathbb Z_p$-scheme $C_{\mathbb Z_p}$ (Lemma~\ref{lem:v5_smo_kum_cov}), with a $\mathbb Z_p$-linear differential, so $H_{\mathbb Z}$ is finitely generated, lying between $H^0(M_k\otimes\Omega^1(\log D_C))$ and $H^1(M_k)$. By the sequence $0\to K\xrightarrow{p}K\to K/p\to0$, the $p$-torsion of $H_{\mathbb Z}$ is the image of $H^0(C_{\mathbb F_p},K/p)$, the horizontal global sections of $M_k\otimes\mathbb F_p$; we show there are none. Let $m$ be one. By (M1) of Definition~\ref{def:v5_mod_mod_kum}, $\omega^{\otimes2}\cong\Omega^1_{X'}(\log Z')$, whose degree on each component of $X'_{\mathbb F_p}$ equals its degree on the corresponding component of $X'_{\mathbb C}$, namely $[\mathrm{PSL}_2(\mathbb Z):\Gamma']/6>0$ by (M4) and the transitivity of $G$ on components; as $\rho$ is finite and surjective on components, $\rho^*\omega$ has positive degree on every component of $C_{\mathbb F_p}$. So the image of $m$ in $\operatorname{gr}^0M_k=\rho^*\omega^{\otimes(2-k)}$ vanishes, and $m\in\operatorname{Fil}^1$. For $1\leq i\leq k-2$, if $m\in\operatorname{Fil}^i$, then $\operatorname{gr}^i\nabla=i\,(\kappa\otimes\mathrm{id})$ kills the image $\bar m_i$ of $m$ in $\operatorname{gr}^iM_k$, where $\kappa:\rho^*\omega^{\otimes2}\to\Omega^1_C(\log D_C)$ is the pull-back of the Kodaira--Spencer isomorphism followed by $\rho^*\Omega^1_{X'}(\log Z')\to\Omega^1_C(\log D_C)$ \cite{bib:kazalicki2013a}, \S2. The map $\kappa$ is an injective map of line bundles, since $\rho_{\mathbb F_p}$ is generically \'etale ($p\nmid d$), and $i$ is a unit as $i-1$. By (2), $r_x\operatorname{ord}_c\Phi$ is an integer, so the logarithmic order at $x\in D_C$ is at least $1$ if and only if $\operatorname{ord}_c\Phi>0$; and a section of $\rho^*\omega^{\otimes(k-2)}\otimes\Omega^1_C(\log D_C)$ of logarithmic order at least $1$ along $D_C$ is a section of $\rho^*\omega^{\otimes(k-2)}\otimes\Omega^1_C$. Every $\tau_0\in\mathbb H$ and every cusp of $\Gamma$ lies under some point of $C$, as $C\to X'\to X_\Gamma$ is surjective, and $\omega_\Phi\neq0$ if and only if $\Phi\neq0$. This proves (3). \end{proof} \begin{lemma}\label{lem:v5_hod_pos_the} Assume that the datum is admissible. Let $H_{a,p}$ be the eigenlattice of the model and $\omega_\Phi$ the twisted differential on $C$. \begin{enumerate} \item $\omega_\Phi$ is a global section over $C$ of $\rho^*\omega^{\otimes(k-2)}\otimes\Omega^1_{C/\mathcal O_{L,(\mathfrak P)}}\subset\operatorname{Fil}^{k-2}M_k\otimes\Omega^1_C(\log D_C)$, and $g^*\omega_\Phi=\chi_\Phi(g)\,\omega_\Phi$ for every $g\in\tilde G$. \item Let $\infty_C$ be a point of $C$ over the cusp $\infty'$ of (M5), defined over a finite unramified extension $W$ of $\mathbb Z_p$, and let $Q=s\,(t/q)^{-1/d}$ in the completed local ring of $C_W$ at $\infty_C$, so that $Q^d=q$. The restriction of $\omega_\Phi$ to the formal neighbourhood of $\infty_C$ is $f_\Phi(Q)\,\omega_{\mathrm{can}}^{\otimes(k-2)}\otimes\frac{dQ}Q$, and $f_\Phi\in Q^j\,\mathbb Z_{(p)}[[Q^d]]$. \item The class $[\omega_\Phi]$ lies in $H_{a,p}$ and spans $\operatorname{Fil}^{k-1}(H_{a,p}\otimes\mathbb Q_p)=\operatorname{Fil}^1(H_{a,p}\otimes\mathbb Q_p)$. \end{enumerate} \end{lemma} \begin{proof} \emph{Rationality and the eigen-property.} By (M4) of Definition~\ref{def:v5_mod_mod_kum}, $f\omega^{\otimes(k-2)}$ is a rational section of $\omega^{\otimes(k-2)}$ over $X'_L$, and $R(t)\,s^{j-1}ds$ is a rational differential on $C_L$; so $\omega_\Phi$ is a rational section of the line bundle $\mathcal L=\rho^*\omega^{\otimes(k-2)}\otimes\Omega^1_{C/\mathcal O_{L,(\mathfrak P)}}$ on the smooth $\mathcal O_{L,(\mathfrak P)}$-scheme $C$ (Lemma~\ref{lem:v5_smo_kum_cov}). Let $g=(h,\zeta)\in\tilde G$. Since $\rho\circ h=h\circ\rho$, (M4) gives $h^*\rho^*(f\omega^{\otimes(k-2)})=\chi_G(h)\,\rho^*(f\omega^{\otimes(k-2)})$, and $h$ fixes $t$ and $s$; the automorphism $[\zeta]$ satisfies $\rho\circ[\zeta]=\rho$ and $[\zeta]^*(s^{j-1}ds)=\zeta^js^{j-1}ds$. Hence $g^*\omega_\Phi=\chi_\Phi(g)\,\omega_\Phi$. \emph{Holomorphy on the generic fibre.} By (M4), the component $X'_0$ of $X'_{\mathbb C}$ is $\Gamma'\backslash\mathbb H^*$ with $\Gamma'$ as in Lemma~\ref{lem:v5_ord_the_twi}, $E$ restricts to the universal curve, and $f\omega^{\otimes(k-2)}$ restricts to $f(\tau)(2\pi i\,dz)^{\otimes(k-2)}$; so on the part of $C_{\mathbb C}$ over $X'_0$, $\omega_\Phi$ is the section of Lemma~\ref{lem:v5_ord_the_twi}. As the datum satisfies (F), Lemma~\ref{lem:v5_ord_the_twi}(3) shows that $\omega_\Phi$ is a holomorphic section of $\mathcal L$ there. The group $\tilde G$ permutes the components of $C_{\mathbb C}$ transitively ($G$ those of $X'_{\mathbb C}$, as $X'_L/G\cong\mathbb P^1_L$ is geometrically connected, and $\mu_d$ those over a given one) and acts on $\mathcal L$ by bundle automorphisms, and $\omega_\Phi$ is an eigensection; so $\omega_\Phi$ is holomorphic on all of $C_{\mathbb C}$, and the horizontal part of its divisor on $C$ is effective. \emph{Proof of (2).} Over $\operatorname{Spf}W[[q']]$, (M5) gives $E=\mathrm{Tate}(q)$, $t$ equal to the $q$-expansion of the Hauptmodul, and $f\omega^{\otimes(k-2)}=F(t)\,\omega_{\mathrm{can}}^{\otimes(k-2)}=f(q)\,\omega_{\mathrm{can}}^{\otimes(k-2)}$. By Definition~\ref{def:v5_kum_twi_dat}, $t/q\in1+q\,\mathbb Z_{(p)}[[q]]$, so $(t/q)^{-1/d}$ is given by the binomial series, which has coefficients in $\mathbb Z[\frac1d]\subset\mathbb Z_{(p)}$ as $p\nmid d$; thus $Q=s\,(t/q)^{-1/d}$ lies in the completed local ring of $C_W$ at $\infty_C$ and $Q^d=s^d\,q/t=q$. Using $s^{j-1}ds=\frac1d\,s^j\frac{dt}t$, $s^j=Q^j(t/q)^a$, $\frac{dt}t=\frac qt\frac{dt}{dq}\frac{dq}q$ and $\frac{dq}q=d\,\frac{dQ}Q$, \[ \omega_\Phi=f\,R(t)\,Q^j\,(t/q)^a\,\frac qt\frac{dt}{dq}\;\omega_{\mathrm{can}}^{\otimes(k-2)}\otimes\frac{dQ}Q=f_\Phi(Q)\,\omega_{\mathrm{can}}^{\otimes(k-2)}\otimes\frac{dQ}Q, \] the last equality being the definition of the coefficients $c(N)$ in Definition~\ref{def:v5_kum_twi_dat}. The same definition gives $f_\Phi=Q^j\cdot(\text{a series in }Q^d=q)$ with coefficients in $\mathbb Z[\frac1{dM}]\subset\mathbb Z_{(p)}$, as $p\nmid dM$. This proves (2). For (1) it remains to show that the vertical part of the divisor of $\omega_\Phi$ is effective; it has one multiplicity for each connected component of $C\otimes W(\bar{\mathbb F}_p)$. On the component containing $\infty_C$ the multiplicity is $\geq0$: by (2), on the formal neighbourhood of $\infty_C$ the section is $f_\Phi(Q)\,\omega_{\mathrm{can}}^{\otimes(k-2)}\otimes\frac{dQ}Q$ with integral coefficients, where $\frac{dQ}Q=w'\frac{du}u$ for a formal parameter $u$, and $f_\Phi$ is divisible by $Q^j$, hence by $u$, so the section is integral there. The group $\tilde G$ acts on $C\otimes\mathbb Z_p$ and on $\mathcal L$ over $\mathbb Z_p$, permutes these components transitively (they correspond to the components of the generic fibre, $C$ being smooth and proper), and $\omega_\Phi$ is an eigensection with eigenvalues $\chi_\Phi(g)\in\mathbb Z_p^\times$; so all vertical multiplicities agree and are $\geq0$. Hence $\omega_\Phi\in H^0(C,\mathcal L)$. Since $\Omega^1_C\subset\Omega^1_C(\log D_C)$ and $\rho^*\omega^{\otimes(k-2)}=\operatorname{Fil}^{k-2}M_k$, this proves (1). \emph{Proof of (3).} The section $\omega_\Phi$ of $\operatorname{Fil}^{k-2}M_k\otimes\Omega^1_C(\log D_C)$ defines a class in $\operatorname{Fil}^{k-1}H_{\mathbb Z}$, represented on any affine cover by the cocycle $(\omega_\Phi|_{U_i},0)$. It is a $\chi_\Phi$-eigenvector by (1), and its residue at every point of $D_C$ vanishes because $\omega_\Phi$ is a section of $\rho^*\omega^{\otimes(k-2)}\otimes\Omega^1_C$; by the proof of Lemma~\ref{lem:v5_par_eig_the}(3), $\operatorname{Res}_z$ is the constant term of the $e_0$-coefficient of the residue. So $[\omega_\Phi]\in H_{a,p}$. We show $[\omega_\Phi]\neq0$ in $H_{\mathbb Z}\otimes\mathbb Q_p$. If it were zero, the cocycle $(\omega_\Phi|_{U_i},0)$ would be the coboundary of sections $m_i$ with $m_j-m_i=0$, that is, $\omega_\Phi=\nabla m$ for a global section $m$ of $M_k$ over $C_{\mathbb Q_p}$. As in the proof of Lemma~\ref{lem:v5_par_eig_the}(1): the image of $m$ in $\operatorname{gr}^0M_k=\rho^*\omega^{\otimes(2-k)}$ vanishes, $\rho^*\omega$ having positive degree on every component; and if $m\in\operatorname{Fil}^i$ with $1\leq i\leq k-2$, the component of $\nabla m=\omega_\Phi$ in $\operatorname{gr}^{i-1}M_k\otimes\Omega^1_C(\log D_C)$ is $i\,\kappa(\bar m_i)$, while that of $\omega_\Phi\in\operatorname{Fil}^{k-2}M_k\otimes\Omega^1_C(\log D_C)$ is zero since $i-10$ on the corresponding component of $X'_{\mathbb C}$ (M4); and $\rho$ is finite and surjective on components. \end{itemize} Now suppose $m\neq0$, and let $j\leq k-2$ be maximal with $m\in H^0(\operatorname{Fil}^jM_k\otimes\mathbb F_p)$, with nonzero image $\bar m\in H^0(\operatorname{gr}^j)$. If $j=0$ this contradicts the third fact. If $j\geq1$, then $\nabla m=\bar\omega\in\operatorname{Fil}^{k-2}\otimes\Omega^1\subset\operatorname{Fil}^j\otimes\Omega^1$, so the image of $\nabla m$ in $\operatorname{gr}^{j-1}\otimes\Omega^1$, which is $j\kappa(\bar m)$, vanishes; by the second fact $\bar m=0$, a contradiction. Hence $m=0$ and $\bar\omega=\nabla m=0$. Since $\mathcal L_{\log}$ is flat over $\mathbb Z_p$, $\bar\omega=0$ means $\omega\in pH^0(C_{\mathbb Z_p},\mathcal L_{\log})$, contrary to the hypothesis. Hence $[\omega]\notin pH_{\mathbb Z}$. \emph{Proof of (2).} The module $H^0(C_{\mathbb Z_p},\mathcal L_{\log})$ is finitely generated and torsion-free, as $C$ is proper, and $\omega_\Phi$ is a nonzero element of it by Lemma~\ref{lem:v5_hod_pos_the}(1),(3). So $\omega_\Phi=p^c\omega_1$ with $c\geq0$ and $\omega_1$ not divisible by $p$. Put $x_1:=[\omega_1]$. Then $p^cx_1=[\omega_\Phi]\in H_{a,p}$ (Lemma~\ref{lem:v5_hod_pos_the}(3)), and $x_1\in H_{a,p}$ because $H_{a,p}$ is saturated in $H_{\mathbb Z}$ (Lemma~\ref{lem:v5_par_eig_the}(2)). By (1), $x_1\notin pH_{\mathbb Z}$, so $x_1\notin pH_{a,p}$. By Lemma~\ref{lem:v5_fro_div_hol}(1), $\varphi(x_1)\in p^{k-1}H_{\mathbb Z}$, and $\varphi(x_1)\in H_{a,p}$ by Lemma~\ref{lem:v5_par_eig_the}(2). Since $H_{a,p}$ is saturated in $H_{\mathbb Z}$, $p^{k-1}H_{\mathbb Z}\cap H_{a,p}=p^{k-1}H_{a,p}$. As $H_{a,p}$ is free of rank $2$ (Lemma~\ref{lem:v5_par_eig_the}(3)) and $x_1$ is not divisible by $p$, there is $y$ with $\{x_1,y\}$ a basis of $H_{a,p}$. The first column of the matrix of $\varphi$ in this basis is divisible by $p^{k-1}$, so $\det(\varphi\mid H_{a,p})\in p^{k-1}\mathbb Z_p$. \end{proof} \subsection{The determinant} \label{subsec:determinant} To determine the valuation of the determinant, we construct a primitive generator $x_1$ of the top Hodge line and extend it to a basis $x_1,y$ of $H_{a,p}$. The other extreme Hodge type identifies the kernel of the relevant mod-$p$ projection with the line spanned by $\bar x_1$. This allows us to show that $p^{1-k}\varphi(x_1)$ and $\varphi(y)$ are independent modulo $p$. \begin{lemma}\label{lem:v5_con_cus_for} Assume that the datum is admissible. Put $\chi=\chi_\Phi$. Let $\operatorname{gr}^0M_k=M_k/\operatorname{Fil}^1M_k$, with the action of $\tilde G$ induced from $M_k$, and let $\mathcal L^*=(\operatorname{gr}^0M_k)^\vee\otimes\Omega^1_C$, with the dual action on $(\operatorname{gr}^0M_k)^\vee$ and the natural action on $\Omega^1_C$. For a character $\psi$ of $\tilde G$ and a $\tilde G$-module $V$ write $V^\psi=\{v\in V:\ g^*v=\psi(g)\,v\ \text{for all }g\in\tilde G\}$. Then \[ H^1(C_{\mathbb Q_p},\operatorname{gr}^0M_k)^{\chi}\neq0\qquad\text{and}\qquad H^0(C_{\mathbb Q_p},\mathcal L^*)^{\chi^{-1}}\neq0 . \] \end{lemma} \begin{proof} \emph{The first assertion, from a class of $H_{a,p}$ outside $\operatorname{Fil}^1$.} Let $K=[M_k\xrightarrow{\nabla}M_k\otimes\Omega^1_C(\log D_C)]$ on $C_{\mathbb Q_p}$, and $\operatorname{Fil}^1K=[\operatorname{Fil}^1M_k\to M_k\otimes\Omega^1_C(\log D_C)]$, so that $K/\operatorname{Fil}^1K=\operatorname{gr}^0M_k[0]$. By flat base change, $H_{\mathbb Z}\otimes\mathbb Q_p=\mathbb H^1(C_{\mathbb Q_p},K)$, and by Lemma~\ref{lem:v5_par_eig_the}(1) its Hodge filtration has $\operatorname{Fil}^1=\operatorname{im}\bigl(\mathbb H^1(C_{\mathbb Q_p},\operatorname{Fil}^1K)\to\mathbb H^1(C_{\mathbb Q_p},K)\bigr)$. The long exact sequence of $0\to \operatorname{Fil}^1K\to K\to\operatorname{gr}^0M_k[0]\to0$ contains the exact segment \[ \mathbb H^1(C_{\mathbb Q_p},\operatorname{Fil}^1K)\longrightarrow\mathbb H^1(C_{\mathbb Q_p},K)\xrightarrow{\ r\ }H^1(C_{\mathbb Q_p},\operatorname{gr}^0M_k), \] so $\ker r=\operatorname{Fil}^1(H_{\mathbb Z}\otimes\mathbb Q_p)$. Since $\tilde G$ acts on $(M_k,\nabla,\operatorname{Fil}^\bullet)$ (Lemma~\ref{lem:v5_par_eig_the}(1)), the map $r$ is $\tilde G$-equivariant. As the datum is admissible, Lemma~\ref{lem:v5_par_eig_the}(3) shows that $H_{a,p}\otimes\mathbb Q_p$ has dimension $2$ and that $\operatorname{Fil}^1(H_{a,p}\otimes\mathbb Q_p)$, the intersection of $H_{a,p}\otimes\mathbb Q_p$ with $\operatorname{Fil}^1(H_{\mathbb Z}\otimes\mathbb Q_p)$, is a line; this is where (R) and (P) enter. Choose $x\in H_{a,p}\otimes\mathbb Q_p$ outside this line. Then $r(x)\neq0$, and $g^*r(x)=r(g^*x)=\chi(g)\,r(x)$ for all $g\in\tilde G$, by the definition of $H_{a,p}$ in Lemma~\ref{lem:v5_par_eig_the}(2). Hence $0\neq r(x)\in H^1(C_{\mathbb Q_p},\operatorname{gr}^0M_k)^\chi$. \emph{The second assertion, by Serre duality.} Cohomology and eigenspaces commute with the flat base change $\mathbb Q_p\to\bar{\mathbb Q}_p$, so it suffices to show that $H^0(C_{\bar{\mathbb Q}_p},\mathcal L^*)^{\chi^{-1}}\neq0$; the characters $\chi^{\pm1}$ take values in $\mathbb Z_p^\times$. The curve $C_{\bar{\mathbb Q}_p}$ is a finite disjoint union of smooth projective connected curves. For the line bundle $\mathcal F=\operatorname{gr}^0M_k$, Serre duality \cite[III, \S7]{locbib:Hartshorne1977} gives a perfect pairing \[ \langle\ ,\ \rangle:\ H^1(C_{\bar{\mathbb Q}_p},\mathcal F)\times H^0(C_{\bar{\mathbb Q}_p},\mathcal F^\vee\otimes\Omega^1_C)\longrightarrow H^1(C_{\bar{\mathbb Q}_p},\Omega^1_C)\xrightarrow{\ \mathrm{tr}\ }\bar{\mathbb Q}_p , \] the cup product followed by the trace map, which on each component is the sum of residues \cite[Ch.~II]{locbib:Serre1988}. Residues of differentials are preserved by isomorphisms of curves, so $\mathrm{tr}\circ g^*=\mathrm{tr}$ for every automorphism $g$ of $C_{\bar{\mathbb Q}_p}$; and as the action of $\tilde G$ on $\mathcal L^*=\mathcal F^\vee\otimes\Omega^1_C$ is dual to that on $\mathcal F$, the cup product is $\tilde G$-equivariant. Hence $\langle g^*\xi,g^*\eta\rangle=\langle\xi,\eta\rangle$ for all $g\in\tilde G$. It remains to pass to eigenspaces. For a character $\psi$ of $\tilde G$ with values in $\mathbb Z_p^\times$ put $e_\psi=|\tilde G|^{-1}\sum_{g\in\tilde G}\psi(g)^{-1}g^*$, the projector onto the $\psi$-eigenspace. By the invariance of the pairing, $\langle e_\chi\xi,\eta\rangle=\langle\xi,e_{\chi^{-1}}\eta\rangle$. Let $\xi$ be the image of $r(x)$ in $H^1(C_{\bar{\mathbb Q}_p},\mathcal F)$, a nonzero $\chi$-eigenvector, so $e_\chi\xi=\xi$, and choose $\eta$ with $\langle\xi,\eta\rangle\neq0$. Then $\langle\xi,e_{\chi^{-1}}\eta\rangle=\langle e_\chi\xi,\eta\rangle\neq0$, so $e_{\chi^{-1}}\eta$ is a nonzero element of $H^0(C_{\bar{\mathbb Q}_p},\mathcal L^*)^{\chi^{-1}}$. \end{proof} \begin{lemma}\label{lem:v5_red_fro_fac} Assume that the datum is admissible. Write $\bar M=M_k\otimes\mathbb F_p$ on $C_{\mathbb F_p}$ and $\operatorname{gr}^0\bar M=\bar M/\operatorname{Fil}^1\bar M$. For $x\in H_{\mathbb Z}$ represented by a Čech--de Rham cocycle $\bigl((\omega_i),(m_{ij})\bigr)$ on a finite cover of the $p$-adic completion of $C_{\mathbb Z_p}$ by charts as in Lemma~\ref{lem:v5_loc_hod_div}, let $\pi(x)\in H^1(C_{\mathbb F_p},\operatorname{gr}^0\bar M)$ be the class of the Čech cocycle $\bigl(m_{ij}\bmod(p,\operatorname{Fil}^1)\bigr)$. Then $\pi:H_{\mathbb Z}\to H^1(C_{\mathbb F_p},\operatorname{gr}^0\bar M)$ is a well-defined homomorphism, and \[ \pi(x)\neq0\ \Longrightarrow\ \varphi(x)\notin pH_{\mathbb Z}. \] \end{lemma} \begin{proof} Modulo $p$, Frobenius sees only the $\operatorname{gr}^0$-part of a class, through a map $\Lambda$ that is a form of the Cartier isomorphism; the proof shows that $\Lambda$ is a bijection onto the horizontal sections. \emph{The map $\pi$.} A coboundary $\bigl((\nabla n_i),(n_j-n_i)\bigr)$ changes $(m_{ij})$ by a Čech coboundary, and refining the cover does not change the class, so $\pi$ is well defined. \emph{The reduced Frobenius.} On a chart $U$ with lift $\sigma$ put $\bar F(m)=F_\sigma(\sigma^*\tilde m)\bmod p$ for $m\in\bar M(U)$ and any lift $\tilde m$; it does not depend on $\tilde m$. By the Taylor formula of the crystal $M_k$ \cite[\S2, \S7]{locbib:BerthelotOgus1978}, \cite[\S6]{locbib:Kato1989}, with $\delta\in pB$ (both lifts reduce to the $p$-th power map, and \cite[(1.4.3)]{locbib:Scholl1985Trace} when $\eta_0=dv/v$) , $F_{\sigma'}(\sigma'^*\tilde m)-F_\sigma(\sigma^*\tilde m)=\sum_{n\geq1}\frac{\delta^n}{n!}F_\sigma(\sigma^*\nabla_\partial^n\tilde m)\in pM_k$, so $\bar F$ does not depend on $\sigma$ either, and it glues to an additive map of sheaves $\bar F:\bar M\to\bar M$ with $\bar F(fm)=f^p\bar F(m)$. By Lemma~\ref{lem:v5_loc_hod_div}(1), $\bar F$ kills $\operatorname{Fil}^1\bar M$, so it factors through a map $\Lambda:\operatorname{gr}^0\bar M\to\bar M$. Its values are horizontal, since $\nabla F_\sigma(\sigma^*\tilde m)=F_\sigma(\sigma^*\nabla_\partial\tilde m)\otimes\sigma^*\eta_0$ and $\sigma^*\eta_0\in p\,\Omega^1$. So $\Lambda$ maps $\operatorname{gr}^0\bar M$ to the sheaf $\bar M^\nabla$ of horizontal sections. The same construction with $\rho^*H$ in place of $M_k$ gives $\bar F$ on $\bar H=\rho^*H\otimes\mathbb F_p$, and $\bar F$ on $\bar M=\operatorname{Sym}^{k-2}\bar H$ is its symmetric power. \emph{The reduction of $\varphi(x)$.} By the description of Frobenius on \v{C}ech--de Rham cocycles \cite[2.3]{locbib:Scholl1985Trace}, with \cite[\S7]{locbib:BerthelotOgus1978} and \cite[Thm.~6.4]{locbib:Kato1989}, written out in the proof of Lemma~\ref{lem:v5_fro_div_hol}, $\varphi(x)$ is represented by $\bigl((F_{\sigma_i}(\omega_i)),(F_{\sigma_i}(\sigma_i^*m_{ij})+h_{\sigma_i,\sigma_j}(\omega_j))\bigr)$. Here $F_{\sigma_i}(\omega_i)\equiv0\pmod p$ because $\sigma_i^*\eta_0\in p\,\Omega^1$, and $h_{\sigma_i,\sigma_j}(\omega_j)\equiv0\pmod p$ because each term contains $\delta^n/n!\in pB$. So modulo $p$, $\varphi(x)$ is represented by $\bigl((0),(\Lambda(\mu_{ij}))\bigr)$ with $\mu_{ij}=m_{ij}\bmod(p,\operatorname{Fil}^1)$. \emph{$\Lambda$ is a bijection onto $\bar M^\nabla$.} We prove three facts. (a) \emph{$u=\bar F(\xi)$ is nowhere zero, for $\xi$ a local generator of $\bar H/\operatorname{Fil}^1\bar H$.} Let $y\notin D_C$ be a closed point with residue field $\kappa_y$. By the proof of Lemma~\ref{lem:v5_loc_hod_div}, $\bar F$ on $\bar H$ is the pull-back by the relative Frobenius of $E_0$ composed with base change along the absolute Frobenius; both commute with restriction to $y$, so the fibre of $\bar F$ at $y$ is $F^*\circ\mathrm{Frob}_{\kappa_y}^*$ on $H^1_{\mathrm{dR}}(E_y/\kappa_y)$, where $F:E_y\to E'_y=E_y^{(p)}$ is the relative Frobenius. The map of complexes $F^*:\Omega^\bullet_{E'_y}\to F_*\Omega^\bullet_{E_y}$ is zero in degree $1$ and maps $\mathcal O_{E'_y}$ isomorphically onto $\mathcal Z=\ker(d:F_*\mathcal O_{E_y}\to F_*\Omega^1_{E_y})$, since a function with $df=0$ is a $p$-th power ($\kappa_y$ is perfect). So on $H^1$ it is the projection $H^1_{\mathrm{dR}}(E'_y)\to H^1(E'_y,\mathcal O)$, followed by the isomorphism $H^1(\mathcal O)\cong H^1(\mathcal Z)$ and by the map induced by $\mathcal Z[0]\to F_*\Omega^\bullet_{E_y}$, which is injective on $H^1$ because the quotient complex has no $\mathcal H^0$. Hence $F^*$ is injective on $H^1_{\mathrm{dR}}/\operatorname{Fil}^1$, and $u(y)\neq0$. At a point $z\in D_C$, defined over $W=W(\kappa_z)$, choose a formal parameter $v$ at $z$ with $q=\delta v^m$, $\delta\in W^\times$ and $p\nmid m$ (proof of Lemma~\ref{lem:v5_par_eig_the}(2)), and compute $\bar F$ on the disc with the logarithmic lift $\sigma_{\mathrm{can}}(v)=\gamma v^p$ of Lemma~\ref{lem:v5_tat_cur_loc}, which satisfies $\sigma_{\mathrm{can}}(q)=q^p$; this is allowed, as $\bar F$ does not depend on the lift, by the Taylor formula on the disc, as above. The Frobenius $F$ for $\sigma_{\mathrm{can}}$ is induced by the isogeny $\mathrm{Tate}(q)\to\mathrm{Tate}(q^p)$, $x\mapsto x^p$ (proof of Lemma~\ref{lem:v5_exp_cus_fro}(2)), so $F(\sigma_{\mathrm{can}}^*\omega_{\mathrm{can}})=p\,\omega_{\mathrm{can}}$ (proof of Lemma~\ref{lem:v5_tat_cur_loc}(2)). Since $F$ is horizontal, $\nabla\omega_{\mathrm{can}}=\xi_{\mathrm{can}}\otimes\frac{dq}q$ and $\sigma_{\mathrm{can}}^*\frac{dq}q=p\frac{dq}q$, applying $\nabla$ to this identity gives $p\,F(\sigma_{\mathrm{can}}^*\xi_{\mathrm{can}})\otimes\frac{dq}q=p\,\xi_{\mathrm{can}}\otimes\frac{dq}q$, so $F(\sigma_{\mathrm{can}}^*\xi_{\mathrm{can}})=\xi_{\mathrm{can}}$, as in \cite[Proposition 3.2, (3.2.1)]{locbib:Scholl1985}. Hence $u$ is a unit multiple of $\xi_{\mathrm{can}}$ near $z$. (b) \emph{The $p$-curvature $\psi$ of $\bar H$ is nonzero at the generic point of every component of $C_{\mathbb F_p}$.} Every component of $C_{\mathbb F_p}$ contains a point $x\in D_C$: by (M3) of Definition~\ref{def:v5_mod_mod_kum}, $t$ is non-constant, hence surjective onto $\mathbb P^1_{\mathbb F_p}$, on every component of $X'_{\mathbb F_p}$, and its zeros lie in $Z'$; and $\rho$ is finite and surjective on components. Near $x$, with coordinate $v$ and $q=v^e\cdot(\text{unit})$ , the derivation $D=v\,d/dv$ satisfies $D^p=D$, and the Gauss--Manin connection of the Tate curve (Lemma~\ref{lem:v5_tat_cur_loc}) gives $\nabla_D\omega_{\mathrm{can}}=c\,\xi_{\mathrm{can}}$, $\nabla_D\xi_{\mathrm{can}}=0$, with $c=D(q)/q=\sum_nc_nv^n$ and $c_0=e$. Hence $\psi(D)\omega_{\mathrm{can}}=(\nabla_D^p-\nabla_D)\omega_{\mathrm{can}}=(D^{p-1}(c)-c)\,\xi_{\mathrm{can}}$, and $D^{p-1}(c)-c=-\sum_{p\mid n}c_nv^n$ has constant term $-e\neq0$. (c) \emph{Every local horizontal section of $\bar M$ is $b^pu^{k-2}$ for a unique local section $b$.} Let $K$ be the function field of a component and $D\neq0$ a derivation of $K$; then $\ker D=K^p$. Near the generic point choose $w$ with $u\wedge w=1$; this uses $\wedge^2\bar H\cong\mathcal O$ with the trivial connection (the Weil pairing is horizontal). Then $\nabla_Dw=\alpha u+\beta w$, and $\beta=0$ because $u\wedge\nabla_Dw=\nabla_D(u\wedge w)=0$. If $\alpha=D(a)$ with $a\in K$, then $u$ and $w-au$ are independent horizontal sections and $\psi=0$ at the generic point, contrary to (b); so $\alpha\notin D(K)$. Let $s=\sum_{i=0}^{k-2}c_iu^{k-2-i}w^i$ be horizontal over $K$. Then $D(c_i)+(i+1)\alpha c_{i+1}=0$ for $0\leq i\leq k-2$, with $c_{k-1}=0$. If $c_{i+1}\neq0$ for some $i\geq0$, take $i$ largest; then $D(c_{i+1})=0$, so $c_{i+1}\in K^p$, and $\alpha=D\bigl(-c_i/((i+1)c_{i+1})\bigr)\in D(K)$, using $i+1\leq k-22$ this holds because $\mathbb P^1$ is a curve \cite{locbib:Deligne1974}, (1.10). Let $\bar\eta$ be a geometric generic point of $U_{\bar{\mathbb F}_p}$ and $x_0$ a geometric point of $\mathbb P^1_{\mathbb F_p}$ over $t=0$, with inertia group $I_{x_0}$; by Lemma~\ref{lem:v5_eta_eig_twi}(5), $I_{x_0}$ has neither nonzero invariants nor nonzero coinvariants on $\mathcal F_{\bar a,\bar\eta}$. By \cite[(1.4.1.1), (1.4.1.3)]{locbib:Deligne1980}, $H^0(\mathbb P^1_{\bar{\mathbb F}_p},o_*\mathcal F_{\bar a})$ is the space of invariants and $H^2(\mathbb P^1_{\bar{\mathbb F}_p},o_*\mathcal F_{\bar a})$ the Tate twist of the space of coinvariants of $\pi_1(U_{\bar{\mathbb F}_p},\bar\eta)$ on $\mathcal F_{\bar a,\bar\eta}$; both vanish, as the invariants and the coinvariants of $I_{x_0}$ do. Now Grothendieck's trace formula \cite[(1.4.5.1)]{locbib:Deligne1980}, in its trace form over $\mathbb F_p$, applied to the constructible $L_\lambda$-sheaf $o_*\mathcal F_{\bar a}$ on the proper curve $\mathbb P^1_{\mathbb F_p}$, gives \[ A_{\mathfrak P}=\operatorname{Tr}\bigl(F\mid V_{\bar a}\bigr)=-\sum_{x\in\mathbb P^1(\mathbb F_p)}\operatorname{Tr}\bigl(\mathrm{Frob}_x\mid(o_*\mathcal F_{\bar a})_{\bar x}\bigr). \] As $0,\infty\in S$, $U(\mathbb F_p)=\mathbb F_p\setminus S(\mathbb F_p)$, and by Lemma~\ref{lem:v5_eta_eig_twi}(2) the stalk of $\mathcal F_{\bar a}=\mathbb V_{\chi_G^{-1}}\otimes\mathcal L_{-j}$ at $x\in U(\mathbb F_p)$ has trace $(x/\mathfrak P)_d^{-j}\operatorname{Tr}(\mathrm{Frob}_x\mid\mathbb V_{\chi_G^{-1},\bar x})$. Splitting the sum into $x\in U(\mathbb F_p)$ and $x\in S(\mathbb F_p)$ gives (3). \textbf{Step 6.} $A_{\mathfrak P}$ is integral. By Step 5, $A_{\mathfrak P}=-\sum_{x\in\mathbb P^1(\mathbb F_p)}\operatorname{Tr}(\mathrm{Frob}_x\mid(o_*\mathcal F_{\bar a})_{\bar x})$, and $A_{\mathfrak P}\in L$ by Step 4; so it suffices that each eigenvalue of each $\mathrm{Frob}_x$ on $(o_*\mathcal F_{\bar a})_{\bar x}$ be an algebraic integer. This stalk is a $\mathrm{Frob}_x$-stable subspace of $(o_*\varpi_*M_\ell)_{\bar x}=(\bar\varpi_*o_*M_\ell)_{\bar x}=\bigoplus_{y\in\bar\varpi^{-1}(\bar x)}(o_*M_\ell)_{\bar y}$ (proper base change for the finite $\bar\varpi$), on which $\mathrm{Frob}_x$ permutes the summands. If $y$ lies in an orbit of length $r$, $\mathrm{Frob}_x^r$ acts on $(o_*M_\ell)_{\bar y}$ as the geometric Frobenius of the $\mathbb F_{p^r}$-rational point $y$: for $y\notin D_C$ as $\operatorname{Sym}^{k-2}$ of the Frobenius of the elliptic curve $E_{\rho(y)}$ over $\mathbb F_{p^r}$, whose eigenvalues are algebraic integers of absolute value $p^{r/2}$ \cite{locbib:Silverman2009}, Theorem V.1.1 and V.2.3.1; for $y\in D_C$ trivially, the Galois group acting trivially on the invariant line (proof of Lemma~\ref{lem:v5_loc_ter_agr}, at the cusps). So every eigenvalue of $\mathrm{Frob}_x$ on the direct sum is an $r$-th root of an algebraic integer, hence an algebraic integer. \textbf{Step 7.} Purity gives the weights in (4). The same description shows that for every $r\geq1$ and $x\in U(\mathbb F_{p^r})$ every eigenvalue of $\mathrm{Frob}_x$ on $\mathcal F_{\bar a,\bar x}$ has absolute value $p^{r(k-2)/2}$ under every complex embedding: $\mathcal F_{\bar a}$ is pointwise pure of weight $k-2$. By \cite{locbib:Deligne1980}, Th\'eor\`eme (3.2.3), applied for every isomorphism $\bar{\mathbb Q}_\ell\cong\mathbb C$, the eigenvalues $\alpha',\beta'$ of $F$ on $V_{\bar a}=H^1(\mathbb P^1_{\bar{\mathbb F}_p},o_*\mathcal F_{\bar a})$ have absolute value $p^{(k-1)/2}$ under every complex embedding of $\mathbb Q(\alpha',\beta')$. Extending $\sigma$ to $L(\alpha',\beta')$, $|\sigma(A_{\mathfrak P})|=|\sigma\alpha'+\sigma\beta'|\leq2p^{(k-1)/2}$ and $|\sigma(\varepsilon_{\mathfrak P})|=|\sigma(\alpha'\beta')|/p^{k-1}=1$. \textbf{Step 8.} The stalks at the points of $S$, (5). Let $D$ be the reduction of $\bar S$, a finite set of closed points of $\mathbb P^1_{\mathbb F_p}$ because $\bar S$ is finite and \'etale over $\mathcal O$ (Lemma~\ref{lem:v5_eta_eig_twi}(1)), so that $U_{\mathbb F_p}=\mathbb P^1_{\mathbb F_p}\setminus D$, and let $x\in S(\mathbb F_p)$, a point of $D$. The stalk of $o_*\mathcal F_{\bar a}$ at $\bar x$ is the space of invariants of a local monodromy group \cite{locbib:Deligne1974}, (2.11): the strict henselisation of $\mathbb P^1_{\bar{\mathbb F}_p}$ at $x$ is a henselian discrete valuation ring whose fraction field has absolute Galois group $I_x$, so $(o_*\mathcal F_{\bar a})_{\bar x}=\mathcal F_{\bar a,\bar\eta}^{I_x}$; as $x$ is $\mathbb F_p$-rational, $\mathrm{Frob}_x$ acts on it through a Frobenius element of a decomposition group at $x$, which normalises $I_x$. The isomorphism $\mathcal F_{\bar a}\cong\mathbb V_{\chi_G^{-1}}\otimes\mathcal L_{-j}$ of Lemma~\ref{lem:v5_eta_eig_twi}(2) on $U_{\mathbb F_p}$ identifies this space, compatibly with $\mathrm{Frob}_x$, with $(\mathbb V_{\chi_G^{-1}}\otimes\mathcal L_{-j})_{\bar\eta}^{I_x}$. This proves (5). \textbf{Step 9.} Complex conjugation, (6). The field $L$ is generated over $\mathbb Q$ by roots of unity and square roots of integers (Definition~\ref{def:v5_exc_set_kum}), so it is abelian over $\mathbb Q$. Let $\sigma:L\to\mathbb C$ be an embedding. As $L\subset\mathbb C$ is Galois over $\mathbb Q$, $\sigma$ is the restriction of some $\tau\in\operatorname{Gal}(L/\mathbb Q)$, and complex conjugation restricts to an automorphism $\xi\mapsto\bar\xi$ of $L$; since $\operatorname{Gal}(L/\mathbb Q)$ is abelian, \[ \overline{\sigma(\xi)}=\overline{\tau(\xi)}=\tau(\bar\xi)=\sigma(\bar\xi)\qquad(\xi\in L). \] Let $\alpha'$, $\beta'$ be the roots of $X^2-A_{\mathfrak P}X+\varepsilon_{\mathfrak P}p^{k-1}$, the eigenvalues of $F$ on $V_{\bar a}$, and extend $\sigma$ to an embedding $\tilde\sigma$ of $L(\alpha',\beta')$ in $\mathbb C$. By (4), $|\tilde\sigma\alpha'|^2=|\tilde\sigma\beta'|^2=p^{k-1}$, so $\overline{\tilde\sigma\alpha'}=p^{k-1}/\tilde\sigma\alpha'$ and $\overline{\tilde\sigma\beta'}=p^{k-1}/\tilde\sigma\beta'$. As $\tilde\sigma\alpha'+\tilde\sigma\beta'=\sigma(A_{\mathfrak P})$ and $\tilde\sigma\alpha'\,\tilde\sigma\beta'=\sigma(\varepsilon_{\mathfrak P})p^{k-1}$, \[ \sigma\bigl(\overline{A_{\mathfrak P}}\bigr)=\frac{p^{k-1}}{\tilde\sigma\alpha'}+\frac{p^{k-1}}{\tilde\sigma\beta'}=\frac{\sigma(A_{\mathfrak P})}{\sigma(\varepsilon_{\mathfrak P})},\qquad\sigma\bigl(\overline{\varepsilon_{\mathfrak P}}\bigr)=\frac{\overline{\tilde\sigma\alpha'}\;\overline{\tilde\sigma\beta'}}{p^{k-1}}=\frac1{\sigma(\varepsilon_{\mathfrak P})}. \] As $\sigma$ is injective, $\overline{A_{\mathfrak P}}=A_{\mathfrak P}/\varepsilon_{\mathfrak P}$ and $\overline{\varepsilon_{\mathfrak P}}=\varepsilon_{\mathfrak P}^{-1}$. The last assertion of (6) is then the second sentence of (2). \end{proof} \begin{lemma}\label{lem:v5_twi_lef_for} Let $H_{\mathrm{cris}}\subset H_{\mathbb Z}\otimes\mathbb Q_p$ be the subspace of classes all of whose residues $\operatorname{Res}_z$ vanish, with the action $x\mapsto g^*x$ of $\tilde G$ of Lemma~\ref{lem:v5_par_eig_the}(1). Let $\widehat C$ be the $p$-adic completion of $C\otimes\mathbb Z_p$, regard $M_k$ as an $F$-crystal with logarithmic singularities on $(\widehat C,\widehat D_C)$ in the sense of \cite{locbib:Scholl1985Trace}, 1.5, and let $\Omega^\bullet(M_k)$ be the complex of loc.\ cit., 2.5. Put $C_0=C\otimes\mathbb F_p$, $C_0^\circ=C_0\setminus D_C$ and $o:C_0^\circ\hookrightarrow C_0$. Let $\ell\neq p$ be a prime, $\lambda$ a prime of $L$ above $\ell$, $M_\ell=\rho^*\operatorname{Sym}^{k-2}R^1\pi_{E*}\mathbb Q_\ell\otimes_{\mathbb Q_\ell}L_\lambda$ on $C_0^\circ$, for the structure map $\pi_E:E\to X'$, with the action of $\tilde G$ by the maps $\zeta^\sharp g^\sharp$, where $g^\sharp=c_g\operatorname{Sym}^{k-2}(\pi_g^*)\circ g^*$ and $\zeta^\sharp=[\zeta]^*$, and $H_\ell=H^1(C_{0,\bar{\mathbb F}_p},o_*M_\ell)$, with the geometric Frobenius $F$ and the induced right action $g\mapsto g^*$. For $n\geq1$ put $q=p^n$, let $\mathrm{Fr}_q$ be the $q$-power Frobenius endomorphism of $C_{\bar{\mathbb F}_p}$, and for $g\in\tilde G$ put \[ \operatorname{Fix}_q(g)=\{y\in C(\bar{\mathbb F}_p):\ \mathrm{Fr}_q(y)=g(y)\}. \] \begin{enumerate} \item $H^i(\widehat C,\Omega^\bullet(M_k))\otimes\mathbb Q_p=0$ and $H^i(C_{0,\bar{\mathbb F}_p},o_*M_\ell)=0$ for $i\neq1$, and $H^1(\widehat C,\Omega^\bullet(M_k))\otimes\mathbb Q_p=H_{\mathrm{cris}}$. \item Let $n\geq1$, $q=p^n$ and $g\in\tilde G$. There are a smooth projective curve $C^{(g)}$ over $W(\mathbb F_q)$ with a divisor $D^{(g)}$ finite \'etale over $W(\mathbb F_q)$, an $F$-crystal with logarithmic singularities $M^{(g)}$ on $(\widehat{C^{(g)}},\widehat{D^{(g)}})$ satisfying the conditions 1.7 of loc.\ cit., and a lisse $L_\lambda$-sheaf $M^{(g)}_\ell$ on $C^{(g)}_{\mathbb F_q}\setminus D^{(g)}$, which become $(C,D_C,M_k)$ and $(C_0^\circ,M_\ell)$ after base change to $W(\bar{\mathbb F}_p)$, respectively $\bar{\mathbb F}_p$, in such a way that the $q$-power Frobenius endomorphism of $C^{(g)}_{\mathbb F_q}$ becomes $g^{-1}\circ\mathrm{Fr}_q$, so that $C^{(g)}(\mathbb F_q)=\operatorname{Fix}_q(g)$, and the $q$-linear Frobenius on the cohomology of the twisted objects becomes $\varphi^n(g^{-1})^*$ on $H_{\mathrm{cris}}$ and $F^n(g^{-1})^*$ on $H_\ell$. For $y\in\operatorname{Fix}_q(g)$ let $\Psi^{\mathrm{cris}}_{g,y}$ be the $q$-linear Frobenius at $y$ of $M^{(g)}$ on $B^{\mathrm{cris}}_y=\operatorname{coker}(R_y)\otimes\mathbb Q$, where $R_y$ is the residue map of $M^{(g)}$ at $y$ ($R_y=0$ if $y\notin D_C$), and $\Psi^\ell_{g,y}$ the geometric Frobenius at $y$ on $B^\ell_y=(o_*M^{(g)}_\ell)_{\bar y}$. Then $\operatorname{Fix}_q(g)$ is finite and \[ \begin{aligned} \operatorname{Tr}\bigl(g^*\varphi^{-n}\mid H_{\mathrm{cris}}\bigr) &=-q^{-1}\sum_{y\in\operatorname{Fix}_q(g)} \operatorname{Tr}\bigl((\Psi^{\mathrm{cris}}_{g,y})^{-1} \mid B^{\mathrm{cris}}_y\bigr),\\ \operatorname{Tr}\bigl(F^n(g^{-1})^*\mid H_\ell\bigr) &=-\sum_{y\in\operatorname{Fix}_q(g)} \operatorname{Tr}\bigl(\Psi^\ell_{g,y}\mid B^\ell_y\bigr). \end{aligned} \] \item Let $y\in\operatorname{Fix}_q(g)\setminus D_C$, $g=(h,\zeta)$, and $x=\rho(y)$, so that $\mathrm{Fr}_q(x)=h(x)$. After extending scalars to $W(\kappa(x))$, $\Psi^{\mathrm{cris}}_{g,y}$ becomes $c_h\operatorname{Sym}^{k-2}(u_{g,y}^*)$ on $\operatorname{Sym}^{k-2}H^1_{\mathrm{cris}}(E_x/W(\kappa(x)))\otimes\mathbb Q$, and $\Psi^\ell_{g,y}$ is $c_h\operatorname{Sym}^{k-2}(u_{g,y}^*)$ on $\operatorname{Sym}^{k-2}H^1(E_{\bar x},\mathbb Q_\ell)\otimes L_\lambda$, where \[ u_{g,y}=\hat\pi_{h,x}\circ F_{x,q}\in\operatorname{End}_{\kappa(x)}(E_x), \] $F_{x,q}:E_x\to E_x^{(q)}=E_{h(x)}$ is the relative $q$-power Frobenius, $\hat\pi_{h,x}:E_{h(x)}\to E_x$ is the dual of the fibre at $x$ of the isogeny $\pi_h:E\to h^*E$ of (M2), and $c_h$ is the constant of (M2). \end{enumerate} \end{lemma} \begin{proof} The formulas of (2) are Scholl's and Grothendieck's trace formulas, applied to the forms of $(C,D_C,M_k)$ and of $M_\ell$ twisted by $g$, on a curve whose $\mathbb F_q$-points are $\operatorname{Fix}_q(g)$; this twisting (Step 3, after Scholl) is the idea of the proof. Write $K$ for the log de Rham complex $M_k\to M_k\otimes\Omega^1_{C/\mathbb Z_p}(\log D_C)$ on $C_{\mathbb Z_p}$, so that $H_{\mathbb Z}=\mathbb H^1(C_{\mathbb Z_p},K)$ is the twisted crystal. \textbf{Step 1: the crystalline side of (1).} The terms of $\Omega^\bullet(M_k)$ and of $K$ are coherent on the proper $\mathbb Z_p$-scheme $C_{\mathbb Z_p}$, so by \cite{locbib:EGAIII1}, (4.1.5), and the hypercohomology spectral sequences, $\mathbb H^i(\widehat C,\widehat K)=\mathbb H^i(C_{\mathbb Z_p},K)$, and likewise for $\Omega^\bullet(M_k)$. The residues of $\nabla$ along $D_C$ are nilpotent (Lemma~\ref{lem:v5_tat_cur_loc}, and (M1)), $M_k$ is locally free, and its Frobenius is an isogeny, so $M_k$ satisfies the conditions 1.7 of \cite{locbib:Scholl1985Trace}. The exact sequence $0\to\Omega^\bullet(M_k)\to \widehat K\to\operatorname{coker}(R_{D_C})[-1]\to0$ of loc.\ cit., 2.5 and (5.6.1), gives, after tensoring with $\mathbb Q$, \[ \begin{aligned} 0&\to H^0(\Omega^\bullet)\to H^0(K)\to0,\\ 0&\to H^1(\Omega^\bullet)\to H^1(K)\xrightarrow{\ r\ }\operatorname{coker}(R_{D_C})\to H^2(\Omega^\bullet)\to H^2(K)\to0 , \end{aligned} \] where $r$ is induced by $\mathrm{id}\otimes\operatorname{res}_{D_C}$. At $z\in D_C$ the cokernel of the residue is spanned by $e_0$ and $r$ is $\operatorname{Res}_z$ (proof of Lemma~\ref{lem:v5_par_eig_the}(3), Reduction); so $H^1(\Omega^\bullet)\otimes\mathbb Q=H_{\mathrm{cris}}$. Scholl's endomorphism $F$ of these groups (loc.\ cit., 2.3) is the crystalline Frobenius $\varphi$: both are computed on a \v{C}ech--de Rham complex of an affine open cover of $\widehat C$ with admissible (that is, logarithmic) local Frobenius lifts, glued by the homotopies $L(\phi',\phi)$ of loc.\ cit., 2.1, which is the description of the logarithmic crystalline Frobenius through a log-smooth lifting \cite{locbib:Kato1989}, \S6, used in Lemma~\ref{lem:v5_exp_cus_fro}(1),(3). Likewise $g^*$ is the action of loc.\ cit., 7.2, for the pairs $(g,g^\sharp)$. For $H^0$, the proof of Lemma~\ref{lem:v5_par_eig_the}(1) shows that $M_k\otimes\mathbb F_p$ has no nonzero horizontal global sections, that is $H^0(C_{\mathbb F_p},K/p)=0$. As $H^0(K)$ is a finitely generated $\mathbb Z_p$-module and $H^0(K)/p\hookrightarrow H^0(K/p)$, Nakayama's lemma gives $H^0(K)=0$, hence $H^0(\Omega^\bullet)=0$. For $H^2$ we pass to $\mathbb C$. Fix a field embedding $\iota:\mathbb Q_p\to\mathbb C$ that is the identity on $L$. Coherent cohomology commutes with flat base change, so it suffices to show that $\mathbb H^2(C_{\mathbb C},K)=0$ and that $r\otimes_\iota\mathbb C$ is surjective. By \cite{locbib:Deligne1970}, II, \S\S5--6, as in the proof of Lemma~\ref{lem:v5_par_eig_the}(3) (Topology), $\mathbb H^i(C_{\mathbb C},K)=H^i(C^{\mathrm{an}}\setminus D_C,\operatorname{Sym}^{k-2}\mathbb V)$ with $\mathbb V=R^1\pi_{E*}\mathbb C$, and $r\otimes\mathbb C$ is the restriction to the punctured discs $\Delta_z^*$ around the points of $D_C$. Every connected component of $C_{\mathbb C}$ meets $D_C$: $t\circ\rho$ is non-constant on it (M3) and its zeros lie in $\rho^{-1}(Z')$. So each component of $C^{\mathrm{an}}\setminus D_C$ is a non-compact Riemann surface, on which $H^2$ of a local system vanishes. The cokernel of the restriction $H^1(C^{\mathrm{an}}\setminus D_C,\operatorname{Sym}^{k-2}\mathbb V)\to\bigoplus_zH^1(\Delta_z^*,\operatorname{Sym}^{k-2}\mathbb V)$ injects into $H^2_c(C^{\mathrm{an}}\setminus D_C,\operatorname{Sym}^{k-2}\mathbb V)$, which is dual to $H^0(C^{\mathrm{an}}\setminus D_C,\operatorname{Sym}^{k-2}\mathbb V^\vee)$ by Poincar\'e duality. This vanishes: $\mathbb V^\vee\cong\mathbb V$ by the Weil pairing, and on each component the monodromy of $\operatorname{Sym}^{k-2}\mathbb V$ contains $\operatorname{Sym}^{k-2}$ of a subgroup of finite index of $\mathrm{SL}_2(\mathbb Z)$, Zariski dense in $\mathrm{SL}_2$, which has no nonzero invariants as $k\geq3$ (proof of Lemma~\ref{lem:v5_par_eig_the}(3), Descent). So $H^2(\Omega^\bullet)\otimes\mathbb Q=0$. \textbf{Step 2: the $\ell$-adic side of (1).} We first show $H^0(C_{0,\bar{\mathbb F}_p},o_*M_\ell)=H^0(C^\circ_{0,\bar{\mathbb F}_p},M_\ell)=0$. Let $V$ be the strict henselisation of $\mathcal O_{L,(\mathfrak P)}$ and $\bar\eta$ a geometric generic point of $\operatorname{Spec}V$. The sheaf $M_\ell$ is the restriction to the special fibre of the sheaf $\rho^*\operatorname{Sym}^{k-2}R^1\pi_{E*}\mathbb Q_\ell\otimes L_\lambda$ on $C^\circ_V=(C\setminus D_C)_V$, which has the lattice $\rho^*\operatorname{Sym}^{k-2}R^1\pi_{E*}\mathbb Z_\ell\otimes\mathcal O_\lambda$; let $M_n$ be its reduction modulo $\lambda^n$, a locally constant constructible sheaf. The morphism $C^\circ_V\to\operatorname{Spec}V$ is smooth, hence locally acyclic relative to $M_n$ \cite{locbib:SGA4vol3}, Exp.~XV. The $M_n$ are tamely ramified along the relative normal crossings divisor $D_{C,V}$, finite \'etale over $V$: near $D_C$ they are trivialised by adjoining $\ell^n$-th roots of the Tate parameter of (M1), a Kummer covering of degree prime to $p$. So by \cite{locbib:SGA4half}, Th.~finitude, Appendice, 1.3.3, the formation of $Ro_*M_n$ commutes with base change, and by the proper base change theorem so does the formation of $R\Gamma(C^\circ,M_n)$; by loc.\ cit., 2.4, specialisation and cospecialisation are then inverse isomorphisms between the cohomology of the special and of the generic geometric fibre. Passing to the limit, $H^0(C^\circ_{0,\bar{\mathbb F}_p},M_\ell)\cong H^0(C^\circ_{\bar\eta},M_\ell)$. The latter vanishes: after an extension of algebraically closed fields of characteristic zero, which does not change \'etale cohomology, Artin's comparison theorem \cite{locbib:SGA4vol3}, Exp.~XVI, Th.~4.1, identifies it with the space of global monodromy invariants of $\operatorname{Sym}^{k-2}\mathbb V\otimes L_\lambda$ on $C^{\mathrm{an}}\setminus D_C$, which is zero as in Step 1. The dual of $M_\ell$ is $M_\ell(k-2)$ (the pairing of Lemma~\ref{lem:v5_kum_eig_pai}(1), pulled back by $\rho$), so by Poincar\'e duality $H^2(C_{0,\bar{\mathbb F}_p},o_*M_\ell)$ is dual to $H^0(C_{0,\bar{\mathbb F}_p},o_*(M_\ell^\vee)(1))=H^0(C_{0,\bar{\mathbb F}_p},o_*M_\ell)(k-1)=0$. Groups $H^i$ with $i>2$ vanish on a curve. This proves (1). \textbf{Step 3: twisted forms.} We construct the objects of (2) as in \cite{locbib:Scholl1985}, proof of Proposition 4.4, (4.4.3)--(4.4.4). Let $m$ be the order of $g$ in $\tilde G$, $R_1=W(\mathbb F_q)$, $R_m=W(\mathbb F_{q^m})$, and $\tau\in\operatorname{Gal}(R_m/R_1)$ the $q$-power Frobenius. The group $\tilde G$ acts on $C\otimes\mathbb Z_p$ over $\mathbb Z_p$ ($G$ over $\mathcal O_{L,(\mathfrak P)}\subset\mathbb Z_p$, and $\mu_d(\mathbb Z_p)$ through $s\mapsto\zeta s$), preserving $D_C$. Let $\gamma$ be the $\tau$-semilinear automorphism $g\otimes\tau$ of $C_{R_m}=C\otimes R_m$; as $g$ commutes with the $\mathbb Z_p$-structure, $\gamma^m=1$, and $\langle\gamma\rangle$ acts on $\operatorname{Spec}R_m$ through $\operatorname{Gal}(R_m/R_1)$, freely. Since $C$ is projective, Galois descent \cite{locbib:BLR1990}, \S6.2, Example B, gives a smooth projective $R_1$-scheme $C^{(g)}$ with $C^{(g)}\otimes_{R_1}R_m=C_{R_m}$ on which the descent datum is $\gamma$, and likewise $D^{(g)}$, finite \'etale over $R_1$. The isomorphisms $\gamma^*M_k\cong M_k$ given by $g^\sharp$ and the base change along $\tau$ are compatible with $\nabla$, the Hodge filtration and the Frobenius structures (M2), and satisfy the cocycle condition because $g\mapsto g^\sharp$ is an action (proof of Lemma~\ref{lem:v5_eta_eig_twi}, Step 5). So, by faithfully flat descent of modules with connection, the morphisms $F_\phi$ descending as they commute with the descent datum \cite{locbib:Scholl1985Trace}, 7.2, $M_k$ descends to an $F$-crystal with logarithmic singularities $M^{(g)}$ on $(\widehat{C^{(g)}},\widehat{D^{(g)}})$, which satisfies the conditions 1.7 of loc.\ cit.\ because they can be checked after the faithfully flat base change to $R_m$. In the same way, \'etale descent along $C_{\mathbb F_{q^m}}\to C^{(g)}_{\mathbb F_q}$ gives $M^{(g)}_\ell$ from $M_\ell$ and the maps $g^\sharp$. The arithmetic Frobenius of the twisted $\mathbb F_q$-structure is $\gamma$; as the absolute $q$-power Frobenius is the identity on closed points, the $q$-power Frobenius endomorphism of $C^{(g)}_{\mathbb F_q}$ acts on $C(\bar{\mathbb F}_p)$ as $\mathrm{Fr}_q\circ g^{-1}=g^{-1}\circ\mathrm{Fr}_q$. Hence $C^{(g)}(\mathbb F_q)=\operatorname{Fix}_q(g)$, a finite set. On cohomology, which commutes with the base changes $R_1\to R_m$ and $\mathbb F_q\to\bar{\mathbb F}_p$, the $q$-linear Frobenius of the twisted objects is the pull-back along $g^{-1}\circ\mathrm{Fr}_q$, that is $\varphi^n(g^{-1})^*$ on $H^\bullet(\widehat C,\Omega^\bullet(M_k))\otimes R_m$ (compare (4.4.4) of \cite{locbib:Scholl1985}) and $F^n(g^{-1})^*$ on $H^\bullet(C_{0,\bar{\mathbb F}_p},o_*M_\ell)$, the formation of $o_*$ commuting with the extension $\mathbb F_q\to\bar{\mathbb F}_p$. At $y\in\operatorname{Fix}_q(g)$ the fibre of the twisted objects is the fibre at $y$, and the Frobenius at $y$ is the composite of $(g^\sharp)^{-1}$, from the fibre at $y$ to the fibre at $g(y)=\mathrm{Fr}_q(y)$, with the $q$-power Frobenius of the crystal, respectively of the sheaf, from the fibre at $\mathrm{Fr}_q(y)$ to that at $y$. \textbf{Step 4: the two trace formulas.} We apply \cite{locbib:Scholl1985Trace}, Theorem 5.2(ii), to $(C^{(g)},D^{(g)},M^{(g)})$ over $R=R_1$, whose absolute ramification index $1$ is less than $p-1$, with residue field $\mathbb F_q$, $q=p^n$ odd, and with the integer $s$ of loc.\ cit.\ equal to $1$: \[ \sum_i(-1)^i\operatorname{Tr}\bigl(F'^{-n}\mid H^i(\widehat{C^{(g)}},\Omega^\bullet(M^{(g)}))_{\mathbb Q}\bigr)=q^{-1}\sum_{y\in C^{(g)}(\mathbb F_q)}\operatorname{Tr}\bigl((\Psi^{\mathrm{cris}}_{g,y})^{-1}\mid\operatorname{coker}(R_y)_{\mathbb Q}\bigr), \] where $F'$ is the $\sigma$-linear Frobenius of the twisted crystal, so that $F'^{n}$ is $R_1$-linear. By Step 3 and (1), after extending scalars to $R_m$ only $i=1$ contributes, and $F'^{-n}$ becomes $(\varphi^n(g^{-1})^*)^{-1}=g^*\varphi^{-n}$ on $H_{\mathrm{cris}}\otimes R_m$; traces are unchanged by extension of scalars. This is the first formula of (2). For the second, Grothendieck's trace formula \cite[(1.4.5.1)]{locbib:Deligne1980}, in its trace form over $\mathbb F_q$, applied to the constructible $L_\lambda$-sheaf $o_*M^{(g)}_\ell$ on the proper curve $C^{(g)}_{\mathbb F_q}$, gives $\sum_i(-1)^i\operatorname{Tr}(F^n(g^{-1})^*\mid H^i(C_{0,\bar{\mathbb F}_p},o_*M_\ell))=\sum_{y\in\operatorname{Fix}_q(g)}\operatorname{Tr}(\Psi^\ell_{g,y}\mid B^\ell_y)$, and (1) removes $i\neq1$. \textbf{Step 5: the local operators off the cusps, (3).} For $g=(h,\zeta)$ the factor $\zeta$ acts on $C$ over $X'$ and trivially on the fibres of $M_k=\rho^*\operatorname{Sym}^{k-2}H$ and of $M_\ell$; so $\rho(g(y))=h(x)$, and as $\rho$ commutes with $\mathrm{Fr}_q$, $\mathrm{Fr}_q(x)=h(x)$. The fibre of $H$ at (a lift of) $x$ is $H^1_{\mathrm{cris}}(E_x/W(\kappa(x)))$, and the Frobenius structure of the crystal $H$ restricts on fibres to the map induced by the relative Frobenius of $E$ over $X'$ \cite{locbib:BerthelotOgus1978}, \S7; so the $q$-power Frobenius from the fibre at $h(x)=\mathrm{Fr}_q(x)$ to the fibre at $x$ is $\operatorname{Sym}^{k-2}(F_{x,q}^*)$, and likewise for $R^1\pi_{E*}\mathbb Q_\ell$. On fibres, $g^\sharp=c_h\operatorname{Sym}^{k-2}(\pi_{h,x}^*)$ from the fibre at $h(x)$ to that at $x$. As $\pi_{h,x}^*\hat\pi_{h,x}^*=(\hat\pi_{h,x}\pi_{h,x})^*=\deg\pi_h$ on $H^1$ and $c_h^2(\deg\pi_h)^{k-2}=1$, its inverse is \[ (g^\sharp)^{-1}=c_h^{-1}(\deg\pi_h)^{-(k-2)}\operatorname{Sym}^{k-2}(\hat\pi_{h,x}^*)=c_h\operatorname{Sym}^{k-2}(\hat\pi_{h,x}^*). \] So $\Psi_{g,y}=\operatorname{Sym}^{k-2}(F_{x,q}^*)\circ c_h\operatorname{Sym}^{k-2}(\hat\pi_{h,x}^*)=c_h\operatorname{Sym}^{k-2}((\hat\pi_{h,x}\circ F_{x,q})^*)$ in both theories. Both $F_{x,q}$ and $\hat\pi_{h,x}$ are defined over $\kappa(x)$, which contains the residue field of $h(x)=\mathrm{Fr}_q(x)$. \end{proof} \begin{lemma}\label{lem:v5_loc_ter_agr} Let $\ell\neq p$ be a prime, $\lambda$ a prime of $L$ above $\ell$, $n\geq1$, $q=p^n$ and $g=(h,\zeta)\in\tilde G$, and let $\operatorname{Fix}_q(g)$, the local Frobenius operators $\Psi^{\mathrm{cris}}_{g,y}$ on $B^{\mathrm{cris}}_y$ and $\Psi^\ell_{g,y}$ on $B^\ell_y$, and the endomorphisms $u_{g,y}$ be those of Lemma~\ref{lem:v5_twi_lef_for}(2),(3). Let $y\in\operatorname{Fix}_q(g)$. Then $\operatorname{Tr}(\Psi^\ell_{g,y}\mid B^\ell_y)$ lies in $L$, and \[ q^{-1}\operatorname{Tr}\bigl((\Psi^{\mathrm{cris}}_{g,y})^{-1}\mid B^{\mathrm{cris}}_y\bigr)=q^{-(k-1)}\,\iota_{\mathfrak P}\operatorname{Tr}\bigl(\Psi^\ell_{g,y}\mid B^\ell_y\bigr). \] More precisely: \begin{enumerate} \item If $y\notin D_C$, let $x=\rho(y)$ and $u=u_{g,y}$, and let $\alpha,\beta$ be the roots of the characteristic polynomial $P_u(X)=X^2-\operatorname{tr}(u)X+\deg u\in\mathbb Z[X]$ of $u^*$ on $H^1(E_{\bar x},\mathbb Q_\ell)$. Then $P_u$ is also the characteristic polynomial of $u^*$ on $H^1_{\mathrm{cris}}(E_x/W(\kappa(x)))\otimes\mathbb Q$, and \[ \operatorname{Tr}(\Psi^{\mathrm{cris}}_{g,y})=\iota_{\mathfrak P}\operatorname{Tr}(\Psi^\ell_{g,y})=c_h\sum_{i=0}^{k-2}\alpha^i\beta^{k-2-i},\qquad\operatorname{Tr}\bigl((\Psi^{\mathrm{cris}}_{g,y})^{-1}\bigr)=q^{-(k-2)}\operatorname{Tr}(\Psi^{\mathrm{cris}}_{g,y}). \] \item If $y\in D_C$, then $B^{\mathrm{cris}}_y$ and $B^\ell_y$ are lines, and there is a nonzero integer $r_y$ such that $\Psi^{\mathrm{cris}}_{g,y}$ acts by $c_h(qr_y)^{k-2}$ and $\Psi^\ell_{g,y}$ by $c_h(\deg\pi_h/r_y)^{k-2}$; $r_y$ is the degree on the tori of the Tate parametrisations of the restriction of $\hat\pi_h$ to the punctured formal neighbourhood of the cusp. \end{enumerate} \end{lemma} \begin{proof} \textbf{Off the cusps.} Let $y\notin D_C$. By Lemma~\ref{lem:v5_twi_lef_for}(3) both local operators are $c_h\operatorname{Sym}^{k-2}(u^*)$, with $u=u_{g,y}$ an endomorphism of the elliptic curve $E_x$ over the finite field $\kappa(x)$, of degree $\deg u=q\deg\pi_h$. The graph of $u$ is a cycle of dimension one with integer coefficients on $E_x\times E_x$, and $E_x$ is projective, smooth and absolutely irreducible; by \cite{locbib:KatzMessing1974}, Theorem 2(2), its characteristic polynomial on $H^1$ lies in $\mathbb Z[X]$ and is the same for $\ell$-adic cohomology and for crystalline cohomology tensored with the fraction field of $W(\bar{\mathbb F}_p)$, the latter being a Weil cohomology by \cite{locbib:GilletMessing1987}. On $\ell$-adic $H^1$ this polynomial is $X^2-\operatorname{tr}(u)X+\deg u$ \cite{locbib:Silverman2009}, Proposition III.8.6 (on the Tate module, whose dual is $H^1$). So in both theories $\operatorname{Sym}^{k-2}(u^*)$ has eigenvalues $\alpha^i\beta^{k-2-i}$, $0\leq i\leq k-2$, and its trace $\sum_i\alpha^i\beta^{k-2-i}$, a symmetric polynomial in $\alpha,\beta$ with integer coefficients, is an integer; as $c_h\in L$ (M2) acts on crystalline cohomology through $\iota_{\mathfrak P}$, $\operatorname{Tr}(\Psi^\ell_{g,y})\in L$ and $\operatorname{Tr}(\Psi^{\mathrm{cris}}_{g,y})=\iota_{\mathfrak P}\operatorname{Tr}(\Psi^\ell_{g,y})$. For the inverse, $\alpha\beta=q\deg\pi_h$ and $c_h^{-1}(\deg\pi_h)^{-(k-2)}=c_h$, which is the normalisation $c_h^2=(\deg\pi_h)^{-(k-2)}$ of (M2), give \[ c_h^{-1}\alpha^{-i}\beta^{-(k-2-i)}=c_h^{-1}(\alpha\beta)^{-(k-2)}\alpha^{k-2-i}\beta^{i}=q^{-(k-2)}\,c_h\,\alpha^{k-2-i}\beta^{i}, \] so the eigenvalues of $(\Psi^{\mathrm{cris}}_{g,y})^{-1}$ are those of $q^{-(k-2)}\Psi^{\mathrm{cris}}_{g,y}$. This proves (1). \textbf{At the cusps.} Let $y\in D_C$, $z=\rho(y)\in Z'(\bar{\mathbb F}_p)$ and $W=W(\bar{\mathbb F}_p)$; then $h(z)=\mathrm{Fr}_q(z)$ (Step 5 of the proof of Lemma~\ref{lem:v5_twi_lef_for}). As $Z'$ and $D_C$ are \'etale over $\mathcal O_{L,(\mathfrak P)}$ , $y$, $g(y)$, $z$, $h(z)$ have unique lifts $\tilde y,\widetilde{g(y)}\in D_C(W)$, $\tilde z,\widetilde{h(z)}\in Z'(W)$, and $\widetilde{h(z)}=\sigma^n(\tilde z)$ for the Frobenius $\sigma$ of $W$, as $X'$ and $Z'$ are defined over $\mathcal O_{L,(\mathfrak P)}\subset\mathbb Z_p$. Fix data $(q_z,\delta_z,m_z)$ as in (M1) at $\tilde z$, take the $\sigma^n$-conjugate data at $\widetilde{h(z)}$, and transport both to the cusps of $C$ above them as in the proof of Lemma~\ref{lem:v5_par_eig_the}(2): with a formal parameter $v$ of $C_W$ along $\tilde y$, the pull-back of $E$ to $\operatorname{Spf}W[[v]]$ is $\mathrm{Tate}(Q)$, $Q=\delta v^m$, $\delta\in W^\times$, $m$ prime to $p$; likewise along $\widetilde{g(y)}$. Both spaces are lines. In the basis $e_i=\omega^{k-2-i}\xi^i$ of Lemma~\ref{lem:v5_tat_cur_loc}, $\omega=\omega_{\mathrm{can}}$, the residue $R_y$ maps $e_i$ to $(k-2-i)m\,e_{i+1}$, so $B^{\mathrm{cris}}_y$ is the line spanned by the image of $e_0=\omega^{\otimes(k-2)}$. Let $K_y$ be the fraction field of the strict henselisation of $C_{0,\bar{\mathbb F}_p}$ at $y$, with inertia group $I$. Over $K_y$, $E$ is the Tate curve $\mathrm{Tate}(Q)$ with $Q$ of valuation $m\geq1$, and $\mathrm{Tate}(Q)[\ell^\nu]$ is an extension of $\mathbb Z/\ell^\nu$ by $\mu_{\ell^\nu}$, the quotient being generated by the class of an $\ell^\nu$-th root of $Q$ \cite{locbib:DeligneRapoport1973}, VII, \S1. So $I$ acts on $T_\ell(E)$ through a nontrivial unipotent group, trivially on $T_\ell(\mu)$ and on $T_\ell(E)/T_\ell(\mu)\cong\mathbb Z_\ell$, and $H^1(E,\mathbb Q_\ell)^I$ is the line dual to $T_\ell(E)/T_\ell(\mu)$, on which the whole Galois group of $K_y$ acts trivially. As $\operatorname{Sym}^{k-2}$ of a nontrivial unipotent automorphism of a plane has one-dimensional invariants, $B^\ell_y=(o_*M_\ell)_{\bar y}=\operatorname{Sym}^{k-2}(H^1(E,\mathbb Q_\ell)^I)\otimes L_\lambda$ is a line. Over $B=\operatorname{Spec}W[[v]][\frac1v]$, which maps to $Y'$, the isogeny $\hat\pi_h:h^*E\to E$ restricts to an isogeny $\psi:\mathrm{Tate}(Q')\to\mathrm{Tate}(Q)$ of degree $\deg\pi_h$, where $\mathrm{Tate}(Q')$ is the pull-back along $g$ of the Tate curve along $\widetilde{g(y)}$. Let $R_0$ be the local ring of $C_W$ at the generic point of the divisor $\tilde y$, a discrete valuation ring with residue field $\kappa_0=\operatorname{Frac}W$ of characteristic zero and completion $\kappa_0[[v]]$, the ideal of $\tilde y$ in $W[[v]]$ being $(v)$; its fraction field is the function field of $C_W$, to which the generic point of $B$ maps. Over $\operatorname{Frac}R_0$ both curves have split multiplicative reduction, and the special fibre of the identity component of their N\'eron models is the torus $\mathbb G_{m,\kappa_0}$ of the Tate parametrisation, on which $\omega_{\mathrm{can}}$ restricts to $dx/x$ and whose $\ell^\nu$-torsion is the reduction of the subgroup scheme $\mu_{\ell^\nu}\subset\mathrm{Tate}(\cdot)[\ell^\nu]$ \cite{locbib:DeligneRapoport1973}, VII, \S1, \cite{locbib:Silverman2009}, Proposition VII.5.1. By the N\'eron mapping property \cite{locbib:BLR1990}, \S1.2, Definition 1, $\psi$ extends to the N\'eron models, and on the special fibres of the identity components it is a homomorphism of tori, $x\mapsto x^{r_y}$ with $r_y\in\mathbb Z\setminus\{0\}$, as $\psi$ is an isogeny. Hence the function $\psi^*\omega_{\mathrm{can}}/\omega_{\mathrm{can}}$, which lies in $W[[v]]$ because $c_h\operatorname{Sym}^{k-2}(\hat\pi_h^*)$ extends to the logarithmic crystal (M2), takes the value $r_y$ at $v=0$. Moreover $\psi$ maps $\mu_{\ell^\nu}$ by $x\mapsto x^{r_y}$ over $R_0$. Indeed, both are morphisms from $\mu_{\ell^\nu,R_0}$, a disjoint union of copies of the local scheme $\operatorname{Spec}R_0$ because $W$ contains $\mu_{\ell^\nu}$, to an \'etale separated $R_0$-scheme, and they agree on the closed point of each copy; the locus where two such morphisms agree is open and closed, the diagonal of an \'etale separated morphism being an open and closed immersion. The same argument over $B$, the components of $\mu_{\ell^\nu,B}$ being copies of the integral scheme $B$, whose generic point maps to $\operatorname{Spec}\operatorname{Frac}R_0$, shows that $\psi$ restricts to $x\mapsto x^{r_y}$ on $\mu_{\ell^\nu}$ over $B$, hence over $K_y$. So over $K_y$, $\psi$ acts by $r_y$ on $T_\ell(\mu)$ and by $r'_y=\deg\pi_h/r_y$ on $T_\ell(E)/T_\ell(\mu)$, the determinant of $\psi$ on $T_\ell$ being $\deg\psi$ \cite{locbib:Silverman2009}, Proposition III.8.6. On the crystalline side $(g^\sharp)^{-1}=c_h\operatorname{Sym}^{k-2}(\hat\pi_h^*)$ (Step 5 of the proof of Lemma~\ref{lem:v5_twi_lef_for}), extended to the logarithmic crystal by (M2), maps the image of $e_0$ in the fibre at the cusp $\tilde y$ (where $v=0$) to $c_hr_y^{k-2}$ times the image of $e_0$ at $\widetilde{g(y)}$, as $\psi^*\omega_{\mathrm{can}}/\omega_{\mathrm{can}}$ takes the value $r_y$ at $v=0$, and the $q$-power Frobenius, induced on Tate curves with conjugate data by $x\mapsto x^q$ (iterate Lemma~\ref{lem:v5_tat_cur_loc}(2)), maps $\omega_{\mathrm{can}}$ at $\widetilde{g(y)}=\mathrm{Fr}_q(\tilde y)$ to $q\,\omega_{\mathrm{can}}$ at $\tilde y$; so $\Psi^{\mathrm{cris}}_{g,y}=c_h(qr_y)^{k-2}$. On the $\ell$-adic side, $(g^\sharp)^{-1}$ acts on the invariant lines by $c_h(r'_y)^{k-2}$, and the $q$-power Frobenius carries the generator dual to the class of the roots of the Tate parameter at $\mathrm{Fr}_q(y)$ to the corresponding generator at $y$, the data being conjugate and Galois acting trivially on $T_\ell(E)/T_\ell(\mu)$; so $\Psi^\ell_{g,y}=c_h(r'_y)^{k-2}$. This proves (2). \textbf{The identity.} Off the cusps, (1) gives \[ \begin{aligned} q^{-1}\operatorname{Tr}((\Psi^{\mathrm{cris}})^{-1}) &=q^{-1}q^{-(k-2)}\operatorname{Tr}(\Psi^{\mathrm{cris}})\\ &=q^{-(k-1)}\iota_{\mathfrak P}\operatorname{Tr}(\Psi^\ell). \end{aligned} \] At a cusp, (2) and $c_h^{-1}=c_h(\deg\pi_h)^{k-2}=c_h(r_yr'_y)^{k-2}$, again by (M2), give $(\Psi^{\mathrm{cris}})^{-1}=c_h^{-1}(qr_y)^{-(k-2)}=q^{-(k-2)}c_h(r'_y)^{k-2}$, and $c_h(r'_y)^{k-2}\in L$. \end{proof} \subsection{Specialisation} \label{subsec:generic_fibre} The computation above takes place over $\overline{\mathbb F}_p$. Tame specialisation identifies these cohomology groups, with their Frobenius action, with the restrictions of the generic-fibre representations to a decomposition group at $\mathfrak P$. \begin{lemma}\label{lem:v5_tam_spe_the} Assume that the datum is admissible. Let $\ell\neq p$ be a prime, $\lambda$ a prime of $L$ above $\ell$, $V_{a,\lambda}$, $V_{\bar a,\lambda}$ the $\lambda$-adic realisations of the model, and $V_a$, $V_{\bar a}$ the cohomology over $\bar{\mathbb F}_p$ of its Kummer eigensheaves, with the geometric Frobenius $F$. Fix a prime of $\bar L$ above $\mathfrak P$, and let $D\supset I$ be its decomposition and inertia groups. Then $I$ acts trivially on $V_{a,\lambda}$ and on $V_{\bar a,\lambda}$, and there are isomorphisms $V_{a,\lambda}\cong V_a$ and $V_{\bar a,\lambda}\cong V_{\bar a}$, compatible with the action of $D$, which acts on $V_a$ and $V_{\bar a}$ through $D/I=\operatorname{Gal}(\bar{\mathbb F}_p/\mathbb F_p)$, so that a geometric Frobenius element $\mathrm{Frob}_{\mathfrak P}\in D$ acts as $F$. In particular $V_{a,\lambda}$ and $V_{\bar a,\lambda}$ are two-dimensional and unramified at $\mathfrak P$, and \[ \det\bigl(X-\mathrm{Frob}_{\mathfrak P}\mid V_{\bar a,\lambda}\bigr)=X^2-A_{\mathfrak P}X+\varepsilon_{\mathfrak P}\,p^{k-1} \] with $A_{\mathfrak P}$, $\varepsilon_{\mathfrak P}$ the numbers of Proposition~\ref{prop:v5_tra_ide_kum}(2). \end{lemma} \begin{proof} We use the notation of Lemma~\ref{lem:v5_twi_lef_for} and of Lemma~\ref{lem:v5_eig_coh_cov}, with $\chi=\chi_\Phi$; the index $\ast$ stands for $a$ or $\bar a$, with $e_\chi$ for $\ast=a$ and $e_{\chi^{-1}}$ for $\ast=\bar a$. Let $\mathcal O=\mathcal O_{L,(\mathfrak P)}$, let $\mathcal O^{\mathrm{sh}}$ be the strict henselisation of $\mathcal O$ at $\mathfrak P$, with closed point $s$, and $\bar\eta$ a geometric generic point of $\operatorname{Spec}\mathcal O^{\mathrm{sh}}$ over the fixed prime of $\bar L$. Let $M$ be the lisse sheaf $\rho^*\operatorname{Sym}^{k-2}R^1\pi_{E*}\mathbb Q_\ell\otimes L_\lambda$ on $C^\circ_{\mathrm{sh}}=(C\setminus D_C)_{\mathcal O^{\mathrm{sh}}}$, with the lattice $M^0=\rho^*\operatorname{Sym}^{k-2}R^1\pi_{E*}\mathbb Z_\ell\otimes\mathcal O_\lambda$ and $M_n=M^0/\lambda^n$, and $o:C^\circ_{\mathrm{sh}}\hookrightarrow C_{\mathrm{sh}}$. \textbf{Step 1: specialisation on $C^\circ$.} By Lemma~\ref{lem:v5_smo_kum_cov}(2), $C_{\mathrm{sh}}$ is smooth and proper over $\mathcal O^{\mathrm{sh}}$ and $D_{C,\mathrm{sh}}$ is finite \'etale over $\mathcal O^{\mathrm{sh}}$, hence a divisor with normal crossings relative to $\mathcal O^{\mathrm{sh}}$. Each $M_n$ is locally constant and tamely ramified along $D_{C,\mathrm{sh}}$: near a point of $D_C$ the curve $E$ is a Tate curve $\mathrm{Tate}(Q)$ (M1), $Q=\delta v^m$ with $p\nmid m$, whose $\ell^n$-torsion, and hence $M_n$, is trivialised by adjoining an $\ell^n$-th root of $v$, a Kummer covering of degree prime to $p$ \cite{locbib:DeligneRapoport1973}, VII, \S1. So by \cite{locbib:SGA4half}, Th.~finitude, Appendice, 1.3.3(i), the formation of $Ro_*M_n$ commutes with every base change, and by the proper base change theorem \cite{locbib:SGA4vol3}, Exp.~XII, Th.~5.1, for $C_{\mathrm{sh}}\to\operatorname{Spec}\mathcal O^{\mathrm{sh}}$, the formation of $R\Gamma(C^\circ,M_n)$ and of $R\Gamma_c(C^\circ,M_n)$ commutes with every base change. The specialisation maps on both are therefore defined \cite{locbib:SGA4half}, Th.~finitude, Appendice, 2.1, and compatible with the forget-supports maps and with the action of $\tilde G$. The smooth morphism $C^\circ_{\mathrm{sh}}\to\operatorname{Spec}\mathcal O^{\mathrm{sh}}$ is locally acyclic relative to the locally constant $M_n$ \cite{locbib:SGA4vol3}, Exp.~XV, so by \cite{locbib:SGA4half}, Th.~finitude, Appendice, 2.4, $\operatorname{sp}:H^1(C^\circ_{\bar s},M_n)\to H^1(C^\circ_{\bar\eta},M_n)$ is an isomorphism. Passing to the limit and tensoring with $\mathbb Q$, the same holds for $M$. \textbf{Step 2: the parabolic parts.} On each geometric fibre, $H^1(C,o_*M)$ is the image of $H^1_c(C^\circ,M)\to H^1(C^\circ,M)$ and injects into $H^1(C^\circ,M)$, by Lemma~\ref{lem:v5_eig_coh_cov}(1). Hence $\operatorname{sp}$ maps $H^1(C_{\bar s},o_*M)=H_\ell$ injectively and $\tilde G$-equivariantly into $H^1(C_{\bar\eta},o_*M)$. By Lemma~\ref{lem:v5_eig_coh_cov}(2), applied to the geometric generic fibre, $e_{\chi^{\pm1}}H^1(C_{\bar\eta},o_*M)=H^1(\mathbb P^1_{\bar\eta},o_*\mathcal F_\ast)$, and this is $V_{\ast,\lambda}$, as $H^1$ of a proper scheme is unchanged by the extension $\bar L\subset\bar\eta$ of algebraically closed fields (proper base change). So $\operatorname{sp}$ maps $V_\ast=e_{\chi^{\pm1}}H_\ell$ injectively into $V_{\ast,\lambda}$. Both have dimension $2$: $V_\ast$ by Proposition~\ref{prop:v5_tra_ide_kum}(2); $V_{a,\lambda}$ by the duality of Lemma~\ref{lem:v5_eta_eig_twi}(3) once $V_{\bar a,\lambda}$ is known; and $V_{\bar a,\lambda}$ because it is an $L_\lambda$-form of $H_a$, of dimension $2$ by (R). To see the last point, fix an embedding $\bar L\subset\mathbb C$ extending $L\subset\mathbb C$. Over $\bar L$, which has characteristic zero, $S$ is a divisor of $\mathbb P^1_{\bar L}$ \'etale over $\bar L$, and the reductions of an integral lattice of $\mathcal F_{\bar a}$ are locally constant on $U_{\bar L}$ and tamely ramified along $S$. Hence the formation of their direct images under $o$ commutes with the base change to $\mathbb C$ \cite{locbib:SGA4half}, Th.~finitude, Appendice, 1.3.3(i), and the proper base change theorem \cite{locbib:SGA4vol3}, Exp.~XII, Th.~5.1, applied to $\mathbb P^1_{\bar L}\to\operatorname{Spec}\bar L$, gives $V_{\bar a,\lambda}\cong H^1(\mathbb P^1_{\mathbb C},o_*\mathcal F_{\bar a})$. By Lemma~\ref{lem:v5_eta_eig_twi}(4) the right side is $H^1(\mathbb P^1(\mathbb C),o_*\mathcal V)\otimes_LL_\lambda$ for a local system $\mathcal V$ of $L$-vector spaces with $H^1(\mathbb P^1(\mathbb C),o_*\mathcal V)\otimes_L\mathbb C\cong H_a$. So $\operatorname{sp}:V_\ast\to V_{\ast,\lambda}$ is an isomorphism. \textbf{Step 3: Galois action.} The decomposition group $D$ is the Galois group of the henselisation of $L$ at $\mathfrak P$ (for the fixed prime), it acts on $\mathcal O^{\mathrm{sh}}$ over the henselisation of $\mathcal O$, and $\operatorname{sp}$ is $D$-equivariant, $D$ acting on the special fibre through $D/I=\operatorname{Gal}(\bar{\mathbb F}_p/\mathbb F_p)$. So $I$ acts trivially on $V_{\ast,\lambda}$. An element of $D$ inducing the arithmetic Frobenius of $\bar{\mathbb F}_p$ acts on $H^1(\mathbb P^1_{\bar{\mathbb F}_p},o_*\mathcal F_\ast)$ as the inverse of the geometric Frobenius $F$ \cite{locbib:Deligne1974}, (1.15); so $\mathrm{Frob}_{\mathfrak P}$ acts as $F$. The last assertion is then Proposition~\ref{prop:v5_tra_ide_kum}(2). \end{proof} \section{The global system and the general theorem} \label{sec:galois} \subsection{Independence of the model} \label{subsec:global} The modular model used in Section~\ref{sec:trace} was chosen at a single prime $\mathfrak P$. To show that the polynomials obtained at different primes come from one system over $L$, we compare the eigensheaves on their common generic base. Geometric irreducibility leaves a possible rank-one arithmetic twist. The invariant line at the Tate cusp determines that twist and shows that it is trivial. \begin{prop}\label{prop:v5_glo_sys_kum} Let $(\Gamma,t,f,a,R)$ be an admissible Kummer twist datum with field $L$, exceptional set $\Sigma$ and singular set $S$. Let $\ell$ be a prime and $\lambda$ a prime of $L$ above $\ell$. \begin{enumerate} \item There are lisse $L_\lambda$-sheaves $\mathcal F_{\bar a,\lambda}$ and $\mathcal F_{a,\lambda}$ on $U_L=\mathbb P^1_L\setminus S$, unique up to isomorphism, such that $\mathcal F_{\bar a,\lambda}\cong\mathcal F_{\bar a}|_{U_L}$ and $\mathcal F_{a,\lambda}\cong\mathcal F_a|_{U_L}$ for the Kummer eigensheaves of every modular model of the datum at every prime of $L$ of residue degree one over a prime not in $\Sigma$. In particular the $\lambda$-adic realisations $V_{\bar a,\lambda}$ and $V_{a,\lambda}$ do not depend, up to isomorphism, on the model or the prime; they are two-dimensional over $L_\lambda$. Moreover, for an embedding $\bar L\subset\mathbb C$ extending $L\subset\mathbb C$, there is a local system $\mathcal V$ of $L$-vector spaces on $U(\mathbb C)$ with \[ V_{\bar a,\lambda}\cong H^1\bigl(\mathbb P^1(\mathbb C),o_*\mathcal V\bigr)\otimes_LL_\lambda,\qquad H^1\bigl(\mathbb P^1(\mathbb C),o_*\mathcal V\bigr)\otimes_L\mathbb C\cong H_a . \] \item Let $\mathfrak P$ be a prime of $L$ of residue degree one over a prime $p\notin\Sigma$, with $\mathfrak P\nmid\ell$. Then $V_{\bar a,\lambda}$ and $V_{a,\lambda}$ are unramified at $\mathfrak P$, and, for a geometric Frobenius $\mathrm{Frob}_{\mathfrak P}$, \[ \det\bigl(X-\mathrm{Frob}_{\mathfrak P}\mid V_{\bar a,\lambda}\bigr)=X^2-A_{\mathfrak P}X+\varepsilon_{\mathfrak P}\,p^{k-1}, \] where $A_{\mathfrak P}\in\mathcal O_L$ and $\varepsilon_{\mathfrak P}\in L^\times$ are the numbers of Proposition~\ref{prop:v5_tra_ide_kum}(2) for any modular model of the datum at $\mathfrak P$; in particular $A_{\mathfrak P}$ and $\varepsilon_{\mathfrak P}$ depend neither on the model nor on $\ell$ and $\lambda$. \item If $L=\mathbb Q$, then $(V_{\bar a,\ell})_\ell$ is a weakly compatible system of two-dimensional $\ell$-adic representations of $\operatorname{Gal}(\bar{\mathbb Q}/\mathbb Q)$, unramified outside $\Sigma$: for every prime $p\notin\Sigma$ and every prime $\ell\neq p$, $V_{\bar a,\ell}$ is unramified at $p$, and a geometric Frobenius at $p$ has characteristic polynomial $X^2-A_pX+\varepsilon_p\,p^{k-1}$, independent of $\ell$, with $A_p\in\mathbb Z$, $\varepsilon_p\in\{\pm1\}$, and roots of absolute value $p^{(k-1)/2}$ under every complex embedding. \end{enumerate} \end{prop} \begin{proof} \emph{Proof of (1).} The set $\Sigma$ is finite, and $L$ is generated over $\mathbb Q$ by roots of unity and square roots of integers, so it is abelian over $\mathbb Q$ and infinitely many primes split completely in it; hence there is a prime $\mathfrak P_0$ of $L$ of residue degree one over some $p_0\notin\Sigma$, and the datum has a modular model at $\mathfrak P_0$ by Proposition~\ref{prop:v5_exi_mod_mod}. Let $\mathcal F_{\bar a,\lambda}$ and $\mathcal F_{a,\lambda}$ be the restrictions to $U_L$ of the Kummer eigensheaves of this model. By Proposition~\ref{prop:v5_mod_ind_kum}, the Kummer eigensheaves of any other modular model at any prime of residue degree one over a prime not in $\Sigma$ are isomorphic to them on $U_L$; uniqueness up to isomorphism is then clear. Applying Lemma~\ref{lem:v5_tam_spe_the} to a modular model at a prime $\mathfrak P$ of residue degree one over $p\notin\Sigma$ with $\mathfrak P\nmid\ell$ (such primes exist, as above), $V_{\bar a,\lambda}$ and $V_{a,\lambda}$ are two-dimensional. For the last assertion, compute $V_{\bar a,\lambda}$ with the Kummer eigensheaf $\mathcal F_{\bar a}$ of one model: as $o_*$ commutes with the base change from $\bar L$ to $\mathbb C$ for the tamely ramified sheaf $\mathcal F_{\bar a}$ \cite{locbib:SGA4half}, Th.~finitude, Appendice, 1.3.3(i), the proper base change theorem \cite{locbib:SGA4vol3}, Exp.~XII, Th.~5.1, gives $V_{\bar a,\lambda}\cong H^1(\mathbb P^1_{\mathbb C},o_*\mathcal F_{\bar a})$, and Lemma~\ref{lem:v5_eta_eig_twi}(4) gives the displayed isomorphisms. \emph{Proof of (2).} By Proposition~\ref{prop:v5_exi_mod_mod} the datum has a modular model at $\mathfrak P$; by (1), $V_{\bar a,\lambda}$ and $V_{a,\lambda}$ are, as representations of $\operatorname{Gal}(\bar L/L)$, the $\lambda$-adic realisations of this model. As $\ell\neq p$, Lemma~\ref{lem:v5_tam_spe_the} shows that they are unramified at $\mathfrak P$ and that the characteristic polynomial of $\mathrm{Frob}_{\mathfrak P}$ on $V_{\bar a,\lambda}$ is $X^2-A_{\mathfrak P}X+\varepsilon_{\mathfrak P}p^{k-1}$, with $A_{\mathfrak P}$, $\varepsilon_{\mathfrak P}$ those of Proposition~\ref{prop:v5_tra_ide_kum}(2) for this model. The left-hand side does not depend on the model, by (1); since $A_{\mathfrak P}$ is the trace and $\varepsilon_{\mathfrak P}p^{k-1}$ the determinant, neither do $A_{\mathfrak P}$ and $\varepsilon_{\mathfrak P}$. They do not depend on $\ell$ and $\lambda$ either: by Proposition~\ref{prop:v5_tra_ide_kum}(2) the polynomial lies in $L[X]$ and its image under the injective map $\iota_{\mathfrak P}$ is the characteristic polynomial of $p^{k-1}\varphi^{-1}$ on $H_{a,p}$, in which $\ell$ and $\lambda$ do not occur. \emph{Proof of (3).} If $L=\mathbb Q$, every prime $p$ is the unique prime of $L$ above itself, of residue degree one, and $\lambda=\ell$. For $p\notin\Sigma$ and $\ell\neq p$, (2) gives unramifiedness and the characteristic polynomial, independent of $\ell$; $A_p\in\mathcal O_{\mathbb Q}=\mathbb Z$; and by Proposition~\ref{prop:v5_tra_ide_kum}(4) the roots have absolute value $p^{(k-1)/2}$ and $|\varepsilon_p|=1$, so $\varepsilon_p=\pm1$ as $\varepsilon_p\in\mathbb Q^\times$. \end{proof} \begin{prop}\label{prop:v5_mod_ind_kum} Let $(\Gamma,t,f,a,R)$ be a Kummer twist datum with field $L$, exceptional set $\Sigma$ and singular set $S$. For $i=1,2$ let $p_i\notin\Sigma$ be primes (possibly equal), $\mathfrak P_i$ a prime of $L$ of residue degree one over $p_i$, and $(X'_i,Z'_i,E_i,G_i,\chi_{G_i})$ a modular model of the datum at $\mathfrak P_i$. Let $\ell$ be a prime, $\lambda$ a prime of $L$ above $\ell$, and $\mathcal F_a^{(i)}$, $\mathcal F_{\bar a}^{(i)}$ the Kummer eigensheaves of the $i$-th model, restricted to $U_L=\mathbb P^1_L\setminus S$. Then \[ \mathcal F_{\bar a}^{(1)}\cong\mathcal F_{\bar a}^{(2)}\qquad\text{and}\qquad\mathcal F_a^{(1)}\cong\mathcal F_a^{(2)} \] as lisse $L_\lambda$-sheaves on $U_L$. In particular $H^1(\mathbb P^1_{\bar L},o_*\mathcal F_{\bar a}^{(1)})\cong H^1(\mathbb P^1_{\bar L},o_*\mathcal F_{\bar a}^{(2)})$ and $H^1(\mathbb P^1_{\bar L},o_*\mathcal F_a^{(1)})\cong H^1(\mathbb P^1_{\bar L},o_*\mathcal F_a^{(2)})$ as representations of $\operatorname{Gal}(\bar L/L)$. \end{prop} \begin{proof} The local system $\mathbb V_f\otimes\mathbb L_a$ is irreducible. Indeed, put $n=\operatorname{lcm}(n_\Gamma,n_f)$. By Lemma~\ref{lem:v5_pic_fuc_loc}(3),(5), its monodromy restricted to $\Gamma(n)$ is the $(k-2)$-th symmetric power of the standard representation of $\mathrm{SL}_2$, tensored with a rank-one character. The group $\Gamma(n)$ is Zariski-dense in $\mathrm{SL}_2$: its upper and lower unipotents with entries in $n\mathbb Z$ are Zariski-dense in the corresponding one-parameter subgroups, which generate $\mathrm{SL}_2$. In characteristic zero the symmetric power of the standard representation is irreducible. Tensoring with a rank-one character preserves irreducibility. Its endomorphisms are therefore scalars. The space $\mathcal N=\operatorname{Hom}_{U_{\bar L}}(\mathcal F_{\bar a}^{(1)},\mathcal F_{\bar a}^{(2)})$ is a line over $L_\lambda$ spanned by an isomorphism. Fix an embedding $\bar L\subset\mathbb C$ extending $L\subset\mathbb C$. By Lemma~\ref{lem:v5_eta_eig_twi}(4), Artin's comparison theorem \cite{locbib:SGA4vol3}, Exp.~XVI, Th.~4.1, identifies $\mathcal F_{\bar a}^{(i)}|_{U(\mathbb C)}$ with $\mathcal V^{(i)}\otimes_LL_\lambda$, where $\mathcal V^{(i)}$ is a local system of $L$-vector spaces with $\mathcal V^{(i)}\otimes_L\mathbb C\cong\mathbb V_f\otimes\mathbb L_a$. By the first step, $\operatorname{Hom}(\mathcal V^{(1)},\mathcal V^{(2)})\otimes_L\mathbb C$ is a line and each $\mathcal V^{(i)}$ is absolutely irreducible; as invariants of a linear action commute with extension of scalars, $\operatorname{Hom}(\mathcal V^{(1)}\otimes_LL_\lambda,\mathcal V^{(2)}\otimes_LL_\lambda)$ is a line, and each $\mathcal V^{(i)}\otimes_LL_\lambda$ is irreducible, so a nonzero homomorphism between them is an isomorphism. Now $\mathcal N$ is the space of global sections over $U_{\bar L}$ of the lisse sheaf $\mathcal Hom(\mathcal F_{\bar a}^{(1)},\mathcal F_{\bar a}^{(2)})$; each of its reductions is trivialised by a connected finite \'etale Galois cover of $U_{\bar L}$, which stays connected, with the same group, over the algebraically closed field $\mathbb C$, so global sections do not change from $U_{\bar L}$ to $U_{\mathbb C}$, and by Artin's comparison they are the homomorphisms of the associated local systems on $U(\mathbb C)$. Hence $\mathcal N$ is a line, and a nonzero $\phi\in\mathcal N$ is an isomorphism, being one on a geometric stalk. Consequently the two sheaves differ by a character of $\operatorname{Gal}(\bar L/L)$. The group $\pi_1(U_L)$ acts on $\mathcal N$ by conjugation, through its quotient $\pi_1(U_L)/\pi_1(U_{\bar L})=\operatorname{Gal}(\bar L/L)$, hence by a continuous character $\nu$. Evaluation $\mathcal F_{\bar a}^{(1)}\otimes_{L_\lambda}\mathcal N\to\mathcal F_{\bar a}^{(2)}$ is equivariant, so it is a morphism of lisse sheaves on $U_L$, with $\mathcal N$ the rank-one sheaf pulled back from $\operatorname{Spec}L$; it is an isomorphism by the previous step. Thus $\mathcal F_{\bar a}^{(2)}\cong\mathcal F_{\bar a}^{(1)}\otimes\nu$. It remains to show that $\nu=1$. Let $K$, $\bar\xi$, $G_K$, $I$, $E_0$ and $S_0$ be as in Lemma~\ref{lem:v5_cus_res_kum}, and let $\psi$ be the character of $G_K$ on the stalk at $\bar\xi$ of the Kummer sheaf $\mathcal L_{-j}$, of rank one by Lemma~\ref{lem:v5_eta_eig_twi}(2), which is built from $[d]:s\mapsto s^d$ alone and so is the same for both models. By Lemma~\ref{lem:v5_eta_eig_twi}(2), $\mathcal F_{\bar a}^{(i)}\cong\mathbb V^{(i)}_{\chi_{G_i}^{-1}}\otimes\mathcal L_{-j}$, and by Lemma~\ref{lem:v5_cus_res_kum}(2) the stalk of $\mathbb V^{(i)}_{\chi_{G_i}^{-1}}$ at $\bar\xi$ is $S_0$ for both $i$. So, as representations of $G_K$, \[ S_0\otimes\psi\cong S_0\otimes\psi\otimes\nu|_{G_K},\qquad\text{hence}\qquad S_0\cong S_0\otimes\nu|_{G_K}, \] where $\nu|_{G_K}$ is $\nu$ composed with restriction $G_K\to\operatorname{Gal}(\bar L/L)$, which is trivial on $I$. Taking $I$-invariants gives $S_0^I\cong S_0^I\otimes\nu$ as representations of $G_K/I=\operatorname{Gal}(\bar L/L)$ (Lemma~\ref{lem:v5_cus_res_kum}(3)). As $S_0^I$ is a line, $\nu=1$. So $\mathcal F_{\bar a}^{(1)}\cong\mathcal F_{\bar a}^{(2)}$. By Lemma~\ref{lem:v5_eta_eig_twi}(3), $\mathcal F_a^{(i)}\cong\mathcal Hom(\mathcal F_{\bar a}^{(i)},L_\lambda(-(k-2)))$, so $\mathcal F_a^{(1)}\cong\mathcal F_a^{(2)}$. The last assertion follows by functoriality of $o_*$ and of $H^1(\mathbb P^1_{\bar L},-)$. \end{proof} \begin{lemma}\label{lem:v5_cus_res_kum} Let $(X',Z',E,G,\chi_G)$ be a modular model, at a prime $\mathfrak P$ of $L$ of residue degree one over $p\notin\Sigma$, of a Kummer twist datum $(\Gamma,t,f,a,R)$ with singular set $S$. Let $\ell$ be a prime, $\lambda$ a prime of $L$ above $\ell$, and $\mathbb V_{\chi_G}$, $\mathbb V_{\chi_G^{-1}}$ its Kummer eigensheaves, restricted to $U_L=\mathbb P^1_L\setminus S$. Let $T\in t+t^2\mathbb Z[\frac1M][[t]]$ be the compositional inverse of the $q$-expansion $t(q)$ of the Hauptmodul, so that $q=T(t)$. Let $K=L((t))$, fix an algebraic closure $\bar K$, let $\bar L$ be the algebraic closure of $L$ in $\bar K$, put $G_K=\operatorname{Gal}(\bar K/K)$ and $I=\operatorname{Gal}(\bar K/\bar LK)$, and let $\bar\xi:\operatorname{Spec}\bar K\to U_L$ be the geometric point defined by $L(t)\subset K\subset\bar K$. Let $E_0=\mathrm{Tate}(T(t))$ be the Tate curve over $K$ with parameter $T(t)$, and \[ S_0=\operatorname{Sym}^{k-2}H^1(E_{0,\bar K},\mathbb Q_\ell)\otimes_{\mathbb Q_\ell}L_\lambda , \] with the natural action of $G_K$. Then: \begin{enumerate} \item $\operatorname{End}_{\bar K}(E_{0,\bar K})=\mathbb Z$. \item The stalks $(\mathbb V_{\chi_G})_{\bar\xi}$ and $(\mathbb V_{\chi_G^{-1}})_{\bar\xi}$, with their actions of $G_K$, are both isomorphic to $S_0$. \item $S_0^{I}$ is a line, and restriction to $\bar L$ induces an isomorphism $G_K/I\cong\operatorname{Gal}(\bar L/L)$. \end{enumerate} \end{lemma} \begin{proof} Since $T(t)$ has $t$-adic valuation one, $E_0$ is the Tate curve with split multiplicative reduction, and for every $n$ the group $E_0[\ell^n](\bar K)$ is the extension of $\mathbb Z/\ell^n$ by $\mu_{\ell^n}$ formed by the classes of $\zeta\,T(t)^{b/\ell^n}$, $\zeta\in\mu_{\ell^n}$, $b\in\mathbb Z$ \cite{locbib:DeligneRapoport1973}, VII, \S1. The group $I$ fixes $\mu_{\ell^\infty}\subset\bar L$, and it acts transitively on the $\ell^n$-th roots of $T(t)$, because $T(t)$ is a uniformiser of the discretely valued field $\bar LK=\bigcup_{L'}L'((t))$ ($L'$ finite over $L$) and $X^{\ell^n}-T(t)$ is Eisenstein. Hence, in a suitable basis $e,e'$ of $V=H^1(E_{0,\bar K},\mathbb Q_\ell)$, every element of $I$ acts by a matrix $\bigl(\begin{smallmatrix}1&*\\0&1\end{smallmatrix}\bigr)$, the line $\mathbb Q_\ell e$ being the space of forms on $T_\ell E_0$ that vanish on $T_\ell\mu$, and the image of every open subgroup of $I$ contains a nontrivial unipotent. \emph{Proof of (1).} Let $\alpha\in\operatorname{End}_{\bar K}(E_{0,\bar K})$. It is defined over a finite extension $K_1\subset\bar K$ of $K$, so $\alpha^*$ commutes on $V$ with $I\cap\operatorname{Gal}(\bar K/K_1)$, which is open in $I$ and so contains an element acting by a unipotent $u\neq1$. The commutant of $u$ in $\operatorname{End}(V)$ is $\mathbb Q_\ell\oplus\mathbb Q_\ell N$ with $N=u-1$, $N^2=0$; write $\alpha^*=a+bN$. The characteristic polynomial of $\alpha^*$ on $V$ is $(X-a)^2$, and it equals $X^2-\operatorname{tr}(\alpha)X+\deg\alpha$ with integer coefficients \cite{locbib:Silverman2009}, Proposition III.8.6 (stated for $T_\ell$; $V$ is its dual). So $2a\in\mathbb Z$ and $a^2\in\mathbb Z$, whence $a\in\mathbb Z$. Then $\beta=\alpha-[a]$ acts on $V$ by the nilpotent $bN$, so $\deg\beta=\det(\beta^*)=0$ and $\beta=0$. \emph{Proof of (3).} In characteristic zero $\operatorname{Sym}^{k-2}(u)$ of a nontrivial unipotent $u\in\mathrm{GL}(V)$ is a single unipotent Jordan block of size $k-1$: its logarithm is the derivation of $\operatorname{Sym}^{\bullet}V$ induced by $N$, which maps $e^{i}e'^{\,k-2-i}$ to a nonzero multiple of $e^{i+1}e'^{\,k-3-i}$. So $S_0^I$ has dimension at most one, and it contains $e^{k-2}$. As $L$ is algebraically closed in $K$, restriction $G_K\to\operatorname{Gal}(\bar L/L)$ is surjective, and its kernel is $I$. Let $B$ be the set of $K$-morphisms $y:\operatorname{Spec}\bar K\to X'_U$ with $\varpi'\circ y=\bar\xi$; put $E_y=y^*E$, an elliptic curve over $\bar K$, and $S_y=\operatorname{Sym}^{k-2}H^1(E_y,\mathbb Q_\ell)\otimes L_\lambda$. Then $(\varpi'_*\operatorname{Sym}^{k-2}\mathcal H\otimes L_\lambda)_{\bar\xi}=\bigoplus_{y\in B}S_y$. The group $G$ acts on $B$ by $y\mapsto g\circ y$, transitively, since $X'_L/G\cong\mathbb P^1_L$ (M3) \cite{locbib:BourbakiAC56}, Ch.~V, \S2, no.~2, Th.~2; and $g^\sharp$ maps $v=(v_y)$ to $(c_g\pi_{g,y}^*v_{g\circ y})_y$, where $\pi_{g,y}:E_y\to E_{g\circ y}$ is the fibre of $\pi_g$. The group $G_K$ acts on $B$ by $\sigma(y)=y\circ\operatorname{Spec}(\sigma)$, and on the stalk by transport of structure: the projection $f_{\sigma,y}:E_{\sigma(y)}=E_y\times_{\operatorname{Spec}\bar K,\operatorname{Spec}\sigma}\operatorname{Spec}\bar K\to E_y$ is an isomorphism of schemes over $\operatorname{Spec}\sigma$, and $\sigma$ maps $S_y$ to $S_{\sigma(y)}$ by $f_{\sigma,y}^*$. The two actions commute. In the same way $\sigma$ acts on $S_0$ by $(f^0_\sigma)^*$, where $f^0_\sigma=\mathrm{id}\times\operatorname{Spec}\sigma$ is the transport of $E_{0,\bar K}=E_0\times_K\operatorname{Spec}\bar K$. Finally, $f\omega^{\otimes(k-2)}$ is a rational section over $X'_L$ (M4), regular and nonzero at the generic points of $X'_L$ (on $X'_0$ it is $f(\tau)(2\pi i\,dz)^{\otimes(k-2)}$, and $G$ permutes the components); its fibres $\phi_y\in H^0(E_y,\Omega^1)^{\otimes(k-2)}$ satisfy $f_{\sigma,y}^*\phi_y=\phi_{\sigma(y)}$, and (M4) gives \begin{equation} c_g\,\pi_{g,y}^*\,\phi_{g\circ y}=\chi_G(g)\,\phi_y\qquad(g\in G,\ y\in B). \end{equation} We next produce a point $y_0\in B$ with a normalised isomorphism $\iota_0:E_{y_0}\to E_{0,\bar K}$. Let $W$, $\infty'\in Z'(W)$, $q'$ and $w$ be as in (M5), and let $x_0\in X'_L$ be the image of the generic point of $\infty'$, a closed point with $t(x_0)=0$. The completed local ring $A$ of $X'_L$ at $x_0$ is a discrete valuation ring finite over $L[[t]]$ ($t$ is finite, (M3)), so $F=\operatorname{Frac}A$ is finite over $K$. The generic point of $\infty'$ is a $\operatorname{Frac}(W)$-point of $X'_L\otimes_L\operatorname{Frac}(W)$ over $x_0$, at which $q'$ restricts to a uniformiser; so the completed local ring there is $\operatorname{Frac}(W)[[q']]$, the induced map $A\to\operatorname{Frac}(W)[[q']]$ is a local injection, and $F$ embeds over $K$ into $F^+=\operatorname{Frac}(W)((q'))$, with $t\mapsto t(q)$, $q=q'^{\,w}$. By (M5) and \cite{locbib:EGAIII1}, (5.4.1), $E\times_{X'}\operatorname{Spec}W[[q']]$ is $\mathrm{Tate}(q)\otimes W[[q']]$, and $f\omega^{\otimes(k-2)}=F(t)\,\omega_{\mathrm{can}}^{\otimes(k-2)}$ there; as $T(t)=q$ in $F^+$, we get an isomorphism $\iota^+:E_{F^+}\to E_{0,F^+}$ with $\iota^{+*}(F(t)\omega_{\mathrm{can}}^{\otimes(k-2)})=f\omega^{\otimes(k-2)}$. Since $j(E_0)=j(T(t))$ has a pole at $t=0$, it is neither $0$ nor $1728$, so $E_F$ and $E_{0,F}$, which have the same $j$-invariant, are quadratic twists of each other, and their isomorphisms over any extension of $F$ are $\pm$ one of them \cite{locbib:Silverman2009}, Theorem III.10.1 and Proposition X.5.4. Hence $\iota^+$ is the base change of an isomorphism $\iota'$ defined over $F'=F(\sqrt\delta)\subset F^+$ for some $\delta\in F^\times$, and $\iota'^*(F(t)\omega_{\mathrm{can}}^{\otimes(k-2)})=f\omega^{\otimes(k-2)}$, as this identity holds in $F^+$. Choose a $K$-embedding $F'\to\bar K$. It defines $y_0\in B$ (the image of $\operatorname{Spec}F\to X'_L$ is a generic point, so $y_0$ lies over $U$) and $\iota_0=\iota'\otimes\bar K$, with $\iota_0^*(F(t)\omega_{\mathrm{can}}^{\otimes(k-2)})=\phi_{y_0}$. Let $\sigma\in G_K$ and $g\in G$ with $g\circ\sigma^{-1}(y_0)=y_0$; put $y=\sigma^{-1}(y_0)$ and $\Pi=\pi_{g,y}\circ f_{\sigma,y}:E_{y_0}\to E_y\to E_{y_0}$, an isogeny of group schemes over $\operatorname{Spec}\sigma$ of degree $\deg\pi_g$. Then $(f^0_\sigma)^{-1}\circ\iota_0\circ\Pi\circ\iota_0^{-1}$ is a $\bar K$-linear isogeny of $E_{0,\bar K}$ of degree $\deg\pi_g$, so by (1) it is $[m]$ with $m\in\mathbb Z$, $m^2=\deg\pi_g$: \begin{equation} \iota_0\circ\Pi\circ\iota_0^{-1}=[m]\circ f^0_\sigma . \end{equation} Apply both sides to differentials. Pull-back along $\Pi$ is $\sigma$-semilinear and, by the identity $c_g\pi_{g,y}^*\phi_{y_0}=\chi_G(g)\phi_y$ (the (M4) display with $g\circ y=y_0$) and $f_{\sigma,y}^*\phi_y=\phi_{y_0}$, maps $\phi_{y_0}$ to $c_g^{-1}\chi_G(g)\phi_{y_0}$ (as $c_g,\chi_G(g)\in L\subset K$). On the other side, $(f^0_\sigma)^*$ fixes the $K$-rational $\omega_{\mathrm{can}}$ and $F(t)\in K$, and $[m]^*\omega_{\mathrm{can}}=m\,\omega_{\mathrm{can}}$; with $\iota_0^*(F(t)\omega_{\mathrm{can}}^{\otimes(k-2)})=\phi_{y_0}$ this gives $\Pi^*\phi_{y_0}=m^{k-2}\phi_{y_0}$. Since $\phi_{y_0}\neq0$, \begin{equation} \chi_G(g)=c_g\,m^{k-2},\qquad\chi_G(g)^2=c_g^2m^{2(k-2)}=(\deg\pi_g)^{-(k-2)}(\deg\pi_g)^{k-2}=1 . \end{equation} \emph{Proof of (2).} Let $\chi\in\{\chi_G,\chi_G^{-1}\}$ and let $p_0$ be the projection of the stalk onto $S_{y_0}$. On the $\chi$-part $p_0$ is injective: if $g\circ y=y_0$, then $\chi(g)v_y=c_g\pi_{g,y}^*v_{y_0}$. It is surjective: for $w\in S_{y_0}$ put $v_y=\chi(g)^{-1}c_g\pi_{g,y}^*w$ for any $g$ with $g\circ y=y_0$; this does not depend on $g$, and $v=(v_y)$ lies in the $\chi$-part, by the composition rule $g^\sharp h^\sharp=(hg)^\sharp$ of Lemma~\ref{lem:v5_eta_eig_twi}(2) and because, for $h$ fixing $y_0$, the case $\sigma=1$ above gives $\pi_{h,y_0}=[m_h]$ (by (1), through $\iota_0$) and $c_h\operatorname{Sym}^{k-2}(\pi_{h,y_0}^*)=c_hm_h^{k-2}=\chi_G(h)=\chi(h)$. Transport the action of $G_K$ to $S_{y_0}$ through $p_0$. For $\sigma\in G_K$ and $v$ in the $\chi$-part, with $y$ and $g$ as above, $(\sigma v)_{y_0}=f_{\sigma,y}^*v_y=\chi(g)^{-1}c_g\,f_{\sigma,y}^*\pi_{g,y}^*v_{y_0}$, that is, $\sigma$ acts on $S_{y_0}$ by $\chi(g)^{-1}c_g\operatorname{Sym}^{k-2}(\Pi^*)$. By the displayed identity for $\Pi$, $\Pi^*=\iota_0^*\circ m\,(f^0_\sigma)^*\circ(\iota_0^*)^{-1}$ on $H^1$, so $\sigma$ acts by \[ \chi(g)^{-1}c_gm^{k-2}\cdot\iota_0^*\circ\operatorname{Sym}^{k-2}\bigl((f^0_\sigma)^*\bigr)\circ(\iota_0^*)^{-1}=\chi(g)^{-1}\chi_G(g)\cdot\iota_0^*\circ\sigma_{S_0}\circ(\iota_0^*)^{-1}, \] where $\sigma_{S_0}=\operatorname{Sym}^{k-2}((f^0_\sigma)^*)$ is the natural action of $\sigma$ on $S_0$, and $\chi(g)^{-1}\chi_G(g)=1$ because $\chi_G(g)=\pm1$. So $(\iota_0^*)^{-1}\circ p_0$ identifies $(\mathbb V_\chi)_{\bar\xi}$ with $S_0$, $G_K$-equivariantly. \end{proof} Crystalline comparison is needed at auxiliary split primes. Its range $p>k$ therefore imposes no extra exclusion on the prime in the final congruence, where $p\geq k$ suffices. The proof applies Faltings' logarithmic comparison \cite[Theorems~5.3 and 6.2]{locbib:Faltings1989} to the Kummer cover and checks its isogeny eigenspaces and residue kernels. \begin{prop}\label{prop:v5_cry_com_for} Let $(\Gamma,t,f,a,R)$ be an admissible Kummer twist datum with field $L$ and exceptional set $\Sigma$. Let $p\notin\Sigma$ with $p>k$, let $\mathfrak P$ be a prime of $L$ of residue degree one over $p$, fix an embedding $\bar L\subset\bar{\mathbb Q}_p$ inducing on $L$ the embedding $\iota_{\mathfrak P}:L\to\mathbb Q_p$ defined by $\mathfrak P$, and let $D_{\mathfrak P}\subset\operatorname{Gal}(\bar L/L)$ be the corresponding decomposition group, identified with $\operatorname{Gal}(\bar{\mathbb Q}_p/\mathbb Q_p)$. Let $V_{a,\lambda}$, $V_{\bar a,\lambda}$ be the $\lambda$-adic realisations. \begin{enumerate} \item For every prime $\lambda$ of $L$ above $p$, the restrictions of $V_{a,\lambda}$ and $V_{\bar a,\lambda}$ to $D_{\mathfrak P}$ are crystalline. \item Let $\lambda=\mathfrak P$, so that $L_\lambda=\mathbb Q_p$. For every modular model of the datum at $\mathfrak P$, with eigenlattice $H_{a,p}$ and crystalline Frobenius $\varphi$, \[ D_{\mathrm{cris}}(V_{a,\mathfrak P})=\bigl(V_{a,\mathfrak P}\otimes_{\mathbb Q_p}B_{\mathrm{cris}}\bigr)^{D_{\mathfrak P}}\cong H_{a,p}\otimes\mathbb Q_p \] as filtered $\varphi$-modules. Consequently $V_{a,\mathfrak P}$ and $V_{\bar a,\mathfrak P}$ are two-dimensional with Hodge--Tate weights $0$ and $k-1$, each of multiplicity one, in the normalisation in which $\mathbb Q_p(-1)$ has weight $1$. \end{enumerate} \end{prop} \begin{proof} Let $(X',Z',E,G,\chi_G)$ be a modular model at $\mathfrak P$: one exists by Proposition~\ref{prop:v5_exi_mod_mod}, and in (2) we take the given one; the argument uses only (M1)--(M5). By Proposition~\ref{prop:v5_glo_sys_kum}(1) we may compute $V_{a,\lambda}$ and $V_{\bar a,\lambda}$ with the sheaves of this model. Let $C^\circ=C\setminus D_C$ and $\mathbb T=\rho^*R^1\pi_*\mathbb Z_p$, a lisse sheaf on $C^\circ_{\mathbb Q_p}$. Let $\lambda\mid p$, let $M_\lambda=\operatorname{Sym}^{k-2}\mathbb T\otimes_{\mathbb Z_p}L_\lambda$ on $C^\circ_{\bar{\mathbb Q}_p}$, with $\tilde G$ acting by the maps $g^\sharp$ (constants $c_g$ and values of $\chi$ taken in $L_\lambda$), and let $\mathcal W_\lambda=H^1(C_{\bar{\mathbb Q}_p},o_*M_\lambda)$, the image of $H^1_c(C^\circ_{\bar{\mathbb Q}_p},M_\lambda)\to H^1(C^\circ_{\bar{\mathbb Q}_p},M_\lambda)$ (Lemma~\ref{lem:v5_eig_coh_cov}(1)). The cohomology of the proper $\mathbb P^1$ does not change under the extension $\bar L\subset\bar{\mathbb Q}_p$ of algebraically closed fields, and Lemma~\ref{lem:v5_eig_coh_cov}(2), with $\Omega=\bar{\mathbb Q}_p$ and $\ell=p$, gives \[ V_{a,\lambda}|_{D_{\mathfrak P}}=e_\chi\mathcal W_\lambda,\qquad V_{\bar a,\lambda}|_{D_{\mathfrak P}}=e_{\chi^{-1}}\mathcal W_\lambda , \] with $e_{\chi^{\pm1}}$ the idempotents attached to $\chi^{\pm1}$. The automorphisms in $\tilde G$ and the isogenies $\pi_g$ are defined over $\mathcal O_{L,(\mathfrak P)}\subset\mathbb Z_p$, so the $g^\sharp$, and the $e_{\chi^{\pm1}}$, commute with $D_{\mathfrak P}=\operatorname{Gal}(\bar{\mathbb Q}_p/\mathbb Q_p)$. As a representation over $\mathbb Q_p$, $\mathcal W_\lambda=\mathcal W\otimes_{\mathbb Q_p}L_\lambda$ with $\mathcal W=H^1(C_{\bar{\mathbb Q}_p},o_*\operatorname{Sym}^{k-2}\mathbb T\otimes\mathbb Q_p)$. Following Faltings, we show that $\mathcal W$ is crystalline and describe $D_{\mathrm{cris}}(\mathcal W)$. The hypotheses of the theory hold: $C_{\mathbb Z_p}$ is smooth and proper over $\mathbb Z_p$ and $D_C$ is finite \'etale, a divisor with normal crossings relative to $\mathbb Z_p$ (Lemma~\ref{lem:v5_smo_kum_cov}(2)). By (M1), $E\to X'$ is a proper generalised elliptic curve which near each point of $Z'$ is a Tate curve $\mathrm{Tate}(\delta q^m)$, with nodes of local equation $xy=\delta q^m$, so it is logarithmically smooth over $(X',Z')$ for the logarithmic structures defined by $Z'$ and its inverse image \cite{locbib:Kato1989}, Theorem 3.5, as for modular curves in \cite{bib:diamond2025a}, \S2.2. By \cite{locbib:Faltings1989}, Theorem 6.2, applied to $E\to X'$ as in \cite{locbib:FaltingsJordan1995}, \S1, p.~4, and \cite{bib:diamond2025a}, \S2.2, $H$ with its Hodge filtration, logarithmic Gauss--Manin connection and Frobenius is an object of $\mathcal{MF}^\nabla_{[0,1]}(X'_{\mathbb Z_p})$ associated to $R^1\pi_*\mathbb Z_p$. Pulling back along the morphism of logarithmic schemes $\rho:(C,D_C)\to(X',Z')$, $\rho^*H$ is an object of $\mathcal{MF}^\nabla_{[0,1]}(C_{\mathbb Z_p})$ associated to $\mathbb T$ (compatibility with pull-back, \cite{locbib:Faltings1989}, V a), as used in \cite{bib:diamond2025a}, \S3.3). Alternatively, Theorem 6.2 applies directly to $E\times_{X'}C\to C$, a proper generalised elliptic curve with nodes of local equation $xy=\delta'v^{em}$, $v$ a parameter at a point of $D_C$ and $e\mid d$ the ramification index of $\rho$, logarithmically smooth over $(C,D_C)$ by the same criterion. As the association respects tensor products (\cite{locbib:Faltings1989}, II h), \cite{bib:diamond2025a}, \S2.2) and $k-2\le p-2$, $M_k$ is an object of $\mathcal{MF}^\nabla_{[0,k-2]}(C_{\mathbb Z_p})$ associated to $\operatorname{Sym}^{k-2}\mathbb T$. Since $1+(k-2)\le p-2$, that is $p>k$, the comparison theorem \cite{locbib:Faltings1989}, Theorem 5.3 (in the form of \cite{bib:mokrane2000}, published version, Ast\'erisque 280 (2002), \S6.1, Theorem 7, with $i=1$ and $a=k-2$), identifies $H^1(C^\circ_{\bar{\mathbb Q}_p},\operatorname{Sym}^{k-2}\mathbb T)$, naturally and functorially, with the Galois module associated to the logarithmic crystalline cohomology $H^1_{\mathrm{crys}}$ of $(C,D_C)$ with coefficients $M_k$, an object of $\mathcal{MF}_{[0,k-1]}(\mathbb Z_p)$; and likewise $H^1_c$ with $H^1_{c,\mathrm{crys}}$, whose underlying filtered module is the hypercohomology of the logarithmic de Rham complex of $M_k(-D_C)$, compatibly with the forget-supports maps (\cite{locbib:FaltingsJordan1995}, \S1, p.~4; \cite{bib:diamond2025a}, \S\S2.2 and 2.5). By the theory of Fontaine and Laffaille \cite{locbib:FontaineLaffaille1982}, as recalled in \cite{bib:diamond2025a}, \S1.1, the Galois module associated to an object $A$ of $\mathcal{MF}_{[0,p-2]}(\mathbb Z_p)$ spans a crystalline representation with $D_{\mathrm{cris}}\cong A\otimes\mathbb Q_p$ as filtered $\varphi$-modules, functorially. As $D_{\mathrm{cris}}$ is exact on crystalline representations and $\mathcal W$ is the image of $H^1_c\otimes\mathbb Q_p\to H^1\otimes\mathbb Q_p$, $\mathcal W$ is crystalline and \[ D_{\mathrm{cris}}(\mathcal W)=\operatorname{Im}\bigl(H^1_{c,\mathrm{crys}}\to H^1_{\mathrm{crys}}\bigr)\otimes\mathbb Q_p . \] The underlying filtered module of $H^1_{\mathrm{crys}}$ is the hypercohomology $H_{\mathbb Z}$ of the logarithmic de Rham complex of $M_k$, and its Frobenius is the crystalline Frobenius $\varphi$ of Lemma~\ref{lem:v5_par_eig_the}(1), both being the logarithmic crystalline cohomology of $(C_{\mathbb F_p},D_C)$ with coefficients $M_k$ \cite{locbib:Kato1989}, Theorem 6.4. \emph{Proof of (1).} For $\lambda\mid p$, $V_{a,\lambda}|_{D_{\mathfrak P}}$ and $V_{\bar a,\lambda}|_{D_{\mathfrak P}}$ are direct summands of $\mathcal W\otimes_{\mathbb Q_p}L_\lambda$, a direct sum of copies of the crystalline $\mathcal W$. A direct summand of a crystalline representation is crystalline, since the comparison map $D_{\mathrm{cris}}(X)\otimes_{\mathbb Q_p}B_{\mathrm{cris}}\to X\otimes_{\mathbb Q_p}B_{\mathrm{cris}}$ is additive in $X$, and $X$ is crystalline exactly when it is an isomorphism \cite{locbib:Fontaine1994}, \S1. The comparison commutes with $\tilde G$. On the \'etale side $(g,\zeta)\in\tilde G$ acts by the maps $g^\sharp=c_g\operatorname{Sym}^{k-2}(\pi_g^*)\circ g^*$ and $[\zeta]^*$; on the crystalline side by the action $x\mapsto g^*x$ of Lemma~\ref{lem:v5_par_eig_the}(1), given by the same formulas, where $c_g\operatorname{Sym}^{k-2}(\pi_g^*)$ extends over $Z'$ and respects all structures by (M2). The morphisms of $\mathcal{MF}^\nabla$ and of \'etale sheaves to be compared are determined by their restrictions to the open part, the functor of \cite{locbib:Faltings1989}, Theorem 2.6, being fully faithful (\cite{bib:diamond2025a}, \S2.2), and there they come from the isogeny $\pi_g$ of elliptic curves. Both are induced by the automorphism $(g,\zeta)$ of $(C,D_C)$ together with the isogeny $\pi_g$ of degree prime to $p$. The comparison isomorphisms are natural for such data: by \cite{locbib:Faltings1989}, 4 c), and the proof of its Theorem 6.2, an isogeny of the families induces a morphism of the associated objects of $\mathcal{MF}^\nabla$ which corresponds to the induced morphism of \'etale sheaves (loc. cit., V a)), exactly as for the isogenies defining Hecke operators in \cite{bib:diamond2025a}, \S3.3, and \cite{locbib:FaltingsJordan1995}, proof of Theorem 1.2(1); and the isomorphism of Theorem 5.3 is functorial (\cite{bib:mokrane2000}, published version, \S6.1, Theorem 7). So $D_{\mathrm{cris}}$ carries $e_\chi$ on $\mathcal W$ to $e_\chi$ on $D_{\mathrm{cris}}(\mathcal W)$, the constants acting through $\iota_{\mathfrak P}$ on both sides. \emph{Proof of (2).} Let $\lambda=\mathfrak P$. By the comparison above and its equivariance, $D_{\mathrm{cris}}(V_{a,\mathfrak P})=e_\chi\operatorname{Im}(H^1_{c,\mathrm{crys}}\to H^1_{\mathrm{crys}})\otimes\mathbb Q_p\subset e_\chi H_{\mathbb Z}\otimes\mathbb Q_p$. Classes in the image of $H^1_{c,\mathrm{crys}}$ have vanishing residues: on an affine neighbourhood of $z\in D_C$ such a class is represented by a logarithmic $1$-form with coefficients in $M_k(-D_C)$, and $\operatorname{Res}_z$ is the constant term at $z$ of the $e_0$-coefficient of the component near $z$ (proof of Lemma~\ref{lem:v5_par_eig_the}(3)), which vanishes. Hence $D_{\mathrm{cris}}(V_{a,\mathfrak P})\subset H_{a,p}\otimes\mathbb Q_p$, the residue-free $\chi$-part (Lemma~\ref{lem:v5_par_eig_the}(2)). Both have dimension two: $V_{a,\mathfrak P}$ by Proposition~\ref{prop:v5_glo_sys_kum}(1), and it is crystalline by (1); $H_{a,p}$ by Lemma~\ref{lem:v5_par_eig_the}(3) and (R). So they are equal, as $\varphi$-modules, and as filtered modules, the filtration of $D_{\mathrm{cris}}(V_{a,\mathfrak P})$ being induced from $D_{\mathrm{cris}}(\mathcal W)$ ($D_{\mathrm{cris}}$ is strict) and that of $H_{a,p}\otimes\mathbb Q_p$ from $H_{\mathbb Z}\otimes\mathbb Q_p$. It remains to compute the Hodge--Tate weights. Over $\mathbb Q_p$, $D_{\mathrm{dR}}=D_{\mathrm{cris}}$ with its filtration, and the Hodge--Tate weights are the jumps of the filtration, the jump of $\mathbb Q_p(-1)$ being at $1$. On $H_{a,p}\otimes\mathbb Q_p$, $F^0$ is everything, $F^1=F^{k-1}$ is a line by Lemma~\ref{lem:v5_par_eig_the}(3) and (P), and $F^k=0$, the filtration of $H^1$ with coefficients in $\mathcal{MF}_{[0,k-2]}$ lying in $[0,k-1]$. So the weights of $V_{a,\mathfrak P}$ are $0$ and $k-1$. By Lemma~\ref{lem:v5_eta_eig_twi}(3) and Poincar\'e duality on $\mathbb P^1_{\bar{\mathbb Q}_p}$ \cite{locbib:Deligne1974}, (2.12) ($p$ is invertible on $\bar{\mathbb Q}_p$), $V_{\bar a,\mathfrak P}\cong\operatorname{Hom}(V_{a,\mathfrak P},\mathbb Q_p(-(k-1)))$, $D_{\mathfrak P}$-equivariantly; it is crystalline by (1), with weights $(k-1)-0$ and $(k-1)-(k-1)$, that is $k-1$ and $0$. \end{proof} \subsection{The determinant as a Hecke character} \label{subsec:hecke} We now identify the normalised determinants $\varepsilon_{\mathfrak P}$ as values of one algebraic Hecke character of $L$. At an auxiliary split prime the determinant of the global representation is Hodge--Tate, so Serre's theory gives an algebraic Hecke character. A second auxiliary prime allows us to remove the first from the modulus. We use the degree-one-prime formulations in Lemmas~\ref{lem:v5_hec_cha_ht} and~\ref{lem:v5_hec_cha_uni}. \begin{definition}\label{def:v5_alg_hec_cha} Let $K$ be a number field, Galois over $\mathbb Q$, and $\mathfrak m$ a nonzero integral ideal of $K$; let $I^{\mathfrak m}$ be the group of fractional ideals of $K$ prime to $\mathfrak m$. An \textbf{algebraic Hecke character of $K$ with values in $K$ and modulus $\mathfrak m$} is a homomorphism $\chi:I^{\mathfrak m}\to K^\times$ for which there are integers $(a_\sigma)_{\sigma\in\operatorname{Gal}(K/\mathbb Q)}$, its \textbf{infinity type}, such that \[ \chi\bigl((\alpha)\bigr)=\prod_{\sigma\in\operatorname{Gal}(K/\mathbb Q)}\sigma(\alpha)^{a_\sigma} \] for every totally positive $\alpha\in K^\times$ with $\alpha\equiv1\bmod^\times\mathfrak m$. \end{definition} \begin{prop}\label{prop:v5_hec_cha_dat} Let $(\Gamma,t,f,a,R)$ be an admissible Kummer twist datum with field $L$ and exceptional set $\Sigma$. There is an algebraic Hecke character $\varepsilon$ of $L$ with values in $L$, whose modulus is prime to every prime of $L$ of residue degree one over a prime not in $\Sigma$, such that \[ \varepsilon(\mathfrak P)=\varepsilon_{\mathfrak P} \] for every prime $\mathfrak P$ of $L$ of residue degree one over a prime $p\notin\Sigma$, where $\varepsilon_{\mathfrak P}$ is the number of Proposition~\ref{prop:v5_glo_sys_kum}(2). \end{prop} \begin{proof} Put \[ \delta(\mathfrak P)=\varepsilon_{\mathfrak P}p^{k-1} \] for a degree-one prime $\mathfrak P$ above $p\notin\Sigma$, with the coefficients of Proposition~\ref{prop:v5_glo_sys_kum}(2). We construct a Hecke character with these values and then divide by the $(k-1)$st power of the norm character. The field $L$ is abelian over $\mathbb Q$, since it is generated by roots of unity and square roots of integers. Choose distinct primes $\ell_1,\ell_2>k$, outside $\Sigma$, that split completely in $L$, by Chebotarev's theorem \cite[Ch.~I, \S2.2]{locbib:Serre1989}, and primes $\lambda_i\mid\ell_i$. Write $\mathcal P$ for the degree-one primes of $L$ above rational primes outside $\Sigma$. Apply Lemma~\ref{lem:v5_hec_cha_ht} to \[ \psi_i=\det V_{\bar a,\lambda_i}:G_L\longrightarrow L_{\lambda_i}^{\times}=\mathbb Q_{\ell_i}^{\times}. \] Its Frobenius condition is Proposition~\ref{prop:v5_glo_sys_kum}(2). At every $w\mid\ell_i$, the representation $V_{\bar a,\lambda_i}$ is crystalline by Proposition~\ref{prop:v5_cry_com_for}(1), since $\ell_i$ splits completely and $\ell_i>k$. Its determinant is therefore crystalline, hence Hodge--Tate \cite[1.5.2, 3.8, 5.1.4 and 5.1.7]{locbib:Fontaine1994}. The lemma gives an algebraic Hecke character $\chi_i$, with values in $L$, such that \[ \chi_i(\mathfrak P)=\delta(\mathfrak P) \qquad(\mathfrak P\in\mathcal P,\ \mathfrak P\nmid\ell_i). \] Its modulus is supported on the primes above $\ell_i$ and on a finite set $T_i$ disjoint from $\mathcal P$. Choose an ideal $\mathfrak n$, supported on $T_1\cup T_2$, and ideals $\mathfrak r_i$, supported on the primes above $\ell_i$, with exponents large enough that $\mathfrak n\mathfrak r_i$ is a modulus for $\chi_i$. These three supports are pairwise disjoint: every prime above either $\ell_i$ belongs to $\mathcal P$. The characters agree on the degree-one primes prime to both moduli, so Lemma~\ref{lem:v5_hec_cha_uni}(2) gives an algebraic Hecke character $\chi$ of modulus $\mathfrak n$ restricting to both. Every $\mathfrak P\in\mathcal P$ is prime to $\mathfrak n$ and to at least one $\ell_i$; using that $i$ shows $\chi(\mathfrak P)=\delta(\mathfrak P)$. The absolute norm $\mathrm N$ is an algebraic Hecke character of modulus $(1)$ and infinity type $(1)_\sigma$: for totally positive $\alpha$, \[ \mathrm N((\alpha))=|N_{L/\mathbb Q}(\alpha)| =\prod_\sigma\sigma(\alpha). \] Here $L$ is totally real or totally imaginary, so the norm on such $\alpha$ is positive. Thus \[ \varepsilon=\chi\,\mathrm N^{1-k} \] is an algebraic Hecke character with values in $L$, whose modulus is prime to $\mathcal P$. Since $\mathrm N\mathfrak P=p$ for $\mathfrak P\in\mathcal P$ above $p$, it has the required value $\varepsilon(\mathfrak P)=\varepsilon_{\mathfrak P}$. \end{proof} \subsection{The rational-field newform} \label{subsec:newform} When $L=\mathbb Q$, the Kummer character is quadratic and the multiplier is real. In this case the two character summands coincide, and Poincar\'e duality gives a pairing on the global representation itself. This determines the determinant and gives oddness. Lemma~\ref{lem:v5_mod_odd_pur} then produces a weight-$k$ newform from the Frobenius polynomials at good primes and the crystalline comparison at an auxiliary prime. \begin{lemma}\label{lem:v5_equ_poi_pai} Let $(\Gamma,t,f,a,R)$ be an admissible Kummer twist datum with field $L=\mathbb Q$ and exceptional set $\Sigma$. For a prime $\ell$ let $V_{a,\ell}$ and $V_{\bar a,\ell}$ be its $\ell$-adic realisations, representations of $G_{\mathbb Q}=\operatorname{Gal}(\bar{\mathbb Q}/\mathbb Q)$. Then $V_{a,\ell}\cong V_{\bar a,\ell}$, and there is a perfect $\mathbb Q_\ell$-bilinear pairing \[ B_\ell:V_{\bar a,\ell}\times V_{\bar a,\ell}\to\mathbb Q_\ell(1-k) \] such that $B_\ell(\sigma x,\sigma y)=\sigma B_\ell(x,y)$ for $\sigma\in G_{\mathbb Q}$ and \[ B_\ell(y,x)=(-1)^{k-1}B_\ell(x,y)\qquad(x,y\in V_{\bar a,\ell}). \] Thus $B_\ell$ is alternating if $k$ is even and symmetric if $k$ is odd. \end{lemma} \begin{proof} We first identify the two sheaves. Fix a prime $p\notin\Sigma$ with $p\neq\ell$, and a modular model of the datum at $p$ (Definition~\ref{def:v5_mod_mod_kum}), which exists by Proposition~\ref{prop:v5_exi_mod_mod}; then $\mathcal U=U$ is smooth over $\mathbb Z_{(p)}$ with generic fibre $U_{\mathbb Q}=\mathbb P^1_{\mathbb Q}\setminus S$. The character $\chi_\Phi(g,\zeta)=\chi_G(g)\zeta^j$ of $\tilde G$ has finite order and values in $L^\times=\mathbb Q^\times$ ((M4) and $\mu_2\subset\mathbb Q$), hence values $\pm1$, so $\chi_\Phi^{-1}=\chi_\Phi$ and the $\chi_\Phi$- and $\chi_\Phi^{-1}$-parts of $\mathcal M$ coincide: $\mathcal F_a=\mathcal F_{\bar a}$ by their definition (Definition~\ref{def:v5_kum_eig_she}(2)). Put $\mathcal F=\mathcal F_a|_{U_{\mathbb Q}}$. By Proposition~\ref{prop:v5_glo_sys_kum}(1), $V_{a,\ell}$ and $V_{\bar a,\ell}$ are both isomorphic, as representations of $G_{\mathbb Q}$, to $V=H^1(\mathbb P^1_{\bar{\mathbb Q}},o_*\mathcal F)$, where $o:U_{\bar{\mathbb Q}}\hookrightarrow\mathbb P^1_{\bar{\mathbb Q}}$. It suffices to construct $B$ on $V$. We next show that $\mathcal F$ carries a perfect pairing $\beta:\mathcal F\otimes\mathcal F\to\mathbb Q_\ell(2-k)$ of lisse sheaves on $U_{\mathbb Q}$ with $\beta(y\otimes x)=(-1)^k\beta(x\otimes y)$. By Lemma~\ref{lem:v5_kum_eig_pai}(1), the perfect alternating cup-product pairing $\langle\,,\rangle:\mathcal H\otimes\mathcal H\to\mathbb Q_\ell(-1)$ induces the pairing \[ \langle x_1\cdots x_{k-2},y_1\cdots y_{k-2}\rangle=\frac1{(k-2)!}\sum_{\sigma\in S_{k-2}}\prod_{i=1}^{k-2}\langle x_i,y_{\sigma(i)}\rangle \] on $\operatorname{Sym}^{k-2}\mathcal H$; composed with the trace of the finite \'etale map $\varpi$ it gives a pairing on $\mathcal M$ whose restriction to $\mathcal F_a\otimes\mathcal F_{\bar a}$ is perfect on $U$, by Lemma~\ref{lem:v5_kum_eig_pai}(2), whose hypotheses hold by Lemma~\ref{lem:v5_eta_eig_twi}(1), (2). Let $\beta$ be its restriction to $U_{\mathbb Q}$. Since $\langle y_i,x_{\sigma(i)}\rangle=-\langle x_{\sigma(i)},y_i\rangle$, substituting $\sigma^{-1}$ for $\sigma$ gives $\langle y,x\rangle=(-1)^{k-2}\langle x,y\rangle$ on $\operatorname{Sym}^{k-2}\mathcal H$; this sign survives the trace and the restriction, so $\beta(y\otimes x)=(-1)^k\beta(x\otimes y)$. By $\beta$, $\mathcal F\cong\mathcal F^\vee(2-k)$, so $\mathcal F^\vee(1)\cong\mathcal F(k-1)$. By the duality theorem \cite{locbib:Deligne1974}, Th\'eor\`eme (2.12), applied to the projective smooth connected curve $X=\mathbb P^1_{\bar{\mathbb Q}}$ over the algebraically closed field $\bar{\mathbb Q}$, the dense open set $U_{\bar{\mathbb Q}}$ and the lisse sheaf $\mathcal F|_{U_{\bar{\mathbb Q}}}$, the pairing $\operatorname{Tr}(x\cup y)$ between $H^1(X,o_*\mathcal F)$ and $H^1(X,o_*\mathcal F^\vee(1))$ is perfect. Transported along $\mathcal F^\vee(1)\cong\mathcal F(k-1)$ it becomes \[ B(x,y)=\operatorname{Tr}\bigl(\beta_*(x\cup y)\bigr)\in\mathbb Q_\ell(1-k)\qquad(x,y\in V), \] where $x\cup y\in H^2(X,o_*\mathcal F\otimes o_*\mathcal F)$, $\beta_*$ is induced by $o_*\mathcal F\otimes o_*\mathcal F\to o_*(\mathcal F\otimes\mathcal F)\xrightarrow{\beta}o_*\mathbb Q_\ell(2-k)=\mathbb Q_\ell(2-k)$, and $\operatorname{Tr}:H^2(X,\mathbb Q_\ell(2-k))\to\mathbb Q_\ell(1-k)$ is the trace map. So $B$ is perfect. The pairing $B$ is $G_{\mathbb Q}$-equivariant. The sheaf $\mathcal F$ and the pairing $\beta$ are defined on $U_{\mathbb Q}$, and $G_{\mathbb Q}$ acts on the cohomology of $X=\mathbb P^1_{\mathbb Q}\otimes\bar{\mathbb Q}$ through the second factor. The cup product and $\beta_*$ commute with this action by functoriality, and so does the trace map: it is the stalk at $\operatorname{Spec}\bar{\mathbb Q}$ of the trace morphism $R^2h_*\mathbb Q_\ell(1)\to\mathbb Q_\ell$ of the smooth proper map $h:\mathbb P^1_{\mathbb Q}\to\operatorname{Spec}\mathbb Q$, a morphism of sheaves on $\operatorname{Spec}\mathbb Q$ \cite{locbib:SGA4vol3}, Exp.~XVIII, Th\'eor\`eme 2.9. Hence $B(\sigma x,\sigma y)=\sigma B(x,y)$, where $\sigma$ acts on $\mathbb Q_\ell(1-k)$ through $\chi_\ell^{1-k}$, $\chi_\ell$ the $\ell$-adic cyclotomic character. Finally we compute the symmetry of $B$. For classes $x,y$ of degree one, $y\cup x=-s_*(x\cup y)$, where $s$ is the symmetry of $o_*\mathcal F\otimes o_*\mathcal F$: this is the Koszul sign rule for cup products \cite{locbib:SGA4half}, Cycle, 1.2--1.3, used in the same way in loc.\ cit., Sommes trig., 3.6 c). As $\beta\circ s=(-1)^k\beta$, we get $\beta_*\circ s_*=(-1)^k\beta_*$, and so \[ B(y,x)=\operatorname{Tr}\bigl(\beta_*(y\cup x)\bigr)=-(-1)^k\operatorname{Tr}\bigl(\beta_*(x\cup y)\bigr)=(-1)^{k-1}B(x,y). \] \end{proof} \begin{prop}\label{prop:v5_det_odd_rat} Let $(\Gamma,t,f,a,R)$ be an admissible Kummer twist datum with field $L=\mathbb Q$ and exceptional set $\Sigma$. For a prime $\ell$ let $V_\ell=V_{\bar a,\ell}$ be its $\ell$-adic realisation, a representation of $G_{\mathbb Q}=\operatorname{Gal}(\bar{\mathbb Q}/\mathbb Q)$, and for $p\notin\Sigma$ let $A_p\in\mathbb Z$ and $\varepsilon_p\in\{\pm1\}$ be as in Proposition~\ref{prop:v5_glo_sys_kum}(3). Let $\chi_\ell$ be the $\ell$-adic cyclotomic character and $c\in G_{\mathbb Q}$ a complex conjugation. \begin{enumerate} \item There is a continuous character $\psi:G_{\mathbb Q}\to\{\pm1\}$, unramified outside $\Sigma$, such that $\det V_\ell=\psi\,\chi_\ell^{1-k}$ for every prime $\ell$, and $\psi(\mathrm{Frob}_p)=\varepsilon_p$ for every prime $p\notin\Sigma$. \item If $k$ is even, then $\psi=1$. \item If $k$ is odd, then $\psi\neq1$ and $\ker\psi=G_K$ for an imaginary quadratic field $K$ unramified outside $\Sigma$; moreover $A_p=0$ for every prime $p\notin\Sigma$ inert in $K$. \item $\det V_\ell(c)=-1$ for every prime $\ell$. \item There is a prime $p_0\notin\Sigma$ such that $X^2-A_{p_0}X+\varepsilon_{p_0}p_0^{k-1}$ is irreducible over $\mathbb Q$. \end{enumerate} \end{prop} \begin{proof} The crux is that $K$ in (3) is imaginary: otherwise the Hodge--Tate weights $0$ and $k-1$ at a prime split in $K$ would make a unit of infinite order a root of unity. \emph{Proof of (1).} For a prime $\ell$ put $\psi_\ell=\det V_\ell\cdot\chi_\ell^{k-1}$, a continuous character $G_{\mathbb Q}\to\mathbb Q_\ell^\times$, unramified outside $\Sigma\cup\{\ell\}$. For $p\notin\Sigma\cup\{\ell\}$, $\psi_\ell(\mathrm{Frob}_p)=\varepsilon_pp^{k-1}\cdot p^{1-k}=\varepsilon_p\in\{\pm1\}$. So $\psi_\ell^2$ is trivial on a dense subset, hence trivial, and $\psi_\ell$ takes values in $\{\pm1\}$. For two primes $\ell,\ell'$, $\psi_\ell$ and $\psi_{\ell'}$ agree at $\mathrm{Frob}_p$ for all $p\notin\Sigma\cup\{\ell,\ell'\}$, hence everywhere. Their common value $\psi$ is unramified outside $\Sigma\cup\{\ell\}$ for every $\ell$, hence outside $\Sigma$, and $\psi(\mathrm{Frob}_p)=\varepsilon_p$ for $p\notin\Sigma$ (take $\ell\neq p$). This proves (1). \emph{Proof of (2).} Let $\ell$ be a prime. By Lemma~\ref{lem:v5_equ_poi_pai}, $B_\ell$ is a perfect alternating pairing on the two-dimensional space $V_\ell$ with $B_\ell(\sigma x,\sigma y)=\chi_\ell(\sigma)^{1-k}B_\ell(x,y)$ for $\sigma\in G_{\mathbb Q}$. For a basis $e_1,e_2$ of $V_\ell$ we have $B_\ell(\sigma e_1,\sigma e_2)=\det(\sigma)\,B_\ell(e_1,e_2)$ and $B_\ell(e_1,e_2)\neq0$; so $\det V_\ell=\chi_\ell^{1-k}$, that is, $\psi_\ell=1$, and $\psi=1$. This proves (2). \emph{Proof of (3).} Until the proof of (4), $k$ is odd. We first show that $\psi\neq1$. The family $(V_\ell)_\ell$ satisfies the hypotheses of Lemma~\ref{lem:v5_irr_cry_two}(2) with $T=\Sigma$: (a) is Proposition~\ref{prop:v5_glo_sys_kum}(3), and (b) is Proposition~\ref{prop:v5_cry_com_for}(2) with $\mathfrak P=\ell$, which applies to every decomposition group at $\ell$ because for $L=\mathbb Q$ every embedding $\bar{\mathbb Q}\subset\bar{\mathbb Q}_\ell$ induces $\iota_{\mathfrak P}$. Fix a prime $\ell_0\notin\Sigma$ with $\ell_0>k$; then $V=V_{\ell_0}$ is absolutely irreducible. Let $B$ be the pairing of Lemma~\ref{lem:v5_equ_poi_pai} on $V$; it is symmetric, as $k$ is odd. If $\psi=1$, then $\wedge^2V=\det V\cong\mathbb Q_{\ell_0}(1-k)$, and $D(x,y)=x\wedge y$ is a perfect alternating $G_{\mathbb Q}$-equivariant pairing $V\times V\to\mathbb Q_{\ell_0}(1-k)$. Both $B$ and $D$ define isomorphisms $V\to V^\vee(1-k)$ of absolutely irreducible representations, so by Schur's lemma $B=\gamma D$ with $\gamma\in\mathbb Q_{\ell_0}^\times$; but a nonzero bilinear form in characteristic zero is not both symmetric and alternating. Hence $\psi\neq1$, and $\ker\psi=G_K$ for a quadratic field $K$, unramified outside $\Sigma$ as $\psi$ is. Let $\ell$ be any prime and $B=B_\ell$ the symmetric pairing of Lemma~\ref{lem:v5_equ_poi_pai}. As $B$ is nondegenerate and $\bar{\mathbb Q}_\ell$ is algebraically closed of characteristic zero, there is a basis $e_1,e_2$ of $V_\ell\otimes\bar{\mathbb Q}_\ell$ with $B(e_1,e_1)=B(e_2,e_2)=0$ and $B(e_1,e_2)=1$. Then $B(x_1e_1+x_2e_2,x_1e_1+x_2e_2)=2x_1x_2$, so the isotropic lines are exactly $\bar{\mathbb Q}_\ell e_1$ and $\bar{\mathbb Q}_\ell e_2$. Every $\sigma\in G_{\mathbb Q}$ satisfies $B(\sigma x,\sigma y)=\chi_\ell(\sigma)^{1-k}B(x,y)$, so it permutes these two lines. \begin{itemize} \item If $\sigma$ fixes both, $\sigma e_1=\alpha e_1$ and $\sigma e_2=\beta e_2$ with $\alpha\beta=B(\sigma e_1,\sigma e_2)=\chi_\ell(\sigma)^{1-k}$, so $\det\sigma=\chi_\ell(\sigma)^{1-k}$. \item If $\sigma$ exchanges them, $\sigma e_1=\beta e_2$ and $\sigma e_2=\alpha e_1$ with $\alpha\beta=\chi_\ell(\sigma)^{1-k}$, so $\det\sigma=-\chi_\ell(\sigma)^{1-k}$ and $\operatorname{tr}\sigma=0$. \end{itemize} By (1), $\sigma$ fixes both lines if and only if $\psi(\sigma)=1$, that is, $\sigma\in G_K$. So $G_K$ acts on $\bar{\mathbb Q}_\ell e_i$ through a character $\xi_i:G_K\to\bar{\mathbb Q}_\ell^\times$, and for $\tau\in G_{\mathbb Q}\setminus G_K$ and $\delta\in G_K$, \[ \xi_1(\tau\delta\tau^{-1})=\xi_2(\delta). \] If $p\notin\Sigma$ is inert in $K$, take $\ell\neq p$: then $\mathrm{Frob}_p\notin G_K$, so $A_p=\operatorname{tr}V_\ell(\mathrm{Frob}_p)=0$. We next compute Hodge--Tate weights at a prime split in $K$. Let $\ell\notin\Sigma$ be a prime with $\ell>k$ that splits in $K$; there are infinitely many. Let $\iota_w:\bar{\mathbb Q}\to\bar{\mathbb Q}_\ell$ be an embedding, with decomposition group $D_w$, let $\tau\in G_{\mathbb Q}\setminus G_K$, and put $\iota_{w'}=\iota_w\circ\tau^{-1}$, with decomposition group $D_{w'}=\tau D_w\tau^{-1}$. Identify $D_w$ and $D_{w'}$ with $G_{\mathbb Q_\ell}=\operatorname{Gal}(\bar{\mathbb Q}_\ell/\mathbb Q_\ell)$ through $\iota_w$ and $\iota_{w'}$; then $\delta\mapsto\tau\delta\tau^{-1}$ becomes the identity of $G_{\mathbb Q_\ell}$. As $\ell$ splits in $K$, $D_w,D_{w'}\subset G_K$, and $\iota_1=\iota_w|_K$, $\iota_2=\iota_{w'}|_K$ are the two embeddings $K\to\mathbb Q_\ell$, with $\iota_2(x)=\iota_1(\bar x)$, where $x\mapsto\bar x$ is the nontrivial automorphism of $K$ (the restriction of $\tau^{-1}$). Let $E\subset\bar{\mathbb Q}_\ell$ be a finite extension of $\mathbb Q_\ell$ containing the coordinates of $e_1,e_2$ in a $\mathbb Q_\ell$-basis of $V_\ell$; then the $\xi_i$ take values in $E^\times$, and $(V_\ell\otimes_{\mathbb Q_\ell}E)|_{G_K}=E(\xi_1)\oplus E(\xi_2)$. By Proposition~\ref{prop:v5_cry_com_for}(2), $V_\ell|_{D_w}$ is crystalline with Hodge--Tate weights $0$ and $k-1$. As crystalline representations are stable under subquotients and $D_{\mathrm{HT}}$ is exact on Hodge--Tate representations \cite{locbib:Fontaine1994}, \S1, each $\xi_i|_{D_w}$ is crystalline with a single Hodge--Tate weight $h_i$, and $\{h_1,h_2\}=\{0,k-1\}$. By the display above and the identification of $\delta\mapsto\tau\delta\tau^{-1}$ with the identity, the character of $G_{\mathbb Q_\ell}$ given by $\xi_1|_{D_{w'}}$ is the one given by $\xi_2|_{D_w}$; so $\xi_1|_{D_{w'}}$ has Hodge--Tate weight $h_2$. As $0\leq h_i\leq k-1\leq\ell-2$, Lemma~\ref{lem:v5_irr_cry_two}(1) gives $\xi_1|_{D_w}=\mu_1\chi_\ell^{-h_1}$ and $\xi_1|_{D_{w'}}=\mu_2\chi_\ell^{-h_2}$ as characters of $G_{\mathbb Q_\ell}$, with $\mu_1,\mu_2$ unramified. Suppose now that $K$ is real, and let $\eta=\xi_1\circ\mathrm{Art}_K$, where $\mathrm{Art}_K:\mathbb A_K^\times\to G_K^{\mathrm{ab}}$ is the reciprocity map; $\eta$ is a continuous character, trivial on $K^\times$, and its restriction $\eta_v$ to $K_v^\times$ is $\xi_1$ composed with the local reciprocity map of $K_v$ and the decomposition map \cite{locbib:Neukirch1999}, Ch.~VI, \S5. We evaluate $\eta_v$ on units. \begin{itemize} \item If $v$ is finite and lies over a prime not in $\Sigma\cup\{\ell\}$, then $\xi_1$ is unramified at $v$, since $V_\ell$ is unramified at the prime below $v$, and the local reciprocity map sends $\mathcal O_v^\times$ into the inertia group \cite{locbib:Neukirch1999}, Ch.~V, \S1; so $\eta_v(\mathcal O_v^\times)=1$. \item If $v$ lies over $q\in\Sigma$, then $q\neq\ell$, and $\eta_v$ is trivial on an open subgroup $U_v$ of $\mathcal O_v^\times$: $\mathcal O_v^\times$ is a finite group times a pro-$q$ group, $\mathcal O_E^\times$ has an open pro-$\ell$ subgroup, and a pro-$q$ group has no nontrivial continuous pro-$\ell$ quotient. \item If $v$ is real, $\eta_v$ is trivial on the connected group $\mathbb R_{>0}$, as $E^\times$ is totally disconnected. \item If $v=v_i$ is the place of $\iota_i$, so that $K_{v_i}=\mathbb Q_\ell$, then for $x\in\mathbb Z_\ell^\times$, $\eta_{v_i}(x)=\chi_\ell(\mathrm{Art}_{\mathbb Q_\ell}(x))^{-h_i}=x^{h_i}$, since $\mu_i$ is unramified and $\chi_\ell(\mathrm{Art}_{\mathbb Q_\ell}(x))=x^{-1}$ in the normalisation in which uniformisers map to arithmetic Frobenius elements \cite{locbib:Neukirch1999}, Ch.~V, \S2; the other normalisation replaces $x^{h_i}$ by $x^{-h_i}$, which changes nothing below. \end{itemize} By Dirichlet's unit theorem \cite{locbib:Neukirch1999}, Ch.~I, (7.4), $\mathcal O_K^\times$ has rank one. Its subgroup of totally positive units lying in $U_v$ for every $v$ over $\Sigma$ has finite index, so it contains a unit $u$ of infinite order, and $u\bar u=N_{K/\mathbb Q}(u)=1$ because $u$ is totally positive. Then \[ 1=\eta(u)=\prod_v\eta_v(u)=\iota_1(u)^{h_1}\,\iota_2(u)^{h_2}=\iota_1(u)^{h_1}\,\iota_1(\bar u)^{h_2}=\iota_1(u)^{h_1-h_2}. \] As $h_1-h_2=\pm(k-1)\neq0$, $\iota_1(u)$ is a root of unity, hence so is $u$, a contradiction. So $K$ is imaginary, and (3) is proved. \emph{Proof of (4).} If $k$ is even, $\psi=1$ by (2), and $\det V_\ell(c)=\chi_\ell(c)^{1-k}=(-1)^{k-1}=-1$. If $k$ is odd, $\chi_\ell(c)^{1-k}=1$, and $c$ acts nontrivially on the imaginary quadratic field $K$, so $\det V_\ell(c)=\psi(c)=-1$. \emph{Proof of (5).} If $k$ is even, every $p\notin\Sigma$ will do: a rational root $r$ of $Q_p$ is real with $|r|=p^{(k-1)/2}$, so $r^2=p^{k-1}$ with $k-1$ odd, which is impossible. Let $k$ be odd, and fix $\ell$ and $w$ as in the computation of Hodge--Tate weights. As $\xi_1|_{D_w}$ and $\xi_2|_{D_w}$ have the distinct Hodge--Tate weights $h_1\neq h_2$, $\xi_1\neq\xi_2$, so $\{\delta\in G_K:\xi_1(\delta)\neq\xi_2(\delta)\}$ is open, nonempty and stable under conjugation. By Chebotarev it contains a Frobenius element $\mathrm{Frob}_v$ at a place $v$ of $K$ of degree one over a prime $p_0\notin\Sigma\cup\{\ell\}$. Then $p_0$ splits in $K$, so $\varepsilon_{p_0}=\psi(\mathrm{Frob}_{p_0})=1$, and $\mathrm{Frob}_v$ is a Frobenius element at $p_0$ in $G_{\mathbb Q}$. The roots of $Q_{p_0}$ are therefore $\xi_1(\mathrm{Frob}_v)\neq\xi_2(\mathrm{Frob}_v)$, with product $p_0^{k-1}$. If $Q_{p_0}$ were reducible over $\mathbb Q$, its roots would be real of absolute value $p_0^{(k-1)/2}$ and distinct, hence $\pm p_0^{(k-1)/2}$, with product $-p_0^{k-1}$, a contradiction. \end{proof} \begin{prop}\label{prop:v5_new_rat_cm} Let $(\Gamma,t,f,a,R)$ be an admissible Kummer twist datum with field $L=\mathbb Q$ and exceptional set $\Sigma$, and for a prime $p\notin\Sigma$ let $A_p\in\mathbb Z$ and $\varepsilon_p\in\{\pm1\}$ be the numbers of Proposition~\ref{prop:v5_glo_sys_kum}(2), (3). \begin{enumerate} \item There is a newform $g$ of weight $k$ and nebentypus $\psi$, of level divisible only by primes in $\Sigma$, such that $A_p=a_p(g)$ and $\varepsilon_p=\psi(p)$ for every prime $p\notin\Sigma$. \item If $k$ is odd, there is an imaginary quadratic field $K$, unramified outside $\Sigma$, with quadratic character $\chi_K$, such that $\psi(p)=\chi_K(p)$ and $a_p(g)=\chi_K(p)\,a_p(g)$ for every prime $p\notin\Sigma$; that is, $g$ has complex multiplication by $K$. \end{enumerate} \end{prop} \begin{proof} We check the hypotheses of Lemma~\ref{lem:v5_mod_odd_pur} for the family $(V_\ell)_\ell$, with $T=\Sigma$ and $Q_p(X)=X^2-A_pX+\varepsilon_pp^{k-1}$. \begin{itemize} \item (a): by Proposition~\ref{prop:v5_glo_sys_kum}(1), (3), each $V_\ell$ is two-dimensional, and for $p\notin\Sigma$ and $\ell\neq p$ it is unramified at $p$; $Q_p$ lies in $\mathbb Z[X]$ ($A_p\in\mathbb Z$, $\varepsilon_p=\pm1$), does not depend on $\ell$, and has roots of absolute value $p^{(k-1)/2}$ under every complex embedding. \item (b): for $\ell\notin\Sigma$ with $\ell>k$, Proposition~\ref{prop:v5_cry_com_for}(2), with $\mathfrak P=\ell$ and $\lambda=\mathfrak P$, shows that $V_\ell$ restricted to a decomposition group at $\ell$ is crystalline with Hodge--Tate weights $0$ and $k-1$, in the normalisation in which $\mathbb Q_\ell(-1)$ has weight $1$. \item (c): $\det V_\ell(c)=-1$ for every prime $\ell$, by Proposition~\ref{prop:v5_det_odd_rat}(4). \item (d): by Proposition~\ref{prop:v5_det_odd_rat}(5) there is $p_0\notin\Sigma$ with $Q_{p_0}$ irreducible over $\mathbb Q$. \end{itemize} By Lemma~\ref{lem:v5_mod_odd_pur} there is a newform $g$ of weight $k$ and nebentypus $\psi$, of level divisible only by primes in $\Sigma$, with $X^2-A_pX+\varepsilon_pp^{k-1}=X^2-a_p(g)X+\psi(p)p^{k-1}$ for every prime $p\notin\Sigma$. Comparing coefficients, $A_p=a_p(g)$ and $\varepsilon_p=\psi(p)$ for every prime $p\notin\Sigma$. This proves (1). For (2), let $k$ be odd, let $\psi'$ be the character of $G_{\mathbb Q}$ of Proposition~\ref{prop:v5_det_odd_rat}(1), and let $K$ be the imaginary quadratic field of Proposition~\ref{prop:v5_det_odd_rat}(3), with $\ker\psi'=G_K$, unramified outside $\Sigma$. A prime $p\notin\Sigma$ is unramified in $K$, and $\chi_K(p)=\psi'(\mathrm{Frob}_p)=\varepsilon_p=\psi(p)$, by Proposition~\ref{prop:v5_det_odd_rat}(1) and item (1) above. If $p$ is inert in $K$, then $a_p(g)=A_p=0$ by Proposition~\ref{prop:v5_det_odd_rat}(3); otherwise $\chi_K(p)=1$. In both cases $a_p(g)=\chi_K(p)a_p(g)$. \end{proof} \subsection{The general theorem} \label{subsec:main} We combine the integral cusp relation with the common Frobenius polynomial to prove Theorem~\ref{thm:introB}. The full statement records the point-count formula, the bounds on the trace and the criterion for the cusp expansion to extend to a modular form. \begin{thm}\label{thm:v5_asd_kum_twi} Let $(\Gamma,t,f,a,R)$ be an admissible Kummer twist datum, with $a=j/d$, coefficients $c(N)$, field $L$ and exceptional set $\Sigma$. Let $\mathfrak P$ be a prime of $L$ of residue degree one over a prime $p\notin\Sigma$ (so $p\equiv1\pmod d$), and let $\iota_{\mathfrak P}:L\to\mathbb Q_p$ be the embedding defined by $\mathfrak P$, which maps $\mathcal O_L[\frac1{dM}]$ into $\mathbb Z_p$. Read congruences through $\iota_{\mathfrak P}$. There are $A_{\mathfrak P}\in\mathcal O_L$ and $\varepsilon_{\mathfrak P}\in L^\times$ with the following properties. Write $B_{\mathfrak P}=\varepsilon_{\mathfrak P}p^{k-1}$ for the constant term of the polynomial. \begin{enumerate} \item For all integers $m\geq1$ prime to $p$ and $r\geq1$, \[ c(mp^r)-A_{\mathfrak P}\,c(mp^{r-1})+B_{\mathfrak P}\,c(mp^{r-2})\equiv0\pmod{p^{(k-1)r}}, \] where $c(x)=0$ for $x\notin\mathbb Z$. \item For every prime $\lambda$ of $L$ not above $p$, the global $\lambda$-adic realisation $V_{\bar a,\lambda}$ of $H_a$ is unramified at $\mathfrak P$, and $X^2-A_{\mathfrak P}X+B_{\mathfrak P}$ is the characteristic polynomial of geometric Frobenius there. The trace $A_{\mathfrak P}$ is given by the twisted point-count formula of Proposition~\ref{prop:v5_tra_ide_kum}(3). Moreover $|\sigma(A_{\mathfrak P})|\leq2p^{(k-1)/2}$ and $|\sigma(\varepsilon_{\mathfrak P})|=1$ for every embedding $\sigma:L\to\mathbb C$, and there is an algebraic Hecke character $\varepsilon$ of $L$ with values in $L$ such that $\varepsilon(\mathfrak P')=\varepsilon_{\mathfrak P'}$ for every prime $\mathfrak P'$ of $L$ of residue degree one over a prime not in $\Sigma$. \item If $L=\mathbb Q$ (so that $d=2$ and $\chi_f$ takes the values $\pm1$), there is a normalised newform $g$ of weight $k$ and nebentypus $\psi$, of level supported on $\Sigma$, such that $A_{p'}=a_{p'}(g)$ and $\varepsilon_{p'}=\psi(p')$ for every prime $p'\notin\Sigma$, where $A_{p'}$ and $\varepsilon_{p'}$ are the numbers attached to $\mathfrak P=p'\mathbb Z$. \item Let $P$ be the pole of $t$ on $X_\Gamma$ and, if $P$ is an interior point, let $e_P$ be its stabiliser order. If $P$ is not a cusp and $d\nmid e_P$, then $\tau\mapsto f_\Phi(e^{2\pi i\tau/d})$ is not the restriction to a half-plane $\operatorname{Im}\tau>y_0$, on which it converges, of a single-valued meromorphic function on $\mathbb H$; in particular it is not a meromorphic modular form, of any weight and multiplier system, for any subgroup of finite index in $\mathrm{SL}_2(\mathbb Z)$. If $P$ is a cusp or $d\mid e_P$, it is a cusp form of weight $k$ on a subgroup of finite index in $\Gamma$. \end{enumerate} \end{thm} \begin{proof} The main inputs are Theorem~\ref{thm:v5_con_cry_coe} and Proposition~\ref{prop:v5_tra_ide_kum}. Choose a modular model at $\mathfrak P$ by Proposition~\ref{prop:v5_exi_mod_mod}, with eigenlattice $H_{a,p}$ and Frobenius $\varphi$. Proposition~\ref{prop:v5_tra_ide_kum}(2) supplies $A_{\mathfrak P}\in\mathcal O_L$ and $\varepsilon_{\mathfrak P}\in L^\times$ such that \[ X^2-\iota_{\mathfrak P}(A_{\mathfrak P})X+ \iota_{\mathfrak P}(\varepsilon_{\mathfrak P})p^{k-1} \] is the characteristic polynomial of $p^{k-1}\varphi^{-1}$. By Proposition~\ref{prop:v5_glo_sys_kum}(1),(2),the single global system $V_{\bar a,\lambda}$ is unramified at $\mathfrak P$ for every $\lambda$ not above $p$, and these are the coefficients of its geometric Frobenius polynomial there; they are independent of the modular model and of $\lambda$. Apply Theorem~\ref{thm:v5_con_cry_coe}(2),(3) to this model. Its coefficients $A^\vee$ and $B^\vee$ are precisely $\iota_{\mathfrak P}(A_{\mathfrak P})$ and $\iota_{\mathfrak P}(B_{\mathfrak P})$, so it gives (1). The required integrality of the expansion is Lemma~\ref{lem:v5_hod_pos_the}(2). The point-count expression and the bounds in (2) are Proposition~\ref{prop:v5_tra_ide_kum}(3),(4). The algebraic Hecke character with these normalised determinant values is supplied by Proposition~\ref{prop:v5_hec_cha_dat}; its values agree at every degree-one prime outside $\Sigma$ with those of the same global system. This proves (2). If $L=\mathbb Q$, then $\mu_d\subset L$ and $0-1,\qquad 1-3(1-a)>-1. \] They give exactly $1/3n$, which proves the Clausen identity. Now take the coefficient of $X^n$ on both sides. On the left it is $\sum_kL_{n,k}L_{n,n-k}$. On the right it is $\sum_kL_{n,k}\binom{2k}{k}\binom{k}{n-k}$, and \[ \binom{2k}{k}\binom{k}{n-k}=\binom nk\binom{2k}{n}, \] both sides vanishing when $2k1$, that is, if and only if $\tau_0$ lies over one of the elliptic points of $\Gamma_0(7)$; these lie over $P$, since none has order two. The points of $\mathbb H$ with nontrivial stabiliser in $\Gamma$ are those over $P$ and those over $x=\pm7$. Indeed, a nontrivial element of $\Gamma_0(7)$ fixing $\tau_0$ makes $\tau_0$ an elliptic point of $\Gamma_0(7)$, and an element of $W_7\Gamma_0(7)$ fixing $\tau_0$ acts on $X_0(7)$ as $w_7$ and fixes the image of $\tau_0$, so that $x(\tau_0)=49/x(\tau_0)$. Conversely, let $\tau_\pm\in\mathbb H$ lie over $x=\pm7$, which are not cusps. As $w_7$ fixes the image of $\tau_\pm$, there is $\gamma\in\Gamma_0(7)$ with $W_7\tau_\pm=\gamma\tau_\pm$, and $\gamma^{-1}W_7\in\Gamma\setminus\Gamma_0(7)$ fixes $\tau_\pm$. Since $D(\pm7)\neq0$, $\tau_\pm$ is not over $P$; so its stabiliser in $\Gamma$ meets $\Gamma_0(7)$ trivially and has order two, and $z(\tau_\pm)\neq0$. Moreover $y(\tau_+)=\frac7{189}=\frac1{27}$ and $y(\tau_-)=\frac{-7}7=-1$. Now let $t_1\in\mathbb P^1$. The point $t_1=0$, the image of the only cusp, and the point $t_1=\infty$, the image of $P$, lie in $S$ by definition. For $t_1=y(\tau_\pm)$, Lemma~\ref{lem:v5_pic_fuc_loc}(1) applies with $e_1=2$, so $t_1\in S$ by Lemma~\ref{lem:v5_pic_fuc_loc}(3). As $y$ is a coordinate on $X_\Gamma$, every other $t_1$ is $y(\tau_1)$ for a point $\tau_1\in\mathbb H$ over neither $P$ nor $x=\pm7$; then $e_1=1$ and $\nu_1=\operatorname{ord}_{\tau_1}z=0$, and Lemma~\ref{lem:v5_pic_fuc_loc}(1) gives a basis of solutions of the Picard--Fuchs equation near $t_1$ of the form $(t-t_1)^iV_i$, $0\leq i\leq2$, with $V_i$ holomorphic at $t_1$ and $V_i(t_1)\neq0$. These solutions are holomorphic at $t_1$, and their Wronskian $\det\bigl(\frac{d^r}{dt^r}((t-t_1)^iV_i)\bigr)_{0\leq r,i\leq2}$ takes the value $2V_0(t_1)V_1(t_1)V_2(t_1)\neq0$ at $t_1$. The coefficients of the Picard--Fuchs equation, normalised to leading coefficient one, are quotients of minors of this Wronskian matrix by the Wronskian, hence holomorphic at $t_1$, and $t_1$ is not a singular point. Hence $S=\{0,-1,\frac1{27},\infty\}$. This proves (3). \emph{The field and the exceptional set.} The field $L$ is generated over $\mathbb Q(\zeta_2)=\mathbb Q$ by the values $\pm1$ of $\chi_f$, and $k$ is even; so $L=\mathbb Q$, in which no prime ramifies. The primes $2$, $3$ and those dividing $dMn_\Gamma n_f=14$ are $2,3,7$, and the primes below $k=4$ are $2,3$. The reductions of $0,\infty,-1,\frac1{27}$ in $\mathbb P^1(\mathbb F_p)$ are pairwise distinct unless $p\in\{2,3,7\}$. Hence $\Sigma=\{2,3,7\}$. This proves (4). \emph{Admissibility.} For (R): at $s=-1$ and $s=\frac1{27}$, that is, at $y(\tau_\pm)$, Lemma~\ref{lem:v5_pic_fuc_loc}(1) with $e_1=2$ and $\nu_1=0$ gives the local exponents $0,\frac12,1$ and a semisimple local monodromy of $\mathbb V_f$ with eigenvalues $1,-1,1$, so $\dim\mathbb V_f^{I_s}=2$. At $t=\infty$ the twist leaves no invariants, since $d=2$ does not divide $e_P=3$ (Lemma~\ref{lem:v5_l2_cri_pol}(2)). By Lemma~\ref{lem:v5_twi_par_rnk}(3), $\dim H_{1/2}=(3-2)+(3-2)=2$. For (F): $\Phi\neq0$ as $R=1$. By Lemma~\ref{lem:v5_ell_dat_and}(3), $\nu_P=\operatorname{ord}_{\tau_P}z=2$, so $\rho_P=\nu_P/e_P=\frac23$ by Lemma~\ref{lem:v5_l2_cri_pol}(1), (3), and since $a=\frac12<\frac23$, (F) holds at the points over $P$ by the same item. It holds at the cusp $\infty$, the only cusp of $\Gamma$, as for every Kummer twist datum (Lemma~\ref{lem:v5_l2_cri_pol}(4)). At $\tau_0\in\mathbb H$ not over $P$, $y$ is holomorphic and nonzero, as its only zero on $X_\Gamma$ is the cusp and its only pole is $P$; so $y^{1/2}$ has a holomorphic branch near $\tau_0$, the coefficient $z\,y^{1/2}y^{-1}\frac{dy}{d\tau}$ of $d\tau$ in $\Phi$ is holomorphic there, and $\operatorname{ord}_{\tau_0}\Phi\geq0>-1$. For (P), the multiplier is real-valued and (R) is established. Since $a=1-a=\frac12$, the datum with exponent $1-a$ is the same datum, for which (F) has just been proved. Both square-integrability hypotheses of Proposition~\ref{prop:v5_hod_typ_win} therefore hold, and that proposition gives (P). This proves (5). \end{proof} \begin{corollary}\label{cor:v5_asd_con_c7} For every prime $p\notin\{2,3,7\}$, every integer $m\geq1$ prime to $p$ and every $r\geq1$, \[ c_7(mp^r)-a_{16}(p)c_7(mp^{r-1})+p^3c_7(mp^{r-2}) \equiv0\pmod{p^{3r}}, \] where $c_7(x)=0$ for $x\notin\mathbb Z$ and $a_{16}(p)=A_p^\eta=\chi_{-4}(p)a_8(p)$. The series $C(Q)$ has no single-valued meromorphic continuation to $\mathbb H$ as a function of $\tau$ with $Q=e^{\pi i\tau}$. Moreover, for every modular model of the Cooper datum at $p$, the characteristic polynomials of $\varphi$ and of $p^3\varphi^{-1}$ on its eigenlattice $H_{1/2,p}$, and that of the geometric Frobenius $F$ on the cohomology $V_{\bar a}=V_a$ over $\bar{\mathbb F}_p$ of its Kummer eigensheaves, with $a=\frac12$, for every prime $\ell\neq p$, are all equal to $X^2-A_p^{\eta}X+p^3$. \end{corollary} \begin{proof} By Lemma~\ref{lem:v5_coo_dat_adm}, the Cooper datum is admissible with $k=4$, $L=\mathbb Q$, $\Sigma=\{2,3,7\}$ and coefficients $c_7(N)\in\mathbb Z[\frac12]$, with $c_7(1)=1$. The pole of $y$ has stabiliser order $3$. Since $2\nmid3$, the assertion on continuation follows from Theorem~\ref{thm:v5_asd_kum_twi}(4). Fix $p\notin\Sigma$ and any modular model at $p$, which exists by Proposition~\ref{prop:v5_exi_mod_mod}. The trace identity Proposition~\ref{prop:v5_tra_ide_kum}(2),(4) and the global system Proposition~\ref{prop:v5_glo_sys_kum}(2),(3) identify the characteristic polynomial of $p^3\varphi^{-1}$ with \[ X^2-A_pX+\varepsilon_pp^3,\qquad A_p\in\mathbb Z,\quad |A_p|\leq2p^{3/2}. \] Since $k=4$ is even and $L=\mathbb Q$, Proposition~\ref{prop:v5_det_odd_rat}(1),(2) give $\varepsilon_p=1$. Thus Theorem~\ref{thm:v5_con_cry_coe}(3) gives \[ (1-A_pV+p^3V^2)\sum_{N\geq1}c_7(N)Q^N \in\theta^3\mathbb Z_p[[Q]]. \] Its coefficient of $Q^p$ is $c_7(p)-A_p$, so $c_7(p)\equiv A_p\pmod{p^3}$. On the other hand, Theorem~\ref{thm:v5_mat_fir_dep} gives $c_7(p)\equiv A_p^\eta\pmod{p^2}$. Both traces are integers, and consequently \[ A_p-A_p^\eta\in p^2\mathbb Z. \] By Proposition~\ref{prop:v5_ind_wei_fou}, $A_p^\eta=a_{16}(p)$ is the $p$-th coefficient of a weight-four newform, so Deligne's bound gives $|A_p^\eta|\leq2p^{3/2}$ \cite[Th\'eor\`eme~8.2]{locbib:Deligne1974}. For $p\geq17$ the difference of the two traces has absolute value at most $4p^{3/2}0$ and $p\nmid\det A$. \end{lemma} \begin{proof} The first step is the classical description of groups commensurable with $\mathrm{PSL}_2(\mathbb Z)$: their elements are rational matrices up to scalars. What is added here is that the determinants can be taken prime to $p$, which comes from a fixed point of the closure of $\Gamma$ on the Bruhat--Tits tree of $\mathrm{PGL}_2(\mathbb Q_p)$. \emph{Elements of $\Gamma$ are rational up to scalars.} Let $\tilde\gamma\in\mathrm{SL}_2(\mathbb R)$ lift $\gamma$. Since $\Gamma(n)$ and $\tilde\gamma\Gamma(n)\tilde\gamma^{-1}$ both have finite index in $\Gamma$, the group $\Delta=\Gamma(n)\cap\tilde\gamma\Gamma(n)\tilde\gamma^{-1}$ has finite index in both. The $\mathbb Q$-linear span of a finite-index subgroup of $\mathrm{SL}_2(\mathbb Z)$ is $M_2(\mathbb Q)$, as the subgroup contains $\bigl(\begin{smallmatrix}1&h\\0&1\end{smallmatrix}\bigr)$ and $\bigl(\begin{smallmatrix}1&0\\h&1\end{smallmatrix}\bigr)$ for some $h\geq1$. So conjugation by $\tilde\gamma$ maps the span $M_2(\mathbb Q)$ of $\tilde\gamma^{-1}\Delta\tilde\gamma$ onto the span $M_2(\mathbb Q)$ of $\Delta$, and is a $\mathbb Q$-algebra automorphism of $M_2(\mathbb Q)$. By the Skolem--Noether theorem it is conjugation by some $A\in\mathrm{GL}_2(\mathbb Q)$; then $A^{-1}\tilde\gamma$ commutes with $M_2(\mathbb Q)$, hence with $M_2(\mathbb R)$, and is a real scalar. Scaling $A$ to be primitive in $M_2(\mathbb Z)$, $\det\tilde\gamma=1$ gives $\det A>0$ and $\tilde\gamma=\pm A/\sqrt{\det A}$. \emph{The closure of $\Gamma$ in $\mathrm{PGL}_2(\mathbb Q_p)$ is compact.} By the first step $\Gamma$ embeds in $\mathrm{PGL}_2(\mathbb Q)\subset\mathrm{PGL}_2(\mathbb Q_p)$. Let $K\subset\mathrm{PGL}_2(\mathbb Q_p)$ be the image of $\mathrm{GL}_2(\mathbb Z_p)$, compact and open. The subgroup $\Gamma\cap\mathrm{PSL}_2(\mathbb Z)$ contains $\Gamma(n)$, so it has finite index in $\Gamma$; with coset representatives $\gamma_1,\dots,\gamma_r$ we get $\Gamma\subset\bigcup_i\gamma_iK$, a compact set. Hence the closure $\overline\Gamma$ is a compact subgroup. It contains the image of $\mathrm{SL}_2(\mathbb Z_p)$: for every $s$, $\mathrm{SL}_2(\mathbb Z)\to\mathrm{SL}_2(\mathbb Z/np^s)$ is surjective, so by the Chinese remainder theorem $\Gamma(n)\to\mathrm{SL}_2(\mathbb Z/p^s)$ is surjective, and $\Gamma(n)$ is dense in $\mathrm{SL}_2(\mathbb Z_p)$. \emph{Fixed points on the tree.} The group $\mathrm{PGL}_2(\mathbb Q_p)$ acts on the Bruhat--Tits tree, whose vertices are the homothety classes of lattices in $\mathbb Q_p^2$, and the stabiliser of the vertex $v_0=[\mathbb Z_p^2]$ is $K$ \cite{locbib:Serre1980Trees}, Ch.~II, \S1. As $\overline\Gamma$ is compact and $K$ open, the orbit $\overline\Gamma v_0$ is finite, so $\overline\Gamma$ fixes a vertex or the midpoint of an edge (loc. cit., Ch.~I, \S6). We show that the image of $\mathrm{SL}_2(\mathbb Z_p)$ fixes no point other than $v_0$. It fixes $v_0$ and acts on the $p+1$ neighbours of $v_0$, which correspond to the lines of $\mathbb F_p^2$, through $\mathrm{SL}_2(\mathbb F_p)$, transitively. Its fixed set is a subtree; if it contained a point $x\neq v_0$, it would contain the first edge $[v_0,v_1]$ of the geodesic from $v_0$ to $x$ up to a point other than $v_0$, and, since $\mathrm{SL}_2(\mathbb Q_p)$ acts without inversion, also $v_1$, contradicting transitivity on the neighbours. Hence the fixed point of $\overline\Gamma$ is $v_0$, and $\overline\Gamma\subset K$. \emph{Conclusion.} Let $\gamma\in\Gamma$ and $A$ as in the first step. As $\gamma\in K$, $A=\lambda B$ with $\lambda\in\mathbb Q_p^\times$ and $B\in\mathrm{GL}_2(\mathbb Z_p)$. Both $A$ and $B$ have an entry that is a $p$-adic unit and no entry of negative valuation, so $v_p(\lambda)=0$ and $\det A=\lambda^2\det B\in\mathbb Z_p^\times$. \end{proof} \subsection{Hecke characters and modularity} \label{subsec:background_galois} In the Hecke-character arguments, rational Frobenius values are known at the degree-one primes, a set of density one. The proofs below explain why this is sufficient for the uses of \cite[Ch.~II, \S2.4, Proposition~2(iii); Ch.~III, \S2.3, Theorem~2, with \S2.4]{locbib:Serre1989}. \begin{lemma}\label{lem:v5_hec_cha_ht} Let $K$ be a number field, Galois over $\mathbb Q$, let $S_0$ be a finite set of rational primes, and let $\mathcal P$ be the set of primes of $K$ of residue degree one over a rational prime not in $S_0$. Let $\ell$ be a prime that splits completely in $K$, let $\lambda$ be a prime of $K$ above $\ell$ and $\iota_\lambda:K\to K_\lambda=\mathbb Q_\ell$ the completion map, let $\delta:\mathcal P\to K^\times$ be a map, and let $\psi:\operatorname{Gal}(\bar K/K)\to\mathbb Q_\ell^\times$ be a continuous character such that: \begin{description} \item[(a)] for every $\mathfrak P\in\mathcal P$ not above $\ell$, $\psi$ is unramified at $\mathfrak P$ and $\psi(\mathrm{Frob}_{\mathfrak P})=\iota_\lambda(\delta(\mathfrak P))$, where $\mathrm{Frob}_{\mathfrak P}$ is a geometric Frobenius element at $\mathfrak P$; \item[(b)] for every place $w$ of $K$ above $\ell$, the restriction of $\psi$ to a decomposition group at $w$ is Hodge--Tate. \end{description} Let $T$ be the set of primes of $K$ not above $\ell$ at which $\psi$ is ramified. Then $T$ is finite and disjoint from $\mathcal P$, and there are a nonzero integral ideal $\mathfrak m$ of $K$ whose prime divisors are the primes in $T$ and the primes above $\ell$, and an algebraic Hecke character $\chi$ of $K$ with values in $K$ and modulus $\mathfrak m$, such that: \begin{enumerate} \item $\psi$ is unramified at every prime $v\nmid\mathfrak m$, and $\psi(\mathrm{Frob}_v)=\iota_\lambda(\chi(v))$; \item $\chi(\mathfrak P)=\delta(\mathfrak P)$ for every $\mathfrak P\in\mathcal P$ not above $\ell$. \end{enumerate} \end{lemma} \begin{proof} For a rational representation, that is, one whose Frobenius traces lie in $K$ at almost all primes, this is the one-dimensional case of Serre's theorem that a locally algebraic abelian representation comes from an algebraic Hecke character \cite{locbib:Serre1989}, Ch.~III, \S2.3, Theorem~2, in its form with coefficients in a number field (loc.\ cit., \S2.4); passing from Hodge--Tate to locally algebraic characters follows \cite{locbib:FontaineMazur1995}, \S6. We check the hypotheses and give the step that differs. Let $w\mid\ell$. As $\ell$ splits completely in $K$, $K_w=\mathbb Q_\ell$, and the restriction of $\psi$ to a decomposition group at $w$ is Hodge--Tate by (b) and, being one-dimensional, semisimple on inertia; so it is locally algebraic by Tate's theorem (loc.\ cit., Ch.~III, \S1.2; proved in the Appendix to Ch.~III as Theorem~3, p.~III-52). Hence $\psi$ is locally algebraic (loc.\ cit., Ch.~III, \S2.1) and has a modulus of definition (loc.\ cit., \S2.2, Proposition~2, p.~III-11), which can be taken of the form $\mathfrak m=\prod_{v\in T}v^{e_v}\prod_{w\mid\ell}w^{e_w}$ with all $e_v,e_w\geq1$; in particular $T$ is finite. By (a), $\psi$ is unramified at every prime of $\mathcal P$ not above $\ell$, so $T\cap\mathcal P=\emptyset$. The step that differs is the last: up to it, the proof of Theorem~2 uses only local algebraicity and the modulus of definition, and yields a character $\phi$ of the group $S_{\mathfrak m}$ (loc.\ cit., Ch.~II, \S2.2) over $K_\lambda=\mathbb Q_\ell$ with the same Frobenius values as $\psi$ at the primes $v\nmid\mathfrak m\ell$. Rationality enters only to show that $\phi$ is defined over $K$, by loc.\ cit., Ch.~II, \S2.4, Proposition~2, whose criterion (iii) asks only that $\operatorname{Tr}\phi(F_v)\in K$ for $v$ in a set of places of density one, $F_v$ denoting the arithmetic Frobenius. The primes of $\mathcal P$ prime to $\mathfrak m\ell$ form such a set: the primes of residue degree one over $\mathbb Q$ have density one (loc.\ cit., Ch.~I, \S2.2, p.~I-7), and $S_0$ and the support of $\mathfrak m\ell$ are finite. For such a prime $\mathfrak P$, (a) gives $\operatorname{Tr}\phi(F_{\mathfrak P})=\psi(\mathrm{Frob}_{\mathfrak P})^{-1}=\iota_\lambda(\delta(\mathfrak P))^{-1}\in\iota_\lambda(K)$. So $\phi$ is defined over $K$. The characters of $S_{\mathfrak m}$ defined over $K$ are the algebraic Hecke characters of $K$ with values in $K$ and modulus $\mathfrak m$ (loc.\ cit., Ch.~II, \S2.4, Exercise, and \S2.7); this gives $\chi$ with $\psi(\mathrm{Frob}_v)=\iota_\lambda(\chi(v))$ for every prime $v\nmid\mathfrak m$, which is (1). Finally (2) is (1) at the primes $\mathfrak P\in\mathcal P$ not above $\ell$, which do not divide $\mathfrak m$ as $T\cap\mathcal P=\emptyset$, together with (a) and the injectivity of $\iota_\lambda$. \end{proof} \begin{lemma}\label{lem:v5_hec_cha_uni} Let $K$ be a number field, Galois over $\mathbb Q$, let $S_0$ be a finite set of rational primes, and let $\mathcal P$ be the set of primes of $K$ of residue degree one over a rational prime not in $S_0$. For $i=1,2$ let $\chi_i$ be an algebraic Hecke character of $K$ with values in $K$, modulus $\mathfrak m_i$ and infinity type $(a_{i,\sigma})_{\sigma\in\operatorname{Gal}(K/\mathbb Q)}$, and suppose that $\chi_1(\mathfrak P)=\chi_2(\mathfrak P)$ for all but finitely many $\mathfrak P\in\mathcal P$ prime to $\mathfrak m_1\mathfrak m_2$. \begin{enumerate} \item Then $a_{1,\sigma}=a_{2,\sigma}$ for every $\sigma\in\operatorname{Gal}(K/\mathbb Q)$, and $\chi_1=\chi_2$ on $I^{\mathfrak m_1\mathfrak m_2}$. \item Suppose moreover that $\mathfrak m_1=\mathfrak n\mathfrak r_1$ and $\mathfrak m_2=\mathfrak n\mathfrak r_2$, where $\mathfrak n$, $\mathfrak r_1$, $\mathfrak r_2$ are integral ideals with pairwise disjoint sets of prime divisors. Then there is a unique algebraic Hecke character $\chi$ of $K$ with values in $K$ and modulus $\mathfrak n$ whose restriction to $I^{\mathfrak m_i}$ is $\chi_i$ for $i=1,2$; its infinity type is $(a_{1,\sigma})_\sigma$. \end{enumerate} \end{lemma} \begin{proof} Part (1) is the analogue, for algebraic Hecke characters, of the uniqueness theorem for compatible rational representations \cite{locbib:Serre1989}, Ch.~I, \S2.3, Theorem, and rests, as its proof does, on the density of the Frobenius elements of a set of places of density one (loc.\ cit., Ch.~I, \S2.2, Corollary~2(b)). Put $\mathfrak M=\mathfrak m_1\mathfrak m_2$, $c_\sigma=a_{1,\sigma}-a_{2,\sigma}$, and $\xi=\chi_1/\chi_2:I^{\mathfrak M}\to K^\times$. A totally positive $\beta\in K^\times$ with $\beta\equiv1\bmod^\times\mathfrak M$ satisfies $\beta\equiv1\bmod^\times\mathfrak m_i$ for $i=1,2$, so $\xi((\beta))=\prod_\sigma\sigma(\beta)^{c_\sigma}$; and $\xi(\mathfrak P)=1$ for every $\mathfrak P\in\mathcal P$ prime to $\mathfrak M$ outside a finite set $F_0$. Let $P^+_{\mathfrak M}$ be the group of principal ideals with a totally positive generator $\equiv1\bmod^\times\mathfrak M$. By class field theory, $I^{\mathfrak M}/P^+_{\mathfrak M}$ is the Galois group of a finite abelian extension $K_{\mathfrak M}/K$ in which every prime $v\nmid\mathfrak M$ is unramified with Frobenius element corresponding to its class (loc.\ cit., Ch.~II, \S2.1, Remark, and \S2.3). \emph{The infinity types agree.} Let $K'$ be the Galois closure of $K_{\mathfrak M}$ over $\mathbb Q$. By Chebotarev's density theorem (loc.\ cit., Ch.~I, \S2.2) infinitely many rational primes split completely in $K'$; choose one, $p$, with $p\notin S_0$ and such that no prime of $K$ above $p$ divides $\mathfrak M$ or lies in $F_0$. Let $\mathfrak P$ be a prime of $K$ above $p$. Since $p$ splits completely in $K$, $\mathfrak P\in\mathcal P$, and $\operatorname{Gal}(K/\mathbb Q)$ acts simply transitively on the primes of $K$ above $p$. Since $\mathfrak P$ splits completely in $K_{\mathfrak M}$, its Frobenius element is trivial, so $\mathfrak P=(\beta)$ with $\beta$ totally positive and $\beta\equiv1\bmod^\times\mathfrak M$; hence $\prod_\sigma\sigma(\beta)^{c_\sigma}=\xi(\mathfrak P)=1$. For $\sigma_0\in\operatorname{Gal}(K/\mathbb Q)$, the ideal $(\sigma(\beta))=\sigma(\mathfrak P)$ equals $\sigma_0(\mathfrak P)$ only for $\sigma=\sigma_0$, and otherwise is prime to it. Taking the $\sigma_0(\mathfrak P)$-adic valuation, \[ 0=\sum_\sigma c_\sigma\,v_{\sigma_0(\mathfrak P)}\bigl(\sigma(\beta)\bigr)=c_{\sigma_0}. \] \emph{The characters agree.} By the first step $\xi$ is trivial on $P^+_{\mathfrak M}$, so it is a character of the finite group $I^{\mathfrak M}/P^+_{\mathfrak M}=\operatorname{Gal}(K_{\mathfrak M}/K)$, trivial on the Frobenius elements of the primes of $\mathcal P$ prime to $\mathfrak M$ and not in $F_0$. These primes form a set of density one, as $\mathcal P$ has density one (loc.\ cit., p.~I-7), so by loc.\ cit., Ch.~I, \S2.2, Corollary~2(b), their Frobenius elements meet every class. So $\xi=1$, which completes the proof of (1). \emph{Proof of (2).} Every $\mathfrak a\in I^{\mathfrak n}$ factors uniquely as $\mathfrak a=\mathfrak b\mathfrak c$ with $\mathfrak b$ divisible only by primes dividing $\mathfrak r_1$ and $\mathfrak c$ prime to $\mathfrak r_1$. Then $\mathfrak b\in I^{\mathfrak m_2}$, as no prime dividing $\mathfrak r_1$ divides $\mathfrak n\mathfrak r_2$, and $\mathfrak c\in I^{\mathfrak m_1}$. Put $\chi(\mathfrak a)=\chi_2(\mathfrak b)\chi_1(\mathfrak c)$; this is a homomorphism $I^{\mathfrak n}\to K^\times$. On $I^{\mathfrak m_1}$ it equals $\chi_1$, since there $\mathfrak b=(1)$. On $I^{\mathfrak m_2}$ it equals $\chi_2$: for $\mathfrak a\in I^{\mathfrak m_2}$, $\mathfrak c=\mathfrak a\mathfrak b^{-1}$ lies in $I^{\mathfrak m_1}\cap I^{\mathfrak m_2}=I^{\mathfrak M}$, where $\chi_1=\chi_2$ by (1). It is unique, because $I^{\mathfrak n}$ is generated by $I^{\mathfrak m_1}$ and $I^{\mathfrak m_2}$. For the infinity type, let $\alpha\in K^\times$ be totally positive with $\alpha\equiv1\bmod^\times\mathfrak n$. By the approximation theorem \cite{locbib:Neukirch1999}, Ch.~II, (3.4), there is $\gamma\in K^\times$, positive at every real place, with $\gamma\equiv1\bmod^\times\mathfrak n$, $\gamma/\alpha\equiv1\bmod^\times\mathfrak r_1$ and $\gamma\equiv1\bmod^\times\mathfrak r_2$. Then $\alpha/\gamma$ is totally positive with $\alpha/\gamma\equiv1\bmod^\times\mathfrak m_1$, and $\gamma$ is totally positive with $\gamma\equiv1\bmod^\times\mathfrak m_2$, so \[ \chi\bigl((\alpha)\bigr)=\chi_1\bigl((\alpha/\gamma)\bigr)\,\chi_2\bigl((\gamma)\bigr)=\prod_\sigma\sigma(\alpha/\gamma)^{a_\sigma}\prod_\sigma\sigma(\gamma)^{a_\sigma}=\prod_\sigma\sigma(\alpha)^{a_\sigma},\qquad a_\sigma=a_{1,\sigma}=a_{2,\sigma}. \] \end{proof} \begin{lemma}\label{lem:v5_irr_cry_two} \begin{enumerate} \item Let $\ell$ be a prime, $E$ a finite extension of $\mathbb Q_\ell$, and $\xi:\operatorname{Gal}(\bar{\mathbb Q}_\ell/\mathbb Q_\ell)\to E^\times$ a crystalline character with Hodge--Tate weight $h$, $0\leq h\leq\ell-2$, in the normalisation in which $\mathbb Q_\ell(-1)$ has weight $1$. Then $\xi\chi_\ell^{h}$ is unramified, where $\chi_\ell$ is the $\ell$-adic cyclotomic character. \item Let $k\geq3$ be an integer, $T$ a finite set of primes, and, for every prime $\ell$, $V_\ell$ a two-dimensional $\mathbb Q_\ell$-vector space with a continuous action of $G_{\mathbb Q}=\operatorname{Gal}(\bar{\mathbb Q}/\mathbb Q)$. Assume: \begin{description} \item[(a)] for every prime $p\notin T$ and every prime $\ell\neq p$, $V_\ell$ is unramified at $p$, and the characteristic polynomial $Q_p(X)$ of a geometric Frobenius at $p$ on $V_\ell$ lies in $\mathbb Z[X]$, does not depend on $\ell$, and has roots of absolute value $p^{(k-1)/2}$ under every complex embedding; \item[(b)] for every prime $\ell\notin T$ with $\ell>k$, the restriction of $V_\ell$ to a decomposition group at $\ell$ is crystalline with Hodge--Tate weights $0$ and $k-1$, in the normalisation in which $\mathbb Q_\ell(-1)$ has weight $1$. \end{description} Then $V_\ell$ is absolutely irreducible for every prime $\ell\notin T$ with $\ell>k$. \end{enumerate} \end{lemma} \begin{proof} \emph{Proof of (1).} The character $\xi\chi_\ell^{h}$ is crystalline with Hodge--Tate weight $0$. As $0\leq h\leq\ell-2$, the rank-one case of the theory of Fontaine and Laffaille \cite{locbib:FontaineLaffaille1982}, Th\'eor\`eme 8.4, applies: the filtered $\varphi$-module of $\xi\chi_\ell^{h}$ is weakly admissible of rank one with trivial filtration, so its Frobenius is a unit, and the corresponding representation is unramified. \emph{Proof of (2).} Fix a prime $\ell\notin T$ with $\ell>k$, and suppose that $V_\ell\otimes_{\mathbb Q_\ell}\bar{\mathbb Q}_\ell$ is reducible. A $G_{\mathbb Q}$-stable line is spanned by a vector $v$ whose coordinates in a $\mathbb Q_\ell$-basis of $V_\ell$ lie in a finite extension $E$ of $\mathbb Q_\ell$; for $g\in G_{\mathbb Q}$ both $v$ and $gv$ lie in $V_\ell\otimes E$, so $gv\in E^\times v$. Hence there are continuous characters $\chi_1,\chi_2:G_{\mathbb Q}\to E^\times$ and an exact sequence of $E[G_{\mathbb Q}]$-modules \[ 0\to E(\chi_1)\to V_\ell\otimes_{\mathbb Q_\ell}E\to E(\chi_2)\to0 . \] The images of $\chi_1,\chi_2$ are compact, so they lie in $\mathcal O_E^\times$. Let $D\subset G_{\mathbb Q}$ be a decomposition group at $\ell$, identified with $\operatorname{Gal}(\bar{\mathbb Q}_\ell/\mathbb Q_\ell)$. As a $\mathbb Q_\ell[D]$-module, $V_\ell\otimes_{\mathbb Q_\ell}E$ is a direct sum of copies of $V_\ell|_D$, which is crystalline with Hodge--Tate weights $0$ and $k-1$ by (b). Crystalline representations are stable under subquotients, and $D_{\mathrm{HT}}$ is exact on Hodge--Tate representations \cite{locbib:Fontaine1994}, \S1. So each $\chi_i|_D$ is crystalline; its $D_{\mathrm{HT}}$ is a graded $E$-vector space of dimension one, so $\chi_i|_D$ has a single Hodge--Tate weight $h_i$, and $\{h_1,h_2\}=\{0,k-1\}$. As $0\leq h_i\leq k-1\leq\ell-2$, (1) shows that $\chi_i|_D$ is $\chi_\ell^{-h_i}$ times an unramified character. Next, $\epsilon_i=\chi_i\chi_\ell^{h_i}$ has finite order. It is unramified at $\ell$ by the previous step, and at every prime $p\notin T\cup\{\ell\}$, because $V_\ell$ is unramified there by (a) and so is $\chi_\ell$. By the Kronecker--Weber theorem, $\epsilon_i$ therefore factors through $\operatorname{Gal}(\mathbb Q(\mu_{N^\infty})/\mathbb Q)\cong\prod_{q\in T}\mathbb Z_q^\times$, where $N=\prod_{q\in T}q$. Each $\mathbb Z_q^\times$ is a finite group times a pro-$q$ group. The group $\mathcal O_E^\times$ contains an open pro-$\ell$ subgroup $U$, and the preimage of $U$ in a pro-$q$ group $P$ with $q\neq\ell$ is an open subgroup of $P$ mapped to $U$ trivially, a pro-$q$ group having no nontrivial continuous pro-$\ell$ quotient. As $\ell\notin T$, $\epsilon_i$ has finite image. Finally we compare absolute values. Let $p\notin T\cup\{\ell\}$ and let $\mathrm{Frob}_p$ be a geometric Frobenius at $p$. The roots of $Q_p$ are $\chi_1(\mathrm{Frob}_p)$ and $\chi_2(\mathrm{Frob}_p)$, and $\chi_i(\mathrm{Frob}_p)=\epsilon_i(\mathrm{Frob}_p)\,p^{h_i}$ with $\epsilon_i(\mathrm{Frob}_p)$ a root of unity. These roots are algebraic numbers, and under every complex embedding $\chi_i(\mathrm{Frob}_p)$ has absolute value $p^{h_i}$; by (a) this equals $p^{(k-1)/2}$. Hence $h_1=h_2=\frac{k-1}2$, contradicting $\{h_1,h_2\}=\{0,k-1\}$ with $k-1\neq0$. So $V_\ell$ is absolutely irreducible. \end{proof} The modularity argument needs the Serre weight, including the orientation of a reducible residual extension. It uses the lifting theorems at one auxiliary prime: the hypotheses of \cite[Theorem~10.1(i)]{locbib:KhareWintenberger2009a}, which require Weil--Deligne compatibility at every prime, have not been established for our system. \begin{lemma}\label{lem:v5_ser_wei_fon} Let $\ell$ be a prime and $k$ an integer with $3\leq k\leq\ell-1$. Let $V$ be a two-dimensional $\mathbb Q_\ell$-vector space with a continuous action of $G_{\mathbb Q_\ell}=\operatorname{Gal}(\bar{\mathbb Q}_\ell/\mathbb Q_\ell)$, crystalline with Hodge--Tate weights $0$ and $k-1$ in the normalisation in which $\mathbb Q_\ell(-1)$ has weight $1$. Let $T\subset V$ be a $G_{\mathbb Q_\ell}$-stable $\mathbb Z_\ell$-lattice and $\bar W=\operatorname{Hom}_{\mathbb F_\ell}(T/\ell T,\mathbb F_\ell)$. Let $I\subset G_{\mathbb Q_\ell}$ be the inertia subgroup, $\omega$ the mod $\ell$ cyclotomic character and $\omega_2$ a fundamental character of level two. Then $(\bar W\otimes\bar{\mathbb F}_\ell)|_I$ is either $\omega_2^{k-1}\oplus\omega_2^{\ell(k-1)}$ or an extension of the trivial character by $\omega^{k-1}$. Consequently, if $\bar r:G_{\mathbb Q}\to\mathrm{GL}_2(\mathbb F)$, $\mathbb F$ a finite field of characteristic $\ell$, restricts on a decomposition group at $\ell$ to $\bar W\otimes_{\mathbb F_\ell}\mathbb F$, then the weight $k(\bar r)$ of \cite{locbib:Serre1987}, \S2, equals $k$. \end{lemma} \begin{proof} The action of inertia on the reductions of Fontaine--Laffaille lattices is \cite{locbib:FontaineLaffaille1982}, Th\'eor\`eme 5.3. The Hodge--Tate weights of $V$ lie in $[0,k-1]\subset[0,\ell-2]$, so $\operatorname{Fil}^0D_{\mathrm{cris}}(V)=D_{\mathrm{cris}}(V)$ and $\operatorname{Fil}^\ell D_{\mathrm{cris}}(V)=0$, and no nonzero quotient $V'$ of $V$ has $V'(\ell-1)$ unramified, since $V'$ would have Hodge--Tate weight $\ell-1$. By \cite{bib:diamond2025a}, \S1.1 (from \cite{locbib:FontaineLaffaille1982}, 6.1 and 8.4), $T\cong\mathbb V(A)$ for an object $A$ of $\mathcal{MF}^0$, and the filtration of $A$ has jumps $0$ and $k-1$, each of rank one. As $\mathbb V$ is exact, $T/\ell T\cong\mathbb V(N)$ with $N=A/\ell A$, and as $N$ is killed by $\ell$, $\bar W\cong\underline U_S(N)$. Extending scalars from $W(\mathbb F_\ell)$ to $W(\bar{\mathbb F}_\ell)$ restricts the Galois action to $I$ \cite{locbib:FontaineLaffaille1982}, 3.11: $\bar W|_I\cong\underline U_S(\bar N)$ for the object $\bar N=N\otimes\bar{\mathbb F}_\ell$ of the category $\tilde{\mathcal M}$ of loc.\ cit., 4.1, with filtration jumps $0$ and $k-1$. Let $L=\operatorname{Fil}^{k-1}\bar N$, a line, and let $\varphi_{\bar N}:\operatorname{gr}\bar N=\bar N/L\oplus L\to\bar N$ be the bijective semilinear map of loc.\ cit., 4.2. Put $I_0=\varphi_{\bar N}(\bar N/L)$ and $I_1=\varphi_{\bar N}(L)$, lines with $\bar N=I_0\oplus I_1$. By loc.\ cit., Lemme 4.7, a line of $\bar N$ is a sub-object if and only if it is stable under the map $f$ of loc.\ cit., 4.6, which sends $\bar N\setminus L$ into $I_0\setminus\{0\}$ and $L\setminus\{0\}$ into $I_1\setminus\{0\}$. So the sub-objects of rank one are $L$, when $I_1=L$, and $I_0$, when $I_0\neq L$. \begin{itemize} \item If $I_0=L$, then $I_1\neq L$, $\bar N$ has no sub-object of rank one and is simple, and by loc.\ cit., Proposition 4.4, $\bar N\cong M(2;i)$ with $\{i_0,i_1\}=\{0,k-1\}$. By loc.\ cit., Th\'eor\`eme 5.3, applicable as $0\leq i_n\leq\ell-1$, $\underline U_S(\bar N)$ is a line over $\mathbb F_{\ell^2}$ on which $I$ acts through $\chi_2^{i_0+\ell i_1}$, $\chi_2$ the fundamental character of level two (loc.\ cit., 5.1). Over $\bar{\mathbb F}_\ell$ this is $\omega_2^{k-1}\oplus\omega_2^{\ell(k-1)}$. \item If $I_0\neq L$, then $I_0$ is a sub-object with filtration jump $0$, isomorphic to $M(1;0)$, and $\bar N/I_0$ has jump $k-1$ and is isomorphic to $M(1;k-1)$. As $\underline U_S$ is exact and contravariant, $\underline U_S(\bar N)$ is an extension of $\underline U_S(I_0)$ by $\underline U_S(\bar N/I_0)$. By loc.\ cit., Th\'eor\`eme 5.3(iii), $I$ acts trivially on the first and through $\chi_1^{k-1}$ on the second, and $\chi_1=\omega$ on $I$. \end{itemize} Finally we compute Serre's weight, which depends only on the restriction to $I$ \cite{locbib:Serre1987}, \S2. In the first case $\bar r|_I\otimes\bar{\mathbb F}_\ell\cong\omega_2^{a+\ell b}\oplus\omega_2^{b+\ell a}$ with $a=0$, $b=k-1$ and $0\leq ak$ and every prime $\lambda$ above $\ell$ of the coefficient field of $g$, where $\rho_{g,\lambda}$ is the $\lambda$-adic representation attached to $g$, normalised so that a geometric Frobenius at $p\nmid N_g\ell$ has characteristic polynomial $X^2-a_p(g)X+\psi(p)p^{k-1}$. \end{lemma} \begin{proof} For systems that are compatible in the sense of \cite{locbib:KhareWintenberger2009a}, \S5, this is \cite{locbib:KhareWintenberger2009a}, Theorem 10.1(i). We apply instead the two theorems behind it, Serre's modularity conjecture and the modularity lifting theorem of Khare and Wintenberger, at a single auxiliary prime $\ell$, chosen so that two Frobenius elements force the residual hypotheses. We first choose the auxiliary prime $\ell$. There is an odd prime $p_1\notin T$ with $a_{p_1}\neq0$: otherwise, for a fixed prime $\ell_1$, $\operatorname{tr}V_{\ell_1}(\mathrm{Frob}_p)=0$ for all odd primes $p\notin T\cup\{\ell_1\}$, so the continuous function $\operatorname{tr}V_{\ell_1}$ would vanish on a dense subset of $G_{\mathbb Q}$, hence everywhere, while its value at $1$ is $2$. Let $\Delta=a_{p_0}^2-4b_{p_0}\in\mathbb Z$, not a square by (d), and $F=\mathbb Q(\sqrt\Delta,\sqrt{p_1})$. Some element of $\operatorname{Gal}(F/\mathbb Q)$ acts nontrivially on both $\sqrt\Delta$ and $\sqrt{p_1}$: the element $(-1,-1)$ of $\operatorname{Gal}(F/\mathbb Q)\cong(\mathbb Z/2)^2$ if $\mathbb Q(\sqrt\Delta)\neq\mathbb Q(\sqrt{p_1})$, and the nontrivial element otherwise. By Chebotarev's theorem infinitely many primes have this Frobenius in $F$, that is, are inert both in $\mathbb Q(\sqrt\Delta)$ and in $\mathbb Q(\sqrt{p_1})$. Fix such a prime $\ell$ with $\ell\notin T\cup\{2,p_0,p_1\}$, $\ell>k$ and $\ell\nmid\Delta a_{p_1}$. We next show that the residual representation is large. Choose a $G_{\mathbb Q}$-stable $\mathbb Z_\ell$-lattice in $V_\ell$, which exists as $G_{\mathbb Q}$ is compact, let $\rho:G_{\mathbb Q}\to\mathrm{GL}_2(\mathbb Z_\ell)$ be the resulting representation and $\bar\rho:G_{\mathbb Q}\to\mathrm{GL}_2(\mathbb F_\ell)$ its reduction. \begin{itemize} \item $\bar\rho$ is irreducible over $\mathbb F_\ell$. By (a), $\bar\rho(\mathrm{Frob}_{p_0})$ has characteristic polynomial $Q_{p_0}\bmod\ell$, whose discriminant $\Delta$ is a non-square in $\mathbb F_\ell^\times$, as $\ell$ is odd, $\ell\nmid\Delta$ and $\ell$ is inert in $\mathbb Q(\sqrt\Delta)$. So $\bar\rho(\mathrm{Frob}_{p_0})$ has no eigenvalue in $\mathbb F_\ell$, and no $\mathbb F_\ell$-line is stable. \item $\bar\rho$ is absolutely irreducible. Otherwise a stable line $L$ of $\bar\rho\otimes\bar{\mathbb F}_\ell$ is defined over a finite field $\mathbb F\supset\mathbb F_\ell$. Its image $\phi(L)$ under the Frobenius $\phi$ of $\mathbb F/\mathbb F_\ell$ is stable, and $\phi(L)\neq L$, since a $\phi$-stable line has its slope in $\mathbb P^1(\mathbb F_\ell)$ and would be an $\mathbb F_\ell$-line. So $\bar\rho\otimes\mathbb F=L\oplus\phi(L)$, with $G_{\mathbb Q}$ acting by characters $\theta$ and $\phi\circ\theta$. As $c^2=1$, $\theta(c)=\pm1\in\mathbb F_\ell$, so $\phi(\theta(c))=\theta(c)$ and $\det\bar\rho(c)=\theta(c)^2=1$, whereas $\det\bar\rho(c)=-1$ by (c), and $-1\neq1$ in $\mathbb F_\ell$. \item $\bar\rho|_{G_{\mathbb Q(\zeta_\ell)}}$ is absolutely irreducible. Suppose not, and put $H=G_{\mathbb Q(\zeta_\ell)}$, a normal subgroup with cyclic quotient. By Clifford's theorem $(\bar\rho\otimes\bar{\mathbb F}_\ell)|_H$ is semisimple, hence a sum of two characters $\theta_1,\theta_2$ of $H$. If $\theta_1=\theta_2$, then $\bar\rho(H)$ consists of scalars, $\bar\rho(G_{\mathbb Q})$ is generated by scalars and one element, so it is abelian and $\bar\rho\otimes\bar{\mathbb F}_\ell$ is reducible, which is excluded. So $\theta_1\neq\theta_2$, $G_{\mathbb Q}$ permutes the two isotypic lines, and the stabiliser $G'$ of one of them has index $2$ and contains $H$; every $g\notin G'$ exchanges the lines, so $\operatorname{tr}\bar\rho(g)=0$. Now $G'=G_{\mathbb Q(\sqrt{\ell^*})}$, $\ell^*=(-1)^{(\ell-1)/2}\ell$, the quadratic subfield of $\mathbb Q(\zeta_\ell)$. By quadratic reciprocity $\bigl(\frac{\ell^*}{p_1}\bigr)=\bigl(\frac{p_1}\ell\bigr)=-1$, the last because $\ell$ is inert in $\mathbb Q(\sqrt{p_1})$; so $p_1$ is inert in $\mathbb Q(\sqrt{\ell^*})$, $\mathrm{Frob}_{p_1}\notin G'$, and $a_{p_1}\equiv\operatorname{tr}\bar\rho(\mathrm{Frob}_{p_1})=0\pmod\ell$, contradicting $\ell\nmid a_{p_1}$. \end{itemize} We next show that $V_\ell$ is modular. Put $W=\rho^\vee$, a lift of $\bar\rho^\vee$; by the previous step $\bar\rho^\vee$ is odd, absolutely irreducible, and absolutely irreducible on $G_{\mathbb Q(\zeta_\ell)}$, these properties passing to the dual. By Serre's modularity conjecture, proved by Khare and Wintenberger \cite{locbib:KhareWintenberger2009a}, Theorem 9.1, together with Kisin's proof of their Hypothesis (H) \cite{locbib:Kisin2009BT}, Theorem 0.1, $\bar\rho^\vee$ arises from a newform. By (a), $W$ is unramified outside $T\cup\{\ell\}$, and $b_p=\pm p^{k-1}$ (an integer of absolute value $p^{k-1}$), so $\det V_\ell\cdot\chi_\ell^{k-1}$ takes the values $\pm1$ at all $\mathrm{Frob}_p$, $p\notin T\cup\{\ell\}$, and is a character of order at most two; thus $\det W$ is a finite-order character times $\chi_\ell^{k-1}$. By (b), $W$ is crystalline at $\ell$, duals of crystalline representations being crystalline \cite{locbib:Fontaine1994}, \S1, with Hodge--Tate weights $0$ and $k-1$ in the normalisation in which $\chi_\ell$ has weight $1$. So $W\otimes\mathbb C_\ell\cong\mathbb C_\ell\oplus\mathbb C_\ell(k-1)$, that is, $W$ is crystalline of weight $k$ in the sense of \cite{locbib:KhareWintenberger2009a}, \S4, and \cite{locbib:KhareWintenberger2009b}, Definition 3.4, with $2\leq k\leq\ell+1$. By Lemma~\ref{lem:v5_ser_wei_fon}, applied to $V_\ell$ restricted to a decomposition group at $\ell$ and to the lattice of $\rho$, the Serre weight of $\bar\rho^\vee$ is $k$; so $\bar\rho^\vee$ lies in the setting of \cite{locbib:KhareWintenberger2009b}, \S1, and of the paragraph preceding \cite{locbib:KhareWintenberger2009a}, Theorem 4.1 (Serre weight in $[2,\ell+1]$), in which \cite{locbib:KhareWintenberger2009a}, Theorem 4.1, is proved. By \cite{locbib:KhareWintenberger2009a}, Theorem 4.1(2)(i), proved in \cite{locbib:KhareWintenberger2009b}, $W$ arises from a newform. For $k\leq\ell-1$, the case used here, this lifting theorem is due to Diamond, Flach and Guo \cite{bib:diamond2025a}, the theorem of the subsection ``Consequences'' of the section on the Taylor--Wiles construction (see \cite{locbib:KhareWintenberger2009b}, \S10.2). Hence there are a newform $f$ and a prime $\lambda$ of $K_f$ above $\ell$ such that $V_\ell\otimes\bar{\mathbb Q}_\ell$ is isomorphic to $\rho_{f,\lambda}\otimes\bar{\mathbb Q}_\ell$ or to its contragredient. Let $p\notin T\cup\{\ell\}$ with $p\nmid N_f$. The geometric Frobenius at $p$ has determinant $b_p$ on $V_\ell$, of absolute value $p^{k-1}$ by (a), and determinant $\psi_f(p)^{\pm1}p^{\pm(k_f-1)}$ on $\rho_{f,\lambda}$, respectively on its contragredient. As $k\geq3$ and $k_f\geq2$, only $V_\ell\otimes\bar{\mathbb Q}_\ell\cong\rho_{f,\lambda}\otimes\bar{\mathbb Q}_\ell$ is possible, and $k_f=k$. Comparing characteristic polynomials, $a_p(f)=a_p$ and $\psi_f(p)p^{k-1}=b_p$ for all such $p$, the identities holding in $K_f$ because the embedding $K_f\to\bar{\mathbb Q}_\ell$ is injective and $a_p,b_p\in\mathbb Z$. We next compare $f$ with the whole system. Let $\ell'\notin T$ be a prime with $\ell'>k$ and $\lambda'$ a prime of $K_f$ above $\ell'$. For every prime $p\notin T\cup\{\ell,\ell'\}$ with $p\nmid N_f$, both $V_{\ell'}$ and $\rho_{f,\lambda'}$ are unramified at $p$, and a geometric Frobenius has characteristic polynomial $Q_p$ on both, by (a) and the previous step. These Frobenius elements are dense in $G_{\mathbb Q}$ and characteristic polynomials vary continuously, so $V_{\ell'}\otimes\bar{\mathbb Q}_{\ell'}$ and $\rho_{f,\lambda'}\otimes\bar{\mathbb Q}_{\ell'}$ have the same characteristic polynomial at every element of $G_{\mathbb Q}$, and by the Brauer--Nesbitt theorem isomorphic semisimplifications. As $V_{\ell'}$ is absolutely irreducible by Lemma~\ref{lem:v5_irr_cry_two}(2), so is $\rho_{f,\lambda'}$, and $V_{\ell'}\otimes\bar{\mathbb Q}_{\ell'}\cong\rho_{f,\lambda'}\otimes\bar{\mathbb Q}_{\ell'}$. It remains to determine the level. Let $p\notin T$ and choose a prime $\ell'\notin T\cup\{p\}$ with $\ell'>k$. By (a), $V_{\ell'}$ is unramified at $p$, hence so is $\rho_{f,\lambda'}$. By local--global compatibility at $p\neq\ell'$ \cite{locbib:Carayol1986}, Th\'eor\`eme (A), the component at $p$ of the automorphic representation of $f$ is then unramified, so $p\nmid N_f$. Therefore $N_f$ is divisible only by primes in $T$, and for every $p\notin T$ \[ Q_p(X)=\det\bigl(X-\mathrm{Frob}_p\mid\rho_{f,\lambda'}\bigr)=X^2-a_p(f)X+\psi_f(p)p^{k-1}. \] The lemma holds with $g=f$ and $\psi=\psi_f$. \end{proof} \section{A level-seven supercongruence} \label{sec:first_depth} The trace in Corollary~\ref{cor:v5_asd_con_c7} is identified by comparing $c_7(p)$ with Cooper's sequence at $(p-1)/2$, and then with the Ap\'ery number at the same index. We first state the two congruences together. Their proofs use the modular parametrisation of Section~\ref{sec:level_seven} and the classical Ap\'ery supercongruence of Ahlgren and Ono \cite{locbib:AhlgrenOno2000}. \begin{thm}\label{thm:v5_mat_fir_dep} For every odd prime $p$, \[ c_7(p)\equiv s_7\!\left(\frac{p-1}{2}\right)\equiv A_p^{\eta}\pmod{p^2}. \] \end{thm} \begin{proof} Put $h=(p-1)/2$. By Lemma~\ref{lem:v5_inv_coo_for}, the first congruence amounts to $d_h\equiv0\pmod p$. By Lemma~\ref{lem:v5_har_for_for}, $d_h$ is the harmonic Cooper sum $e_h$ of Definition~\ref{def:v5_coo_rec_dfm}, and we show that every summand of $e_h$ vanishes modulo $p$, by the symmetry $m\mapsto p-1-m$ of the harmonic numbers. For $0\leq m\leq p-1$, the harmonic numbers in Definition~\ref{def:v5_log_coo_com} are $p$-integral and satisfy \[ \mathfrak h_{p-1-m}\equiv\mathfrak h_m\pmod p. \] Indeed, pairing $j$ with $p-j$ proves $\mathfrak h_{p-1}\equiv0\pmod p$, and subtracting the last $m$ terms gives the displayed congruence. For each $0\leq k\leq h$, the equalities $h+k=p-1-(h-k)$ and $2h-k=p-1-k$ therefore yield \[ \mathfrak h_{h+k}+\mathfrak h_{2h-k}-\mathfrak h_k-\mathfrak h_{h-k} \equiv0\pmod p. \] All factorial arguments in the coefficient \[ \frac{(h+k)!(2h-k)!}{k!^3(h-k)!^3} \] are between $0$ and $p-1$, so this coefficient is $p$-integral. The factor $3/2$ is also $p$-integral, including at $p=3$. Hence $e_h\in p\mathbb Z_p$ term by term, and $d_h=e_h\in p\mathbb Z_p$. Applying Lemma~\ref{lem:v5_inv_coo_for} gives \[ c_7(p)-s_7(h)\equiv-\frac p2d_h\equiv0\pmod{p^2}. \] The second congruence $s_7(h)\equiv A_p^{\eta}\pmod{p^2}$ is Proposition~\ref{prop:v5_coo_hal_ind}. \end{proof} \begin{definition}\label{def:v5_log_coo_com} In the notation of Definition~\ref{def:v5_coo_lev_sev}, let $G(Y)=(1+Y)(1-27Y)$, use the formal branch $\sqrt{G(Y)}\in1+Y\mathbb Q[[Y]]$ and define \[ \rho(Y)=\frac{1}{F(Y)\sqrt{G(Y)}},\qquad \ell(Y)=\int_0^Y\frac{\rho(T)-1}{T}\,dT,\qquad \mathcal H(Y)=F(Y)\ell(Y)=\sum_{n\geq0}d_nY^n. \] The integral denotes termwise formal integration, with zero constant term. The series $\mathcal H$ is the \textbf{logarithmic Cooper companion}. The \textbf{harmonic numbers} are $\mathfrak h_0=0$ and $\mathfrak h_m=\sum_{j=1}^m1/j$ for integers $m\geq1$. \end{definition} \begin{definition}\label{def:v5_coo_ope} With $\theta=Y\,d/dY$, the \textbf{Cooper operators} are \[ \mathcal L=\theta^3-Y(2\theta+1)(13\theta^2+13\theta+4)-3Y^2(\theta+1)(3\theta+2)(3\theta+4), \] \[ \mathcal D=(1+Y)(1-27Y)\,\theta^2-(13Y+27Y^2)\,\theta-(2Y+6Y^2), \] acting on $\mathbb Q[[Y]]$ and on holomorphic functions on open subsets of $\mathbb C^\times$. Up to the factor $Y$ they are Cooper's: $\mathcal D/Y$ and $\mathcal L/Y$ are the second- and third-order operators of \cite[p.~176]{locbib:Cooper2012}. \end{definition} \begin{definition}\label{def:v5_coo_rec_dfm} The \textbf{Cooper recurrence polynomials} are \[ A(v)=(2v-1)(13v^2-13v+4),\qquad B(v)=3(v-1)\bigl(9(v-1)^2-1\bigr), \] with derivatives $A'$, $B'$, so that the recurrence of Definition~\ref{def:v5_coo_lev_sev} reads $n^3s_7(n)=A(n)s_7(n-1)+B(n)s_7(n-2)$ for $n\geq1$. A sequence $(u_n)_{n\geq0}$ satisfies the \textbf{deformed Cooper recurrence} if $u_0=0$, $u_1=9$ and \[ n^3u_n-A(n)u_{n-1}-B(n)u_{n-2}=-3n^2s_7(n)+A'(n)s_7(n-1)+B'(n)s_7(n-2)\qquad(n\geq2). \] For integers $0\leq k\leq n$ put \[ T(n,k)=\frac{(n+k)!\,(2n-k)!}{k!^3\,(n-k)!^3}. \] With the harmonic numbers $\mathfrak h_m$ of Definition~\ref{def:v5_log_coo_com}, the \textbf{harmonic Cooper sums} are, for $n\geq0$, \[ e_n=\frac32\sum_{k=0}^nT(n,k)\bigl(\mathfrak h_{n+k}+\mathfrak h_{2n-k}-\mathfrak h_k-\mathfrak h_{n-k}\bigr). \] \end{definition} \begin{lemma}\label{lem:v5_zei_cer_for} Put \[ \mathcal T(v,u)=\frac{\Gamma(v+u+1)\Gamma(2v-u+1)}{\Gamma(u+1)^3\Gamma(v-u+1)^3},\qquad Z(v,u)=\frac{P(v,u)\Gamma(v+u-1)\Gamma(2v-u-2)}{\Gamma(u)^3\Gamma(v-u+1)^3}, \] where \[ \begin{aligned} P(v,u)={}&(42v^2-57v+20)u^3+(-175v^3+300v^2-165v+28)u^2\\ &+v(244v^3-488v^2+321v-70)u-v^2(v-1)(115v^2-144v+46). \end{aligned} \] Then $\mathcal T(n,k)=T(n,k)$ for integers $0\leq k\leq n$, and, as meromorphic functions of $(v,u)\in\mathbb C^2$, \[ v^3\mathcal T(v,u)-A(v)\mathcal T(v-1,u)-B(v)\mathcal T(v-2,u)=Z(v,u+1)-Z(v,u). \] Consequently, for every integer $n\geq0$ and as meromorphic functions of $(v,x)$, \[ \sum_{k=0}^n\Bigl(v^3\mathcal T(v,x+k)-A(v)\mathcal T(v-1,x+k)-B(v)\mathcal T(v-2,x+k)\Bigr)=Z(v,x+n+1)-Z(v,x). \] \end{lemma} \begin{proof} For integers $0\leq k\leq n$ all four gamma arguments are positive integers, and $\Gamma(m+1)=m!$ gives $\mathcal T(n,k)=T(n,k)$. For the certificate identity, set \[ D=(v+u)(v+u-1)(2v-u)(2v-u-1)(2v-u-2)(2v-u-3). \] Apply $\Gamma(z+1)=z\Gamma(z)$ to write each of the five terms as a polynomial in $v,u$ times $\beta=\Gamma(v+u-1)\Gamma(2v-u-3)/\bigl(\Gamma(u+1)^3\Gamma(v-u+1)^3\bigr)=\mathcal T(v,u)/D$, and divide by $\beta$. The identity becomes the polynomial equality \[ \begin{aligned} &(v-u)^3(v+u-1)P(v,u+1)-u^3(2v-u-3)P(v,u)\\ &\quad=v^3D-A(v)(v-u)^3(v+u-1)(2v-u-2)(2v-u-3)\\ &\qquad\quad-B(v)\bigl((v-u)(v-u-1)\bigr)^3, \end{aligned} \] which holds by expansion. Both sides of the original identity are meromorphic on $\mathbb C^2$ and agree on the open set where the division is legitimate, so they agree identically. Finally, substitute $u=x+k$ for $k=0,\dots,n$ and sum; the right-hand side telescopes to $Z(v,x+n+1)-Z(v,x)$. \end{proof} \begin{lemma}\label{lem:v5_cre_tel_har} The harmonic Cooper sums $(e_n)_{n\geq0}$ satisfy the deformed Cooper recurrence. \end{lemma} \begin{proof} The proof is by creative telescoping. We deform the Cooper summand by a continuous parameter $r$. The certificate of Lemma~\ref{lem:v5_zei_cer_for} shows that the deformed sums satisfy the Cooper recurrence up to $O(r^2)$, and differentiating at $r=0$ produces the harmonic sums together with the stated inhomogeneity. We use the notation $\mathcal T$, $Z$ of Lemma~\ref{lem:v5_zei_cer_for}. \emph{The deformed sums.} For $n\geq0$ define, analytically near $r=0$, \[ a_n(r)=\sum_{k=0}^n\mathcal T(n+r,k+r/2). \] By Lemma~\ref{lem:v5_zei_cer_for} and Lemma~\ref{lem:v5_cla_con_for}, $a_n(0)=\sum_kT(n,k)=\sum_kL_{n,k}L_{n,n-k}=s_7(n)$. Logarithmic differentiation of the gamma factors, using $\psi(m+1)=\mathfrak h_m-\gamma$, gives $a_n'(0)=e_n$; the Euler constants cancel. In particular $e_0=0$ and $e_1=9$. \emph{Telescoping.} For $n\geq2$, apply the telescoped identity of Lemma~\ref{lem:v5_zei_cer_for} with $v=n+r$ and $x=r/2$. The boundary terms are $O(r^2)$. Indeed, $Z(n+r,r/2)=O(r^3)$ because $1/\Gamma(r/2)^3=O(r^3)$ and both numerator gamma factors are regular. At the upper boundary, $Z(n+r,n+1+r/2)$ also contains $1/\Gamma(r/2)^3$; its only possibly singular numerator factor is $\Gamma(n-3+3r/2)$, with at most a simple pole. Hence this boundary is $O(r^2)$, including $n=2,3$. The sum of $\mathcal T(n-1+r,k+r/2)$ differs from $a_{n-1}(r)$ only by its term $k=n$, and that of $\mathcal T(n-2+r,k+r/2)$ differs from $a_{n-2}(r)$ only by its terms $k=n-1,n$. Every such extra term is $O(r^2)$: the inverse cube of a gamma function at a nonpositive integer supplies a zero of order three, while at most one numerator gamma factor has a simple pole. Consequently \[ (n+r)^3a_n(r)-A(n+r)a_{n-1}(r)-B(n+r)a_{n-2}(r)=O(r^2). \] Differentiating at $r=0$ and substituting $a_m(0)=s_7(m)$, $a_m'(0)=e_m$ gives the assertion. \end{proof} \begin{lemma}\label{lem:v5_coo_ope_prd} \begin{enumerate} \item $\mathcal LF=0$. \item If $u,v$ are analytic solutions of $\mathcal Du=\mathcal Dv=0$ on a connected open subset of $\mathbb C\setminus\{0,-1,\frac1{27}\}$, then $\mathcal L(uv)=0$ there. \item $\mathcal D$ has a unique solution $\phi\in1+Y\mathbb Q[[Y]]$, and $\phi^2=F$. \end{enumerate} \end{lemma} \begin{proof} Item (1) is the recurrence of the Cooper numbers in operator form; (2) and (3) apply the classical formula for the square of a solution of a second-order equation. \emph{Proof of (1).} Extracting the coefficient of $Y^n$ in $\mathcal LF$ gives \[ n^3s_7(n)-(2n-1)(13n^2-13n+4)s_7(n-1)-3(n-1)(3n-4)(3n-2)s_7(n-2)=0. \] For $n\geq2$ this is the defining recurrence shifted by one, and for $n=1$ it is the recurrence at index $0$, that is, $s_7(1)=4s_7(0)$; the equation at $n=0$ follows from the initial values. \emph{Proof of (2).} Put $G=(1+Y)(1-27Y)$. In ordinary derivative form, $\mathcal Du=0$ is $u''+au'+bu=0$ with \[ a=\frac1Y+\frac{G'}{2G},\qquad b=-\frac{2(1+3Y)}{YG}. \] By \cite[Lemma 6.1]{locbib:Cooper2012}, p.~175, the square of a solution satisfies \[ g'''+3ag''+(a'+4b+2a^2)g'+(2b'+4ab)g=0, \] and substitution of $a,b$ identifies this operator with $\mathcal L/(Y^3G)$; note that the coefficient of $\theta^3$ in $\mathcal L$ is $G$. As $uv=\frac14\bigl((u+v)^2-(u-v)^2\bigr)$ and $\mathcal L$ is linear, $\mathcal L(uv)=0$. \emph{Proof of (3).} The formula for the square used in (2) is a differential-algebraic identity, valid for formal solutions in $\mathbb Q[[Y]]$, with $a,b\in\mathbb Q((Y))$. At $Y=0$ both $\mathcal D$ and $\mathcal L$ have indicial polynomial a power of $\theta$, so their coefficient recurrences have leading coefficients $n^2$ and $n^3$, respectively. Hence each has a unique power-series solution with constant term $1$; denote that of $\mathcal D$ by $\phi$. Then $\phi^2\in1+Y\mathbb Q[[Y]]$ solves $\mathcal L$, and by (1) and uniqueness $\phi^2=F$. \end{proof} \begin{lemma}\label{lem:v5_red_ord_the} The coefficients $(d_n)_{n\geq0}$ of the logarithmic Cooper companion satisfy the deformed Cooper recurrence. \end{lemma} \begin{proof} The series $F\log Y+\mathcal H$ is the product of the two Frobenius solutions of $\mathcal D$, hence a logarithmic solution of $\mathcal L$, and the recurrence is the coefficient form of this fact. \emph{The logarithmic solution.} Let $\phi$ be as in Lemma~\ref{lem:v5_coo_ope_prd}(3), so $\phi^2=F$; all series below converge near $Y=0$. In ordinary derivative form the coefficient of $\phi'$ in $\mathcal D$ is $a=1/Y+G'/(2G)$, so $\exp(-\int a)=1/(Y\sqrt G)$. Reduction of order gives the second solution \[ \phi_1=\phi\bigl(\log Y+\ell(Y)\bigr),\qquad\text{since}\qquad \frac{d}{dY}\bigl(\log Y+\ell(Y)\bigr)=\frac{\rho(Y)}{Y}=\frac{1}{Y\,\phi^2\sqrt{G}}, \] on a slit neighbourhood of $0$. By Lemma~\ref{lem:v5_coo_ope_prd}(2), $\phi\phi_1=F\log Y+\mathcal H$ solves $\mathcal L$. \emph{The coefficient form.} Write $\mathcal L=\theta^3-YP_1(\theta)-Y^2P_2(\theta)$ with $P_1(\theta)=(2\theta+1)(13\theta^2+13\theta+4)$ and $P_2(\theta)=3(\theta+1)(3\theta+2)(3\theta+4)$, so $P_1(n-1)=A(n)$ and $P_2(n-2)=B(n)$. Since $\theta^j(g\log Y)=(\theta^jg)\log Y+j\theta^{j-1}g$, one has $\mathcal L(F\log Y)=(\mathcal LF)\log Y+(\partial_\theta\mathcal L)F$, where $\partial_\theta\mathcal L$ is the formal $\theta$-derivative of $\mathcal L$. As $\mathcal LF=0$ (Lemma~\ref{lem:v5_coo_ope_prd}(1)) and $\mathcal L(F\log Y+\mathcal H)=0$, \[ \mathcal L\mathcal H=-(\partial_\theta\mathcal L)F. \] Taking the coefficient of $Y^n$, with $d_m=s_7(m)=0$ for $m<0$, gives the relation of the deformed Cooper recurrence for every $n\geq0$, in particular for $n\geq2$, since $\partial_\theta P_1(\theta)|_{\theta=n-1}=A'(n)$ and $\partial_\theta P_2(\theta)|_{\theta=n-2}=B'(n)$. \emph{Initial values.} $d_0=0$ because $\ell$ has zero constant term. Since $F=1+4Y+O(Y^2)$ and $\sqrt G=1-13Y+O(Y^2)$, $\rho=1+9Y+O(Y^2)$, so $[Y]\ell=9$ and $d_1=9$. \end{proof} \begin{lemma}\label{lem:v5_har_for_for} For every integer $n\geq0$, $d_n=e_n$. \end{lemma} \begin{proof} By Lemma~\ref{lem:v5_cre_tel_har} and Lemma~\ref{lem:v5_red_ord_the}, both $(e_n)$ and $(d_n)$ satisfy the deformed Cooper recurrence, so $e_0=d_0=0$ and $e_1=d_1=9$. Since $n^3\neq0$, the relation of that recurrence determines its $n$-th term from the two preceding ones for $n\geq2$. Induction on $n$ gives $d_n=e_n$ for all $n\geq0$. \end{proof} \begin{lemma}\label{lem:v5_inv_coo_for} For every integer $n\geq0$, \[ c_7(2n+1)=[Y^n]F(Y)\exp\!\left(-\frac{2n+1}{2}\ell(Y)\right). \] For every odd prime $p$ this implies \[ c_7(p)-s_7\!\left(\frac{p-1}{2}\right) \equiv-\frac p2\,d_{(p-1)/2}\pmod{p^2}. \] \end{lemma} \begin{proof} \emph{The exact formula.} Cooper's identity $z=F(y)$ \cite[Theorem 3.1]{locbib:Cooper2012}, the identity $q\frac{d}{dq}\log y=zw$ of Lemma~\ref{lem:v5_ell_dat_and}(4) and the conic identity $w^2=G(y)$ of Proposition~\ref{prop:v5_lev_sev_squ} give \[ q\frac{d\log y(q)}{dq}=F(y(q))\sqrt{G(y(q))}. \] Both square roots have constant term one. Let $q=\psi(Y)$ be the compositional inverse of $y(q)=q+O(q^2)$. Formal differentiation gives \[ Y\frac{d\log\psi(Y)}{dY}=\rho(Y),\qquad \psi(Y)=Y\exp(\ell(Y)). \] Thus the inverse of $t=s(Q)$ is \[ Q(t)=t\exp\!\left(\frac12\ell(t^2)\right). \] For $m=2n+1$, invariance of the formal residue under this unit-leading change of variable and the defining differential identity give \[ \begin{aligned} c_7(m) &=\operatorname{Res}_{Q=0}C(Q)Q^{-m}\frac{dQ}{Q}\\ &=\operatorname{Res}_{t=0}F(t^2)Q(t)^{-m}\,dt\\ &=[t^{m-1}]F(t^2)\exp\!\left(-\frac m2\ell(t^2)\right)\\ &=[Y^n]F(Y)\exp\!\left(-\frac m2\ell(Y)\right). \end{aligned} \] This proves the exact formula. \emph{The congruence.} Fix an odd prime $p$ and put $h=(p-1)/2$. The integrality of $s_7(n)$ is Lemma~\ref{lem:v5_cla_con_for}; $\sqrt G$ and its inverse are integral at every odd prime by recursive coefficient comparison. Hence $\rho\in\mathbb Z_p[[Y]]$. For $1\leq j\leq h$, the coefficient $[Y^j]\ell=([Y^j]\rho)/j$ is $p$-integral. Since $h