% Ceci est la version finale de l'article intitule
% Diagonal cycles and Euler systems I:   A p-adic Gross-Zagier formula.
% 23 Avril, 2013.

\documentclass[a4paper,11pt]{amsart}

\newfont{\cyr}{wncyr10 scaled 1100}

\usepackage[left=2.7cm,right=2.7cm,top=3.5cm,bottom=3cm]{geometry}
\usepackage{amsthm,amssymb,amsmath,amsfonts,mathrsfs,amscd}
\usepackage[latin1]{inputenc}
\usepackage[all]{xy}
\usepackage{latexsym}
\usepackage{longtable}

\theoremstyle{plain}
\newtheorem{theorem}{Theorem}[section]
\newtheorem{corollary}[theorem]{Corollary}
\newtheorem{lemma}[theorem]{Lemma}
\newtheorem{proposition}[theorem]{Proposition}
\newtheorem{conjecture}[theorem]{Conjecture}

\theoremstyle{definition}
\newtheorem{definition}[theorem]{Definition}
\newtheorem{question}[theorem]{Question}
\newtheorem{examplewr}[theorem]{Example}
\newtheorem{ass}[theorem]{Assumption}
\newtheorem{app}[theorem]{Application}

\theoremstyle{remark}
\newtheorem{obswr}[theorem]{Observation}
\newtheorem{remarkwr}[theorem]{Remark}

\newenvironment{obs}{\begin{obswr}\begin{upshape}}{\end{upshape}\end{obswr}}
\newenvironment{remark}{\begin{remarkwr}\begin{upshape}}{\end{upshape}\end{remarkwr}}
\newenvironment{example}{\begin{examplewr}\begin{upshape}}{\end{upshape}\end{examplewr}}

\DeclareMathOperator{\fil}{fil}
\DeclareMathOperator{\fr}{fr}

\DeclareMathOperator{\an}{an}
\DeclareMathOperator{\nh}{nh}
\DeclareMathOperator{\cusps}{cusps}
\DeclareMathOperator{\ffm}{ffm}
\DeclareMathOperator{\ppar}{par}


\DeclareMathOperator{\lcm}{lcm}
\DeclareMathOperator{\dR}{dR}
\DeclareMathOperator{\fp}{fp}
\DeclareMathOperator{\cris}{cris}
\DeclareMathOperator{\Frac}{Frac}
\DeclareMathOperator{\et}{et}
\DeclareMathOperator{\syn}{syn}
\DeclareMathOperator{\oc}{oc}
\DeclareMathOperator{\ur}{u-r}
\DeclareMathOperator{\ah}{a-h}
\DeclareMathOperator{\para}{par}

\DeclareMathOperator{\cts}{cts}
\DeclareMathOperator{\bal}{bal}
\DeclareMathOperator{\KS}{KS}
\DeclareMathOperator{\sym}{\mathrm{sym}}
\DeclareMathOperator{\Sym}{Sym}
\DeclareMathOperator{\sgn}{sgn}
\DeclareMathOperator{\spec}{Spec}
\DeclareMathOperator{\la}{la} 

\newcommand{\uomega}{{\underline{\omega}}}
\newcommand{\cZ}{{\mathcal Z}}
\newcommand{\hf}{{\mathbf{f}}}
\newcommand{\hg}{{\mathbf{g}}}
\newcommand{\hh}{{\mathbf {h}}}
% For below, try \breve, \check, \dot, \hat, \mathring, \ddot
\newcommand{\testf}{\breve{f}}
\newcommand{\testg}{\breve{g}} 
\newcommand{\testh}{\breve{h}}
\newcommand{\testG}{\breve{G}}
\newcommand{\testH}{\breve{H}}
\newcommand{\htf}{\breve{\mathbf{f}}}
\newcommand{\htg}{\breve{\mathbf{g}}}
\newcommand{\hth}{\breve{\mathbf {h}}}
\newcommand{\uS}{{\mathbf{S}}}
\newcommand{\hphi}{\boldsymbol{\phi}}
\newcommand{\uhp}{{\mathfrak{H}}}
\newcommand{\PPhi}{{\underline{\phi}}}
\newcommand{\ff}{{\mathbf{f}}}
\newcommand{\aaa}{{\mathbf{a}}}
\newcommand{\LL}{{\mathscr{L}}}
\newcommand{\Lp}{{\mathscr{L}_p}}
\newcommand{\rhop}{\rho(P,\omega_2,\omega_3)}
\newcommand{\ukappa}{\underline{\kappa}}
\newcommand{\uV}{{\bf V}}

\newcommand{\hB}{{\mathbf B}}
\newcommand{\St}{{\mathrm{St}}}
\newcommand{\cl}{{\mathrm{cl}}}
\DeclareMathOperator{\red}{red}

\newcommand{\cA}{\mathcal A}
\newcommand{\cN}{\mathcal N}
\newcommand{\cW}{\mathcal W}
\newcommand{\cV}{\mathcal V}
\newcommand{\cF}{\mathcal F}
\newcommand{\cX}{\mathcal X}
\newcommand{\cH}{\mathcal H}
\newcommand{\cC}{\mathcal C}
\newcommand{\V}{\mathcal V}
\newcommand{\E}{\mathcal E}
\newcommand{\cE}{\mathcal E}
\newcommand{\g}{\gamma}
% \newcommand{\G}{\Gamma}
\newcommand{\Gap}{\Gamma_0^D(p M)}
\newcommand{\Ga}{\Gamma_0^D(M)}
\newcommand{\hGa}{\hat{\Gamma }_0(M)}
\newcommand{\Q}{\mathbb{Q}}
\newcommand{\A}{\mathbb{A}}
\newcommand{\Z}{\mathbb{Z}}
\newcommand{\G}{\mathbb{G}}
\newcommand{\F}{\mathbb{F}}
\newcommand{\K}{\mathbb{K}}
\newcommand{\C}{\mathbb{C}}
\newcommand{\I}{\mathbb{I}}
\newcommand{\Ql}{\Q_{\ell}}
\newcommand{\GQ}{G_{\Q}}
\newcommand{\PP}{\mathbb{P}}
\newcommand{\Sel}{\mathrm{Sel}}
\newcommand{\Sha}{\mathrm{Sha}}
\newcommand{\Gal}{\mathrm{Gal\,}}
\newcommand{\GL}{\mathrm{GL}}
\newcommand{\Cl}{\mathrm{Cl}}
\newcommand{\Tr}{\mathrm{Tr}}
\newcommand{\Div}{\mathrm{Div}}
\newcommand{\Fil}{\mathrm{Fil}}
\newcommand{\cond}{\mathrm{cond}}
\newcommand{\Frob}{\mathrm{Frob}}
\newcommand{\End}{\mathrm{End}}
\newcommand{\Jac}{\mathrm{Jac}}
\newcommand{\disc}{\mathrm{disc}}
\newcommand{\Id}{\mathrm{Id}}
\newcommand{\MS}{\mathrm{MS}}
\newcommand{\Aut}{\mathrm{Aut}}
\newcommand{\Fr}{\mathrm{Fr}}
\newcommand{\diag}{\mathrm{diag}}
\newcommand{\Up}{\mathrm{U}_p}
\newcommand{\ord}{{\mathrm{ord}}}
\newfont{\gotip}{eufb10 at 12pt}
\newcommand{\gn}{\mbox{\gotip n}}
\newcommand{\gm}{\mbox{\gotip m}}
\newcommand{\ga}{\mbox{\gotip a}}
\newcommand{\gb}{\mbox{\gotip b}}
\newcommand{\gf}{\mbox{\gotip f}}
\newcommand{\go}{{\mathcal O}_{A_f}}
\newcommand{\OAf}{{\mathcal O}_{A_f}}
\newcommand{\gp}{\mbox{\gotip p}}
\newcommand{\gL}{\mbox{\gotip L}}
\newcommand{\gd}{\mbox{\gotip d}}
\newcommand{\cO}{{\mathcal O}}
\newcommand{\cM}{{\mathcal M}}
\newcommand{\cP}{{\mathcal P}}
\newcommand{\cL}{{\mathcal L}}
\newcommand{\cG}{{\mathcal G}}
\newcommand{\GG}{{\mathcal G}}
\newcommand{\cD}{{\mathcal D}}
\newcommand{\ra}{\rightarrow}
\newcommand{\lra}{\longrightarrow}
\newcommand{\hra}{\hookrightarrow}
\newcommand{\qbar}{\bar\Q}
\newcommand{\Norm}{\mathrm{N}}
\newcommand{\NS}{\mathrm{NS}}
\newcommand{\SL}{{\mathrm {SL}}}
\newcommand{\SO}{{\mathrm {SO}}}
\newcommand{\n}{{\mathrm{n}}}
\newcommand{\Pic}{{\mathrm{Pic}}}
\newcommand{\CH}{{\mathrm{CH}}}
\newcommand{\AJ}{{\mathrm{AJ}}}
\newcommand{\tr}{{\mathrm{tr}}}
\newcommand{\si}{\sigma}
\newcommand{\eps}{\epsilon}
\newcommand{\ta}{{\tau}}
\newcommand{\R}{{\mathbb R}}
\newcommand{\M}{{\mathrm{M}}}
\newcommand{\HC}{\mathcal F_{\rm har}}
\newcommand{\PGL}{{\mathrm{PGL}}}
\newcommand{\Supp}{\mathrm{Supp}}
\newcommand{\ep}{\varepsilon}

\def \mint {\times \hskip -1.1em \int}

%\newcommand{\mint}{\times\!\!\!\!\!\hskip-0.3em\int}

\newcommand{\SP}{\vspace{0.5cm}}
\newcommand{\T}{\mathbb T}
\newcommand{\new}{\mathrm{new}}
\DeclareMathOperator{\Hom}{Hom} 
\DeclareMathOperator{\Meas}{Meas}
\newcommand{\X}{\mathbb X}
\newcommand{\Y}{\mathbb Y}
\newcommand{\U}{\mathbb U}
\newcommand{\Rat}{{\rm Rat}\bigl(\PP^1(\Q_p),\C_p\bigr)}
\newcommand{\Ker}{{\mathrm Ker}}
\newcommand{\res}{\mathrm{res}}
\DeclareMathOperator{\rig}{rig}
\DeclareMathOperator{\cmp}{comp}
\DeclareMathOperator{\can}{can}
\DeclareMathOperator{\fin}{fin}
\DeclareMathOperator{\even}{even}
\DeclareMathOperator{\spl}{Spl}
\DeclareMathOperator{\hdg}{hdg}
 \DeclareMathOperator{\noc}{n-oc}
 \DeclareMathOperator{\hol}{hol}

\newcommand{\TT}{\mathbb{T}}
\newcommand{\uTT}{\underline{\mathbb{T}}}
\newcommand{\D}{\mathbb D}


\newcommand{\rom}{\mathrm}
 

\newcommand{\longmono}{\mbox{$\lhook\joinrel\longrightarrow$}}
\newcommand{\longleftmono}{\mbox{$\longleftarrow\joinrel\rhook$}}
\newcommand{\longepi}{\mbox{$\relbar\joinrel\twoheadrightarrow$}}
\newcommand{\mat}[4]{\left(\begin{array}{cc}#1&#2\\#3&#4\end{array}\right)}
\newcommand{\smallmat}[4]{\bigl(\begin{smallmatrix}#1&#2\\#3&#4\end{smallmatrix}\bigr)}
\newcommand{\dirlim}{\mathop{\varinjlim}\limits}
\newcommand{\invlim}{\mathop{\varprojlim}\limits}


\newcommand{\Corr}{\mathrm{Corr}}

\include{thebibliography}

\begin{document}

\title[A $p$-adic Gross-Zagier formula for diagonal cycles]{Diagonal cycles and Euler systems I: \\ A $p$-adic Gross-Zagier formula}



\author{Henri Darmon and Victor Rotger}

\begin{abstract}


This article is the first in a series devoted to 
studying  {\em  generalised  Gross-Kudla-Schoen diagonal cycles}
in the product of three Kuga-Sato varieties 
 and the Euler system
properties of   
   the  associated   Selmer classes, with special 
   emphasis on their application to the Birch--Swinnerton-Dyer
   conjecture and the theory of Stark-Heegner points. 
  The basis for the entire study is a 
  $p$-adic   formula of Gross-Zagier type which relates
   the images of these diagonal cycles under
the  $p$-adic  Abel-Jacobi map    to   special values
of  certain $p$-adic $L$-functions
attached to the Garrett-Rankin
triple convolution
of  three  Hida families
of  modular forms. 
The main goal of this article is to describe and prove this
formula. 

\medskip
\medskip

\noindent
{\em 
Cet article est le premier d'une s\'erie consacr\'ee aux
     {\em cycles de  Gross-Kudla-Schoen  g\'en\'eralis\'es} 
appartenant aux  groupes de Chow de   produits de trois vari\'et\'es de Kuga-Sato, 
et aux {\em syst\`emes d'Euler} qui leur sont 
associ\'es. La s\'erie au complet  repose sur une variante
$p$-adique de la formule  de Gross-Zagier
qui relie l'image  des cycles de Gross-Kudla-Schoen par
l'application d'Abel-Jacobi $p$-adique aux valeurs sp\'eciales
de certaines fonctions $L$ $p$-adiques
attach\'ees  \`a la convolution de Garrett-Rankin 
de trois familles de Hida de  formes modulaires cuspidales.
L'objectif principal de cet article est de d\'ecrire et de d\'emontrer cette
variante.}


\medskip\medskip
\noindent
{\em MSC}: 11F12,  11G05, 11G35, 11G40.

\medskip\medskip
\noindent
{\em Keywords}: Gross-Kudla-Schoen cycle, Garrett-Rankin $p$-adic $L$-function,
$p$-adic Abel-Jacobi map, Chow group, Coleman integration.


 \end{abstract}

\address{H. D.: McGill University, Montreal, Canada}
\email{darmon@math.mcgill.ca}
\address{V. R.: Universitat Polit\`{e}cnica de Catalunya, Barcelona, Spain}
\email{victor.rotger@upc.edu}

%\subjclass{11G18, 14G35}


\maketitle

\tableofcontents

\section{Introduction}

This article is the first in a series devoted to 
studying  {\em  generalised  diagonal cycles}
in the product of three Kuga-Sato varieties 
 and the Euler system
properties of   
   the  associated   Selmer classes, with special 
   emphasis on their application to the Birch--Swinnerton-Dyer
   conjecture and the theory of Stark-Heegner points. 
  The basis for the entire study is a 
  $p$-adic    Gross-Zagier formula   relating
\begin{itemize}
\item the image under
the  $p$-adic  Abel-Jacobi map
of certain {\em  generalised Gross-Kudla-Schoen cycles}
in the product of three Kuga-Sato varieties, to
\item  the  special value
of the  $p$-adic $L$-function of \cite{HaTi}
attached to
the Garrett-Rankin triple convolution
of  three  Hida families of  modular forms,
at a point lying outside its region of  interpolation.
\end{itemize} 
 
In order to precisely state the main result, let
$$f = \sum a_n(f) q^n \in S_{k}(N_f,\chi_f),$$
$$g=\sum a_n(g) q^n \in S_{\ell}(N_g,\chi_g),$$
$$h=\sum a_n(h) q^n \in S_{m}(N_h,\chi_h)$$ be three
normalized primitive cuspidal eigenforms of weights
$k, \ell, m \geq 2$, levels $N_f, N_g, N_h\geq 1$,
and Nebentypus characters $\chi_f, \chi_g$, and $\chi_h$,
respectively. Let  $N:=\mathrm{lcm}(N_f,N_g,N_h)$ and
assume that
$$\chi_f\cdot \chi_g \cdot \chi_h=1,$$
so that in
particular $k+\ell+m$ is even.

The triple $(k,\ell,m)$ is said to be {\em balanced} if the
largest weight is strictly smaller than the sum of the other two.
A triple of weights which is not balanced will be called
{\em unbalanced}, and the largest weight in an
unbalanced triple will be referred to as the
{\em dominant weight}.

 Section  \ref{3L} recalls the definition of 
the Garrett-Rankin  $L$-function $L(f,g,h; s)$  attached to the triple tensor product
$$V_p(f,g,h) := V_p(f) \otimes V_p(g) \otimes  V_p(h) $$
of the (compatible systems of)  $p$-adic Galois representations 
$V_p(f)$, $V_p(g)$ and $V_p(h)$ attached to 
 $f$, $g$ and $h$ respectively.
 This $L$-function  satisfies a functional equation relating its
values at  $s$ and $k+\ell+m-2-s$. In particular,
 the parity of the order of
vanishing of $L(f,g,h;s)$ at the central critical point
$c:=\frac{k+\ell+m-2}{2}$ is
controlled by the sign $\varepsilon\in\{\pm 1\}$ in this functional equation,
a quantity that can be expressed as a product $ \varepsilon = \prod_{v|N\infty} \varepsilon_v$, $\varepsilon_v\in \{ \pm 1\}$, 
of local root numbers indexed by
the places dividing $N\infty$. The following hypothesis is assumed throughout:  
\begin{equation*}
\mbox{H:} \quad \mbox{The local root numbers $\varepsilon_v$ at all the
 finite primes $v|N$ are  equal to  $+1$.}
\end{equation*}
This assumption holds in a broad collection of settings
of arithmetic interest.  For instance, it is satisfied in either of the
following  two cases:
\begin{itemize}
\item
$\mathrm{gcd}(N_f,N_g,N_h)=1$, or,
\item
$N=N_f=N_g=N_h$ is square-free
and $a_v(f) a_v(g) a_v(h)=-1$  for all primes $v\mid N$.
\end{itemize}
Assumption $H$ implies that $\varepsilon=\varepsilon_\infty$ depends only on the local sign
at $\infty$, which in turn depends only on whether the weights of
$(f,g,h)$ are balanced or not:
$$ 
\varepsilon = \varepsilon_\infty = \left\{
\begin{array}{rl}
-1 & \mbox{ if } (k,\ell,m) \mbox{ is balanced};  \\
1 & \mbox{ if } (k,\ell,m) \mbox{ is unbalanced}. 
\end{array}
\right.
$$
In particular, the $L$-function $L(f,g,h,s)$ necessarily vanishes
(to odd order)  at its central point  $c$ 
when $(k,\ell,m)$ is balanced. 
  
Let $\cE$ denote the universal generalised
elliptic curve  fibered over $X=X_1(N)$.
For any $n\geq 0$,  let
$\cE^n$ be the $n$-th Kuga-Sato variety over $X_1(N)$.
It is an $n+1$-dimensional variety obtained
by desingularising the $n$-fold
fiber product of $\cE$ over  $X_1(N)$. (Cf.~\cite{Sc}
for a more detailed account of its construction.)
The $p$-adic Galois representation $V_p(f,g,h)$ 
occurs in the middle cohomology of  the  triple product
\begin{equation}
\label{eqn:defW}
W:= \cE^{k-2}\times \cE^{\ell-2}\times \cE^{m-2}.
\end{equation}
When $(k,\ell,m)$ is balanced and assumption $H$ is satisfied, 
the conjectures of Bloch-Kato and Beilinson-Bloch  predict 
(because of the vanishing of $L(f,g,h,c)$)
that there should then exist a non-trivial cycle in the Chow group
$\Q \otimes \CH^c(W)_0$ of rational equivalence classes of
null-homologous cycles of codimension $c$ on the variety $W$ of
\eqref{eqn:defW}.
Section   \ref{cycles} introduces  
cycles $\Delta_{f,g,h}\in \Q \otimes \CH^c(W)_0$
which are natural candidates to fulfill these expectations,
and whose construction we now briefly summarize.


Set $r=\frac{k + \ell + m-6}{2}$. As  explained in \S \ref{cycles}, there
exists an essentially unique, natural way of embedding the
Kuga-Sato variety $\cE^r$  in the variety $W$.
Its image gives rise to an element in the Chow group
$\CH^{r+2}(W)$ which, suitably modified, becomes homologically trivial.
In this way, we obtain a cycle
$$
\Delta_{k,\ell,m}\in \CH^{r+2}(W)_0 :=
\ker (\CH^{r+2}(W) \overset{\cl}{\lra} H^{2r+4}_{\dR}(W/\C)).
$$
In the special case  where $k=\ell=m=2$, the cycle
$\Delta_{2,2,2}$ is just the modified diagonal considered by
Gross--Kudla \cite{GrKu}
and
Gross--Schoen \cite{GrSc}.

The cycles $\Delta_{f,g,h}$ alluded to above are defined as the $(f,g,h)$-isotypical component of the null-homologous cycle $\Delta_{k,\ell,m}$ with respect to the action of the Hecke operators.

It is natural to conjecture that the heights of these cycles  in the sense
of  Beilinson and Bloch are well-defined
(cf.\,\cite{GrKu} and \cite{GrSc} for more details on the
necessary definitions), and  can be directly related to the first derivative
of the triple product
$L$-function $L(f,g,h,s)$ at the central  point:
\begin{equation}
\label{eqn:GZ}
h(\Delta_{f,g,h}) \overset{?}{=} \mbox{(Explicit non-zero factor)}\times L'(f,g,h,r+2).
\end{equation}
When $(k,\ell,m)=(2,2,2)$, this
was predicted in \cite{GrKu}
and has recently been proved by X. Yuan,
S. Zhang and W. Zhang in \cite{YZZ}.

\begin{remark} It would be natural to relax assumption $H$ to the weaker condition
\begin{equation}
\label{ass:victor}
\mbox{$H_{\even}$: 
The set of primes $v|N$ for which 
$\varepsilon_v=-1$  is of {\em even cardinality}.}
\end{equation}
This is sufficient to guarantee that $\varepsilon=\varepsilon_\infty$, and
can be dealt with at the cost of
replacing Kuga-Sato varieties with more general objects arising from the
self-fold  products of certain families
of abelian surfaces (or  genus two curves)  fibered over
Shimura curves rather than classical modular curves. 
Hypothesis $H$ may thus  be regarded
as analogous to the classical Heegner or Gross-Zagier hypothesis imposed
in the study of the Rankin-Selberg $L$-function $L(f\otimes \theta_K,s)$
attached to a single
eigenform $f$ and the weight one theta series  of an imaginary quadratic
field $K$.
Both are meant to avoid having to deal with
Shimura curves associated with a  quaternion division algebra,
and make it possible
to confine one's attention
to  classical  modular curves.
Much of our study extends to the setting of  $H_{\even}$ by appealing to the work of P. Kassaei \cite{PaymanPhD} and R. Brasca \cite{Br}; in our exposition we have tried to present our results in a way that suggests the modifications necessary to deal with arbitrary Shimura curves. 
%Nevertheless, while we definitely conjecture that our main result holds true under $H_{\even}$, there is a (single) point in our proof which, to the best of our knowledge, does not seem to extend easily to the setting of division quaternion algebras, and therefore poses an interesting challenge in the theory of $p$-adic families of quaternionic modular forms that we encourage the reader to solve or circumvent: see \S \ref{p3L-classical} for more details. 
\end{remark}


In this work we do not focus on
 \eqref{eqn:GZ},
but rather on a $p$-adic
analogue.
Our main result  relates
the image of $\Delta_{f,g,h}$ under the $p$-adic  Abel-Jacobi map
\begin{equation}\label{AJpadic}
\AJ_{p}:  \CH^{r+2}(W)_0(\Q_p) \, \lra \, \mathrm{Fil}^{r+2} H_{\dR}^{2r+3}(W/\Q_p)^{\vee}
\end{equation}
to the  special value of a  triple product $p$-adic $L$-function
attached to three Hida families of modular forms,
which we now describe in more detail.

Fix an odd prime number $p\nmid N$ at
which $f$, $g$ and $h$ are
ordinary.
% \footnot*{One could probably assume that $f$, $g$ and $h$  admit $p$-stabilisations of finite slope at $p$ and consider the Coleman families passing through them in order to obtain more general results, but for simplicity we confine ourselves to the setting of  Hida families, which is  sufficient for many applications. The reader is referred to \cite{Pan} and the references therein for a construction (using an alternate method to the one considered here) of a $p$-adic triple $L$-function in this level of generality. The $p$-adic $L$-function constructed in loc.\,cit.\,is of different nature than the one introduced in the present work: the former starts with a triple $(f,g,h)$ of modular forms whose weights $(k,\ell,m)$ are {\em unbalanced}.}
 Let
$$
\hf: \Omega_f \lra \C_p[[q]], \qquad \hg: \Omega_g \lra \C_p[[q]], \quad
\hh: \Omega_h \lra \C_p[[q]]
$$
denote the Hida families of overconvergent $p$-adic
modular forms passing though $f$, $g$ and $h$, respectively,
as constructed in \cite{Hi86a} and \cite{Hi86}, and briefly
reviewed in \S \ref{hidatheory} below. 
The spaces $\Omega_f$, $\Omega_g$ and $\Omega_h$
are finite rigid analytic coverings of suitable subsets of
the {\em weight space}
$$ \Omega := \Hom_{\cts}(\Z_p^\times,\C_p^\times), $$
which contains the integers $\Z$ as a dense subset via the
natural inclusion $k\mapsto (x\mapsto x^{k}).$
A point $x\in \Omega_f$ is said to be {\em classical} if its
image in $\Omega$, denoted $\kappa(x)$,
belongs to $\Z^{\ge 2}$, and the set of classical
points in $\Omega_f$ is denoted by $\Omega_{f,\cl}$.
Part of the requirement that $\hf$ be a Hida family is that
the formal $q$-series  $f_x^{(p)}:=\hf(x)$ should correspond
to a normalised
eigenform of weight $\kappa(x)$ on $\Gamma_1(N)\cap \Gamma_0(p)$,
for almost all $x\in \Omega_{f,\cl}$. For all but finitely many such
$x$, the form $f_x^{(p)}$ is the ordinary $p$-stabilisation of a
normalised eigenform on $\Gamma_1(N)$, denoted $f_x$.

The natural domain of definition of the triple product $p$-adic $L$-functions
is the $p$-adic analytic space
$$\Sigma := \Omega_f\times\Omega_g\times\Omega_h.$$
Let $\Sigma_{\cl} := \Omega_{f,\cl}\times\Omega_{g,\cl}\times\Omega_{h,\cl}\subset
\Sigma$ denote its subset of ``classical points".
This set
is naturally partitioned into four disjoint subsets:
\begin{eqnarray*}
\Sigma_f &=& \{(x,y,z)\in \Sigma_{\cl}, \quad \mbox{ such that  }
\kappa(x)\geq \kappa(y)+\kappa(z)\}; \\
\Sigma_g &=& \{(x,y,z)\in \Sigma_{\cl}, \quad \mbox{ such that  }
\kappa(y)\geq \kappa(x)+\kappa(z)\}; \\
\Sigma_h &=& \{(x,y,z)\in \Sigma_{\cl}, \quad \mbox{ such that  }
\kappa(z)\geq \kappa(x)+\kappa(y)\}; \\
\Sigma_{\bal} &=& \{(x,y,z)\in \Sigma_{\cl}, \quad \mbox{ such that  }
(\kappa(x),\kappa(y),\kappa(z)) \mbox{ is balanced}. \}.
\end{eqnarray*}
Section \ref{sec:p-adic-Lfct}
exploits the strategy
pioneered by Hida  \cite{Hi88b} and subsequently extended
by Harris and Tilouine  \cite{HaTi} to construct {\em three
a priori distinct}
$p$-adic
$L$-functions of three variables, denoted
$$
\Lp^f(\hf,\hg,\hh), \quad
\Lp^g(\hf,\hg,\hh), \quad
\Lp^h(\hf,\hg,\hh):
\Sigma \lra \C_p,$$
which interpolate the
{\em square-roots} of the {\em central critical values} of
the classical $L$-function
$L(f_x,g_y,h_z,s)$, as $(x,y,z)$ ranges over
$\Sigma_f$, $\Sigma_g$, and $\Sigma_h$ respectively.
The precise interpolation property defining the three
$p$-adic $L$-functions is spelled out in Theorem \ref{sec3:main}
of Section \ref{sec:trilinear-periods}.

Given $(x,y,z)\in \Sigma_{\bal}$,
the Heegner assumption  $H $  can be used
to show that the
classical $L$-function  $L(f_x,g_y,h_z,s)$
vanishes at its central point
for reasons of sign. The
{\em central critical
derivative}  $L'(f_x,g_y,h_z,\frac{\kappa(x)+\kappa(y)+\kappa(z)-2}{2})$ is then a natural
object of arithmetic interest.
In the $p$-adic realm,  the 
 three distinct $p$-adic avatars of the classical $L$-function,
namely, $\Lp^f(\hf,\hg,\hh)$, $\Lp^g(\hf,\hg,\hh)$, and 
$\Lp^h(\hf,\hg,\hh)$, need not vanish at the  balanced  point $(x,y,z)$,  
since this point  lies outside the region of classical interpolation.
The corresponding $p$-adic special values can be viewed as
different $p$-adic avatars 
of the complex leading term, and one might expect 
them to encode similar  information related to the motive
of $V_{f_x}\otimes V_{g_y}\otimes V_{h_z}$.


\begin{remark}
\label{rem:Lp-bal}
One can also  envisage
a fourth  $p$-adic $L$-function
$$L_p^{\bal}(\hf,\hg,\hh)(x,y,z,s):
\Omega_f\times \Omega_g\times\Omega_h\times \Omega \lra \C_p $$
involving a further ``cyclotomic" variable $s$
and interpolating the classical special values of
$L(f_x,g_y,h_z,s)$--but {\em not} their square roots--in
the critical range
$$ (x,y,z)\in \Sigma_{\bal}, \qquad
1\le s \le \kappa(x) + \kappa(y) + \kappa(z) -3.$$
The construction of such an $L$-function is described in 
\cite{Pan} (see also the references therein).
Under hypothesis $H$, the function $L_p^{\bal}(\hf,\hg,\hh)$
should vanish identically on the
``central critical hyperplane"  $2s=\kappa(x)+\kappa(y)+\kappa(z)-2$,
and the presence of the cyclotomic variable is
therefore key to ensuring its non-triviality.
This  ``balanced" $p$-adic $L$-function
 plays no role in  this article.
 \end{remark}

In stating our main result, it will be convenient to assume for simplicity
that $N_f=N_g=N_h$, i.e., that the three eigenforms $f$, $g$ and $h$ 
are new of the same level $N$. (This assumption, which is too restrictive for most 
interesting arithmetic applications, will be relaxed in the body of the text.)
To  any classical   newform $\phi$ of weight
$r+2$ on $\Gamma_1(N)$  which is ordinary at $p$, there corresponds
a  cohomology  class
$$
\omega_{\phi} \in \Fil^{r+1} H^{r+1}_{\dR}(\cE^{r}/\bar\Q) \subset
\Fil^{r+1} H^{r+1}_{\dR}(\cE^r/\C_p), $$
where the inclusion   is induced from our fixed embedding $\bar\Q\subset \C_p$. 
The $\phi$-isotypic component of
$H^{r+1}_{\dR}(\cE^{r}/\C_p)$ is two-dimensional over $\C_p$ and (because $\phi$ is  ordinary)
it admits a
one-dimensional 
{\em unit root subspace}, denoted
$H^{r+1}_{\dR}(\cE^{r}/\C_p)^{\ur}$,
on which the Frobenius
endomorphism acts as multiplication by a $p$-adic unit.
This unit root subspace is complementary to the middle step
in the Hodge filtration, and hence, there is a unique element
$\eta_{\phi}^{\ur} \in H^{r+1}_{\dR}(\cE^{r}/\C_p)^{\ur}$ satisfying
$$ \langle \omega_{\phi},\eta_{\phi}^{\ur} \rangle = 1,$$
where $\langle\ ,\ \rangle$ denotes the non-degenerate
Poincar\'e pairing on $H^{r+1}_{\dR}(\cE^{r}/\C_p)$.
One thus obtains a natural basis $(\omega_{\phi},\eta_{\phi}^{\ur})$
of the $\phi$-isotypic component of $H^{r+1}_{\dR}(\cE^{r}/\C_p)$,
for any ordinary classical newform $\phi\in S_{r+2}(\Gamma_1(N))$.

If $(f,g,h)$ is a triple of newforms of level $N$ and balanced weights
$(k,\ell,m) =  (r_1+2,r_2+2,r_3+2)$, then
\begin{eqnarray}
\label{eqn:kunneth-decomp}
\eta_f^{\ur} \otimes \omega_g\otimes\omega_h &\in&
H^{r_1+1}_{\dR}(\cE^{r_1})\otimes
\Fil^{r_2+1} H^{r_2+1}_{\dR}(\cE^{r_2})
\otimes
\Fil^{r_3+1} H^{r_3+1}_{\dR}(\cE^{r_3}) \\
\nonumber
&\subset& \Fil^{r+2}\left(
H^{r_1+1}_{\dR}(\cE^{r_1})\otimes
H^{r_2+1}_{\dR}(\cE^{r_2})
\otimes
H^{r_3+1}_{\dR}(\cE^{r_3})\right) \\
\nonumber
&\subset &
\Fil^{r+2} H^{2r+3}_{\dR}(W/\bar\Q_p),
\end{eqnarray}
where the last inclusion arises from the K\"unneth decomposition.
In particular, the class $\eta_f^{\ur}\otimes\omega_g\otimes\omega_h$ lies
in the domain of $\AJ_p(\Delta)$ when $(k,\ell,m)$ is balanced.

For any $f\in S_k(N,\chi)$, we shall always write
 $$ (x^2-a_p(f)x + \chi_f(p)p^{k-1}) = (x-\alpha_f)(x-\beta_f), 
 \qquad \mbox{ with } \ord_p(\alpha_f) \le \ord_p(\beta_f),   $$ 
so that in particular $\alpha_f$ is a $p$-adic unit when $f$ is ordinary.

The main result of this article is
\begin{theorem}
\label{mainDR}
Given  $(x,y,z)\in \Sigma_{\bal}$, let
$$ (f,g,h) := (f_x,g_y,h_z), \qquad\qquad  (k,\ell,m) := (\kappa(x),\kappa(y),\kappa(z)),  $$
$$ c := (k+\ell+m-2)/2, \qquad \qquad k= \ell+ m-2-2t \quad   (\mbox{with  } t\ge0), $$
 and let
$ \Delta := \Delta_{k,\ell,m}$
be the generalised diagonal cycle in $\cE^{k-2}\times \cE^{\ell-2}\times \cE^{m-2}$.  Then
$$\Lp^f(\hf,\hg,\hh)(x,y,z) = (-1)^t    \frac{\E(f,g,h)}{t!\cdot \E_0(f) \E_1(f)}  \times 
 \AJ_p(\Delta)(\eta_{f}^{\ur}\otimes \omega_{g}\otimes \omega_{h}),$$
 where 
 \begin{eqnarray}
\label{eqn:defEE}
\E(f,g,h) & := &
\left(1- \beta_f\alpha_g\alpha_h p^{-c}\right)\times
\left(1-\beta_f \alpha_g\beta_h p^{-c}\right) \\
\nonumber
& & \times \left(1- \beta_f\beta_g \alpha_h 
p^{-c}\right)\times
\left(1- \beta_f \beta_g\beta_h p^{-c}\right), \\
\label{eqn:defE0}
\E_0(f) & := & (1- \beta_f^2 \chi_f^{-1}(p)  p^{1-k}), \\
\label{eqn:defE1}
\E_1(f) & := & (1- \beta_f^2 \chi_f^{-1}(p)  p^{-k}).
\end{eqnarray}
\end{theorem}
See  Theorem \ref{main-general}
 for a more general statement
 involving newforms of possibly different levels. Theorem \ref{mainDR} can be viewed as a $p$-adic analogue
of the  archimedean formula suggested in (\ref{eqn:GZ}), and in fact the Euler factor $\E(f,g,h)$ that arises in the formula
fits within the general
conjectural description of the $p$-adic $L$-function of an arbitrary motive given by Panciskin in \cite[p.\,285]{Pan2}.

One could also envisage a more direct
$p$-adic analogue,
relating the cyclotomic $p$-adic height of $\Delta_{f_x,g_y,h_z}$
to the derivative
in the  cyclotomic direction
of the $p$-adic $L$-function $L_p^{\bal}(\hf,\hg,\hh)(x,y,z,s)$
alluded to in
Remark \ref{rem:Lp-bal}.
Such a formula, which is currently unavailable in the literature,
 would be
closer in spirit to the archimedean formulae conjectured
in \cite{GrKu}  and proved in \cite{YZZ}, and to the 
$p$-adic analogues of the Gross-Zager formula 
proved in 
\cite{perrin-riou-gz} and \cite{nekovar-gz}, 
while 
Theorem \ref{mainDR}
  is  better adapted to the arithmetic applications that the authors
  wish to pursue by exploiting the
  {\em Euler system
properties}  of $p$-adic families of diagonal cycles  and associated explicit reciprocity laws in the spirit
 of   Coates--Wiles and Kato--Perrin-Riou. 
 Let us close this introduction by describing some of these applications.
 

\medskip\noindent
{\bf I.  The Euler system of diagonal cycles}.  
  Theorem \ref{mainDR} is available when $f$ is replaced by $g$ or $h$ if the latter
two forms are also assumed to be ordinary.
The Abel-Jacobi image  $\AJ_p(\Delta)$ therefore
encodes the values of the three distinct   $p$-adic $L$-functions
$\Lp^f(\hf,\hg,\hh)$,
$\Lp^g(\hf,\hg,\hh)$
and
$\Lp^h(\hf,\hg,\hh)$ at $(x,y,z)\in \Sigma_{\bal}$. This suggests that these $L$-functions
should be viewed as the different projections of a common {\em Euler system} obtained by $p$-adically
interpolating the diagonal cycles themselves  as  $(x,y,z)$ ranges over $\Sigma_{\bal}$.   (More precisely: their images
$\kappa({f_x,g_y,h_z})\in H^1(\Q, V_{f_x,g_y,h_z})$ 
under the $p$-adic  \'etale Abel-Jacobi map, where
$V_{f_x,g_y,h_z}$ denotes the self-dual Tate twist of the triple tensor product
$V_{f_x}\otimes V_{g_y}\otimes V_{h_z}$  of the Deligne representations attached to the eigenforms $f_x$, $g_y$ and $h_z$.)
The sequel \cite{DR2} to this paper pieces these global classes together    into an element 
$$\ukappa(\hf,\hg,\hh) \in H^1(\Q,\uV_{\hf, \hg, \hh}),$$ 
where
$\uV_{\hf,\hg,\hh}$ is a twist of
the tensor product  $\uV_{\hf}\otimes \uV_{\hg}\otimes \uV_{\hh}$ of Hida's $\Lambda$-adic representations attached to $\hf$, $\hg$, and $\hh$ respectively,
interpolating the representations $V_{f_x,g_y,h_z}$. 
 The three 
Garrett-Rankin $p$-adic $L$-functions are then obtained from the image of 
$\ukappa(\hf,\hg,\hh)$ under a homomorphism  interpolating the Bloch-Kato 
logarithms attached to the specialisations $V_{f_x}\otimes V_{g_y}\otimes V_{h_z}$
in the range $(x,y,z)\in\Sigma_{\bal}$. 
The resulting construction of the Garrett-Rankin $p$-adic $L$-functions in terms of 
diagonal cycles is directly analogous to the construction of the Kubota-Leopoldt 
(resp.~Katz)
$p$-adic $L$-function from the  $p$-adic logarithms  of circular (resp.~elliptic) units.
An application of this point of view  to the Birch-Swinnerton-Dyer conjecture, obtained by considering   weight one specialisations of $\hg$ and $\hh$,  is  the implication
$$ L(E,\rho_1\otimes\rho_2,1)\ne 0 \implies \Hom_{G_\Q}(\rho_1\otimes\rho_2,E(\bar\Q)\otimes\C) = 0,$$
where $E$ is an elliptic curve over $\Q$ 
and $\rho_1$ and $\rho_2$ are odd irreducible  two-dimensional Artin representations for which 
$\rho_1\otimes \rho_2$ has determinant one. 
 
 \medskip\noindent
 {\bf II. Beilinson-Flach elements}. 
 The methods of the present article, transposed to the setting
   where   $\hh$ is a Hida family of Eisenstein series, lead to a proof \cite{BDR} of a $p$-adic Beilinson formula relating the $p$-adic regulators of certain Flach 
  elements in the Higher Chow group $\CH^2(X_0(N)\times X_0(N), 1)$ to values of Hida's three-variable
  $p$-adic $L$-function attached to the Rankin convolution of two Hida families $\hf$ and
  $\hg$ of cusp forms. A notable application of this result (when made to vary in $p$-adic families, as in the previous paragraph) is the implication
 \begin{equation}
 \label{eqn:BSDrho}
 L(E,\rho,1)\ne 0 \implies \Hom_{G_\Q}(\rho,E(\bar\Q)\otimes \C)=0,
 \end{equation}
  where $\rho$ is an odd, irreducible two-dimensional Artin representation.
  
  
\medskip\noindent
{\bf III. Beilinson elements and Kato's Euler system}.
 The  point of view sketched in the two previous Remarks is also consistent with the Kato-Perrin-Riou
approach to the Mazur-Swinnerton-Dyer $p$-adic $L$-function  attached to a cusp form of weight $2$, which one  recovers when both $\hg$ and $\hh$ are taken to be 
Hida families of Eisenstein series, the role of the diagonal cycles being played by Beilinson
elements in the $K_2$ of modular curves, or in the higher Chow group 
$\CH^2(X_0(N),2)$. Guided by this analogy and  relying crucially on  the techniques  of the present work, the article
\cite{BD-kato}   gives a new proof of the $p$-adic Beilinson formula relating the $p$-adic regulators of  the  Beilinson  elements to the special values  at $s=2$ of the  Mazur-Swinnerton-Dyer $p$-adic $L$-functions. The authors' study of diagonal cycles and Flach elements is thus a direct generalisation of the approach of
 Kato which underlies the proof of  \eqref{eqn:BSDrho}
 when $\rho$ is replaced by a 
  Dirichlet character.


\medskip\noindent
{\bf IV. The Euler system of Heegner points, revisited}.
In part, the authors were led  to  Theorem \ref{mainDR}
by the analogy with the main
result of \cite{BDP1}, in which the images of  Heegner points
(or more general Heegner cycles) under $p$-adic Abel-Jacobi maps
are related to the values of certain  anticyclotomic $p$-adic $L$-functions at classical points
lying outside the range of $p$-adic interpolation defining them. In his forthcoming 
PhD thesis, F. Castella uses this to construct these anticyclotomic $p$-adic $L$-functions in terms 
of $p$-adic logarithms of Heegner points, leading to a treatment of the Heegner point Euler system    entirely  parallel to the other examples
 alluded to above (namely, circular units, elliptic units,  Beilinson-Kato elements, Flach elements, 
and diagonal cycles.)


\medskip\noindent
{\bf V. $p$-adic calculations of Chow-Heegner points}.
The article \cite{lauder-heidelberg} and the  forthcoming Ph.\,D thesis of M. Daub \cite{DaubPhD} combine   Theorem \ref{mainDR}  with Alan Lauder's
 fast algorithm \cite{lauder-alg}
 for calculating ordinary projections 
to calculate the ``Chow-Heegner points" attached to Gross-Schoen
diagonal cycles (as described in \cite{YZZ} and studied in \cite{DRS1}) by 
$p$-adic analytic methods, thus supplying the $p$-adic counterpart of the complex
calculations carried out in \cite{DDLR}.
 

\medskip
\noindent
{\em Notations}:
Throughout the article,
 given a power  $q=p^d$  of a prime
$p$, the symbols
$\F_q$, $\Z_q$, and $\Q_q$  are reserved for
the finite field with $q$ elements, its ring of
Witt vectors, and the  finite unramified extension of 
$\Q_p$ of degree $d$ respectively.
For any field extension $F/\Q$, we will write $G_F=\Gal(\bar F/F)$ for the absolute Galois group of an algebraic closure of $F$, and if $X$ is any variety over $F$, we let
   $\bar X := X\times_{\spec(F)} \spec(\bar F)$ denote the base change
   of $X$ to the algebraic closure.  
   We adopt the usual conventions regarding motives and their Tate twists: for any integer $j$ we write $\Z(j)=H^2(\PP_1)^{\otimes -j}$, so that a geometric frobenius element at $\ell\ne p$ (resp.~at $\ell=p$)
   acts on its $p$-adic \'etale (resp.~cristalline)  realisation
   as multiplication by  $\ell^{-j}$. If $M$ is a motive over $\Q$, we let $M(j):= M\otimes \Z(j)$ denote its $j$-th Tate twist,
so that $L(M(j),s) = L(M,s+j)$, where 
   $L(M,s)$ is the $L$-function attached to $M$.
   
      
 \medskip\noindent
 {\em Acknowledgements}:
 The authors thank Ignacio Sols and Dipendra Prasad
  for many stimulating exchanges about the 
 geometric aspects of diagonal cycles and the analytic properties of triple product
 $L$-functions, respectively. The work on this article began during the summer of 
 2010 at the special number theory semester organised by the CRM in Barcelona, and  the
 authors also gratefully acknowledge the role of this institute in facilitating their collaboration. The
 first author was funded by an NSERC Discovery grant, and the  second author
received financial support from DGICYT Grant MTM2009-13060-C02-01 and from 2009 SGR 1220.

%\newpage
\section{Cohomology and modular forms}

\subsection{The de Rham cohomology of curves over $p$-adic rings}
\label{wideopens}

Let $\cX$ be an arbitrary smooth proper curve
over $\spec(\Z_p)$ and write $\tilde{X}$ and $X$ for its special and generic fiber, respectively.
Let
$\{P_1,\ldots,P_s\} \subset  \tilde{X}(\bar \F_{p})$ be a
non-empty $G_{\F_p}$-stable collection
of closed points in its special fiber.
Since $\tilde{X}$ is smooth,
these  points  admit lifts $\tilde P_1,\ldots, \tilde P_s\in \cX(\cO_{\C_p})$
to characteristic zero.
It will be convenient (albeit not indispensable)  to fix a choice of such lifts 
which is stable under the natural action of $G_{\Q_p}$.
This   determines    the affine scheme
$$ \cX' = \cX-\{ \tilde P_1,\ldots, \tilde P_s\}   $$
over $\spec(\Z_p)$, whose special and generic fiber are denoted
$\tilde{X}'$ and $X'$ respectively.
Because $\cX$ is proper over $\spec(\Z_p)$, there is a natural identification $X(\C_p) = \cX(\cO_{\C_p})$ and a
resulting {\em reduction map}
$$ \red: X(\C_p) \lra \tilde{X}(\bar\F_p).$$
The {\em standard affinoid} in $X(\C_p)$ attached to $X'$ is defined to be
$$  \cA  :=  \red^{-1}(\tilde{X}'(\bar\F_p)).$$
It is a connected affinoid region obtained by deleting from $X(\C_p)$ a
collection of $s$ disjoint
 residue discs.

 For each $j=1,\ldots,s$, choose a local coordinate $\lambda_j$
at $\tilde P_j$, i.e.,
 a rigid analytic isomorphism from the residue disc of $\tilde P_j$  in $X(\C_p)$
 to the open unit
 disc in $\C_p$, sending $\tilde P_j$ to the origin.
These local parameters give rise to
 a family of  {\em wide open neighborhoods}  of $\cA$, indexed by
a real parameter $\epsilon>0$ and defined by
$$ \cW_\epsilon := \cA\cup \bigcup_{j=1}^s \{ x\in \red^{-1}(P_j)
\mbox{ with } \ord_p \lambda_j(x) < \epsilon \}.$$
The region $\cW_\epsilon$ is
obtained by adjoining  open annuli $\cV_1,\ldots,\cV_s$
of ``width $\epsilon$"
to $\cA$ around the boundaries of each of the deleted   residue discs. Note  the obvious inclusions
$$ \cA \subset \cW_\epsilon \subset   X'(\C_p), \qquad \cW_{\epsilon_1} \subset  \cW_{\epsilon_2} \mbox{ if } \epsilon_1<\epsilon_2.$$

One of the main reasons for
working with the wide open neighborhoods  $\cW_\epsilon$
rather than with the affinoid $\cA$ itself
is that their cohomology is better behaved
and a more faithful reflection of  algebraic de Rham
cohomology over $\C_p$.
More precisely,
let $\cO$ and $\Omega^1$ denote the  structure sheaf and
the sheaf of differentials on $X$.
The restrictions of these sheaves to $\cA$ and to $\cW_\epsilon$, viewed as rigid analytic
sheaves, are denoted by the same symbols by a slight abuse of notation. If $K$ is any complete
subfield of $\C_p$ we will denote by $\Omega^1(\cW_\epsilon/K)$ the rigid differentials on $\cW_\epsilon$
that are defined over $K$.
Set
$$ H^1_{\rig}(\cW_\epsilon/K) := \frac{\Omega^1(\cW_\epsilon/K)}{ d \cO_{\cW_\epsilon/K} }.$$
Note that, because $X'$ is affine, we have $H^1_{\dR}(X'/K) =  \frac{\Omega^1(X'/K)}{ d \cO_{X'}}.$
The natural restriction map $\Omega^1(X'/K) \lra \Omega^1(\cW_\epsilon/K)$
sends exact forms to exact forms and therefore induces a map
$$ \cmp_\epsilon: H^1_{\dR}(X'/K) \lra H^1_{\rig}(\cW_\epsilon/K).$$
For each annulus $\cV_1,\ldots, \cV_s$ appearing in the definition of $\cW_\epsilon$, let
$$ \res_{\cV_j}: \Omega^1(\cW_\epsilon/K) \lra K(-1)$$
denote the $p$-adic annular residue, as it is described in
\cite[Ch.\,7]{coleman-bu} for example. 


The annular  residue vanishes on $d\cO_{\cW_\epsilon}$,
and is therefore well-defined on cohomology.
It is related to the usual residue of algebraic differential forms through the following commutative  diagram:
\begin{equation}\label{res-dia}
\xymatrix{
H^1_{\dR}(X'/K) \ar[rr]^{\oplus_j \res_{\tilde P_j}} \ar[d]^{\cmp_\epsilon} & &
K(-1)^s \ar[r]^{\Sigma} \ar@{=}[d]  &
K(-1) \ar[r] \ar@{=}[d] &
0  \\
H^1_{\rig}(\cW_\epsilon/K) \ar[rr]^{\oplus_j \res_{\cV_j}} &  &
K(-1)^s \ar[r]^{\Sigma} &
K(-1) \ar[r] & 0. }
\end{equation}
\begin{proposition}
\label{prop:alg-to-rigid}
For any $\epsilon>0$,
the map $\cmp_\epsilon$ is an
isomorphism of $K$-vector spaces.
\end{proposition}
\begin{proof}
This follows as in \cite{coleman-bu}
 from the long exact Mayer-Vietoris sequence (cf.~A.2. of
loc.cit. for instance) associated to the admissible covering
of $X$ by wide open subsets  consisting of 
$\cW_\epsilon$  together with the $p$-adic residue discs in the complement of $\cA$.
\end{proof} 

Thanks to this proposition, the de Rham cohomology $H^1_{\dR}(X_K)$ of the base change of $X$ to $K$
can be identified with the
space of classes of rigid analytic forms on $\cW_\epsilon$ over $K$ with
vanishing annular residues (cf.\,e.g.\,\cite[Prop.\,4.11]{BDP1}).
%,  via the diagonal map  in the
%following commutative diagram  with exact rows:
%$$ \xymatrix{
%0 \ar[r]  &
%H^1_{\dR}(X_K)  \ar@{^{(}.>}[dr]_j \ar[r] &
%H^1_{\dR}(X'/K) \ar[rr]^{\oplus_j \res_{\tilde P_j}} \ar@{=}[d] & &
%K^s \ar[r]^{\Sigma} \ar@{=}[d]  &
%K \ar[r] \ar@{=}[d] &
%0  \\
% &
%&
%H^1_{\rig}(\cW_\epsilon/K) \ar[rr]^{\oplus_j \res_{\cV_j}} &  &
%K^s \ar[r]^{\Sigma} &
%K \ar[r] & 0. }
%$$
This  description of $H^1_{\dR}(X_K)$
is the basis for a  concrete description of the action of
the  Frobenius operator on de Rham cohomology.
Let $\sigma\in \Gal(\bar K/\Q_p)$ be a Frobenius automorphism and
let
$$ \Phi:\cA \lra \cA$$
be any characteristic zero lift of the Frobenius morphism on the special fiber
$\tilde{X}'$. This rigid analytic morphism extends to a
 morphism $\Phi: \cW_{\epsilon } \lra \cW_{\epsilon'},$
for suitable $0< \epsilon < \epsilon'$,
and induces 
%$\sigma$-semi
linear maps
$$ \Phi: \cO(\cW_{\epsilon'}/K) \lra \cO(\cW_{\epsilon}/K), \qquad
\Phi: \Omega^1(\cW_{\epsilon'}/K) \lra \Omega^1(\cW_{\epsilon}/K).$$
Although the  operator $\Phi$  need not  preserve any of the spaces
$\Omega^1(\cW_{\epsilon}/K)$ for a given fixed $\epsilon$, 
it does give rise to an endomorphism on $H^1_{\dR}(X'/K)$,
which shall also be denoted $\Phi$ by abuse of notation.
This Frobenius morphism  is thus
the unique endomorphism of $H^1_{\dR}(X'/K)$ that
completes  the top row in the  following commutative
diagram:
\begin{equation}
\label{eqn:Phi-wt2}
\xymatrix{
H^1_{\dR}(X'/K) \ar@{.>}[r]^\Phi \ar@{=}[d]^{\cmp_{\epsilon'}} & H^1_{\dR}(X'/K) \ar@{=}[d]^{\cmp_{\epsilon }} \\
H^1_{\rig}(\cW_{\epsilon'}/K) \ar[r]^\Phi & H^1_{\rig}(\cW_{\epsilon }/K). }
\end{equation}
The endomorphism $\Phi$, which is compatible with the annular
residue in the obvious sense,  preserves the subspace
$H^1_{\dR}(X_K)$.


The $K$-vector subspace of $H^1_{\dR}(X_K)$ (resp.~ of
$H^1_{\dR}(X'/K)$) spanned by the vectors
on which $\Phi$ acts via multiplication
by a $p$-adic unit is called the {\em unit root subspace}
and is denoted by $H^1_{\dR}(X_K)^{\ur}$ (resp.~
by $H^1_{\dR}(X'/K)^{\ur}$).
More generally, the subspaces spanned by vectors on which
$\Phi$ acts with slope $t\in\Q$ (i.e., as multiplication by a scalar
$\lambda\in\C_p^\times$ with $\ord_p\lambda = t$) is called the
{\em slope $t$ subspace} of $H^1_{\dR}(X_K)$ and is denoted
$H^1_{\dR}(X_K)^{\Phi,t}$.

The de Rham cohomology $H^1_{\dR}(X_K)$ is equipped with the usual alternating
Poincar\'e duality
$$\langle\ ,\ \rangle: H^1_{\dR}(X_K)\times H^1_{\dR}(X_K) \lra
H^2_{\dR}(X_K) = K(-1),$$
which
in terms of
representatives $\omega_1,\omega_2\in \Omega^1_{\rig}(\cW_\epsilon)$
for  cohomology classes $\xi_1$ and $\xi_2$
is described by the formula
$$ \langle \xi_1,\xi_2\rangle
= \sum_{j=1}^s \res_{\cV_j} (F_{\omega_1}^{(j)}\cdot\omega_2),$$
where $\res_{\cV_j}$ is the $p$-adic annular residue and $F_{\omega_1}^{(j)}$
denotes a local analytic primitive of $\omega_1$ on the annulus $\cV_j$.

Poincar\'e duality is compatible with the
Frobenius endomorphism in the sense that
$$ \langle \Phi \xi_1,\Phi \xi_2\rangle =
\Phi\langle \xi_1,\xi_2\rangle = p \langle \xi_1,\xi_2\rangle.$$
In particular,
Poincar\'e duality descends to a well-defined non-degenerate pairing
\begin{equation}
\label{eqn:pd-slope}
\langle\ ,\ \rangle:  H^1_{\dR}(X_K)^{\ur}  \times
H^1_{\dR}(X_K)^{\Phi,1} \lra K(-1).
\end{equation}


\subsection{$p$-adic modular forms}
\label{KatzKassaei}

Denote by $S_k^{(p)}(N)$ the space of
  $p$-adic modular forms of weight $k$    and  tame level $N$ 
  (as defined in 
  \cite{serre-padic} or \cite{katz}  for example)
and let
$S_k^{\oc}(N)$ denote its subspace of {\em overconvergent forms}.
These spaces are equipped with two non-commuting operators
$U$ and $V$,  defined on $q$-expansions by the rule
\begin{equation}
\label{eqn:defUV}
 (Uf)(q) = \sum_{n=1}^\infty a_{pn} q^n, \qquad
(Vf)(q) = \sum_{n=1}^\infty a_n q^{pn}.
\end{equation}
These operators satisfy
$$  UV f = f, \qquad
VUf (q)  = \sum_{n=1}^\infty a_{np} q^{np}, $$
so that
\begin{equation}
\label{eqn:deffppp}
 f^{[p]} :=   (1-VU)f(q) = \sum_{p\nmid n} a_{n} q^{n} 
 \end{equation}
has fourier coefficients supported on the integers prime to $p$.
Note  that the operators $U$ and $V$ do not commute--although, as we will explain later,
the  operators induced
on the cohomology  of modular curves (with coefficients in the relevant
local systems)  {\em do} commute, and are inverse to each other.

The operator $U$ on the $p$-adic Banach space of overconvergent modular forms
is completely continuous and gives rise to a slope decomposition on this
infinite-dimensional vector
space.   A $p$-adic modular form which belongs to the slope $0$
subspace for $U$ is said to be {\em ordinary}, and the space
of all such $p$-adic modular forms is denoted by
$S_k^{\ord}(N)$.  The ordinary subspace
(like all the   finite slope subspaces) is finite-dimensional
over $\C_p$.
More precisely, Coleman's classicality
theorem (cf. \cite{coleman-classical-overconvergent})
 asserts that any ordinary overconvergent modular form of weight $k\ge 2$
is (the $p$-stabilisation of) a classical modular form of weight $k$ on
$\Gamma_1(N)$. In particular,
$S_k^{\ord}(N)$  is naturally contained in the space
$S_k(\Gamma_1(N)\cap \Gamma_0(p))$ of classical modular forms (with fourier coefficients
in $\C_p$). 
Hida's ordinary projector
\begin{equation}
\label{eqn:hida-projector}
e_{\ord} := \lim_n U^{n!} 
\end{equation}
gives a   Hecke-equivariant
projection from $S_k^{\oc}(N)$ 
to  $S_k^{\ord}(N)$.

Let $\cX_1(N)$ denote the modular curve over
$\spec(\Z[1/N])$ classifying generalised elliptic curves
equipped with an embedding of the finite flat group scheme $\mu_N$ of $N$-th roots of unity. (See \cite{PaymanPhD} for a more general scenario.)

%{\bf There will be no problem at all here to discuss Shimura curves on the same footing}. Indeed, we just have to consider $X_1^D(N)$ for any square-free integer $D$ with an even number of prime factors and relatively coprime with $N$.

%Briefly explain that Kassaei also constructs a line bundle $\uomega_{\cE/X}$ over any Shimura curve such that the space of $p$-adic overconvergent modular forms of integral weight $k$ on $X$ can be defined exactly in the same manner.  Note that although we introduce $\cE/X$ as the universal genus two curve instead of the universal abelian surface $\mathcal A/X$, we have $H^1(\cE/X)=H^1(\cA/X)$ and  therefore Kassaei's construction remains intact.

Recalling that the prime $p$  does not divide $N$,   set
$$\cX := \cX_1(N) \times_{\spec \Z[1/N]} \Z_p, \quad X=\cX \times \spec(\Q_p)$$
for the smooth curve over $\Z_p$ (resp. over $\Q_p$) obtained by change of base.

Let $P_1,\ldots,P_s\in \tilde{X}(\F_{p^2})$ denote the
supersingular points of the special
fiber of $\cX$.  These points are the zeroes of a distinguished
mod $p$ modular form of weight $(p-1)$---the
so-called {\em Hasse invariant}.
As in the previous section, we may choose
lifts $\tilde P_1,\ldots, \tilde P_s\in \cX(\Z_{p^2})$
of the supersingular points
to characteristic zero.
For example, when $p\ge 5$, one may do this  by taking the zeroes
of the Eisenstein series $E_{p-1}$,  which is the customary lift of the Hasse
invariant to characteristic $0$.
We continue to write 
$$\cX' = \cX-\{ \tilde P_1,\ldots, \tilde P_s\} $$
for  the  resulting affine scheme
over $\spec(\Z_p)$, whose special and generic fiber are denoted
$\tilde{X}'$ and $X'$ respectively. The connected affinoid
region obtained by deleting from $X(\C_p)$ the $s$ disjoint
supersingular residue discs:
$$  \cA= \cA_{\ord} :=  \red^{-1}(\tilde{X}'(\bar\F_p))$$
is called
the  {\em ordinary locus}, or {\em Hasse domain}, in
$X(\C_p)$.
Note that
\begin{equation}
\label{eqn:defW0}
\cA =\{ x\in X(\C_p) \mbox{ with } \ord_pE_{p-1}(x) =0 \},
\end{equation}
where
$$ \ord_p E_{p-1}(x) := \ord_p E_{p-1}(A_x,\omega_x),$$
and
\begin{enumerate}
\item
$A_x$ is the generalised elliptic curve with $\Gamma_1(N)$-structure attached to $x$ by the moduli interpretation
of $X$;
\item $\omega_x\in \Omega^1(A_x/\C_p)$ is a regular differential on $A_x$, chosen
so that it extends to a regular differential over
$\cO_{\C_p}$ if $A_x$ has good reduction at $p$, or corresponds to the canonical differential on the Tate curve if
$x$ lies in the residue disc of a cusp.
\item The notation $E_{p-1}(A_x,\omega_x)$ follows
Katz's geometric definition of modular forms as functions on such
pairs, as described in \cite[Ch.\,1]{katz}, for example.
\end{enumerate}
While $E_{p-1}(A_x,\omega_x)$  genuinely depends on the choice of $\omega_x$,  its $p$-adic valuation
is independent of it since any two  such choices
differ by multiplication by an element of $\cO_{\C_p}^\times$.



Define  a system of
wide open neighborhoods  of $\cA$  by choosing
a real parameter $\epsilon>0$ and setting
$$ \cW_\epsilon := \{ x\in X(\C_p) \mbox{ with } \ord_p E_{p-1}(x) < \epsilon \}.$$
When
$0<\epsilon<1$, the region $\cW_\epsilon$ does not depend
on the choice of lift of the Hasse invariant to characteristic zero.
As suggested by (\ref{eqn:defW0}),
the quantity $\ord_p E_{p-1}(x)$ is (at least,
when it is not too large)  a sensible
measure of the ``degree of supersingularity" of the elliptic curve $A_x$ associated to $x$.  If $\ord_pE_{p-}(x)<\frac{p}{p+1}$, Katz has shown that the elliptic curve $A_x$,
although supersingular at $p$,
continues to  admit a {\em canonical subgroup} $Z_x$,
a connected subgroup scheme of
$A_x$  of order $p$ generalising the canonical subgroup on an
ordinary elliptic curve.
This makes it possible to choose a {\em canonical} lift to characteristic
zero of the Frobenius morphism, by setting, for all $x\in\cW_\epsilon$
with $\epsilon<\frac{p}{p+1}$,
\begin{equation}
\label{eqn:canonical-phi}
 \Phi(x) =  \mbox{ Point corresponding to } A_x/Z_x.
 \end{equation}
The affinoid $\cA$ and the wide opens $\cW_\epsilon$
play a key role in Katz's geometric description of
$p$-adic and overconvergent  modular forms, which we will now briefly recall.



\medskip\noindent
{\bf Modular forms of weight two}. 
We begin with 
the somewhat simpler case of forms of weight $k=2$, which can be treated by specialising
 the discussion of Section \ref{wideopens}
to the case 
where  $X=X_1(N)$ with $p\nmid N$, so that $X$ has good reduction at $p$.
For any complete subfield $K$ of $\C_p$ we have 
\begin{equation}\label{oc-k2}
S_2^{(p)}(N;K) = \Omega^1_{\rig}(\cA/K), \qquad
S_2^{\oc}(N;K) = \bigcup_{ \epsilon>0} \Omega^1_{\rig}(\cW_\epsilon/K),
\end{equation}
that is to say, 
the  space of rigid sections of $\Omega^1(\cW_\epsilon/K)$ is identified with
the $p$-adic Banach space of
overconvergent modular forms of weight two with ``annuli of
convergence of width $\epsilon$", and fourier coefficients in $K$.
Under this identification, a weight two modular form $f$ with
$q$-expansion $f(q) = \sum_n a_n(f) q^n$ corresponds to the differential
$$\omega_f=f(q) \frac{dq}{q}  =\left(\sum_{n=1}^\infty a_n(f) q^n\right) \frac{dq}{q}.$$
 By definition of the operators $U$ and $V$,
 \begin{equation}
\label{eqn:primitive-of-f}
f^{[p]}(q) = (1-VU)f(q) = q\frac{d}{dq}F,  \qquad \mbox{where }\quad
 F(q) =\sum_{p\nmid n} \frac{a_n(f)}{n}q^n.
\end{equation}
The modular form $F(q)$ is an overconvergent modular form
of weight $0$ and level $N$,
i.e., an element of $\cO_{\cW_\epsilon}$ for a suitable $\epsilon>0$.
It corresponds to the rigid analytic primitive of $ \omega_{f^{[p]}}$ which vanishes at the cusp
$\infty$, i.e., it is determined by the properties
$$ d F =  f^{[p]}(q) \frac{dq}{q}, \qquad F(\infty) = 0.$$

Define $S_2^{\oc}(N;K)_0$ to be the subspace of $S_2^{\oc}(N;K)$
consisting of overconvergent modular forms with coefficients in $K$ and vanishing residues at the supersingular annuli. Set also $S_2^{\ord}(N;K)_0 = S_2^{\oc}(N;K)_0\cap S_2^{\ord}(N;K)$
and write $\phi^{\ord}:= e_{\ord} \phi$ for the ordinary projection of an overconvergent modular form.

\begin{lemma}
\label{lemma:compUPhi}
If $\phi$ is an overconvergent $p$-adic modular form of weight two
on $\Gamma_1(N)$, then the class of $\omega_\phi$ belongs to
$H^1_{\rig}(\cW_{\epsilon})^{\Phi,1}$. Furthermore, the assignment $\phi\mapsto [\omega_\phi]$ 
induces
isomorphisms 
$$S_2^{\ord}(N;K)\overset{\sim}{\lra} H^1_{\rig}(\cW_\epsilon/K)^{\Phi,1},\qquad
S_2^{\ord}(N;K)_0 \overset{\sim}{\lra} H^1_{\dR}(X_K)^{\Phi,1}.$$

\end{lemma}
\begin{proof}
The Frobenius morphism
$\Phi:\Omega^1(\cW_\epsilon) \lra \Omega^1(\cW_{\epsilon/p})$
is related to
the operator $V$ on overconvergent modular forms of weight two by $\Phi (\omega_f) = p \omega_{Vf}.$
The relation between the operators $U$ and $\Phi$ on
cohomology (relative to the
identifications described above between differentials and
weight two modular forms) is therefore
given by
$$ \Phi = p V = pU^{-1}.$$
Hence, if $\phi$ belongs to the slope zero subspace
for the action of $U$,  the class
of the rigid  differential $\omega_\phi$  lies in
the slope one
subspace  $H^1_{\rig}(\cW_\epsilon)^{\Phi,1}$ for the action of $\Phi$.
The first statement follows. The second is a well-known result of Coleman: cf.~the cases $k=0$ of
Cor.~6.3.1.  and Prop.~6.6 
of \cite{coleman-classical-overconvergent} for the injectivity and surjectivity respectively
of the maps induced by restriction.
\end{proof}

\begin{proposition}
\label{prop:depends-on-ord}
For any class $\eta\in H^1_{\dR}(X_K)^{\ur}$ and any overconvergent modular form
$\phi\in S_2^{\oc}(N;K)_0$, we have
$$ \langle \eta,\omega_\phi\rangle = \langle \eta, \omega_{\phi^{\ord}}\rangle,$$
and Poincar\'e duality induces a 
well-defined non-degenerate pairing
$$ \langle\ ,\ \rangle: H^1_{\dR}(X_K)^{\ur} \times S_2^{\ord}(N;K)_0  \lra K.$$
\end{proposition}
\begin{proof}
This follows directly  from
Lemma \ref{lemma:compUPhi} in light of
\eqref{eqn:pd-slope}.
\end{proof}




\medskip\noindent
{\bf Modular forms of  higher weight}.
Turning now to the case of forms of general weight $k\ge 2$,
let $\cE\lra Y$ denote the universal elliptic curve
over the affine modular curve $Y=Y_1(N)/\Q$. Let
$ \uomega :=\pi_* \Omega^1_{\cE/Y}$ denote the line bundle of relative differentials on $\cE$ over $Y$.
It extends to a sheaf over $X=X_1(N)$,  also denoted by $ \uomega$, by setting 
$$H^0(\spec\Q[[q]], \uomega) = \Q[[q]]\cdot \omega_{\can},$$
where $\omega_{\can}:=\frac{dt}{t}$ is the canonical differential  on the Tate curve $\G_m/q^\Z$. 

Let $\Omega^1_X(\log\cusps)$ be the sheaf of differentials $1$-forms on X with logarithmic poles at the cusps,
for which 
$$
H^0(\spec\Q[[q]],\Omega^1(\log\cusps)) = \Q[[q]]\cdot \frac{dq}{q}.
$$

A modular form $\phi$ on $X$ of weight $k=r+2$  with fourier coefficients in a field $K$
(viewed as a function on ``test objects" $(E,\omega_E)$, following the point of view adopted 
in \cite[Ch.\,1]{katz} for example) 
corresponds to a global section of the sheaf
$\underline{\omega}^{r+2} $ over $X_K$, by sending $\phi$ to the global section $
\phi(E,\omega_E) \omega_E^{r+2},$ 
and hence we can define
$$ 
M_k(N;K) = 
H^0(X_1(N)_K,\underline{\omega}^{k}). $$
Let
$$ \cL:= {\mathbb R}^1 \pi_\ast \Omega^{\text{\tiny{\textbullet}}}_{\cE/Y}$$
be the relative de Rham cohomology sheaf on $Y$. It is equipped with a
filtration
\begin{equation}
\label{eqn:hodge-fil-fibers}
0 \lra  \uomega  \lra \cL \lra \underline{\omega}^{-1} \lra 0
\end{equation}
arising from the Hodge filtration on the  fibers.
The sheaf $\cL$ and its $r$-th symmetric power
$$ \cL_r := \sym^r \cL$$
are vector bundles over $Y$ (of rank $2$ and $r\!+\!1$ respectively)
endowed with a canonical  integrable connection:
$$ \nabla: \cL_r \lra \cL_r\otimes \Omega^1_X(\log \cusps), $$
the so-called {\em Gauss-Manin connection}.
The sheaf $\cL_r$ extends to a sheaf on $X$ by setting 
\begin{equation}
\label{eqn:def-eta-can}
 H^0(\spec\Q[[q]], \cL_r) = \Q[[q]] \eta_{\can}^r + \Q[[q]] \eta_{\can}^{r-1}\omega_{\can} + \cdots + \Q[[q]] \omega_{\can}^r,
 \end{equation}
 where $\eta_{\can} := \nabla(q\frac{d}{dq})(\omega_{\can})$ is a complementary vector
 to $\omega_{\can}$ in $H^1_{\dR}(\cE/\Z[[q]])$,
 and similarly at the other cusps of $X$. The connection $\nabla$ extends by setting
\begin{equation}
\label{eqn:nabla-can}
 \nabla \omega_{\can} = \eta_{\can}\otimes \frac{dq}{q}, \qquad 
 \nabla \eta_{\can} =0.
 \end{equation}

The filtration \eqref{eqn:hodge-fil-fibers} gives rise to an $(r\!+\!1)$-step
decreasing filtration on $\cL_r$, with successive quotients 
\begin{equation}\label{successive}
\cL_r /\Fil^1\cL_r  \simeq \underline{\omega}^{-r}, \cdots,
\Fil^{r-j}\cL_r /\Fil^{r-j+1}\cL_r \simeq \underline{\omega}^{r-2j}, \cdots,
\Fil^{r}\cL_r \simeq \underline{\omega}^r.
\end{equation}

 The connection $\nabla$ obeys  Griffiths transversality:
$$ \nabla \Fil^{r-j} \cL_r \subset \Fil^{r-j-1} \cL_r\otimes \Omega^1_X(\log \cusps).$$
Furthermore, it
induces an isomorphism of $\cO_X$-modules:
\begin{equation}
\label{eqn:nabla-isom}
\nabla:\frac{\Fil^{r-j} \cL_r}{\Fil^{r-j+1}\cL_r} \simeq
 \frac{\Fil^{r-j-1}\cL_r}{\Fil^{r-j}\cL_r}\otimes\Omega^1_X(\log \cusps),
 \end{equation}
which gives rise (by setting $r=1$ and $j=0$ for example) to 
the {\em Kodaira-Spencer isomorphism} 
$$ \KS:  \underline{\omega}^{\otimes 2} \stackrel{\sim}{\lra} \Omega^1_X(\log\cusps).$$
It follows that a modular form $\phi$ of weight $r+2$
can be interpreted, via this isomorphism, as a global section of $\underline{\omega}^r\otimes \Omega^1_X(\log\cusps)$, while a cusp form can be interpreted as a global
section of $\underline{\omega}^r\otimes \Omega^1_X$, i.e.,
$$ S_k(N;K) = H^0(X_K,\underline{\omega}^r\otimes \Omega^1_X).$$
At a geometric point  of $X$ attached  to 
an elliptic curve $E$ with $\Gamma_1(N)$-level structure, 
the section $\omega_\phi$ is given   by
$$ \omega_\phi = \phi(E,\omega_E) \omega_E^r \KS(\omega_E^2).$$
At the test object $(\G_m/q^\Z, \omega_{\can})$ corresponding to  the Tate curve with its canonical
differential, this leads to the formula for  $\omega_\phi$ in terms of the $q$-expansion of $\phi$:
$$\omega_\phi(q) = \phi(q) \omega_{\can}^r  \left(\frac{dq}{q}\right).$$
 Let $(\cL_r\otimes\Omega^1_X)_{\mathrm{par}}$ denote the subsheaf 
 of $\cL_r\otimes\Omega^1(\log\cusps)$ defined in the neighborhood of the cusps by
\begin{eqnarray*}
 H^0(\spec \Q[[q]],(\cL_r\otimes\Omega^1_X)_{\mathrm{par}}) &=&  \nabla H^0(\spec \Q[[q]],\cL_r) 
 \\ &=& 
 (\Q[[q]] \eta_{\can}^r + \Q[[q]]\eta_{\can}^{r-1}\omega_{\can} + \cdots + q\Q[[q]]\omega_{\can}^r) \frac{dq}{q}.
 \end{eqnarray*}
Note that for $r=0$ we have $(\cL_r\otimes\Omega^1_X)_{\mathrm{par}}=\Omega^1_X$. A standard inductive argument using \eqref{eqn:nabla-isom} shows that the natural inclusion
$\underline{\omega}^r \lra \cL_r$ induces an isomorphism
\begin{equation}
\label{eqn:forms-to-sections}
 H^0(X_K, \underline{\omega}^r \otimes \Omega^1_X) \simeq \frac{H^0(X_K,(\cL_r\otimes \Omega^1_X)_{\mathrm{par}})}{\nabla H^0(X_K,\cL_r)}.
 \end{equation}
We write
$$ H^j_{\dR}(X_K,\cL_r,\nabla) := {\mathbb H}^j(0\rightarrow \cL_r \stackrel{\nabla}{\lra}
 \cL_r\otimes \Omega^1_X(\log\cusps)\rightarrow 0)$$
for the $j$-th hypercohomology of the complex of sheaves on $X$ over $K$
associated to $\nabla$, and 
$H^j_{\para}(X_K,\cL_r,\nabla)$ for the {\em parabolic cohomology}:
$$H^j_{\para}(X_K,\cL_r,\nabla) := {\mathbb H}^j(0 \rightarrow \cL_r \stackrel{\nabla}{\lra}
(\cL_r\otimes\Omega^1_X)_{\mathrm{par}} \rightarrow 0).$$
(Cf. also 
Chapter 2.1 of \cite{BDP1} for example.)
These algebraic de Rham cohomology groups are finite-dimensional $K$-vector spaces.
The group $H^1_{\para}(X_K,\cL_r,\nabla)$ is
equipped with a two-step Hodge filtration given by
\begin{equation}
\label{eqn:hodge-k}
\Fil^j H^1_{\para}(X_K,\cL_r,\nabla) = \left\{
\begin{array}{ll}
H^1_{\para}(X_K,\cL_r,\nabla) & \mbox{ if } j \le 0;\\
H^0(X_K,\uomega^r\otimes \Omega^1_X)  & \mbox{ if } 1\le j \le r+1;\\
0 & \mbox{ if } j \ge r+2,
\end{array}\right. 
\end{equation}
giving rise to the exact sequence
\begin{equation}
\label{eqn:hodge-filtration-k}
 0 \lra H^0(X_K,\underline{\omega}^r\otimes \Omega^1_X) \lra  H ^1_{\para}(X_K,\cL_r,\nabla) \lra
H^1(X_K,\underline{\omega}^{-r}) \lra 0.
\end{equation}
We note the Poincar\'e duality pairing
\begin{equation}
\label{eqn:pd-wtk}
 \langle \ , \  \rangle:
H^1_{\para}(X_K,\cL_r,\nabla) \times H^1_{\para}(X_K,\cL_r,\nabla) \lra K(-1-r).
\end{equation}
Since $H^0(X_K,\underline{\omega}^r\otimes \Omega^1_X)$ is its own orthogonal complement under \eqref{eqn:pd-wtk},
Poincar\'e duality descends to a perfect pairing
\begin{equation}
\label{eqn:pp-descended}
 \langle \ ,\ \rangle: H^1(X_K,\underline{\omega}^{-r})\times H^0(X_K,\underline{\omega}^r\otimes \Omega^1_X) \lra K(-1-r),
 \end{equation}
which is denoted by the same symbol by a slight abuse of notation. 

In the sequel, if $\cL$ is a local system on a variety $V$, endowed with an integrable connection $\nabla$ that is clear from the context, we shall write $H^\star(V,\cL)$ instead of $H^\star(V,\cL, \nabla)$, and likewise for similar cohomology groups. 


\subsection{Nearly holomorphic modular forms and the Shimura-Maass derivative}
\label{sec:nearly-holomorphic}
Suppose now that $K=\C$. 
Hodge theory gives  a  canonical  (real-analytic, but non-holomorphic)  splitting  
$$ \spl_{\hdg}: \cL\lra \underline{\omega}$$
of the exact sequence
\eqref{eqn:hodge-fil-fibers} over the affine modular curve $Y$. This map can be viewed as a homomorphism
of $\cO_{Y(\C)_{\an}}$--modules, where $\cO_{Y(\C)_{\an}}$ is the structure sheaf of
real analytic functions on $Y(\C)$. 
We will also denote by the same symbol the associated map
$\cL^k \lra \underline{\omega}^k$, as well as the resulting map
\begin{equation}
\label{eqn:hodge-splitting}
 \spl_{\hdg}: H^0(X_\C,(\cL_r\otimes\Omega^1_X)_{\mathrm{par}}) \lra  H^0(Y(\C)_{\an},\underline{\omega}^{r}\otimes \Omega^1_X)
 \end{equation}
 restricted to regular (i.e., holomorphic) sections over $X$ of the sheaf
  $(\cL_r\otimes\Omega^1_X)_{\mathrm{par}}$.
      \begin{definition}
The image of $\spl_{\hdg}$ is called the space of {\em nearly holomorphic cusp
forms} of weight $k =r+2$ on $\Gamma_1(N)$. 
\end{definition}
Nearly holomorphic cusp forms were  introduced in \cite{Sh86}; see also \cite[Ch.\,10]{hida-book} for a more elementary description.
The space of nearly holomorphic cusp forms on
$\Gamma_1(N)$  is denoted by $S_{k}^{\nh}(N;\C)$. It is contained in the space of real analytic functions on the upper half plane which satisfy 
the same transformation property under $\Gamma_1(N)$
 as (holomorphic) modular forms of weight $k$.
 The following basic facts about nearly holomorphic modular forms, which we recall without proof, will be useful in the sequel:
\begin{enumerate}
\item[(i)] The map $\spl_{\hdg}$ of \eqref{eqn:hodge-splitting} is injective, and hence induces an isomorphism of finite-dimensional complex vector spaces:
$$ \spl_{\hdg}: H^0(X_\C,(\cL_r\otimes \Omega^1_X)_{\mathrm{par}}) \stackrel{\sim}{\lra} 
S_{k}^{\nh}(N;\C).$$
(Cf. equation (5a) in \S10.1 of \cite{hida-book}.)
\item[(ii)]
If $K$ is any subfield of $\C$, the image of $H^0(X_K,(\cL_r\otimes \Omega^1_X)_{\mathrm{par}})$ under
$\spl_{\hdg}$ yields a natural $K$-structure on $S_{k}^{\nh}(N;\C)$, and is denoted by
$S_{k}^{\nh}(N;K)$. 
\item[(iii)]   If $\phi= \spl_{\hdg}(\omega_\phi)$ belongs to $S_{k}^{\nh}(N;K)$, then equation \eqref{eqn:forms-to-sections}    allows us to write
\begin{equation}
\label{eqn:holomorphic-projection}
 \omega_\phi = \Pi_N^{\hol}(\phi) + \nabla s, \quad \mbox{ with }
\left\{ \begin{array}{l} 
 \Pi_N^{\hol}(\phi) \in H^0(X_K,\underline{\omega}^r\otimes\Omega^1_X) = S_{k}(N;K), \\
  s\in H^0(X_K,\cL_r). \end{array}\right. 
  \end{equation}
The modular form $\Pi_N^{\hol}(\phi)$ is called the {\em holomorphic projection} of 
the nearly holomorphic modular form $\phi$. (Cf. equation (8a) in \S 10.1 of \cite{hida-book}; the fact that $\Pi_N^{\hol}$, which is denoted by $H$ in loc. cit., preserves $K$-rational structures 
is stated in (8b).) 
\item[(iv)]   The   inverse of the Kodaira-Spencer isomorphism followed by  the
Gauss-Manin connection  
 gives a 
well-defined map
\begin{equation}
\label{eqn:nabla-KS-def}
 \tilde \nabla: H^0(X_K,(\cL_r\otimes \Omega^1_X)_{\mathrm{par}}) \lra H^0(X_K,(\cL_{r+2}\otimes\Omega^1_X)_{\mathrm{par}}).
 \end{equation}
This map corresponds (under the identification $\spl_{\hdg}$) to the weight $k$ Shimura-Maass
derivative operator $\delta_{k} = \frac{1}{2\pi i}(\frac{d}{d z} + \frac{k }{z-\bar z})$, i.e., the following diagram commutes:
$$ \xymatrix{
H^0(X_K,(\cL_r\otimes \Omega^1_X)_{\mathrm{par}}) \ar@{->}[rr]^-{\spl_{\hdg}} \ar[d]_{\tilde\nabla} &  &S_k^{\nh}(N;K) \ar[d]^{\delta_k} \\
H^0(X_K,(\cL_{r+2}\otimes \Omega^1_X)_{\mathrm{par}}) \ar@{->}[rr]^-{\spl_{\hdg}} &  &S_{k+2}^{\nh}(N;K). }
$$
\end{enumerate}
This follows from a direct calculation based on the identities (in terms of the standard complex coordinates $\tau\in \cH$ and $z\in \C/\langle 1,\tau\rangle$)
$$ \nabla (2\pi i dz) = 2\pi i \left(\frac{dz-\bar dz}{\tau-\bar\tau}\right)\otimes d\tau, \qquad
\nabla \bar dz = 0, \qquad \KS( (2\pi i dz)^{\otimes 2}) = 2\pi i d\tau.$$

Since nearly holomorphic modular forms are closed under taking products and under applying
the Shimura-Maass derivative, it follows that, if $g\in S_\ell(N;K)$ and $h\in S_m(N;K)$  are classical cusp forms with fourier coefficients in $K$, then for all $t\ge 0$, 
the product $\delta_\ell^t g \times h$ belongs to $S_{\ell+m+2t}^{\nh}(N;K)$. 
More precisely,
let 
\begin{equation}
\label{eqn:def-section-gh}
 \tilde\nabla^t \omega_g \otimes \tilde\omega_h \in H^0(X_K,(\cL_{\ell+m+2t-2}\otimes\Omega^1_X)_{\mathrm{par}})
 \end{equation}
 be the global section obtained by tensoring the sections
 $$ \tilde\nabla^t\omega_g \in H^0(X_K,(\cL_{\ell+2t-2}\otimes\Omega^1_X)_{\mathrm{par}})
 \, \mbox{ and } \, \tilde\omega_h := \KS^{-1}(\omega_h) \in H^0(X_K,\cL_m).$$
 Then
\begin{equation}
\label{eqn:nh-form-is-algebraic}
 \delta_\ell^t g \times h = \spl_{\hdg}(\tilde\nabla^t \omega_g \otimes  \tilde\omega_h).
 \end{equation}


\medskip
Hodge theory gives a canonical splitting of the exact sequence 
\eqref{eqn:hodge-filtration-k}:
$$ H^1_{\para}(X_{\C},\cL_r) = H^0(X_{\C},\underline{\omega}^r\otimes \Omega^1_X) \oplus \overline{H^0(X_{\C},\underline{\omega}^r\otimes \Omega^1_X)}.$$

The Petersson scalar
product $( \,,\ )_N$ of level $N$ 
on $S_k^{\nh}(N;\C)$ 
is defined
 by the familiar rule
\begin{equation}
\label{Petersson-first}
( \, , \  )_N: S_k^{\nh}(N;\C)\times S_k^{\nh}(N;\C)\lra \C,
\qquad (f_1,f_2)_N =
\int_{\Gamma_1(N)\backslash \uhp} \overline{f_1(z)} \, f_2(z)\, y^{k} \frac{dx dy}{y^2},
\end{equation}
where the integration is performed relative to the variable $z=x+iy$ on any
fundamental domain in the upper-half plane $\uhp$ under the action
of $\Gamma_1(N)$.
Note that this pairing is Hermitian-linear in the first argument and $\C$-linear in the second,
in contrast with the more customary conventions. 
 \begin{lemma}
 \label{lemma:rule-H}
For all $\eta\in S_{r+2}(N;\C)$, 
and all $\phi\in S_{r+2}^{\nh}(N;\C)$, 
$$ (\eta,\phi)_N = (\eta, \Pi_N^{\hol}(\phi))_N.$$
\end{lemma} 
The equation of Lemma \ref{lemma:rule-H} gives an independent definition
of the holomorphic projection, since the Petersson product is a perfect 
pairing on the space $S_k(N;\C)$ of cusp forms.


\subsection{Nearly overconvergent modular forms and the $d$ operator}
 \label{sec:noc-mfs}
Recall the  ordinary locus $\cA$ and  its system of wide open 
neighborhoods $\cW_\epsilon\supset\cA$ that were introduced  in Section \ref{KatzKassaei}.
We define
\begin{equation}
\label{eqn:forms-to-sections-p}
H^1_{\rig}(\cW_\epsilon,\cL_r) := \frac{H^0(\cW_\epsilon,(\cL_r\otimes \Omega^1_X)_{\mathrm{par}})}
{\nabla H^0(\cW_\epsilon,\cL_r)},
\end{equation}
where $H^0(\cW_\epsilon,-)$ designates a space of rigid sections.
The quotient on the right of \eqref{eqn:forms-to-sections-p}
 is related to overconvergent cusp forms of weight $k=r+2$ by
noting that any rigid section  $\eta\in H^0(\cW_\epsilon,(\cL_r\otimes \Omega^1_X)_{\mathrm{par}})$ 
can be written as 
\begin{equation}
\label{eqn:omegar-rep}
\eta = \eta_0 + \nabla s, \qquad \mbox{ with } \eta_0 \in H^0(\cW_\epsilon, \uomega^r\otimes \Omega^1_X),
\quad s \in H^0(\cW_\epsilon,\cL_r). 
\end{equation}
This fact follows from an   inductive argument based on \eqref{eqn:nabla-isom}.

Similarly as in \eqref{oc-k2}, the spaces of overconvergent modular (cusp) forms of weight $k$ are
\begin{equation}\label{oc-k}
S_k^{\oc}(N;K) = \bigcup_{ \epsilon>0} H^0(\cW_\epsilon/K,\uomega^r\otimes \Omega^1_{\rig}) \subseteq M_k^{\oc}(\Gamma_1(N),K) = \bigcup_{ \epsilon>0} H^0(\cW_\epsilon/K,\uomega^k).
\end{equation}

It is also known (cf.\,\cite{coleman-classical-overconvergent}) that any overconvergent modular form of weight $-r$, viewed as a section
$s\in H^0(\cW_\epsilon,\uomega^{-r})$, admits a unique lift   
$\tilde s$   under the projection
$ H^0(\cW_\epsilon,\cL_r) \lra H^0(\cW_\epsilon,\uomega^{-r})$ induced by \eqref{successive}  satisfying
$$ \nabla \tilde s \in H^0(\cW_\epsilon, \uomega^r\otimes\Omega^1_X),$$
and that 
$\nabla \tilde s$ corresponds to the overconvergent modular form
$d^{r+1} s$, where $ d:= q\frac{d}{dq}$ is Serre's operator   sending $p$-adic 
modular forms of weight $m$ to $p$-adic modular forms of weight $m+2$. 
(Note  that the operator $d$ does not preserve overconvergence in general,
even though  $d^{r+1}$ maps  $S_{-r}^{\oc}(N)$ to 
$S_{r+2}^{\oc}(N)$.)
Thanks to  \eqref{eqn:omegar-rep}, equation \eqref{eqn:forms-to-sections-p} can be re-written  as
\begin{equation}
\label{eqn:forms-to-sections-p-bis}
H^1_{\rig}(\cW_\epsilon,\cL_r) = \frac{H^0(\cW_\epsilon,\uomega^r\otimes \Omega^1_X)}
{\nabla H^0(\cW_\epsilon,\cL_r) \cap H^0(\cW_\epsilon,\uomega^r\otimes \Omega^1_X) }
= \frac{S_{r+2}^{\oc}(N)}{d^{r+1} S_{-r}^{\oc}(N)}.
\end{equation}


Just as when $r=0$,  there is a canonical
isomorphism 
\begin{equation}\label{eqn:alg-to-rig-k}
H^1_{\para}(X'_{\C_p},\cL_r) = H^1_{\rig}(\cW_\epsilon,\cL_r)
\end{equation}
between the algebraic (parabolic) de Rham cohomology over $\C_p$ and the rigid
de Rham cohomology. As explained in \cite[\S\,4.5]{BDP1}, for each supersingular annulus $\cV_j$, $j=1,...,s$, there is a residue map 
\begin{equation}
\label{res-map}
\res: H^1_{\rig}(\cW_\epsilon,\cL_r) \lra (H^0(\cV_j,\cL_r)^{\nabla=0})^\vee\simeq \cL_r(P_j)\simeq \left(\Sym^r H^1_{\dR}(E_j)\right)(-1),
\end{equation}
where $E_j/\C_p$ stands for the supersingular elliptic curve corresponding to the point $\tilde{P}_j$.

By \cite[Prop.\,4.11]{BDP1}, the image of $H^1_{\para}(X_{\C_p},\cL_r)$ in $H^1_{\para}(X'_{\C_p},\cL_r)$ under the restriction map consists of those classes represented by $\cL_r$-valued differential forms $\omega$ on $\cW_\epsilon$ whose residues at the supersingular annuli $\cV_j$, $j=1,...,s$, are all zero. 

Over $\cA$, the slope decomposition arising from the action of Frobenius
 gives  a  canonical    splitting  
\begin{equation}
\label{eqn:spl-ur} 
 \spl_{\ur}: \cL\lra \underline{\omega}
 \end{equation}
of the exact sequence
\eqref{eqn:hodge-fil-fibers}. This map can be viewed as a homomorphism
of $\cO_{\cA}$-modules, where $\cO_{\cA}$ is the structure sheaf of
rigid analytic functions on $\cA$.  
We will also denote by the same symbol the associated map
$\cL^r \lra \underline{\omega}^r$, as well as the resulting map
\begin{equation}
\label{eqn:ur-splitting}
 \spl_{\ur}: \bigcup_{ \epsilon>0} H^0(W_\epsilon,(\cL_r\otimes\Omega^1_X)_{\mathrm{par}}) \lra  H^0(\cA,\underline{\omega}^r\otimes\Omega^1_X)
 \end{equation}
  on overconvergent sections. The image of $\spl_{\ur}$ is contained in the space of
  $p$-adic modular forms of weight $k=r+2$, and contains the space of overconvergent modular forms,  but  is not equal to it in general,
  because the splitting \eqref{eqn:spl-ur} 
    does not extend to a  rigid analytic splitting over any of the wide
  opens $\cW_\epsilon$. The following definition  arises naturally from our
  parallel  discussion of the complex-analytic setting.
\begin{definition}
The image of the map $\spl_{\ur}$ in \eqref{eqn:ur-splitting}, denoted $S_k^{\noc}(N;\C_p)$, 
is called the space of {\em nearly overconvergent} modular
forms of weight $k $ on $\Gamma_1(N)$. 
\end{definition}

We refer the reader to the forthcoming work \cite{Ur} of Urban, where this notion has also been introduced independently. 

Note that the weight of a nearly overconvergent modular form
always belongs to $\Z^{\ge 2}$, by definition.
 The following basic facts about nearly overconvergent modular forms are analogous to those
 that were observed  in the complex setting:
 \begin{enumerate}
\item[(i)] The map $\spl_{\ur}$ of \eqref{eqn:ur-splitting} is injective, and
   induces an isomorphism of $p$-adic Fr\'echet spaces:
$$ \spl_{\ur}: \bigcup_{\epsilon>0} H^0(\cW_\epsilon,(\cL_r\otimes\Omega^1_X)_{\mathrm{par}}) \stackrel{\sim}{\lra}S_{k}^{\noc}(N;\C_p).$$
This is a consequence of the main theorem of \cite{coleman-gouvea-jochnowitz},
which asserts that the $p$-adic modular form $E_2$ is transcendental over the ring of overconvergent modular forms.
\item[(ii)]
If $K$ is any subfield of $\C_p$, the image of
$\bigcup_{ \epsilon>0} H^0(W_\epsilon/K,(\cL_r\otimes\Omega^1_X)_{\mathrm{par}})$
under
$\spl_{\ur}$ yields a natural $K$-vector space $ S_{k} ^{\noc}(N;K)\subset S_{k}^{\noc}(N;\C_p)$.
\item[(iii)] 
Let $\phi=\spl_{\ur}(\omega_\phi)$ be an element of $S_{k}^{\noc}(N;\C_p)$, where
$\omega_\phi$  is a  global section of $(\cL_r\otimes \Omega^1_X)_{\mathrm{par}}$ over some $\cW_\epsilon$. 
 Equation  \eqref{eqn:omegar-rep} then allows us to write
 
 \begin{equation}
\label{eqn:overconvergent-projection}
 \omega_\phi = \Pi_N^{\oc}(\phi) + \nabla s, \quad \mbox{ with }
\left\{ \begin{array}{l} 
 \Pi_N^{\oc}(\phi) \in H^0(\cW_\epsilon,\underline{\omega}^r\otimes\Omega^1) = S_{k}^{\oc}(N;K), \\
  s\in H^0(\cW_\epsilon,\cL_r). \end{array}\right.  
  \end{equation} 
The overconvergent modular form $\Pi_N^{\oc}(\phi)$
of weight $k$ and level $N$ is  called the {\em overconvergent projection} of 
the nearly overconvergent modular form $\phi$. Note that $\Pi_N^{\oc}(\phi)$ is only
well-defined modulo $d^{r+1}(S_{-r}^{\oc}(N))$, by
  \eqref{eqn:forms-to-sections-p-bis}.  
  \item[(iv)]
If $K$ is a field equipped with
simultaneous embeddings into $\C$ and $\C_p$, then there are  natural identifications
$$
\xymatrix{
 S_k^{\nh}(N;K) & \ar[l]_-{\spl_{\hdg}}   H^0(X_K,(\cL_r\otimes\Omega^1_X)_{\mathrm{par}})
  \ar[r]^-{\spl_{\ur}}  & S_k^{\noc}(N;K).} 
  $$
It follows directly from the definitions that the holomorphic and overconvergent projections, restricted to 
$S_k^{\nh}(N;K)$ and $S_k^{\noc}(N;K)$ respectively,
take values in $S_k(N;K)$ and are equal (under the above identification of $S_k^{\nh}(N;K)$
and $S_k^{\noc}(N;K)$).
\item[(v)]   The  map $\tilde\nabla$ of  
\eqref{eqn:nabla-KS-def} 
 corresponds (under the identification $\spl_{\ur}$) to the operator $d = q\frac{d}{dq}$ on
 $p$-adic modular forms, i.e.,
   the following diagram commutes:
$$ \xymatrix{
\bigcup_{\epsilon>0} H^0(\cW_\epsilon,(\cL_r\otimes\Omega^1_X)_{\mathrm{par}}) \ar[rr]^-{\spl_{\ur}} \ar[d]_{\tilde\nabla} & & S_k^{\noc}(N;\C_p) \ar[d]_{d} \\
\bigcup_{\epsilon>0} H^0(\cW_\epsilon,(\cL_{r+2}\otimes\Omega^1_X)_{\mathrm{par}}) \ar[rr]^-{\spl_{\ur}} & & S_{k+2}^{\noc}(N;\C_p). }
$$
\end{enumerate}
A nearly overconvergent modular form admits a $q$-expansion, and hence Hida's ordinary projector $e_{\ord}$  of \eqref{eqn:hida-projector} extends formally to the space $S_k^{\noc}(N;\C_p)$.
The following lemma relates this ordinary projection to the
overconvergent projection $\Pi_N^{\oc}$. 
\begin{lemma}
\label{lemma:ordinary-oc}
Let $\phi$ be a nearly overconvergent modular form on 
$\Gamma_1(N)$. Its image under Hida's ordinary projector is overconvergent, and thus classical on $\Gamma_1(N)\cap \Gamma_0(p)$. More precisely,
\begin{equation}
\label{eqn:coleman-for-nearly-oc}
e_{\ord} \phi = e_{\ord} \Pi_N^{\oc}(\phi).
\end{equation}
\end{lemma}
\begin{proof}
If $s$ is any overconvergent section of 
$\cL_r$, then  a direct calculation using the relations \eqref{eqn:nabla-can} shows that
$$ \spl_{\ur}(\nabla s)  \mbox{ belongs to }    d (\C_p\otimes \cO_{\C_p}[[q]]) \cdot \omega_{\can}^r\otimes  \frac{dq}{q}.$$
But  $e_{\ord}$ annihilates the image under $d$ of any $q$-series with bounded denominators, so
\begin{equation}
\label{eqn:eordnabla0}
 e_{\ord}(\spl_{\ur}(\nabla s)) = 0.
 \end{equation}
Now write  
$ \phi = \spl_{\ur}(\omega_\phi)$, with $\omega_\phi$ a rigid section of 
$(\cL_{r}\otimes\Omega^1_X)_{\mathrm{par}}$ over some $\cW_\epsilon$. 
 By definition of the overconvergent projection, 
 $$ \omega_\phi =  \phi_0   + \nabla s \quad \mbox{ with } \phi_0 \in H^0(\cW_\epsilon,\underline{\omega}^r\otimes\Omega^1_X) \, \mbox{ and } \,
s\in H^0(\cW_\epsilon,\cL_r).$$

Applying the operator $\spl_{\ur}$ to this last identity gives $\phi = \Pi_N^{\oc}(\phi) +  \spl_{\ur}(\nabla s).$
The result now follows by applying $e_{\ord}$ and invoking
\eqref{eqn:eordnabla0}. 
\end{proof}

Let $g\in S_\ell(N;K)$ and $h\in S_m(N;K)$ be classical cusp forms defined over $K$,
and fix embeddings of $K$ into $\C$ and $\C_p$. The forms $g$ and $h$ can then   be regarded simultaneously as complex and overconvergent modular forms.
\begin{proposition}
\label{prop:hida-book}
\label{prop:dtgh-is-noc}
For all $t\ge 0$, the modular form $d^t g\times h$ belongs to 
$S_{\ell+m+2t}^{\noc}(N;K)$ and 
$$ e_{\ord} (d^tg \times h)  = e_{\ord}\Pi_N^{\hol}(\delta_\ell^t g\times h).$$
\end{proposition}
\begin{proof}
Recall the global section $\tilde\nabla^t \omega_g \otimes \tilde\omega_h \in
H^0(X_K,(\cL_{\ell + m + 2t-2} \otimes\Omega^1_X)_{\mathrm{par}})$ that was introduced in 
\eqref{eqn:def-section-gh}.
Since 
$$ d^t g \times h = \spl_{\ur}(\tilde\nabla^t \omega_g \otimes \tilde\omega_h),  \qquad 
\delta_\ell^t g \times h = \spl_{\hdg}(\tilde\nabla^t \omega_g \otimes \tilde\omega_h),$$
it follows that
$$ \Pi_N^{\oc}(d^t g \times h) = \Pi_N^{\hol}(\delta_\ell^t g \times h).$$
The proposition follows by applying the projector $e_{\ord}$ to this identity and invoking
 \eqref{eqn:coleman-for-nearly-oc}.
 \end{proof}
 
 We next turn to the case where the exponent appearing in Proposition
 \ref{prop:dtgh-is-noc} is {\em strictly negative}. 
 After replacing $g$ by its $p$-depletion $g^{[p]}\in S_k^{\oc}(N;\C_p)$, the
      form 
 $d^{-1-t}  g^{[p]} \times h$ (with $t\ge 0$) 
  is still a $p$-adic modular form of weight $k:=\ell + m -2t-2$. (Cf. 
  for instance Th\'eor\`eme 5 of \S 2 of \cite{serre-padic}.)
  The 
 following proposition shows that it is 
  nearly overconvergent, at least in certain cases where  $k \ge 2$.  
 \begin{proposition} 
 \label{prop:dtgh-bis}
  Assume that  $0\le t \le \min(\ell-2,m-2)$, so that   
  $k:=\ell+m-2t-2  \ge 2$. Then  the $p$-adic modular form  
 $d^{-1-t} g^{[p]}\times h$ belongs to $S_{k}^{\noc}(N;\C_p)$, and in particular
 $$ e_{\ord}(d^{-1-t} g^{[p]}\times h) \in S_k^{\ord}(N;\C_p)  \subset S_k(\Gamma_1(N)\cap\Gamma_0(p);\C_p).$$
 \end{proposition}

\begin{proof} Set $r_2=\ell-2$ and  $r_3=m-2$. Since   $1-VU$ annihilates 
 $H^1_{\rig}(\cW_\epsilon,\cL_{r_2})$, it follows that the overconvergent section
 $\omega_{g^{[p]}}$  of $\underline{\omega}^{r_2} \otimes \Omega^1_X$ is 
 $\nabla$-exact, i.e., there exists $G^{[p]}\in H^0(\cW_\epsilon, \cL_{r_2})$
 satisfying $\omega_{g^{[p]}}= \nabla G^{[p]}$.
 The $q$-expansion of the section $G^{[p]}$ can be written down 
 explicitly in terms of the differentials 
 $\omega_{\can}$ and $\eta_{\can}$ on the Tate curve. Using 
 \eqref{eqn:nabla-can}, one checks that it is equal to
\begin{equation}
\label{eqn:rigid-primitive}
 G^{[p]}(q) =  \sum_{j=0}^{r_2} 
 (-1)^j  j! {r_2\choose j} d^{-j-1}g^{[p]}(q) \omega_{\can}^{r_2-j} \eta_{\can}^j.
 \end{equation}
 Set $r = r_2+r_3-t$, and let $\cL^{(1)},\ldots, \cL^{(r)}$ denote $r$
 copies of the sheaf $\cL_1$ over $X$, numbered consecutively.
     If $S=\{i_1,\ldots, i_s\}$ with $ i_1<i_2<\ldots<i_s$ is any subset of $\{1,\ldots,r\}$,     
 we set
$$\cL^S:=  \cL^{(i_1)} \otimes   \cdots \otimes 
\cL^{(i_s)}.$$

Let $\epsilon_S := \frac{1}{a!}\sum_{\sigma\in \Sigma_s} \sgn(\sigma) \sigma$
denote the symmetrisation projector and write $\cL_S :=  \epsilon_S \cL^S$,
viewed as a subsheaf of $\cL^S$ in the obvious way.

Choose now two  subsets
 $B$ and $C$ of $\{1,\ldots, r\}$ of cardinalities $r_2 $ and $r_3$ respectively,
 whose union is equal to $\{1,\ldots, r\}$. Such a choice is possible, since $r=r_2+r_3-t \le r_2+r_3$. 
Put $A'=B\cap C$ and $A=\{1,\ldots,r\}\setminus A'$.

Poincar\'e duality on the fibers of $\cE$ gives rise to a duality $\cL_1\times \cL_1\lra \cO_X(-1)$ 
of sheaves. Since the cardinality of $A'$ is $t$, this in turn induces a map of sheaves
\begin{equation}
\label{eqn:tensorBCA}
\cL^B \otimes \cL^C  \lra   \cL^A(-t).
\end{equation}

The natural inclusions $\cL_{r_2} \subset \cL^{r_2}\simeq\cL^B$ and 
$\cL_{r_3} \subset \cL^{r_3} \simeq\cL^C$ allow us to build 
certain rigid sections of $\cL^B$ and $(\cL^C\otimes\Omega^1_X)_{\ppar}$ 
out of  $G^{[p]}$ and $\omega_h$ respectively, denoted
$$ G^{[p]}(B) \in H^0(\cW_\epsilon,\cL^B), \qquad \omega_h(C) \in H^0(\cW_\epsilon,(\cL^C\otimes\Omega^1_X)_{\ppar}).$$
Taking the tensor product of these two sections and applying \eqref{eqn:tensorBCA}
gives an overconvergent section $G^{[p]}(B)\otimes \omega_h(C) \in    H^0(\cW_\epsilon, (\cL^A\otimes\Omega^1_X)_{\ppar}),$
whose  symmetrisation can be viewed as an element $\epsilon_A (G^{[p]}(B)\otimes\omega_h(C)) \in H^0(\cW_\epsilon, (\cL_{r-t}\otimes \Omega^1_X)_{\ppar}).$
A direct calculation using \eqref{eqn:rigid-primitive}
    reveals that
 \begin{equation}
 \label{eqn:drgh}
  \spl_{\ur}(\epsilon_A(G^{[p]}(B)\otimes \omega_h(C))) = (-1)^t t! (d^{-1-t} g^{[p]} \times h) \omega_{\can}^{r_1} \left(\frac{dq}{q}\right),
  \end{equation}
which implies that $d^{-1-t} g^{[p]}\times h$ belongs to $S_{k}^{\noc}(N;\C_p)$, as desired. 
 \end{proof}

 
 
 
The sheaf $\cL_r$ equipped with the Gauss-Manin connection is an overconvergent
 $F$-crystal in the sense of \cite[Sec. 10]{coleman-bu}, 
 i.e., the action of Frobenius on the relative de Rham cohomology
 $\cL_r$ induces a horizontal morphism
 $$ \Phi_{\cL_r,\epsilon,\epsilon'}: \Phi^* (\cL_r)_{|\cW_{\epsilon}} 
  \lra (\cL_r)_{|\cW_{\epsilon'}},$$
 for suitable $\epsilon, \epsilon'>0$.  These  give rise to the Frobenius   endomorphism 
 $$  \Phi_r := \cmp_{\epsilon'}^{-1} \circ \Phi_{\cL_r,\epsilon,\epsilon'} \circ \Phi^* \circ \cmp_{\epsilon}$$
 of $H^1_{\dR}(X,\cL_r)$, which is equal to $\Phi$ when $r=0$. 
 By abuse of notation, we will continue to write $\Phi$ instead of $\Phi_r$,
 since the context will make it clear which Frobenius endomorphism is being
 referred to.
 
The action of   $\Phi$ on $H^1_{\dR}(X_{\C_p},\cL_r)$ 
induces a decomposition of its $f$-isotypic part,
for all ordinary modular forms $f$ of weight $k=r+2$:
$$ H^1_{\dR}(X_{\C_p},\cL_r,\nabla)^f = H^0(X_{\C_p},\underline{\omega}^r\otimes \Omega^1_X)^f
\oplus  H^1_{\dR}(X_{\C_p},\cL_r)^{f,\ur},$$
where the superscript $\ur$ denotes the unit-root subspace, i.e.,
the  part of the cohomology on which the
Frobenius endomorphism  acts with slope zero.
This decomposition plays a role somewhat analogous to that of the Hodge decomposition
in the complex setting.

The following lemma generalizes Lemma \ref{lemma:compUPhi} to higher weight.
\begin{lemma}
\label{lemma:compUPhik}
If $\phi = \spl_{\ur}(\omega_\phi) \in S_k^{\noc}(N)_0$ is an ordinary overconvergent $p$-adic 
modular form of weight $k=r+2 > 2$
on $\Gamma_1(N)$,
 then the class of $\omega_\phi$ belongs to
$H^1_{\dR}(X_K,\cL_r)^{\Phi,k-1}$.
Furthermore, the assignment $\phi\mapsto [\omega_\phi]$ 
induces an
isomorphism 
$$ S_k^{\ord}(N)\overset{\sim}{\lra} H^1_{\dR}(X_K,\cL_r)^{\Phi,k-1}.$$
\end{lemma}
\begin{proof}
The Frobenius morphism
$\Phi $
is related to
the operator $V$ on overconvergent modular forms of weight $k$ by
$$ \Phi (\omega_f) =  p^{k-1}\omega_{Vf},$$
as can be seen from a computation on the Tate object $(\G_m/q^\Z,\frac{dt}{t})$ 
after noting that $\Phi(\frac{dt}{t})= p \frac{dt}{t}$. 
The relation between the operators $U$ and $\Phi$ on
cohomology (relative to the
identifications described above between differentials and
weight two modular forms) is therefore
given by
$$ \Phi = p^{k-1} V =  p^{k-1}U^{-1}.$$
If $\phi$ belongs to the slope zero subspace
for the action of $U$, the class
of the rigid  differential $\omega_\phi$  lies in
the slope $k-1$
subspace of  $H^1_{\rig}(\cW_\epsilon,\cL_r)^{\Phi,k-1}$ for the action of $\Phi$.
Since $\Phi$ acts with slope $k/2$ on the target of the residue map, 
the class $\omega_\phi$ automatically has vanishing residues at the supersingular annuli
when $k>2$, and the class of $\omega_\phi$ can therefore be viewed as an
element of $H^1_{\dR}(X_K, \cL_r)$.
The injectivity and surjectivity assertions in the second statement follow from 
Cor.~6.3.1.  and Prop.~6.6 
of \cite{coleman-classical-overconvergent}, just as in the proof of Lemma \ref{lemma:compUPhi}.
\end{proof}
We also record the generalisation of Prop. \ref{prop:depends-on-ord} for $k\ge 2$. 
\begin{proposition}
\label{prop:depends-on-ord-k}
Let $\eta$ be any class in $H^1_{\dR}(X_K,\cL_r)^{\ur}$, and let
$\phi$ be a nearly  overconvergent modular form of weight $k>2$ on $\Gamma_1(N)$ with vanishing residues at the supersingular annuli.
Then
$$ \langle \eta,\omega_\phi\rangle = \langle \eta, \omega_{\phi^{\ord}}\rangle, \qquad \mbox{ where } 
\phi^{\ord}:= e_{\ord} \phi.$$
In other words the expression $\langle \eta,\omega_\phi\rangle$
depends only on the ordinary projection of $\phi$, and Poincar\'e duality induces a 
well-defined pairing
$$ \langle\ ,\ \rangle: H^1_{\dR}(X_{\C_p},\cL_r)^{\ur} \times e_{\ord}S_k^{\noc}(N) \lra \C_p.$$
\end{proposition}
\begin{proof}
The Poincar\'e pairing of \eqref{eqn:pd-wtk} is compatible with the Frobenius endomorphism 
$\Phi$ and hence gives rise to a well-defined pairing
 \begin{equation}
\label{eqn:pd-wtk-ur}
 \langle \ , \  \rangle:
H^1_{\dR}(X_K,\cL_r)^{\ur} \times H^1_{\dR}(X_K,\cL_r)^{\Phi,k-1} \lra \C_p(-1-r).
\end{equation}
The proposition therefore follows from  Lemma \ref{lemma:compUPhik}.
\end{proof}









\subsection{Periods of modular forms}
\label{sec:periods-mf}

The newform   $f\in S_k(N_f,\chi_f;K_f)\subset S_k(N_f;K_f)$ 
 generates an automorphic representation of 
$\GL_2(\A_\Q)$, denoted $\pi_f$. 
For any multiple $N$ of $N_f$ and any field $K\supset K_f$,  let
 $S_k(N;K)[\pi_f]$
 denote the $f$-isotypic  subspace of $S_k(N;K)$,
attached to  the automorphic representation
$\pi_f$.
The space $S_k(N;K)[\pi_f]$ is a finite-dimensional $K$-vector space of
dimension $\sigma_0(N/N_f)$, where $\sigma_0(m)$ denotes as usual the
number of divisors of $m$, and a basis for $S_k(N;K)[\pi_f]$ 
is given by
\begin{equation}
\label{eqn:basis-f}
 \{ f(dz) = f(q^d) \}_{d|(N/N_f)}. 
\end{equation}
Similar remarks and notations apply to the modular forms $g$ and $h$. 

Fix from now on a field $K\supset K_f$, endowed with a complex embedding $K\subset \C$.
\begin{lemma} 
\label{lemma:rat-period}
For all $\testf\in S_k(N;K)[\pi_f]$ and all $\phi\in S_k(N;K)$, 
the Petersson
scalar product $(\testf,\phi)_N$ is a $K$-rational multiple of
the period $(f,f)_{N}$. 
\end{lemma}
\begin{proof}
Let $\TT_N$ be the Hecke algebra of level $N$ generated over $\Q$ by the ``good"
Hecke operators $T_n$ with $\gcd(n,N)=1$. The eigenform $f$ corresponds to 
an idempotent $e_{f}\in \TT_N\otimes K_f$ which induces a projection of
$S_k(N;K)$ onto $S_k(N;K)[\pi_{f}]$.  The vector $\testf$ is orthogonal to the kernel
of $e_f$ and therefore 
$(\testf,\phi)_N = (\testf,e_{f}\phi)_N$ depends only on the projection of $\phi$
to $S_k(N;K)[\pi_{f}]$.
By the remark preceeding equation \eqref{eqn:basis-f}, 
it is thererefore enough to show that, for all 
 divisors $d_1 $ and $d_2$ of $N/N_f$,
$$(f(d_1z), f(d_2z))_N = \varrho(f,d_1,d_2)\cdot(f,f)_N, \mbox{ with }
\varrho(f,d_1,d_2)\in K_f.  $$
If $d_1d_2=1$, this is clear. Otherwise, 
let $q$ be a prime dividing $d_1 d_2$.
The compatibility beween the weight $k$
slash operator and the Petersson scalar product
shows that 
\begin{equation}
\label{eqn:effect-of-slashing1}
 (f(d_1z) ,f(d_2z))_N  = q^{-k} (f(d_1/q z), f(d_2/qz))_N, \qquad \mbox{ if }  q|d_1 \mbox{ and } q|d_2.
 \end{equation}
Otherwise, assume without loss of generality that $q$ divides $d_1$ but not $d_2$.
We then have
\begin{equation}
\label{eqn:effect-of-slashing2}
 (f(d_1z),f({d_2}z))_N = 
\left\{ \begin{array}{ll}
\frac{q^{1-k} a_q(f)}{q+1} (f(d_1/q z), f(d_2 z))_{N}  & \mbox{ if } q||d_1,\\
\frac{q^{1-k} a_q(f)}{q} (f(d_1/q z), f(d_2 z))_{N}  & \\
 \phantom{somespace} - \chi_f(q) q^{-k-1} (f(d_1/q^2 z),f(d_2 z))_N,  & \mbox{ if } q^2|d_1.
\end{array} \right. 
\end{equation}
These relations imply that
\begin{equation}
\label{eqn:rhoq}
\varrho(f,d_1,d_2) = 
\left\{ \begin{array}{ll}
q^{-k}\varrho(f,d_1/q,d_2/q) & \mbox{ if } q| d_1 \mbox{ and } q|d_2;\\
\frac{q^{1-k} a_q(f)}{q+1} \varrho(f,d_1/q,d_2) & \mbox{ if } q||d_1 \mbox{ and } q\nmid d_2;\\
\frac{q^{1-k} a_q(f)}{q} \varrho(f,d_1/q, d_2) - \chi_f(q) q^{-1-k} \varrho(f,d_1/q^2,d_2),  & \mbox{ if } q^2|d_1
\mbox{ and } q\nmid d_2.
\end{array} \right.
\end{equation}
Equation \eqref{eqn:rhoq}, together with the fact
that  
$\varrho(f,1,1)=1$ and $\varrho(f,d_1,d_2) = \bar\varrho(f,d_2,d_1)$ 
make it clear (by induction on $d_1 d_2$) that
$\varrho(f,d_1,d_2)$ belongs to $K_f$ for all $d_1, d_2$ dividing $N/N_f$. 
\end{proof}

The above proposition allows us to associate to any (not necessarily new)
eigenform $\testf\in S_k(N;K_f)$,  and to any modular form    $\phi\in S_k(N;K)$,  
a $K$-rational period
$$ J(\testf,\phi) := \frac{(\testf,\phi)_N}{(f,f)_N}\in K.$$
Let 
\begin{equation}
\label{eqn:def-eta-f-ah}
\eta_{\testf}^{\ah}\in \overline{H^0(X_\C, \underline{\omega}^r\otimes \Omega^1_X)} \subset 
 H^1_{\dR}(X_\C, \cL_r) 
 \end{equation}
  denote the class of the anti-holomorphic form $\frac{1}{\langle \overline{\omega_{\testf}},\omega_{\testf} \rangle}\cdot \overline{\omega_{\testf}}$,
  and let $\eta_{\testf}$ denote its natural
 image in $H^1(X_\C,\underline{\omega}^{-r})$ under the projection in 
 \eqref{eqn:hodge-filtration-k}.
  \begin{corollary}
 \label{cor:def-eta-f}
  The class $\eta_{\testf}$ belongs to 
 $H^1(X_{K_f},\underline{\omega}^{-r})$. 
 \end{corollary}
 \begin{proof}
By Lemma \ref{lemma:rat-period}, for any $\omega_\phi\in H^0(X_{K_f},\underline{\omega}^r\otimes \Omega^1_X)$ associated to a cusp form $\phi\in S_k(N;K_f)$ with $K_f$-rational
fourier coefficients, we have
\begin{equation}
\label{eqn:rat-statement}
 \langle \eta_{\testf}, \omega_\phi\rangle = 
\langle \eta_{\testf}^{\ah}, \omega_\phi\rangle = 
\frac{(\testf,\phi)_N}{(f,f)_N} \mbox{ belongs to } K_f.
\end{equation}
(Where the first occurence of    
 $\langle\ , \ \rangle$ designates the pairing of
 \eqref{eqn:pp-descended}  induced from Poincar\'e duality, with $K=\C$.)
But   $H^1(X_{K_f},\underline{\omega}^{-r})$ can be characterized as the set of $\eta\in H^1(X_\C,\underline{\omega}^{-r})$
satisfying \eqref{eqn:rat-statement} for all $\phi\in S_k(N;K_f)$. 
Corollary \ref{cor:def-eta-f} follows.
  \end{proof}
 
 
\subsection{Hida families }
\label{hidatheory}
Fix a rational prime $p>2$ and 
assume that the field $K\supset K_f$ of  the previous section is furnished 
with a $p$-adic embedding $K\hookrightarrow \C_p$. Let $\cO$ denote the ring of integers of the $p$-adic closure of $K$ in $\C_p$.

For every $p\nmid N$ write the characteristic polynomial of a 
Frobenius element at $p$ acting on the two-dimensional Galois representation over $K_f\otimes\Q_p$
associated by Deligne to $f$ as
\begin{equation}
\label{alphabeta}
L^{(p)}(f; T) =(1-a_p(f) T + \chi_f(p) p^{k-1} T) =
(1-\alpha_{f,p} T)(1-\beta_{f,p} T),
\end{equation}
where  $\chi$ is the nebentype character of $f$ 
and $\alpha_{f,p}$ and $\beta_{f,p}\in \bar\Q$ are the reciprocal
roots of the polynomial $L^{(p)}(f; T)$. 
 
The modular form $f$ is said to be  {\em ordinary} at $p$ if  the
two reciprocal roots of \eqref{alphabeta} can be labelled
in such a way that
$\alpha_{f,p}$ is a $p$-adic unit, i.e., belongs
to $\cO^\times$. The modular form given by
$$
f^{(p)}(q):=f(q)-\beta_{f,p} f(q^p)
$$
is called the {\em ordinary  $p$-stabilization
of $f$}; it has level $p N$, although it is only new at
the primes dividing $N$, and it is again an eigenform for all
the Hecke operators. To be precise,
$$f^{(p)}|T_\ell = a_\ell(f) f^{(p)}, \quad \forall \ell\ne p,
\qquad \quad f^{(p)}|U_p = \alpha_{f,p} f^{(p)}.$$
Set $\Gamma = 1+pN\Z_p$
%\subseteq \Gamma_N=\lim_{\leftarrow} (\Z/Np^n\Z)^\times \simeq (\Z/Np\Z)^\times \times \Gamma,$$
and let $\Lambda=\cO[[\Gamma]]$  
%\subseteq \Lambda_N=\cO[[\Gamma_N]]$$
be the completed group ring of $\Gamma$.
%the choice of a topological generator $\gamma$ of $\Gamma$ (which we may fix to be $\gamma=1+p$) gives rise to a topological isomorphism $\Lambda\simeq \Z_p[[X]]$ by means of the rule %$\gamma=1+X$.
The {\em weight space} is defined  to be
$$\Omega=\mathrm{Spf}(\Lambda)(\cO) = \Hom_{\cO-\mathrm{alg}}(\Lambda,\cO), $$
which may naturally be identified with the space
$\Hom_{\cts}(\Gamma,\cO^\times)$ of continuous characters of $\Gamma$.
The  subset of classical characters of $\Omega$ is  defined to be
$$
\Omega_{\cl} = \{ \chi_k := (\gamma \mapsto \gamma^k), \qquad
\mbox{ with }
k\in  \Z^{\ge 2} \}.
$$
 

Given any finite flat extension $\Lambda_f$ of $\Lambda$, let
$$\Omega_f:=\mathrm{Spf}(\Lambda_f)(\cO) = \Hom(\Lambda_f,\cO). $$
This space is endowed with a natural $p$-adic topology and is equipped with
a natural projection
$$\kappa: \Omega_f \ra \Omega$$ to
weight space  induced by the inclusion
$\Lambda \subseteq \Lambda_f$
of $\cO$-algebras.
A point $x\in \Omega_f$ for which  $\kappa(x)$ belongs to $\Omega_{\cl}$
will be referred to as a {\em classical point}
of $\Omega_f$, and the set of all such classical points will be
denoted  $\Omega_{f,\mathrm{cl}}$.

We will mostly work with the following definition of a {\em Hida family}
of $p$-adic modular forms, which  is slightly more restrictive than
what can sometimes be found in the literature.
\begin{definition}
\label{def:hida-fam}
Let $N_f\ge 1$ be an integer and let $p$ be a prime not dividing $N_f$.
A {\em Hida family}
of tame level $N_f$ is a quadruple
$(\Lambda_f, \Omega_f, \Omega_{f,\cl},\hf)$,
where
\begin{enumerate}
\item[(i)] $\Lambda_f$ is a finite flat extension of $\Lambda$; 
\item[(ii)]  $\Omega_f$ is a non-empty open subset
of $X_f:=\Hom(\Lambda_f,\C_p)$ and 
$\Omega_{f,\cl}$ is  a $p$-adically dense subset of
$\Omega_f$ whose image under $\kappa$ lies in $\Omega_{\cl}$;
\item[(iii)] $\hf := \sum {\bf a}_n q^n\in \Lambda_f[[q]]$
is a formal $q$-series with coefficients in $\Lambda_f$ such that,
for  all   $x \in \Omega_{f,\cl}$,
the power series
$$ f_x^{(p)}:= \sum_{n=1}^\infty {\bf a}_n(x) q^n$$
is the $q$-expansion of the ordinary $p$-stabilization  of
a  normalised newform (denoted $f_x$) of weight $\kappa(x)$ 
on $\Gamma_1(N_f)$.
\end{enumerate}
\end{definition}
The collection of $\{f_x\}_{x\in \Omega_{f,\cl}}$ 
arising from Hida theory can be thought of as a $p$-adically coherent collection of
eigenforms on $\Gamma_1(N_f)$ of varying weights.
In particular, 
 the fourier coefficients $a_n(f_x)$ are analytic functions of $x$ when $p\nmid n$,
(but not when $p|n$, in general).
The following theorem of Hida reveals the ubiquity of Hida families in the above sense.
\begin{theorem}[Hida]
\label{hida-fam}
\cite{Hi86}
Let $f$ be an ordinary newform in $S_k(N_f;K_f)$.
There exists a Hida family $(\Lambda_f, \Omega_f, \Omega_{f,\cl}, \hf)$  of tame level
$N_f$ and a
classical point
$x_0\in\Omega_f$ satisfying
$$ \kappa(x_0) = k, \qquad f_{x_0} = f.$$
\end{theorem}

By shrinking $\Omega_f$ if necessary, we can and will
assume that $\kappa(x)=k$ (mod $p-1$) for all
$x\in \Omega_f$; in particular the integers
$\kappa(x)$ and $k$ have the same parity for all classical
$x\in \Omega_f$.

It will be also convenient, for later purposes, to dispose of a
somewhat more  flexible
notion of $p$-adic families of modular forms,
 interpolating classical modular forms which are not necessarily
new, or even Hecke eigenvectors; 
as well, it will be convenient to allow the  fourier
coefficients to belong to more general coefficients rings which are not necessarily finite
over $\Lambda$. This leads   to the following definition:
\begin{definition}
\label{def:padic-fam}
A $\Lambda$-adic modular form of tame level $N$ is
a quadruple $(R, \Omega_\phi, \Omega_{\phi,\cl}, \hphi)$,
where
\begin{enumerate}
\item[(i)] $R$ is a complete, finitely generated   (but not necessarily finite), flat
 extension of $\Lambda$;
\item[(ii)] $\Omega_\phi$ is an open subset of $\Hom(R,\C_p)$ and
$\Omega_{\phi,\cl}$ is a dense  subset of  $\Omega_\phi$;
 \item[(ii)] $\hphi := \sum {\bf a}_n q^n\in R[[q]]$
is a formal $q$-series with coefficients in $R$ such that,
for  all  $x \in \Omega_{\phi,\cl}$,
the power series
$$ \phi_x^{(p)}:= \sum_{n=1}^\infty {\bf a}_n(x) q^n \in \C_p[[q]]
$$
is the $q$-expansion of a classical ordinary   cusp form  in  
$S_{\kappa(x)}(\Gamma_1(N)\cap \Gamma_0(p);\C_p):= 
S_{\kappa(x)}(\Gamma_1(N)\cap \Gamma_0(p);\Q)\otimes \C_p$. 
\end{enumerate}
\end{definition}

The following   examples of $\Lambda$-adic families of modular forms are of   importance
in our discussion.

\medskip\noindent
{\em 1. Families of old forms}.
Let $f\in S_k(N_f;K_f)$ be a newform of level $N_f$ and let $N$ be some 
multiple of $N_f$ with $p\nmid N$. 
Let  $\testf\in S_k(N;K_f)[\pi_f]$ be an element of  the old class  of level $N$
associated to $f$.
By the remark preceding equation \eqref{eqn:basis-f}, 
there are (unique) scalars
$\lambda_d\in K$ indexed by the divisors of $N/N_f$ and satisfying
$$ \testf = \sum_{d|(N/N_f)} \lambda_d \cdot f(q^d).$$
The $p$-stabilisation of the modular form $f(q^d)$ is  the weight $k$ specialisation of  the
formal $q$-series
$$ \hf(q^d) :=  \sum_{n} {\bf a}_n q^{dn},$$
where $(\Lambda_f,\Omega_f,\Omega_{f,\cl},\hf)$ is the Hida family of tame level
$N_f$ attached to $f$ via Theorem \ref{hida-fam}.
We can then  set
\begin{equation}
\label{eqn:hida-family-oldforms}
\htf(q) := \sum_{d|(N/N_f)} \lambda_d \hf(q^d).
\end{equation}
The triple $(\Lambda_f, \Omega_f,\Omega_{f,\cl},  \htf)$ is a $\Lambda$-adic 
modular form whose classical specialisations are eigenvectors for the
good  Hecke
operators $T_n$ with $\gcd(n,N)=1$, and for the $U$ operator,
but they are not  new at the primes dividing $N/N_f$ and specialise to
the old-form $\testf$ at the   weight $k$ point $x_0\in  \Omega_{f,\cl}$ alluded to in 
Theorem \ref{hida-fam}.

\medskip\noindent
{\em 2. Products of modular forms}. 
Let $(\Lambda_g,\Omega_g,\hg)$ and $(\Lambda_h,\Omega_h,\hh)$ be $\Lambda$-adic
modular forms of tame level $N$ (for example, Hida families of eigenforms
arising from Theorem \ref{hida-fam}
or families of oldforms constructed as in the previous paragraph).
Let $\Lambda_{gh}:= \Lambda_g\otimes_{\cO} \Lambda_h$ be the finitely generated
(but not finite) $\Lambda$-algebra equipped with the natural  diagonal
embedding $\Lambda\lra \Lambda_g\otimes\Lambda_h$ sending the group-like element 
$[a]\in\Lambda$ to $[a]\otimes[a]$. Set 
$$\Omega_{gh}:= \Omega_g\times \Omega_h, \qquad \Omega_{gh,\cl} := \Omega_{g,\cl}\times \Omega_{h,\cl}.$$
 Then
the quadruple $(\Lambda_{gh},\Omega_{gh},\Omega_{gh,\cl}, e_{\ord} (\hg\times \hh))$, where the power series
$\hg \times\hh$ is viewed as an element of $\Lambda_{gh}[[q]]$ in the natural way,
and $e_{\ord}$ is Hida's ordinary projection operator,
is an example of a $\Lambda$-adic family of modular forms with Fourier 
coefficients in $\Lambda_{gh}$. 

\medskip\noindent
{\em 3. Derivatives of modular forms}.
Recall the operators  $U$, $V$  defined in  \eqref{eqn:defUV}, and 
the differential operator $d := q\frac{d}{dq}$, which
 induces
a map from $p$-adic modular forms of weight $k$ to $p$-adic 
modular forms of weight $k+2$. Recall that 
 $$\Omega:=\mathrm{Spf}(\Lambda)(\cO) 
 = \Hom_{\cO-\mathrm{alg}}(\Lambda,\cO)=\Hom(\Gamma,\cO^\times)$$ 
 and notice that for any $n\in \Z$ such that $p\nmid n$, the group-like element $[n]$ gives rise to a function 
 $$[n]: \Omega \lra \cO$$ whose value at 
 a character  $k\in \Omega$ represented  by $\gamma\mapsto \gamma^k$, is simply $[n](k) = n^k$.
 
Let $\hg$ and $\hh$ be $\Lambda$-adic families of eigenforms of tame level $N$ 
(but not necessarily new of that level).  Assume that $p$ is a prime that does not divide $N$, and let $a_p(\hg)\in \Lambda_g$, $a_p(\hh)\in \Lambda_h$ denote the Hecke eigenvalues associated to  the Hecke operator 
 $T_p$. Let  
$$\hg^{[p]} := (1-VU)\hg = (1-a_p(\hg)V+[p]p^{-1}V^2)\hg = \sum_{p\nmid n} a_n(\hg)q^n$$ 
be the $\Lambda$-adic counterpart of the modular form defined in 
\eqref{eqn:deffppp}.
The specialisation $g^{[p]}_y$  of $\hg^{[p]}$ at a classical point
 $y\in \Omega_{g,\cl}$ can either be viewed as a
$p$-adic modular form  of tame level $N$ as in \eqref{eqn:deffppp}, or as a classical modular form
 of level $Np^2$. Note that $\hg^{[p]}$ is not ordinary; in fact it lies in the kernel of the $U$ operator.
But the fact that $\hg^{[p]}$ has fourier coefficients supported on the integers prime to $p$
allows the formal $q$-series
\begin{equation}
d^{\bullet}\hg^{[p]} := \sum_{p\nmid n} [n]a_n(\hg) q^n 
\end{equation}
to be viewed as an element of $\Lambda \otimes_{\cO}\Lambda_g[[q]]$.
The specialization of this $q$-series  at a classical point 
$(t,y)\in \Omega_{\cl}\times\Omega_{g,\cl}$ is simply
$$
(d^{\bullet}\hg^{[p]})_{ (t,y)} 
%:=(d^{\bullet}\hg^{[p]})_{  t,y } 
= d^tg_y^{[p]}.
$$

Define $R_{gh}:= \Lambda\otimes_{\cO}\Lambda_g\otimes_{\cO}\Lambda_h$, regarded as a $\Lambda$-algebra by mapping the group-like element 
$[a]\in\Gamma$ to $[a^2]\otimes [a]\otimes[a]$, so that the map from 
$\Hom(R_{gh},\C_p)=\Omega\times\Omega_g\times\Omega_h$ to the weight space sends the classical point $(t,y,z)\in \Z^{\ge 0} \times\Omega_{g,\cl}\times
\Omega_{h,\cl}$ to
$\kappa(y)+\kappa(z)+2t$. 

Let $d^{\bullet}\hg^{[p]}\times\hh$ denote the product of $d^{\bullet}\hg^{[p]}$
and $\hh$, viewed as a  formal series with coefficients in $R_{gh}$. Let
$e_{\ord}(d^{\bullet}\hg\times\hh)$ denote its image under the ordinary projection operator.
The specialisation of $e_{\ord}(d^\bullet \hg^{[p]}\times \hh)$ at   $(t,y,z)$ is equal to
\begin{equation}
\label{eqn:specialisation-gh}
e_{\ord}(d^\bullet \hg^{[p]}\times \hh)_{t,y,z} = e_{\ord}(d^t g_y^{[p]} \times h_z^{(p)}) 
= e_{\ord}(d^t g_y^{[p]} \times h_z),
\end{equation}
where the last equality is a consequence of the following simple but extremely useful lemma:
 \begin{lemma}
 \label{lemma:ignore-p}
 If $g$ and $h$ are $p$-adic modular forms of tame level $N$, 
 then $g^{[p]} \times (Vh)$ is in the kernel of the $U$ operator, and in particular
 $$ e_{\ord}(g^{[p]} \times Vh) = 0.$$
 \end{lemma}
 \begin{proof} This follows from the fact that $a_n(g^{[p]} \times (Vh))=0$ 
 whenever $p|n$. 
 \end{proof} 
The above discussion is summarised  in the  following proposition, which
   plays a key role in the construction of the triple
Garrett-Rankin $p$-adic $L$-function described in Chapter \ref{sec:p-adic-Lfct}.
\begin{proposition}
\label{prop:prod-deriv-family}
Let 
$$\Omega_{gh,\cl} :=  \{ (t,y,z)\in  \Z \times \Omega_{g,\cl}\times \Omega_{h,\cl}, \quad t> -\min(\kappa(y),\kappa(z)).  \} $$
The quadruple 
$$e_{\ord}(d^{\bullet}\hg^{[p]}\times \hh) := 
(R_{gh},\Omega\times\Omega_g\times\Omega_h,
\Omega_{gh,\cl}, e_{\ord}(d^\bullet\hg^{[p]}\times\hh))$$
is an ordinary $\Lambda$-adic modular form of tame level $N$. 
For all $(t,y,z) \in \Omega_{gh,\cl}$,
the  specialisation of this family at $(t,y,z)$ is 
  the classical modular form (with coefficients in $\C_p$) 
$$ e_{\ord}(d^t g_y^{[p]}\times h_z)  \in S_k(\Gamma_1(N)\cap \Gamma_0(p);\C_p).$$
This specialisation has algebraic fourier coefficients (lying in $K=K_{g_y} K_{h_z}$) when
$t\ge 0$.
\end{proposition}
 
We conclude this section by describing the $\Lambda$-adic interpolation of the periods 
that arise in 
Lemma 
\ref{lemma:rat-period}.
Write $\uS^{\ord}(N;R)$ for the space of $\Lambda$-adic modular forms with coefficients
in the  $\Lambda$-algebra $R$. A Hida family $(\Lambda_f,\Omega_f,\hf)$ 
of eigenforms  in the sense of 
definition \ref{def:hida-fam} 
gives rise to a subspace
$$ \uS^{\ord}(N;\Lambda_f)[\pi_f]:= \left\{ 
\htf \in \uS^{\ord}(N;\Lambda_f) \quad \mbox{ such that } 
T_n \htf = {\bf a}_n \htf, \quad \mbox {for all } (n,N)=1  \right\}.$$
Letting $\Lambda_f'$ denote the fraction field of the integral domain
$\Lambda_f$, the vector space $\uS^{\ord}(N;\Lambda_f')[\pi_f]$ is finite-dimensional
over $\Lambda_f'$ and has for basis the   set  
$ \{ \hf(q^d) \}_{d|(N/N_f)}$
of  $\Lambda$-adic forms.
 Let $\hf \in \uS^{\ord}(N_f,\Lambda_f)$ be a Hida family of ordinary eigenforms, and 
let $\htf \in \uS^{\ord}(N,\Lambda_f)[\pi_{\hf}]$ be an associated test vector
of tame level $N$.  

Let $\hphi =(R, \Omega_\phi,\Omega_{\phi,\cl},\hphi) 
\in \uS^{\ord}(N;R)$ be a $\Lambda$-adic modular form, 
and let $(x,y)\in \Omega_{f,\cl} \times \Omega_{\phi,\cl}$ 
be a pair of points with $\kappa(x)=\kappa(y)$. 
 The specialisation 
$\phi_y^{(p)}$ of $\hphi$ at $y\in \Omega_{\phi,\cl}$ need not be the $p$-stabilisation of
a classical modular form,  but its projection $e_{f_x}\phi_y^{(p)}$ to 
the $f_x$-isotypic component is the $p$-stabilisation of a classical modular form, which shall be
denoted $\phi_{x,y}$. 
 
If $R$ is any flat $\Lambda$-algebra with associated analytic space
$\Omega_R= \Hom(R,\cO)$, the  elements of the ring $\Lambda_f'\otimes_\Lambda R$ can be 
  viewed as ``rational functions" on the fiber product 
  $\Omega_f\times_{\Omega} \Omega_R$ with poles at finitely many 
  $x\in \Omega_f$.  Given $J\in \Lambda_f'\otimes_{\Lambda} R$ and $(x,y)\in \Omega_f\times_{\Omega} \Omega_R$, we write 
  $J(x,y)$ for the value of $J$ at $(x,y)$, when it is defined. Let $(\ ,\ )_{N,p}$ denote the Petersson scalar product on modular forms attached to
the group $\Gamma_1(N)\cap \Gamma_0(p)$. 
   \begin{lemma} 
\label{lemma:Lambda-period}
For all $\htf\in \uS^{\ord}(N;\Lambda_f)[\pi_f]$ and all $\hphi =(R, \Omega_\phi,\Omega_{\phi,\cl},\hphi) 
\in \uS^{\ord}(N;R)$,   
 there exists (a unique)  $J(\htf,\hphi) \in \Lambda_f'\otimes_{\Lambda} R$ such that,
for all  classical points   $(x,y)\in\Omega_{f,\cl}\times_{\Omega_{\cl}}\Omega_{\phi,\cl}$, 
\begin{equation}
\label{eqn:period-formulae}
 J(\htf,\hphi)(x,y) = \frac{( \testf_x^{(p)}, \phi_{x,y}^{(p)})_{N,p}} {(f_x^{(p)}, f_x^{(p)})_{N,p}} 
= \frac{( \testf_x , \phi_{x,y} )_{N}} {(f_x , f_x )_{N }}  
= \langle \eta_{f_x},  \phi_{x,y}\rangle,
 \end{equation}
 where the last pairing is the Poincar\'e duality between
 $H^1(X_{\C_p},\underline{\omega}^{-r})$ and $H^0(X_{\C_p},\underline{\omega}^r\otimes \Omega^1_X)$. 
 \end{lemma}
\begin{proof}
Let $\uTT_N$ be the $\Lambda$-adic Hecke algebra of tame level $N$ generated by the  
Hecke operators $T_n$ with $\gcd(n,Np)=1$ and $U$  acting on $\uS^{\ord}(N;\Lambda)$. 
The Hida family $\hf $ corresponds to 
an idempotent $e_{\hf}\in \uTT_N\otimes_{\Lambda}  \Lambda_f'$ 
which induces a projection of
$\uS^{\ord}(N;\Lambda)$  to $\uS^{\ord}(N; \Lambda_f' )[\pi_f]$. 
Hence $e_{\hf} \hphi$ is a  $(\Lambda_f'\otimes_\Lambda R)$-linear
combination of the forms $\hf(q^d)$ with $d|N/N_f$, while the same is of course true for
$\htf$. 
It is therefore enough to show that, for all 
 divisors $d_1 $ and $d_2$ of $N/N_f$,
$$\frac{(f_x^{(p)}(q^{d_1}), f_x^{(p)}(q^{d_2}))_{N,p}}{(f_x^{(p)},f_x^{(p)})_{N,p}} =
\varrho(\hf,d_1,d_2)(x), \mbox{ for some  }
\varrho(\hf,d_1,d_2)\in  \Lambda_f\otimes \Q.  $$
But the proof of Lemma \ref{lemma:rat-period} with $f$ replaced by
$f_x^{(p)}$ and $\Gamma_1(N)$ by $\Gamma_1(N)\cap \Gamma_0(p)$ 
shows that  $\varrho(f_x^{(p)}, d_1,d_2)$ (defined in the obvious way) 
is a polynomial involving the expressions
$q^{\kappa(x)}$,  $a_q(f_x)$, $\frac{1}{q}$ and $\frac{1}{q+1}$
 as $q$ ranges over the divisors of $d_1 d_2$.
Since the primes $q$ that arise  are different from $p$,
these expressions all belong to $\Lambda_f\otimes \Q$ and hence the same is true of 
$\varrho(\hf,d_1,d_2)$.  It follows that the expression $J(\htf,\hphi)$ defined by
$$ J(\htf,\hphi)(x,y) := 
\frac{ (\testf_x^{(p)},\phi_y^{(p)})_{N,p}} 
{(f_x^{(p)},f_x^{(p)})_{N,p}}  $$
belongs to $\Lambda_f'\otimes_{\Lambda} R$, and the first equality in 
\eqref{eqn:period-formulae} follows.
The second equality follows from a direct calculation, and the third from the definition
of $\eta_{f_x}$ and the familiar expression for  the Poincar\'e pairing in terms of the 
Petersson scalar product.
Lemma \ref{lemma:Lambda-period}   follows.
\end{proof}




 \section{Diagonal cycles and $p$-adic Abel-Jacobi maps}
 \label{AJp}


\subsection{Generalised Gross-Kudla-Schoen cycles}
\label{cycles}

The main aim of this section is to introduce, for each triplet $(k,\ell,m)$ of {\em balanced} weights, a distinguished algebraic cycle $\Delta_{k,\ell,m}$ on the product of three Kuga-Sato varieties fibered over the modular curve $X=X_1(N)$. When the triplet is $(k,\ell,m)=(2,2,2)$, the cycle $\Delta_{2,2,2}$ is the one introduced by Gross and Kudla in \cite{GrKu} and studied in detail by Gross and Schoen in \cite{GrSc}.



%Recall our running assumption \eqref{ass-1} that $B=B_{Pr}(f,g,h)$ is an indefinite quaternion algebra, of reduced discriminant $D$. Let $X=X_0^D(M)$ be Shimura's canonical model over $\Q$ of the curve associated with any choice of an Eichler order of level $M$ in $B$ as in \cite{Sh67}. If $D=1$, $X=X_0(N)$ is the classical modular curve  considered in the introduction, which parametrizes generalized elliptic curves $x=(E,T)$ together with a cyclic subgroup $T$ of order $N$. If $D>1$, $X$ will be regarded in this work (among other possible interpretations) as the coarse moduli space of triplets $(C,\iota,T)$ where $C$ is a generalized curve of genus two, $\iota: \cO_B \hookrightarrow \Corr(C)$ is an embedding of a maximal order of $B$ into the ring $\Corr(C)\simeq \End(\Jac(C))$ of correspondences on the curve, and $T$ is a principal $\cO_B$-submodule of the $N$-torsion subgroup of $\Jac(C)$.

Let $\cE$ denote the universal elliptic curve 
 fibered over $X$, as constructed in \cite{Sc}.
It is a projective smooth algebraic surface defined over $\Q$ equipped with a proper regular (but not smooth) fibration
$$
\pi: \cE \lra X,
$$
whose fiber $\cE_x$ at a point $x\in Y$ outside the finite set of cusps is the elliptic curve corresponding to $x$ under the moduli interpretation. 


Fix a base point $o\in  X(\Q)$, say the cusp at infinity. Write $u$ for the unique automorphism on $\cE$ extending the 
involution $-1$ on the fibers with respect to the zero section $\sigma_0$ of $\pi$.

For any $r\geq 0$, write $\cE^r = \cE_1 \times_X  ... \times_X \cE_r$ for the $r$-th fibered product of $\cE$ over $X$. A generic point in $\cE^r$ is $(x;P_1,...,P_r)$ where $x\in X$ and $P_i$ are points in the fiber $\cE_x$.  Let
$$
\epsilon_{\sym} = \frac{1}{r!} \sum_{\sigma\in \Sigma_r} \sgn(\sigma) \sigma \in \mathrm{Corr}(\cE^r)\otimes \Q
$$
denote the projector in which a permutation $\sigma$ acts on $\cE^r$ by permuting the factors in the fibration
$\pi: \cE^r\lra X$. Let also
$$\epsilon_{\mathrm{inv}} := \left(\frac{1-u_1}{2}\right)\otimes \cdots \otimes
\left(\frac{1-u_r}{2}\right) \in \mathrm{Corr}(\cE^r)\otimes \Q$$
denote the idempotent in the ring of correspondences from $\cE^r$ to itself, in which
$u_j$ denotes the involution on the  $j$-th factor in the fibration $\cE^r\lra  X$. Write 
\begin{equation}\label{def-eps}
\epsilon_r=\epsilon_{\sym}\cdot \epsilon_{\mathrm{inv}} \in \mathrm{Corr}(\cE^r)\otimes \Q
\end{equation}
for the composition of the two idempotents.

Put $(k,\ell,m) = (r_1+2,r_2+2,r_3+2)$ with $r_3\geq r_2\geq r_1\geq 0$ and set 
$$r=\frac{r_1+r_2+r_3}{2}\geq 0.$$
 Let us now define a generalized Gross-Kudla-Schoen 
cycle $\Delta_{k,\ell,m}$ of codimension $r+2$ in the $(2r+3)$-dimensional variety 
$$W=\cE^{r_1}\times \cE^{r_2}\times \cE^{r_3}$$
introduced in \eqref{eqn:defW} of the introduction.
  We shall regard it as an element in the group 
  $$\CH^{r+2}(W):=\cZ^{r+2}(W)\otimes \Q/\cZ_{\mathrm{rat}}^{r+2}(W)\otimes \Q$$
   of rational equivalence classes of cycles of codimension $r+2$ with coefficients in $\Q$.

We treat the three  cases $(k, \ell,m) = (2,2,2)$, $(2,\ell,\ell)$ with $\ell>2$, and $k,\ell,m>2$ separately. 

\begin{definition} 
\label{def:Delta222}
Assume $(k,\ell,m)=(2,2,2)$.  For any non-empty subset $I\subseteq \{ 1,2,3\}$, let
$$
X_I:=\{ (P_1,P_2,P_3)\in X\times X\times X:\, P_i=P_j \mbox{ for all } \{i, j\}\subset I, P_j=o \mbox{ for all } j\not \in I \}.
$$
Then the Gross-Kudla-Schoen diagonal cycle is defined to be
$$
\Delta_{2,2,2} = X_{123}-X_{12}-X_{13}-X_{23} + X_1 + X_2 + X_3 \in \CH^2(X_1\times X_2 \times X_3).
$$
\end{definition}

To treat the remaining cases, choose three subsets 
\begin{equation}\label{ABC}
A =\{ a_1,\ldots, a_{r_1}\}, \qquad B=\{b_1,\ldots,b_{r_2}\}, \qquad
C =\{c_1,\ldots,c_{r_3}\}
\end{equation}
of $\{1,\ldots,r\}$ of cardinalities $r_1$, $r_2$ and $r_3$ respectively, 
such that $A\cap B \cap C=\emptyset$. If some of the $r_i$ is $0$, we take the corresponding subset to be the empty set. One readily checks that such subsets exist, and that they satisfy $A=B\cup C\setminus B\cap C$, $B=C\cup A\setminus C\cap A$ and $C=A\cup B\setminus A\cap B$. The choice of the triplet $(A,B,C)$ is unique up to permutations in $S_r$. Since the union of any two of the sets $A$, $B$, $C$ is equal to $\{1,...,r\}$, the maps 
\begin{equation}\label{phiABC}
\begin{matrix}
\varphi_{ABC}: \cE^r \lra \cE^{r_1}\times \cE^{r_2} \times \cE^{r_3}, \quad  (x;P_1,...,P_r) \mapsto ((x;P_{a_{i}}),(x;P_{b_{i}}),(x;P_{c_{i}}))\\
\\
\mbox{ and} \quad \varphi_{BC}: \E^r \lra \E^{r_2} \times \E^{r_3}, \quad  (x;P_1,...,P_r) \mapsto ((x;P_{b_{i}}),(x;P_{c_{i}}))
\end{matrix}
\end{equation}
are closed embeddings of $\cE^r$ into $W$ (and likewise for the analogous maps $\varphi_{AB}$ and $\varphi_{AC}$).
 
\begin{definition} 
\label{def:Delta2ll}
If $(k,\ell,m)=(2,\ell,\ell)$ for some $\ell=r+2> 2$, the generalised Gross-Kudla-Schoen cycle is defined by  
%Let 
%\begin{eqnarray*}
%X_{123} &=&  \{ (P,Q,Q)\in X\times \cE^r \times \cE^r \mbox{ with }  P=\pi(Q)\}, \\
%X_{23} &=& \{ (o,Q,Q) \in X\times \cE^r \times \cE^r \}.
%\end{eqnarray*} 
%The generalised Gross-Kudla-Schoen cycle on $X\times \cE^r\times \cE^r$ is
$$
\Delta_{2,\ell,\ell} = (\Id, \epsilon_{r_2},\epsilon_{r_3})(\varphi_{ABC}(\cE^r)-\{o\}\times \varphi_{BC}(\cE^r))\in \CH^{r+2}(X\times \cE^r\times\cE^r).
$$
\end{definition}


 
\begin{definition} 
\label{def:Deltaklm}
If $k,\ell, m>2$, the generalised Gross-Kudla-Schoen cycle is defined by
$$\Delta_{k,\ell,m} = (\epsilon_{r_1},\epsilon_{r_2},\epsilon_{r_3}) \varphi_{ABC}(\cE^r)\in \CH^{r+2}(W).$$
\end{definition}

By examining the image of these cycles  by the cycle class map in each of the K\"unneth components of the complex de Rham cohomology group $H_{\dR}^{2r+4}(W/\C)$ of the variety $W$, it follows from \cite[Lemma 2.2]{BDP1} that the cycles $\Delta_{k,\ell,m}$ we defined for each triple of balanced weights $(k,\ell,m)$ are null-homologous, that is to say:
$$
\Delta_{k,\ell,m} \in \CH^{r+2}(W)_0 := \ker\left(\cl: \CH^{r+2}(W)\ra H_{\dR}^{2r+4}(W)\right).
$$

%To check that these cycles are null-homologous, note that by \cite[lemma 2.1]{BDP1} we have that, if $i>0$, $\epsilon_i H^\ast(\cE^i) = \epsilon_i H^{i+1}(\cE^i) = H^1_{\para }(X,\cL_i)$. If $r_1>0$, then %$(\epsilon_{r_1},\epsilon_{r_2},\epsilon_{r_3}) H^{2r+4}(W)=0$ because $r_1+r_2+r_3+3=2r+3<2r+4$. If $r_1=0$ and $r_3\geq r_2>0$, then $(\epsilon_{r_1},\epsilon_{r_2},\epsilon_{r_3}) H^{2r+4}%(W)=H^2(X)\otimes H^1_{\para}(X,\cL_{r_2}) \otimes H^1_{\para}(X,\cL_{r_3})$. The two summands $(\Id, \epsilon_{r_2},\epsilon_{r_3})(\varphi_{ABC}(\cE^r)$ and $\{o\}\times \varphi_{BC}(\cE^r))$ have %the same image in $H^2(X)\otimes H^1_{\para}(X,\cL_{r_2}) \otimes H^1_{\para}(X,\cL_{r_3})$, and therefore their difference cancels out in cohomology.

Fix a prime $p\nmid N$ and 
\begin{equation}\label{AJpp}
\AJ_p: \CH^{r+2}(W)_0 \lra  \Fil^{r+2} H^{2r+3}_{\dR}(W)^\vee
\end{equation}
denote the {\em $p$-adic Abel-Jacobi map}, as introduced e.g. in \cite[(1.2)]{Nek-survey}, \cite{Bes-inv}.

There are several equivalent definitions of \eqref{AJpp}. Given that $\Fil^{r+2} H^{2r+3}_{\dR}(W)^\vee$ is naturally isomorphic to the group $\mathrm{Ext}^1(\Q_p,H_{\dR}^{2r+3}(W))$ of isomorphism classes of extensions of the trivial filtered frobenius module $\Q_p$ by $H_{\dR}^{2r+3}(W)$, the map $\AJ_p$ sends $\Delta$ to the extension class given by
\begin{equation}\label{AJpExt}
\xymatrix{
0 \ar[r] & H_{\dR}^{2r+3}(W) \ar@{=}[d]  \ar[r] & V_\Delta \ar[d]\ar[r] & \Q_p \ar[d]^{\mathrm{cl}_{\dR}} \ar[r] & 0 \\
0 \ar[r] & H_{\dR}^{2r+3}(W)  \ar[r] & H_{\dR}^{2r+3}(W\setminus |\Delta|) \ar[r] & H^{2r+4}_{|\Delta|}(W) \ar[r] & 0,
}
\end{equation}
where the lower row is the short excision exact sequence associated with the pair $(W,\Delta)$ and the upper row is obtained from the lower by pull-back under the cycle class map $\mathrm{cl}_{\dR}$ in de Rham cohomology.



\subsection{A formula for $\AJ_p(\Delta_{k,\ell,m})$ in terms of Coleman integration}

The goal of this section is to give a $p$-adic analytic description of
(a piece of) the functional $\AJ_p(\Delta_{k,\ell,m})$, involving $p$-adic integration of differential forms, \`a la Coleman.

Let $(k,\ell,m)=(r_1+2,r_2+2,r_3+2)$ with $r_3\geq r_2\geq r_1\geq 0$ be a triplet of balanced weights and recall that we set $r=\frac{r_1+r_2+r_3}{2}$.

Our description of $\AJ_p(\Delta_{k,\ell,m})$ rests on the $p$-adic analytic description of $H^1_{\dR}(X_{\C_p},\cL_r)$ that was given in 
Sections \ref{wideopens} and \ref{KatzKassaei}. In order to keep track of the factors it will be convenient to write $X^2 = X_2\times X_3$  and likewise write $(X')^{2} = X'_2\times X'_3$, where $X'$ denotes the affine subvariety of $X$ fixed in Section \ref{wideopens}. By Proposition \ref{prop:alg-to-rigid} and equation \eqref{eqn:alg-to-rig-k} we have
\begin{equation*}\label{comp-klm}
H^1_{\dR}(X',\cL_{r_2}) \otimes H^1_{\dR}(X',\cL_{r_3})  \simeq H^1_{\rig}(\cW_\epsilon,\cL_{r_2}) \otimes H^1_{\rig}(\cW_{\epsilon},\cL_{r_3}).
\end{equation*}
 
We fix a choice of lift of 
Frobenius to $\cW_\epsilon\times\cW_\epsilon$  by setting
$\Phi := \Phi_2 \times \Phi_3$,
where $\Phi_2$ and $\Phi_3$ denote the  canonical lift of the
Frobenius endomorphism on  $\cW_\epsilon$ described in 
\eqref{eqn:canonical-phi}, viewed as acting on the 
first and second factors  of $X_2\times X_3$ respectively. This choice yields a linear transformation 
$$ 
\Phi := \Phi_2 \otimes \Phi_3: \Omega^1_{\rig}(\cW_{\epsilon},\cL_{r_2})\otimes 
\Omega^1_{\rig}(\cW_\epsilon,\cL_{r_3}) \lra
\Omega^1_{\rig}(\cW_{\epsilon},\cL_{r_2})\otimes 
\Omega^1_{\rig}(\cW_\epsilon,\cL_{r_3})
$$ 
and induces an endomorphism of $H^1_{\rig}(\cW_\epsilon,\cL_{r_2}) \otimes H^1_{\rig}(\cW_{\epsilon},\cL_{r_3})$ which we denote with the same letter. View $\cL_{r_2}\otimes \cL_{r_3}$ as a sheaf on $X\times X$. The Gauss-Manin connection on $\cL_{r_1}$ and on $\cL_{r_2}$ gives rise to a 
connection
$$ 
\nabla: \cL_{r_2}\otimes \cL_{r_2} \lra \cL_{r_2}\otimes \cL_{r_3} \otimes\Omega^1_{X\times X}
$$
on sheaves on $X\times X$, denoted again by $\nabla$ by abuse of notation, and defined on sections by the rule
$$ 
\nabla(s_2\otimes s_3) = \nabla(s_2)\otimes s_3 + s_2\otimes \nabla(s_3).
$$




Given a class
\begin{eqnarray*}
\omega_2\otimes\omega_3& \in & H^0(X, \Omega^1_X\otimes \uomega^{r_2}) \otimes
 H^0(X, \Omega^1_X\otimes\uomega^{r_3})  \\
 &=&  
\Fil^{r_2+r_3+2} (H^1_{\dR}(X,\cL_{r_2}) \otimes H^1_{\dR}(X,\cL_{r_3}) ) \\
&
\subset & H^1_{\rig}(\cW_\epsilon,\cL_{r_2}) \otimes  H^1_{\rig}(\cW_\epsilon,\cL_{r_3})
\subset H^2_{\rig}(\cW_\epsilon\times\cW_\epsilon, \cL_{r_2}\otimes \cL_{r_3}),
\end{eqnarray*}
choose a
polynomial  $P\in \C_p[x]$  satisfying

\begin{enumerate}
\item[(i)] $P(\Phi)= P(\Phi_2\Phi_3)$ annihilates  the class of $\omega_2\otimes \omega_3$ in $H^2_{\rig}(\cW_\epsilon\times \cW_\epsilon, \cL_{r_2}\otimes \cL_{r_3})$.
\item[(ii)] For each supersingular annulus $\cV_j$, $j=1,...,s$, $P(\Phi)$ annihilates  the target of the residue map \eqref{res-map}, namely $(\Sym^r H^1_{\dR}(E_j))(-1)$. 
\item[(iii)] None of the roots of $P(x)$ are of complex absolute value $p^{\frac{r_2+r_3+1}{2}}$.
\end{enumerate}

The existence of such a polynomial follows from the fact that the eigenvalues of
the geometric Frobenius
$\Phi$ acting on $H^1_{\dR}(X_{\C_p},\cL_r)$ (resp. on $(\Sym^r H^1_{\dR}(E_j))(-1)$) are algebraic numbers
with complex absolute value $p^{\frac{r+1}{2}}$ (resp. $p^{\frac{r+2}{2}}$), and hence a polynomial $P$ satisfying (i) and (ii) can be chosen so that all its roots have
complex absolute value either $p^{\frac{r_2+r_3+2}{2}}$ or $p^{\frac{r+2}{2}}$; such a choice of $P$ automatically satisfies (iii) because
the triplet of weights is assumed throughout to be balanced. 

See the discussion right after Proposition \ref{defxi} below for a justification of the need of conditions (ii) and (iii). As for (i), note that a direct consequence of it is the existence of a rigid analytic primitive of $P(\Phi) (\omega_2 \wedge \omega_3)$, as we quote in the following statement.

\begin{lemma}
\label{lemma:xi-k}
There exists a real $\epsilon>0$ and
an $\cL_{r_2}\otimes \cL_{r_3}$-valued rigid one-form $\rhop$
on $\cW_\epsilon\times \cW_\epsilon$
satisfying
\begin{equation}
\label{eqn:diff-eqn-xi-k}
\nabla \rhop = P(\Phi) (\omega_2 \wedge \omega_3).
\end{equation}
This one-form is well-defined  up to rigid $\nabla$-closed one-forms on
$\cW_{\epsilon}\times\cW_{\epsilon}$.
\end{lemma}



Recall the base point $o\in X$ that was chosen  to define the cycle $\Delta_{2,2,2}$. This choice of base point determines the horizontal and vertical inclusions
\begin{equation}\label{horveremb}
\iota_2: X = X\times \{o\} \hookrightarrow X\times X,\qquad
\iota_3: X = \{o\} \times X \hookrightarrow X\times X.
\end{equation}
Let
\begin{equation}\label{diagemb}
\iota_{23}: X\hookrightarrow X\times X
\end{equation}
denote the diagonal morphism.
By abuse of notation, we will denote by the same symbols the resulting maps
$$\iota_2, \iota_3, \iota_{23}:
X'\hookrightarrow X'\times X', \qquad \iota_2, \iota_3, \iota_{23}: \cW_\epsilon \hookrightarrow \cW_\epsilon \times \cW_\epsilon.$$
Finally write
$$\varphi_{23}^* := \iota_{23}^\ast - \iota_2^\ast - \iota_3^\ast: \Omega^1_{\rig}(\cW_\epsilon\times\cW_\epsilon) \lra
\Omega^1(\cW_\epsilon)$$
for the maps obtained  by combining the  pullbacks of these three morphisms.



\begin{lemma}
\label{lemma:epsilon-is-0}
The map $H^1_{\rig}(\cW_\epsilon\times\cW_\epsilon)\lra H^1_{\rig}(\cW_\epsilon)$ induced by $\varphi_{23}^\ast$ is the zero map.
\end{lemma}

\begin{proof}
This is a direct consequence of the following two facts:
\begin{enumerate}
\item The map
$$ \varphi_{23}^\ast:H^1_{\dR}(X'_2\times X'_3/\Q_p) \lra H^1_{\dR}(X'/\Q_p)$$ is $0$. This can be checked by choosing a complex embedding of $\Q_p$
and noting that the  map $\varphi_{23}: H_1(X'/\C) \lra H_1(X'_2\times X'_3/\C)$
vanishes, using  topological methods.
\item  There is a commutative diagram
$$ \xymatrix{
H^1_{\dR}(X'_2\times X'_3/\Q_p) \ar[r]^{\varphi_{23}^\ast} \ar@{=}[d]^{\cmp_\epsilon} & H^1_{\dR}(X'/\Q_p) \ar@{=}[d]^{\cmp_\epsilon} \\
H^1_{\rig}(\cW_\epsilon\times \cW_\epsilon/\Q_p) \ar[r]^{\varphi_{23}^\ast} &   H^1_{\rig}(\cW_\epsilon/\Q_p). }
$$
\end{enumerate}
\end{proof}
To formulate the counterpart of Lemma \ref{lemma:epsilon-is-0}
for general weights $(k,\ell,m)$, recall
 the subsets $A$, $B$ and $C$ of $\{1,\ldots, r\}$ of cardinalities $r_1$, $r_2$ and $r_3\geq 0$ that were chosen in \S \ref{cycles}, and denote by $A'$, $B'$ and $C'$ their respective complements. Note that
$$A' = B\cap C,  \quad B' = A\cap C \quad\mbox{ and }\quad C' = A\cap B.$$
Recall also the diagonal inclusions
$$\varphi_{ABC}: \E^r \lra  \E^{r_1}\times  \E^{r_2} \times \E^{r_3} \,\,\mbox{ and }\,\varphi_{BC}: \E^r \lra \E^{r_2} \times \E^{r_3}
$$
introduced in \eqref{phiABC}. As in \eqref{eqn:tensorBCA}, the map  $\varphi_{BC}$ together with Poincar\'e duality on the fibers of the projection $\cE^r\ra \cE^{r_1}$ induced by $A$, give rise to a pullback operation on sheaves
\begin{equation}\label{pb}
\cL_{r_2}\otimes \cL_{r_3} \lra \cL_A(-t) 
%\cL_A \otimes \cZ_{A'} = ,
\end{equation}
where $t:= |A'|=r-r_1$ satisfies $k = \ell + m -2-2t$. We hence obtain a map
$$
\varphi_{A,BC}^* : \Omega^1_{\rig}(\cW_\epsilon\times\cW_\epsilon, \cL_{r_2}\otimes\cL_{r_3}) \lra \Omega^1_{\rig}(\cW_\epsilon, \cL_A(-t)).
$$
Set
\begin{equation}\label{def-varphi}
\varphi^\ast:=\begin{cases}
\varphi_{23}^\ast & \mbox{ if } (k,\ell,m)=(2,2,2), \\
\varphi_{A,BC}^\ast & \mbox{otherwise.}
\end{cases}
\end{equation}

\begin{corollary}
\label{cor:closedexact}
If $\sigma\in \Omega^1(\cW_\epsilon\times\cW_\epsilon,\cL_{r_2}\otimes \cL_{r_3})$ is 
$\nabla$-closed, then $\varphi^\ast (\sigma)$ is $\nabla$-exact on $\cW_\epsilon$. 
\end{corollary}

\begin{proof}
If $(r_1,r_2,r_3)=(0,0,0)$, this is just Lemma \ref{lemma:epsilon-is-0}. If $r_3,r_2>0$, by 
the K\"unneth decomposition we have
\begin{eqnarray*}
H^1_{\dR}(X'\times X', \cL_{r_2}\otimes \cL_{r_3}) &\simeq &
H^1_{\dR}(X', \cL_{r_2})\otimes H^0_{\dR}(X', \cL_{r_3}) \\
 & & \qquad \oplus \ \ H^0_{\dR}(X', \cL_{r_2})\otimes H^1_{\dR}(X', \cL_{r_3}),
\end{eqnarray*}
and these modules vanish because the sheaves $\cL_{r_2}$ and $\cL_{r_3}$ 
have no global horizontal sections   (cf. \cite[Lemma 2.1]{BDP1}).
In light of \eqref{eqn:alg-to-rig-k} we deduce that in fact $\sigma$
 is already exact, and a fortiori so is $\varphi^\ast (\sigma)$.
\end{proof}

\begin{proposition}\label{defxi}
The element 
$$ \xi(P,\omega_2,\omega_3) := \rm{class \ of  } \   \varphi^\ast \rhop \ \rm{ in }  \ 
H^1_{\rig}(\cW_\epsilon, \cL_A(-t))  
$$ 
does not depend on the choice of rigid differential $\rhop$ satisfying
\eqref{eqn:diff-eqn-xi-k} of Lemma \ref{lemma:xi-k} and
has vanishing annular residues. In particular, $\xi(P,\omega_2,\omega_3)$ belongs to $H^1_{\dR}(X, \cL_A(-t))$.
\end{proposition}


\begin{proof}
The first assertion is a direct consequence of Corollary \ref{cor:closedexact}. In light of \eqref{res-map} and the discussion following it, the second assertion follows the condition (ii) satisfied by $P$. 
\end{proof}


%The Frobenius endomorphism $\Phi$ acts on $H^1_{\dR}(X_{\C_p})$ with
%eigenvalues of complex absolute value $\sqrt{p}$, and in particular, it is invertible. 

The Frobenius endomorphism $\Phi$ acts on $H^1_{\dR}(X,\cL_A(-t))$ with
eigenvalues of complex absolute value $\sqrt{p}^{1+r_2+r_3}$. 
Therefore, since the roots of $P$ have absolute value either $p^{r+1}$ or $\sqrt{p}^{2+r_2+r_3}$, the endomorphism $P(\Phi)$ acts invertibly on $H^1_{\dR}(X,\cL_A(-t))$. In particular, for all $\eta \in H^1_{\dR}(X, \cL_A(-t))$, the class
$P(\Phi)^{-1}\eta$ is well-defined.
Furthermore, the class
\begin{equation}
\label{eqn:def-xi-noP}
\xi(\omega_2,\omega_3) := P(\Phi)^{-1} \xi(P,\omega_2,\omega_3) \in  
H^1_{\rig}(\cW_\epsilon, \cL_A(-t))  
\end{equation}
does not depend on the choice of  polynomial $P$.
 More precisely, replacing $P$ by a polynomial $PQ$ satisfying the conditions 
 before the statement of Lemma \ref{lemma:xi-k}, 
one sees that
$$ \rho(PQ,\omega_2,\omega_3)  = Q(\Phi) \rhop, \qquad \xi(PQ,\omega_2,\omega_3)  = Q(\Phi) \xi(P,\omega_2,\omega_3).$$





We will now describe (part of) the image of the generalized Gross-Kudla-Schoen cycle
$\Delta_{k,\ell,m}$ under the $p$-adic Abel-Jacobi map.
More precisely, we will   describe the restriction of the functional 
 $\AJ_p(\Delta_{k,\ell,m})$ to the summand
\begin{equation}
\label{eqn:direct-summand}
H^1_{\dR}(X,\cL_{r_1}) \otimes H^0(X,\underline{\omega}^{r_2}\otimes\Omega^1_X) \otimes
H^0(X,\underline{\omega}^{r_3}\otimes\Omega^1_X) \subseteq H^{2r+3}_{\dR}(W),
\end{equation}
where the inclusion arises from the K\"unneth decomposition as
in \eqref{eqn:kunneth-decomp}.

Let $\iota_A: \cE^{A} \lra \cE^{r_1}$ denote the natural isomorphism between the varieties $\cE^{A}:=\cE_{a_1}\times_X \times ... \times_X \cE_{a_{r_1}}$ and $\cE^{r_1}$, giving rise to an isomorphism of sheaves between $\cL_{r_1}$ and $\cL_A$.

\begin{theorem}
\label{thm:AJp-theoretical-k}
 Let $\eta\otimes\omega_2\otimes \omega_3$
be any class in \eqref{eqn:direct-summand}. 
Then
\begin{equation}
\label{eqn:AJp-formula-k}
\AJ_p(\Delta_{k,\ell,m})(\eta\otimes \omega_2 \otimes  \omega_3)  =
  \langle \iota_A^*\eta,   \xi(\omega_2,\omega_3) \rangle,
  \end{equation}
where 
$$ \langle \ ,\  \rangle: H^1_{\dR}(X,\cL_A) \times H^1_{\dR}(X,\cL_A(-t)) \lra \C_p(-1-r)$$
 arises from   Poincar\'e duality.
\end{theorem}


\begin{remark}
The reader mainly interested in the case $(k,\ell,m)=(2,2,2)$ will
 notice that Theorem \ref{thm:AJp-theoretical-k} asserts
  that the image of the Gross-Kudla-Schoen cycle $\Delta_{2,2,2}$ 
  in $X^3$ under the $p$-adic Abel-Jacobi map satisfies
\begin{equation}
\AJ_p(\Delta_{2,2,2})(\eta\otimes \omega_2 \otimes  \omega_3)  =
  \langle \eta,    \xi(\omega_2,\omega_3) \rangle,
\end{equation}
where $\langle \ ,\  \rangle$ is the usual   Poincar\'e duality pairing
 on $H^1_{\dR}(X)$.
\end{remark}

\subsection{Proof of the formula: 
Besser's finite polynomial cohomology}

The goal of this section is proving Theorem \ref{thm:AJp-theoretical-k}, and to do that we first set some notation. Let $V$ be a smooth, proper, irreducible variety of dimension $d$ over $\Q_p$ which admits a smooth proper, flat model $\cV$ over $\Z_p$. There are {\em syntomic} and {\em finite polynomial} cohomology groups $$H^i_{\syn}(\cV,n)\subseteq H^i_{\fp}(\cV,n)$$ for every $i, n\geq 0$ (cf.\,e.g.\,\cite{Bes-inv} and the references therein). These groups are related to the $p$-adic de Rham cohomology of $V$ by the following diagram (cf.\,\cite[Prop.\,2.5 (1-2)]{Bes-inv}):
\begin{equation}\label{comp-syn-dR}
\xymatrix{
0 \ar[r] &   H^{i-1}_{\dR}(V)/\Fil^n H^{i-1}_{\dR}(V) \ar[r]^{\quad\quad\quad\mathrm{i}_{\syn}}\ar@{=}[d]  &  H^{i}_{\syn}(\cV,n) \ar[r]^{\mathrm{p}_{\syn}}\ar[d] & \Fil^{n} H_{\dR}^{i}(V)\ar@{=}[d]  & \\
0 \ar[r] &   H^{i-1}_{\dR}(V)/\Fil^n H^{i-1}_{\dR}(V)  \ar[r]^{\quad\quad\quad\mathrm{i}_{\fp}} &  H^{i}_{\fp}(\cV,n) \ar[r]^{\mathrm{p}_{\fp}} & \Fil^{n} H_{\dR}^{i}(V) \ar[r] & 0,
}
\end{equation}
in which the rows are exact. In addition there are compatible cycle class maps
$$
\xymatrix{
\CH^i(\cV) \ar[d] \ar[r]^{\cl_{\syn}}  \ar@/^2pc/[rr]^{\cl_{\fp}}  & H_{\syn}^{2i}(\cV,i) \ar[dr]^{\mathrm{p}_{\syn}} \ar[r] & H^{2i}_{\fp}(\cV,i) \ar[d]^{\mathrm{p}_{\fp}}\\
\CH^i(V) \ar[rr]^{\cl_{\dR}} &  & \Fil^i H^{2i}_{\dR}(V)
}
$$
which give rise (by the formalism of e.g. \cite[(1.2)]{Nek-survey}) to the {\em $p$-adic Abel-Jacobi maps}
\begin{equation}
\AJ_p: \CH^{i}(V)_0 \lra \ker (\mathrm{p}_{\syn}) = H_{\dR}^{2i-1}(V)/\Fil^i(H_{\dR}^{2i-1}(V)) \simeq \Fil^{d-i+1} H^{2d-2i+1}_{\dR}(V)^\vee
\end{equation}
that we already introduced in \eqref{AJpp}. Besides the definition of $\AJ_p$ given in \eqref{AJpExt}, Besser proved in  \cite[Theorem 1,2]{Bes-inv} that the $p$-adic Abel-Jacobi map may be expressed purely in terms of Coleman integration. 

Namely, let $\Delta=\sum a_j \Delta_j$ be a representative of a class in $\CH^{i}(\mathcal V)_0$, with $a_j\in \Q$ and $\Delta_j$ irreducible, smooth proper subschemes of $\mathcal V$ over $\Z_p$. Besser showed that $\AJ_p$ sends the null-homological cycle $\Delta$ to the functional
\begin{equation}\label{AJpBes}
\AJ_p(\Delta): \Fil^{d-i+1} H^{2d-2i+1}_{\dR}(V) \lra \Q_p, \, \omega \mapsto \int_{\Delta} \omega := \sum a_j \tr(\iota_j^*(\tilde \omega)),
\end{equation}
where $\tilde\omega \in H^{2d-2i+1}_{\fp}(\mathcal V,d-i+1)$ is a lift of $\omega$ under the map $\mathrm{p}_{\fp}$ appearing in \eqref{comp-syn-dR}, $\iota_j: \Delta_j \hookrightarrow \mathcal V$ is the natural inclusion and 
$$
\tr: H^{2d-2i+1}_{\fp}(\Delta_j,d-i+1) \overset{\sim}{\lra} \Q_p
$$
is the canonical trace isomorphism (\cite[Prop.\,2.5 (4)]{Bes-inv}). 

It is Besser's formula \eqref{AJpBes} which we shall apply in order to prove Theorem \ref{thm:AJp-theoretical-k}.  As a final piece of notation, let 
\begin{equation}\label{cup-fp}
\langle\,,\rangle_{\fp}: H_{\fp}^i(\mathcal V,n) \times H^{2d+1-i}_{\fp}(\mathcal V,d+1-n) \lra \Q_p
\end{equation}
denote the cup product in finite polynomial cohomology described in \cite[Prop.\,2.5 (4)]{Bes-inv}. 


We first focus in the particular case $(k,\ell,m)=(2,2,2)$. 
%Note that, since \eqref{eqn:AJp-formula-k} depends linearly on the $1$-form $\eta\in H^1_{\dR}(X)$, it suffices to prove it for the elements of a %basis of this space. Recall that $H^1_{\dR}(X)$ admits a slope decomposition, and is therefore generated by forms which are eigenvectors under %the Frobenius endomorphism, of slope $t=0$ or $1$. Hence we can assume, without loss of generality, that the form $\eta$ is one of those.
Set
$$
\begin{matrix}
\varphi_{\dR,*}:= \iota_{23,\dR,*}-\iota_{2,\dR,*}-\iota_{3,\dR,*}: H^1_{\dR}(X)\lra \Fil^1 H^3_{\dR}(X^2),\\ \\ \varphi_{\fp,*}:= \iota_{23,\fp *}-\iota_{2,\fp *}-\iota_{3,\fp *}: H^1_{\fp}(\cX,0) \lra  H_{\fp}^3(\cX^2,1)
\end{matrix}
$$ 
to be the maps induced by push-forward by the three embeddings $\iota_2$, $\iota_3$, $\iota_{23}$ introduced in \eqref{horveremb} and \eqref{diagemb} on de Rham and finite polynomial cohomology, respectively. 

By \cite[Proposition 2.5 (1) and Lemma 5.1]{Bes-inv}, 
%the push-forward maps induced by the embedding $\iota$ in de Rham and finite polynomial cohomology give rise to 
there is a commutative diagram
\begin{equation}\label{Besser51}
\xymatrix{ 
 &    0 \ar[r]^{i_1}   \ar[d]  & H^1_{\fp}(\cX,0)  \ar[r]^{\mathrm{p}_1}  \ar[d]_{ \varphi_{\fp,*}}  & H^1_{\dR}(X)  \ar[r] \ar[d]_{\varphi_{\dR,*}}  & 0 \\     
0   \ar[r] & \frac{H^2_{\dR}(X^2)}{\Fil^1 H^2_{\dR}(X^2)} \ar[r]^{i_2}  & H_{\fp}^3(\cX^2,1) 
\ar[r]^{\mathrm{p}_2}  & \Fil^1 H^3_{\dR}(X^2) \ar[r]  & 0   }
\end{equation} 
with exact rows arising from \eqref{comp-syn-dR}.

Let $\tilde \eta \in H^1_{\fp}(\cX,0)$ be a preimage of $\eta$ under $\mathrm{p}_1$ and  $\tilde{\omega}_2$, $\tilde{\omega}_3\in H^1_{\fp}(\cX,1)$ be preimages of $\omega_2$ and $\omega_3$ respectively, so that $\tilde{\omega}_2\otimes \tilde{\omega}_3$ is a preimage in $H^2_{\fp}(\cX^2,2)$ of $\omega_2\otimes \omega_3\in \Fil^2 H^2_{\dR}(X^2)$. 

\begin{lemma}\label{X3toX2} The following equality holds in $\Q_p$:
\begin{equation*}
\langle \cl_{\fp}(\Delta_{2,2,2}),\tilde{\eta} \otimes \tilde{\omega}_2\otimes \tilde{\omega}_3 \rangle_{\fp} =  \langle \varphi_{\fp *}(\tilde \eta), \tilde{\omega}_2\otimes \tilde{\omega}_3\rangle_{\fp}.
\end{equation*}
\end{lemma}

\begin{proof}
The class of the cycle $\cX_{123}-\cX_{12}-\cX_{13}-\cX_{23}+\cX_1+\cX_2+\cX_3$
is an integral, smooth proper model of $\Delta_{2,2,2}$ in $\CH^2(\cX^3)_0$. Hence
$$
\langle \cl_{\fp}(\Delta_{2,2,2}),\tilde{\eta} \otimes \tilde{\omega}_2\otimes \tilde{\omega}_3 \rangle_{\fp} = -\sum_{I} (-1)^{|I|} \tr_{\cX}(\iota_I^*(\tilde{\eta} \otimes \tilde{\omega}_2\otimes \tilde{\omega}_3))
$$
where $I$ ranges through the seven non-empty subsets of $\{1,2,3\}$ and $\tr_{\cX}: H^3_{\fp}(\cX,2)\overset{\sim}{\lra} \Q_p$ is Besser's trace isomorphism. For $I=123$, $12$ and $13$, it follows from the very definitions that the above traces may be recast as the cup-products
$$
\begin{matrix}
\tr_{\cX}(\iota_{123}^*(\tilde{\eta} \otimes \tilde{\omega}_2\otimes \tilde{\omega}_3)) & = \langle \tilde{\eta}, (\tilde{\omega}_2\otimes \tilde{\omega}_3)_{|\cX_{23}}\rangle_{\fp} \\
\tr_{\cX}(\iota_{12}^*(\tilde{\eta} \otimes \tilde{\omega}_2\otimes \tilde{\omega}_3)) & = \langle \tilde{\eta}, (\tilde{\omega}_2\otimes \tilde{\omega}_3)_{|\cX_{2}}\rangle_{\fp} \\
\tr_{\cX}(\iota_{13}^*(\tilde{\eta} \otimes \tilde{\omega}_2\otimes \tilde{\omega}_3)) & = \langle \tilde{\eta}, (\tilde{\omega}_2\otimes \tilde{\omega}_3)_{|\cX_{3}}\rangle_{\fp}
\end{matrix}
$$
on $\cX$, while $\tr_{\cX}(\iota_I^*(\tilde{\eta} \otimes \tilde{\omega}_2\otimes \tilde{\omega}_3))$ vanishes for the remaining four choices of $I$. 

On the other hand, the push-forward map $\varphi_{\fp *}$ is dual under cup-product \eqref{cup-fp} to the pull-back homomorphism $\varphi_{\fp}^*=\iota^*_{23,\fp}-\iota^*_{2,\fp}-\iota^*_{3,\fp}: H^2_{\fp}(\cX^2,2)\ra H^2_{\fp}(\cX,2)$, and hence 
$$
\langle \varphi_{\fp *}(\tilde \eta), \tilde{\omega}_2\otimes \tilde{\omega}_3\rangle_{\fp} = \langle \tilde{\eta}, (\tilde{\omega}_2\otimes \tilde{\omega}_3)_{|\cX_{23}}\rangle_{\fp}-\langle \tilde{\eta}, (\tilde{\omega}_2\otimes \tilde{\omega}_3)_{|\cX_{2}}\rangle_{\fp}-\langle \tilde{\eta}, (\tilde{\omega}_2\otimes \tilde{\omega}_3)_{|\cX_{3}}\rangle_{\fp}.
$$
This proves the lemma.
\end{proof}


Lemma \ref{X3toX2} combined with \eqref{AJpBes} yields 
%(using e.g.\,\cite[(14)]{Bes-inv})  
\begin{equation}\label{comp:syn-fp}
\AJ_p(\Delta_{2,2,2})(\eta \otimes \omega_2\otimes \omega_3) = \langle \varphi_{\fp *}(\tilde \eta), \tilde{\omega}_2\otimes \tilde{\omega}_3\rangle_{\fp}.
\end{equation} 


%Let $\iota: \cX \hookrightarrow \cX^2$ be any closed immersion of schemes. 
 %Since $\varphi_{\dR,*}$ 
%is the zero map on  $H^1_{\dR}(X)$ by Lemma \ref{lemma:epsilon-is-0}, $\varphi_{\fp *}(\tilde \eta)$ lies in the kernel of the projection %$\mathrm{p}_2$ in diagram \eqref{Besser51}.
%; choose a preimage $i_2^{-1} \varphi_{\fp *}(\tilde \eta)$ in $\frac{H^2_{\dR}(X^2)}{\Fil^1 H^2_{\dR}(X^2)}$. 
%By \eqref{AJpBes} and \cite[p.\,415]{Bes-inv},
%\begin{equation}\label{AJp-cup}
%\AJ_p(\Delta)(\eta \otimes \omega_2\otimes \omega_3) = \int_\Delta \omega = \langle \cl_{\fp}(\Delta),\tilde{\eta} \otimes \tilde{\omega}_2\otimes \tilde{\omega}_3 \rangle_{\fp},
%\end{equation} 
%Note that the right hand-side of \eqref{comp:syn-fp} does not depend on the choice made, because $$\langle \Fil^1 H^2_{\dR}(X^2), \omega_2\otimes \omega_3 \rangle = \langle \Omega^1(X)\otimes %H^1_{\dR}(X) + H^1_{\dR}(X)\otimes \Omega^1(X), \omega_2\otimes \omega_3 \rangle = 0.$$
By the functoriality of \cite[(8)]{Bes-inv}, there is another commutative
 diagram with exact rows
\begin{equation}
\label{Besser51b}
\xymatrix {
0 \ar[r]  & H^1_{\dR}(X^2) \ar[r]^{\mathrm{i}} \ar[d]_{\varphi_{\dR}^*}   & H^2_{\fp}(\cX^2,2)  \ar[r]^{\mathrm{p}\quad }
\ar[d]_{ \varphi_{\fp}^*}   & \Fil^2 H^2_{\dR}(X^2) \ar[r] \ar[d]_{ \varphi_{\dR}^*} & 0 \\
  0  \ar[r]  & H^1_{\dR}(X) \ar[r]^{\mathrm{i}}  & H_{\fp}^2(\cX,2) \ar[r]^{\mathrm{p}\qquad}  & \Fil^2 H^2_{\dR}(X)=0.    & }
\end{equation} 
In light of \cite[Def.\,2.2 and eq.\,(6)]{Bes-inv}, a pair 
$$(\alpha,\beta)\in \Omega^1_{\rig}(\cW_\epsilon^2)\oplus \Fil^2 H^2_{\dR}(X^2)=\Omega^1_{\rig}(\cW_\epsilon^2)\oplus \Omega^2(X^2)$$
 satisfying  $d\alpha=P(\Phi)(\beta)$ gives rise to a class in $H^2_{\fp}(\cX^2,2)$. Since the map $\mathrm{p}$ of the upper row of \eqref{Besser51b} is the projection $[\alpha,\beta]\mapsto [\beta]$ to the second factor, the class $\tilde{\omega}_2\otimes \tilde{\omega}_3$ in $H^2_{\fp}(\cX^2,2) $ may be represented by the pair $$(\rho,\omega_2\otimes \omega_3)\in \Omega^1_{\rig}(\cW_\epsilon^2)\oplus \Omega^2(X^2),$$
 where $\rho:=\rho(P,\omega_2,\omega_3)$ is as in Lemma \ref{lemma:xi-k}. 
Since $\Fil^2 H^2_{\dR}(X)=0$, the class $\varphi_{\fp}^*(\tilde{\omega}_2\otimes \tilde{\omega}_3)$ has a preimage in $H^1_{\dR}(X)$ under the map $\mathrm{i}$ of the lower row of \eqref{Besser51b}. Such preimage is the class of $\xi:=\xi(\omega_2,\omega_3)\in H^1_{\dR}(X)$, as 
\begin{equation}\label{sss}
i(\xi):=[P(\Phi)\xi,0] = [\varphi^* \rho,0] = \varphi_{\fp}^*(\tilde{\omega}_2\otimes \tilde{\omega}_3)\in H^2_{\fp}(\cX,2).
\end{equation}

From this we find, as desired, that
$$\langle \varphi_{\fp *}(\tilde \eta), \tilde{\omega}_2\otimes \tilde{\omega}_3\rangle_{\fp} = \langle \tilde \eta , \varphi_{\fp}^*(\tilde{\omega}_2\otimes \tilde{\omega}_3) \rangle_{\fp} = \langle \tilde \eta , i(\xi) \rangle_{\fp} = \langle \eta, \xi\rangle,
$$
where the first equality follows from the functoriality of the cup product, the second is \eqref{sss} and the third is a direct consequence of \cite[(14)]{Bes-inv}. 


\vspace{0.4cm}

This concludes the proof of Theorem \ref{thm:AJp-theoretical-k} in the case where all three weights are equal to $2$. We turn now to show how a similar approach yields Theorem \ref{thm:AJp-theoretical-k} in the remaining cases, that is to say, when either $(r_1,r_2,r_3)=(0,r,r)$ with $r>0$ or $(r_1,r_2,r_3)$ with $r_3\geq r_2\geq r_1>0$ and $r_3\leq r_1+r_2$. 

By a slight abuse of notation, let us still denote $W$ the base change of the triple product $\cE^{r_1}\times \cE^{r_2}\times \cE^{r_3}$ to $\Q_p$, which recall has dimension $r_1+r_2+r_3+3=2r+3$. 

Let $\eta\in H^1_{\dR}(X,\cL_{r_1})\subset H^{r_1+1}_{\dR}(\cE^{r_1})$ and
$$
\omega_2\in H^1_{\dR}(X,\omega^{r_2}\otimes \Omega^1_X)\subset \Fil^{r_2+1}H_{\dR}^{r_2+1}(\cE^{r_2}), \quad \omega_3\in H^1_{\dR}(X,\omega^{r_3}\otimes \Omega^1_X)\subset \Fil^{r_3+1}H_{\dR}^{r_3+1}(\cE^{r_3})
$$
be classes as in \eqref{eqn:direct-summand}, which we may interchangeably regard either as $\cL_{r_i}$-valued $1$-forms on $X$ or as $(r_i+1)$-forms on $\cE^{r_i}.$ We thus have $$\eta\otimes \omega_2\otimes \omega_3\in \Fil^{r_2+r_3+2} H^3_{\dR}(X^3,\cL_{r_1}\otimes \cL_{r_2}\otimes \cL_{r_3})\subset \Fil^{r_2+r_3+2} H^{2r+3}_{\dR}(W).$$

Denote $\mathfrak{E}^r$ the canonical integral, smooth and proper model of $\cE^r$ over $\Z_p$.
Let  $$\tilde{\eta}\in H^{r_1+1}_{\fp}(\mathfrak{E}^{r_1},-t), \,\,\tilde{\omega}_2\in H^{r_2+1}_{\fp}(\mathfrak{E}^{r_2},r_2+1) \,\, \mbox{ and }  \,\,\tilde{\omega}_3\in H^{r_3+1}_{\fp}(\mathfrak{E}^{r_3},r_3+1)$$ be, respectively, lifts of $\eta$, $\omega_2$ and $\omega_3$ in finite polynomial cohomology, and write $\tilde{\eta} \otimes \tilde{\omega}_2\otimes \tilde{\omega}_3\in H_{\fp}^{2r+3}(\mathcal W,r+2)$ for their tensor product.

Similarly as for $\varphi_{BC}$ and $\varphi_{ABC}$, write $\varphi_A: \cE^r\lra \cE^{r_1}$, $(x;P_1,...,P_r)\mapsto (x;P_{a_1},...,P_{a_{r_1}})$ for the natural projection induced by the choice of the subset $A$ of $\{1,...,r\}$. 

\begin{lemma}
We have 
\begin{equation}
\AJ_p(\Delta_{k,\ell,m})(\eta \otimes \omega_2\otimes \omega_3) =\langle \varphi_{A,\fp}^*(\tilde \eta),  \varphi_{BC,\fp}^*(\tilde{\omega}_2\otimes \tilde{\omega}_3)\rangle_{\mathfrak{E}^r,\fp}.
\end{equation}
\end{lemma}

\begin{proof} Cycle $\Delta_{k,\ell,m}$ is a linear combination $\sum_j a_j \Delta_j$, where $a_j\in \Q$ and $\Delta_j$ are irreducible subvarieties of $W$, all of which are the image of $\cE^r$ under a closed embedding $\iota_j: \cE^r\hookrightarrow W$; see Definitions \ref{def:Delta2ll} and \ref{def:Deltaklm} for more details. These embeddings lift in a natural way to proper maps $\iota_j: \mathfrak{E}^r\hookrightarrow \cW$, and $\sum a_j \iota_j(\mathfrak{E}^r)$ is thus a representative of $\Delta_{k,\ell,m}$ in $\CH^{r+2}(\cW)_0$.

By Besser's formula \eqref{AJpBes}, 
\begin{equation}\label{fBes}
\AJ_p(\Delta_{k,\ell,m})(\eta \otimes \omega_2\otimes \omega_3) = \langle \cl_{\fp}(\Delta_{k,\ell,m}),\tilde{\eta} \otimes \tilde{\omega}_2\otimes \tilde{\omega}_3 \rangle_{\fp}=\sum_j a_j \tr_{\mathfrak{E}^r}(\iota_j^*(\tilde{\eta} \otimes \tilde{\omega}_2\otimes \tilde{\omega}_3)).
\end{equation}

If $k=2$ (and thus $\ell = m\geq 3$), according to  Definition \ref{def:Delta2ll} then half of the terms in the above sum correspond to the image of $\{o\}\times \varphi_{BC}(\cE^r)$ under some automorphism of $\cE^{r_1}\times \cE^{r_2}\times \cE^{r_3}$ that acts as the identity on the copy of $\cE^{r_1}$. Here $o$ is some choice of a base point in $\cE^{r_1}$. For such embeddings, it follows that $\iota_j^*(\tilde{\eta} \otimes \tilde{\omega}_2\otimes \tilde{\omega}_3))$ vanishes, and hence those terms do not contribute to the sum in \eqref{fBes}. 

In view of this and Definition \ref{def:Deltaklm}, for any balanced triple $(k,\ell,m)\ne (2,2,2)$ we conclude that
%after writing the correspondence $(\epsilon_{r_1},\epsilon_{r_2},\epsilon_{r_3})$ on $\cW$ as $\sum r_j (\alpha_1,\alpha_2,\alpha_3)$
$\AJ_p(\Delta_{k,\ell,m})(\eta \otimes \omega_2\otimes \omega_3)$ is equal to a linear combination of the form 
\begin{equation}\label{linear-comb}
\sum a_{\alpha_1,\alpha_2,\alpha_3}\tr_{\mathfrak{E}^r}(\varphi_{ABC}^*\circ (\alpha_1\otimes \alpha_2\otimes \alpha_3)^*(\tilde{\eta} \otimes \tilde{\omega}_2\otimes \tilde{\omega}_3))
\end{equation}
where $\alpha_i$ are automorphisms of $\mathfrak E^{r_i}$ for $i=1,2,3$ and the scalars $a_{\alpha_1,\alpha_2,\alpha_3}$ are each equal to $\pm \frac{1}{2^n}$ for some $n\geq 0$. We refer to \S \ref{cycles} for the explicit description of the automorphisms $\alpha_i$ that intervene here; all them satisfy $\alpha_i^*(\tilde\omega)=\pm \tilde\omega \in H^{r_i+1}_{\fp}(\mathfrak{E}^{r_i},\cdot)$ for the classes in play, so that $\tr_{\mathfrak{E}^r}(\varphi_{ABC}^*\circ (\alpha_1\otimes \alpha_2\otimes \alpha_3)^*(\tilde{\eta} \otimes \tilde{\omega}_2\otimes \tilde{\omega}_3)) = \pm \tr_{\mathfrak{E}^r}(\varphi_{ABC}^*(\tilde{\eta} \otimes \tilde{\omega}_2\otimes \tilde{\omega}_3))$. It is a simple combinatorial exercise to check that the terms in \eqref{linear-comb} sum up to $\tr_{\mathfrak{E}^r}(\varphi^*_{ABC,\fp}(\tilde \eta\otimes \tilde{\omega}_2\otimes \tilde{\omega}_3))$.

By Besser's definitions of trace and cup-product in finite polynomial cohomology, it directly follows that $\tr_{\mathfrak{E}^r}(\varphi^*_{ABC,\fp}(\tilde \eta\otimes \tilde{\omega}_2\otimes \tilde{\omega}_3))=\langle \varphi_{A,\fp}^*(\tilde \eta),  \varphi_{BC,\fp}^*(\tilde{\omega}_2\otimes \tilde{\omega}_3)\rangle_{\mathfrak{E}^r,\fp}$.
\end{proof}



%The class of $\varphi_{BC,\dR}^*(\omega_2\otimes \omega_3)$ in $H_{\dR}^{r_2+r_3+2}(\cE^{r})$ vanishes and hence $\varphi_{BC,%\fp}^*(\tilde{\omega}_2\otimes \tilde{\omega}_3)\in H^{r_2+r_3+2}_{\fp}(\cE^{r},r_2+r_3+2)$ lies in the kernel of the map $\mathrm{p}$ in %the lower exact row of \eqref{comp-syn-dR}. 

The class $\varphi_{BC,\dR}^*(\omega_2\otimes \omega_3)$ in de Rham cohomology vanishes, because it lies in $\epsilon_r H^{r_2+r_3+2}_{\dR}(\cE^r)$ and the idempotent $\epsilon_r$ annihilates $H^{j}_{\dR}(\cE^r)$ for all $j\ne r+1$; note that indeed $r_2+r_2+2\ne r+1$ because the triplet $(k, \ell, m)$ is balanced. Hence the pair $(\varphi_{BC}^*(\rho(P,\omega_2,\omega_3)),0)$ is a representative of $\varphi_{BC,\fp}^*(\tilde{\omega}_2\otimes \tilde{\omega}_3)$ in finite polynomial cohomology. 

It follows  exactly as in \eqref{sss} that $P(\Phi)^{-1} \varphi_{BC}^*(\rho(P,\omega_2,\omega_3))$ is a preimage of the class $\varphi_{BC,\fp}^*(\tilde{\omega}_2\otimes \tilde{\omega}_3)$ under Besser's map $$\mathrm{i}: H^{r_2+r_3+1}_{\dR}(\cE^{r})/\Fil^{r_2+r_3+2}(H^{r_2+r_3+1}_{\dR}(\cE^{r}))\lra H^{r_2+r_3+2}_{\fp}(\mathfrak{E}^{r},r_2+r_3+2).$$ It thus again follows that
\begin{equation}\label{2to1}
\langle \varphi_{A,\fp}^*(\tilde \eta),  \varphi_{BC,\fp}^*(\tilde{\omega}_2\otimes \tilde{\omega}_3)\rangle_{\cE^r,\fp} = \langle \varphi_{A,\dR}^*(\eta), P(\Phi)^{-1} \varphi_{BC}^*(\rho(P,\omega_2,\omega_3))\rangle_{\E^r,\dR}.
\end{equation}

Pulling-back under the natural immersion $\cE^{r_1}\hookrightarrow \cE^r$ induced by $A$, we obtain that the right-hand side of \eqref{2to1} equals
%\vspace{0.5cm}
%Checking the numerology: for this we apply on the nose the results of Besser in \cite{Bes-inv}, {\em without} using local systems and regarding all these forms as classes in the cohomology groups of Kuga-Sato %varieties, say over $\Q_p$. It is then that we notice that we must indeed consider  $\tilde{\eta}$ in $H^1_{\fp}(\cX,\cL_{r_1},-t)$, because this way $\tilde{\eta} \otimes \tilde{\omega}_2\otimes \tilde{\omega}_3$
%is in $H_{\fp}^{2r+3}(\cW,r_2+r_3+2-t) = H_{\fp}^{2r+3}(\cW,r+2)$. This is what we want, because we are pairing it with $\cl_{\fp}(\Delta)$, which lies in $H_{\fp}^{2r+4}(\cW,r+2)$, and the numerology of the %cup product (Prop. 2.5 (4) of loc. cit.) fits with the numerology here.
%
%Regard now $\tilde{\eta}$ in $H^1_{\fp}(\cX,\cL_{r_1},-t)\subset H_{\fp}^{r_2+r_3+2}(\cE^r,r_2+r_3+2)$ by means of the Leray spectral sequence as above. Apply the push-forward %induced by the map $\varphi_{BC}: \cE^r \lra \cE^{r_2}\times \cE^{r_3}$ If and the formulae of the beginning of \cite[\S 5]{Bes-inv}: we find that $\varphi_{\fp *}(\tilde\eta)$ lies in $H_{\fp}^{r_2+r_3+3}%(\cE^{r_2}\times \cE^{r_3},1)$. This is perfectly compatible with the numerology of Besser's cup-product, given that we are pairing $\varphi_{\fp *}(\tilde\eta)$ with %$\tilde{\omega}_2\otimes \tilde{\omega}_3$.
%\vspace{0.5cm}
%Similarly as in \eqref{Besser51b}, we find a commutative diagram with exact rows
%\begin{equation}
%\label{Besser51bklm}
%\xymatrix {
%0 \ar[r]^<<<<<<<<<<<{\mathrm{i}} \ar[d]   & H^2_{\fp}(\cX^2,\cL_{r_2}\otimes \cL_{r_3},r_2+r_3+2)  \ar[r]^{\mathrm{p}}
%\ar[d]_{ \varphi_{\fp}^*}   & \Fil^{r_2+r_3+2} H^2_{\para}(X^2,\cL_{r_2}\otimes \cL_{r_3}) \ra 0 \ar[d]_{ \varphi_{\dR}^*}  \\
%0\ra H^1_{\para}(X,\cL_A) \ar[r]^<<<<<<{\mathrm{i}}  & H_{\fp}^2(\cX,\cL_A,r_2+r_3+2) \ar[r]^{\mathrm{p}}  & \Fil^{r_2+r_3+2} H^2_{\para}(X,\cL_A)=0.  }
%\end{equation} 
$$ 
\langle  \iota_A^*\eta,   P(\Phi)^{-1}\xi(P,\omega_2,\omega_3) \rangle_{\cE^{r_1},\dR} = \langle  \iota_A^*\eta, \xi(\omega_2,\omega_3) \rangle_{\cE^{r_1},\dR}.
$$ 
Theorem \ref{thm:AJp-theoretical-k} follows.
%\vspace{0.5cm}
%Checking the numerology: by $\varphi_{\fp}^*$ I mean the pullback map $H_{\fp}^{r_2+r_3+2}(\cE^{r_2}\times \cE^{r_3},r_2+r_3+2)\lra H_{\fp}^{r_2+r_3+2}(\cE^r,r_2+r_3+2)$ induced by $\varphi_{BC}: \cE^r %\lra \cE^{r_2}\times \cE^{r_3}$, so that $\varphi_{\fp}^*\tilde{\omega}_2\otimes \tilde{\omega}_3\in H_{\fp}^{r_2+r_3+2}(\cE^r,r_2+r_3+2)$ and it can be indeed paired with $\tilde \eta\in H_{\fp}^{r_2+r_3+2}%(\cE^r,r_2+r_3+2)$; the numerology matches with that of \cite[Prop. 2.5 (4)]{Bes-inv}.




\subsection{A formula for $\AJ_p(\Delta_{k,\ell,m})$ in terms of $p$-adic 
modular forms}


Let $g$ and $h$ denote modular forms of weights $\ell=r_2+2$ and $m=r_3+2$, respectively, on $\Gamma_1(N)$. For the calculations of this section, it is only necessary to assume that $g$ and $h$ are eigenvectors for the Hecke operator $T_p$; in particular it will not be  assumed that
they are new of level $N$. 
Let $\alpha_g$ and $\beta_g$ be the roots of the Hasse polynomial
$x^2-a_p(g) x + \chi_g(p) p^{\ell-1}$ for $g$ at $p$, ordered in such a way that
$\ord_p(\alpha_g) \le \ord_p(\beta_g)$, and let
 \begin{equation}
  \label{eqn:stabilisations-form}
g_\alpha = g - \beta_g Vg, \qquad g_\beta = g-\alpha_g V g
\end{equation}
denote the respective $p$-stabilisations, on which the  $U_p$ operator acts with eigenvalue 
$\alpha_g$ and $\beta_g$ respectively. Similar notational conventions are adopted for $h$.
Note that with these conventions, when $g$ is ordinary then
 $g_\alpha$ is the ordinary $p$-stabilisation of $g$ 
that was previously denoted $g^{(p)} $, but that no ordinariness assumption
on $g$ or $h$ are made in this section.

Let $f$ denote a modular form of weight $k=r_1+2$ on $\Gamma_1(N)$ which is an
eigenvector for all the good Hecke operators, and is ordinary at $p$ (but is not necessarily
new of level $N$) and let 
 $\eta_{f}^{\ur}\in H^1_{\para}(X_{\C_p}, \cL_{r_1})^{\ur}$ be the 
unique lift to the unit root subspace of the  cohomology class  in
 $ H^1(X_{K_{f}},\underline{\omega}^{-r_1})$   attached to $f$ as in 
 Corollary \ref{cor:def-eta-f}.  
 Recall that $e_{\ord}$ denotes Hida's ordinary projector. Let $e_{f^*}$ denote the
 commuting idempotent in the Hecke algebra giving the 
 projection onto the $f^*$-isotypic part,  where $f^*$ is the modular form which
  is dual to $f$, obtained by applying complex conjugation to the Fourier coefficients of $f$,
and set
 $$ e_{f^*,\ord} = e_{f^*} e_{\ord}.$$
 
  The goal of the next two theorems  is to give an explicit expression for the class 
$\xi(\omega_g,\omega_h) \in H^1_{\dR}(X,\cL_{r_1})$  that appears in Theorem
\ref{thm:AJp-theoretical-k}, or rather, its image under $e_{f^*,\ord}$.
 
Theorem \ref{thm:aj-comp-prelim} below treats 
 the setting where $k=\ell=m=2$, 
in which the cycle $\Delta_{2,2,2}$ is simply the Gross-Kudla-Schoen modified diagonal
on $X_1(N)^3$. This setting 
 is notationally simpler and therefore easier to follow, but already brings out the key ideas needed to handle  the general case, which will then be treated in
  Theorem \ref{thm:aj-comp-prelim-general}.
  \begin{theorem} 
 \label{thm:aj-comp-prelim}
 Suppose  that $k=\ell=m=2$, so that $\xi(\omega_g,\omega_h)$ can be viewed as an overconvergent 
 modular form of weight $2$. 
 The ordinary projection $e_{f^*,\ord}(\xi(\omega_g,\omega_h))$ is equal to  the classical
 modular form
 $$ e_{f^*,\ord}(\xi(\omega_g,\omega_h)) = -\frac{\cE_1(f)}{ \cE(f,g,h)} e_{f^*,\ord}(d^{-1}g^{[p]} \times h),$$
 where $\cE_1(f)$ and $\cE(f,g,h)$ are defined as in 
 Theorem \ref{mainDR} of the introduction.
 \end{theorem}
\begin{proof} 
  Let
\begin{eqnarray*} 
P_g(x) = 1-a_p(g)p^{-1} x+ \chi_g(p)p^{-1}x^2 & = &
 (1-\alpha_g p^{-1} x)(1-\beta_g p^{-1} x),   \\
 P_h(x) = 1-a_p(h) p^{-1} x+ \chi_h(p)p^{-1} x^2 & = &
 (1-\alpha_h p^{-1} x)(1-\beta_h p^{-1} x), 
\end{eqnarray*}
denote the Hasse polynomials attached to the  forms $g$ and $h$, 
and set 
\begin{eqnarray*} 
 && P_{gh}(x) =  (1-\alpha_g\alpha_h p^{-2} x) (1-\alpha_g\beta_h p^{-2} x) 
 (1-\beta_g\alpha_h p^{-2} x) (1-\beta_g\beta_h p^{-2} x),  \\
 &&  P_{\alpha\alpha}(x)  =   (1-\alpha_g\alpha_h p^{-2} x)^{-1} P_{gh}(x), \qquad \qquad
 P_{\alpha\beta}(x)  = (1-\alpha_g\beta_h p^{-2} x)^{-1} P_{gh}(x), \\
 &&    P_{\beta\alpha}(x)  =  (1-\beta_g \alpha_h p^{-2} x)^{-1} P_{gh}(x), \qquad\qquad
    P_{\beta\beta}(x)  =  (1-\beta_g \beta_h p^{-2} x)^{-1} P_{gh}(x).
 \end{eqnarray*}
  Recall that $\Phi_2$ and $\Phi_3$ denote the canonical lift $\Phi$  of 
frobenius operating on the Hasse domains, viewed as contained 
in the second and third factors respectively of the three-fold
of $X_1(N)^3$. The operator $\Phi$ is related to the $V$ operator on (nearly) overconvergent
$p$-adic modular forms of weight two by the rule $\Phi = pV$. After writing 
   $\Phi_2 = p V_2$ and $\Phi_3 = p V_3$,
the operator $\Phi := \Phi_2\Phi_3 = p^2 V_2 V_3$ 
corresponds   to the the canonical 
lift of Frobenius  acting on $\Omega^2_{\rig}(\cW_\epsilon\times\cW_\epsilon)$. 

The operators
$P_g(\Phi_2)$ and $P_h(\Phi_3)$ 
annihilate the classes of $\omega_g$  and $\omega_h$
in $H^1_{\rig}(\cW_\epsilon)$. More precisely, as in 
(\ref{eqn:primitive-of-f}),
\begin{eqnarray}
\label{eqn:explicit-primitive}
 P_g(\Phi_2) \omega_{g} &=&
(1-  a_p(g) V_2 + \chi_g(p) p V_2^2 ) g(q)
= g^{[p]}(q)  =    d G^{[p]} , \\
\nonumber
P_h(\Phi_3) \omega_{h} &=&
(1-  a_p(h) V_3 + \chi_h(p) p V_3^2 ) h(q)
= h^{[p]}(q)  =    d H^{[p]} , 
\end{eqnarray}
where $G^{[p]}$ and $H^{[p]}    \in \cO_{\cW_\epsilon}$ are given by
$$ G^{[p]} (q) = d^{-1} g^{[p]} =  \sum_{p\nmid n} \frac{a_n(g)}{n} q^n, \qquad
H^{[p]}(q) = d^{-1} h^{[p]} =  \sum_{p\nmid n} \frac{a_n(h)}{n} q^n.$$
These primitives are overconvergent modular forms of level $N$ and weight $0$. 
Note that they have been normalized so that they vanish at the cusp $\infty$. 

Equation 
\eqref{eqn:explicit-primitive} indicates that
 $P_{gh}(\Phi_2 \Phi_3)$ annihilates the class 
  of the rigid differential $\omega_g \omega_h$
 in 
$H^2_{\dR}(X_1(N)^2)$ .
Hence, there is a rigid one-form $\rho(P_{gh},\omega_g,\omega_h)$ 
satisfying
\begin{equation}
\label{eqn:def-rhoV}
 d\rho(P_{gh},\omega_g,\omega_h) = P_{gh}(\Phi_2 \Phi_3) \omega_g\omega_h.
 \end{equation}
To describe $\rho(P_{gh},\omega_g,\omega_h)$ more explicitly,  we   exploit the
identities
$$ g = (\alpha_g-\beta_g)^{-1} (\alpha_g g_\alpha - \beta_g g_\beta),
\qquad
 h = (\alpha_h-\beta_h)^{-1} (\alpha_h h_\alpha - \beta_h h_\beta) $$
 expressing $g$ and $h$ as linear combinations of the stabilisations appearing 
 in \eqref{eqn:stabilisations-form}.
This leads to an expression for the 
right-hand side  of \eqref{eqn:def-rhoV}
as a sum of four contributions:
$$ P_{gh}(\Phi_2 \Phi_3) \omega_g\omega_h = \theta_{\alpha\alpha} - \theta_{\alpha\beta} - \theta_{\beta\alpha} + \theta_{\beta\beta},$$
where $\theta_{\alpha\alpha}$ is the rigid two-form on $\cW_\epsilon\times \cW_\epsilon$ (for a suitable $\epsilon>0$ given by
\begin{eqnarray}
\nonumber
\theta_{\alpha\alpha} &=& \frac{  \alpha_g \alpha_h P_{gh}(\Phi_2 \Phi_3)(g_\alpha\otimes h_\alpha)}{(\alpha_g-\beta_g) (\alpha_h-\beta_h)} \\
\label{eqn:theta-alpha-alpha}
&=&   \frac{  \alpha_g \alpha_h P_{\alpha\alpha}(\Phi_2 \Phi_3) (1-\alpha_g \alpha_hV_2V_3)(g_\alpha\otimes h_\alpha)}{(\alpha_g-\beta_g) (\alpha_h-\beta_h)} ,
\end{eqnarray}
and $\theta_{\alpha\beta}$ (resp. $\theta_{\beta\alpha}$ and $\theta_{\beta\beta}$) are
defined in the identical way, after replacing  $(\alpha_g,\alpha_h)$ by $(\alpha_g,\beta_h)$ 
(resp.~$(\beta_g,\alpha_h)$, $(\beta_g,\beta_h)$.)
We next observe  that
\begin{eqnarray}
\nonumber
 (1-\alpha_g\alpha_h V_2V_3)(g_\alpha\otimes h_\alpha) &=&
 \frac{1}{2}   \left((1-\alpha_gV_2)(1+\alpha_h V_3)\phantom{^{[]}} + \phantom{^{[]}} (1+\alpha_g V_2)(1-\alpha_hV_3)\right)  g_\alpha\otimes h_\alpha \\
 \label{eqn:part-theta-alpha-alpha}
&=& \frac{1}{2} \left(g^{[p]} \otimes (1+\alpha_h V_3) h_\alpha \phantom{^{[]}} + \phantom{^{[]}}
 (1+\alpha_g V_2) g_\alpha \otimes h^{[p]}\right).
\end{eqnarray}
It follows from \eqref{eqn:theta-alpha-alpha} and 
 \eqref{eqn:part-theta-alpha-alpha}, together with the fact that $d\Phi  =  \Phi d$, that
 \begin{equation}
 \label{eqn:introduce-rho-2}
 \theta_{\alpha\alpha} = d \rho_{\alpha\alpha}, 
 \end{equation}
  where
\begin{equation}
\label{eqn:formula-rho-2}
 \rho_{\alpha\alpha}  =   -\frac{   \alpha_g \alpha_h P_{\alpha\alpha}(\Phi_2 \Phi_3)\left(G^{[p]}
  \otimes (1+\alpha_h V_3) h_\alpha - (1+\alpha_g V_2) g_\alpha \otimes H^{[p]}\right)}{2(\alpha_g-\beta_g) (\alpha_h-\beta_h)}.
  \end{equation}
  The rigid one-forms $\rho_{\alpha\beta}$, $\rho_{\beta\alpha}$, and $\rho_{\beta\beta}$ 
  are defined similarly,   
   after replacing  $(\alpha_g,\alpha_h)$ as before  by $(\alpha_g,\beta_h)$, 
$(\beta_g,\alpha_h)$, and  $(\beta_g,\beta_h)$ respectively, and 
the differential one-form $\rho(P_{gh},\omega_g,\omega_h)$ 
of \eqref{eqn:def-rhoV} 
can be  chosen to be
  $$ \rho(P_{gh},\omega_g,\omega_h) = \rho_{\alpha\alpha} - \rho_{\alpha\beta} - \rho_{\beta\alpha} + \rho_{\beta\beta}.$$
  Let $\xi_{\alpha\alpha}$, $\xi_{\alpha\beta}$, $\xi_{\beta\alpha}$, and $\xi_{\beta\beta}$ 
  denote the pullbacks to the modified diagonal of the one-forms $\rho_{\alpha\alpha}$, $\rho_{\alpha\beta}$, $\rho_{\beta\alpha}$, and $\rho_{\beta\beta}$, so that for example
\begin{equation}
\label{eqn:xi-alpha-alpha}
 \xi_{\alpha\alpha} =  -  \frac{   \alpha_g \alpha_h P_{\alpha\alpha}(\Phi )\left(G^{[p]} \times
 (1+\alpha_h V) h_\alpha - (1+\alpha_g V) g_\alpha  \times H^{[p]}\right)}{2(\alpha_g-\beta_g) (\alpha_h-\beta_h)}.
 \end{equation}
 The frobenius operator $\Phi$ acts on $ e_{f^*,\ord}(H^1_{\rig}(\cW_\epsilon))$ 
 with eigenvalue $p \alpha_{f^*}^{-1} = \beta_f$, and hence, by
 Lemma 
   \ref{lemma:ignore-p}, 
   \begin{eqnarray*}
 e_{f^*,\ord}\left(P_{\alpha\alpha}(\Phi )(G^{[p]}
 (1+\alpha_h V) h_\alpha)\right) &=& P_{\alpha\alpha}(\beta_f) e_{f^*,\ord}(G^{[p]} h), \\
 e_{f^*,\ord}\left( P_{\alpha\alpha}(\Phi )((1+\alpha_g V) g_\alpha H^{[p]})\right) &=& 
 P_{\alpha\alpha}(\beta_f)e_{f^*,\ord}( g  H^{[p]} ). 
 \end{eqnarray*}
 Invoking Lemma \ref{lemma:ignore-p} once again, we find
 $$ e_{f^*,\ord}( g H^{[p]} )  = e_{f^*,\ord}( g^{[p]} H^{[p]} )  = - e_{f^*,\ord}(G^{[p]} h^{[p]})
 = - e_{f^*,\ord}(G^{[p]} h),$$
 where the second equality follows by  noting that 
 $g^{[p]}H^{[p]} + G^{[p]} h^{[p]} = d(G^{[p]}H^{[p]})$ is exact
 and invoking the fact that exact rigid differentials are in the kernel of the ordinary projection.
 Hence applying the projector $e_{f^*,\ord}$ to \eqref{eqn:xi-alpha-alpha}    
 gives
\begin{equation}
\label{eqn:xi-alpha-ord} 
e_{f^*,\ord}(\xi_{\alpha\alpha}) = -\frac{   \alpha_g \alpha_h P_{\alpha\alpha}(\beta_f) }
{(\alpha_g-\beta_g) (\alpha_h-\beta_h)}
e_{f^*,\ord}(G^{[p]}h).
\end{equation}
The definition of $\xi(\omega_g,\omega_h)$ given in 
\eqref{eqn:def-xi-noP} therefore implies
that 
\begin{equation}
\label{eqn:ord-xi-wt2}
 e_{f^*,\ord}(\xi(\omega_g,\omega_h)) = \xi_{\alpha\alpha}' - \xi_{\alpha\beta}'-\xi_{\beta\alpha}' + \xi_{\beta\beta}',
 \end{equation}
 where 
 $$ \xi_{\alpha\alpha}' = - \frac{   \alpha_g \alpha_h   }
{(\alpha_g-\beta_g) (\alpha_h-\beta_h) ( 1- \alpha_g\alpha_h \beta_f p^{-2}) }
e_{f^*,\ord}(G^{[p]}h),$$
and likewise for the other three contributions to $e_{f^*,\ord}(\xi(\omega_g,\omega_h))$. 
A direct calculation   reveals that
\begin{eqnarray*}
\xi_{\alpha\alpha}' - \xi_{\alpha\beta}' &=&  -  \frac{   \alpha_g   }
{(\alpha_g-\beta_g)   ( 1- \alpha_g\alpha_h \beta_f p^{-2})  ( 1- \alpha_g\beta_h \beta_f p^{-2} ) }
e_{f^*,\ord}(G^{[p]}h), \\
\xi_{\beta\alpha}' - \xi_{\beta\beta}' &=&  -  \frac{   \beta_g   }
{(\alpha_g-\beta_g)   ( 1- \beta_g\alpha_h \beta_f p^{-2})  ( 1- \beta_g\beta_h \beta_f p^{-2}) }
e_{f^*,\ord}(G^{[p]}h).
\end{eqnarray*}
Subtracting these two equations  and invoking  \eqref{eqn:ord-xi-wt2} 
 gives
$$ e_{f^*,\ord}(\xi(\omega_g,\omega_h)) = -\frac{(1-\chi_f(p)^{-1} \beta_f^2 p^{-2})}{\cE(f,g,h)} 
e_{f^*,\ord}( d^{-1} g^{[p]} \times h),
$$
as was to be shown.
\end{proof}

We now turn to the case of general weights $(k,\ell,m)$. 
Before stating  the result, 
 recall that the triple of weights $(k,\ell,m)$ is still assumed to be balanced, and that,
 following    notations  similar to those in the proof of Proposition 
 \ref{prop:dtgh-bis},  we have set
 $$ k= \ell+m-2-2t, \quad \mbox{with  $t\ge 0$}, \quad \qquad c = (k+\ell+m-2)/2,$$
so that $\xi(\omega_g,\omega_h)$ corresponds to a class in $H^1_{\dR}(X,\cL_{r_1}(-t))$.

\begin{theorem} 
 \label{thm:aj-comp-prelim-general}
The projection $e_{f^*,\ord}(\xi(\omega_g,\omega_h))$ is represented by the classical 
 modular form
$$ e_{f^*,\ord}(\xi(\omega_g,\omega_h)) =   -\frac{(-1)^t  \cdot t! \cdot \cE_1(f)}{ \cE(f,g,h)} e_{f^*,\ord}(d^{-1-t}g^{[p]} \times h),$$
 where $\cE_1(f)$ and $\cE(f,g,h)$ are defined as in 
 Theorem \ref{mainDR} of the introduction.
 \end{theorem}
\begin{proof} 
 Let $\omega_{g}$ and $ \omega_{h}$ be the global sections
of $\underline{\omega}^{r_2}\otimes \Omega^1_X$ 
and  of $\underline{\omega}^{r_3}\otimes \Omega^1_X$   
over  $X=X_1(N)$
attached to $g$ and $h$ respectively.
Since these sections are algebraic, they can also be viewed as   
$\cL_{r_2}$ and $\cL_{r_3}$-valued
rigid differentials on 
$\cW_\epsilon/\C_p$ 
for any $\epsilon>0$. 
Modifying slightly the definitions of the weight two setting, 
we define
$$ P_g(x) = (1-\alpha_g p^{-r_2-1} x)(1-\beta_g p^{-r_2-1}x), \qquad P_h(x) = (1-\alpha_h p^{-r_3-1} x)(1-\beta_h p^{-r_3-1}x).$$
The   operators
$P_g(\Phi_2)$ and $P_h(\Phi_3)$ 
annihilate the classes of $\omega_{g}$  and $\omega_{h}$
in $H^1_{\rig}(\cW_\epsilon, \cL_{r_2})$ and 
$H^1_{\rig}(\cW_\epsilon,\cL_{r_3})$ respectively, and 
in terms of $q$-expansions,
\begin{eqnarray*} 
P_g(\Phi_2)(\omega_g) &=& (1-\alpha_g V_2)(1-\beta_g V_2) g = g^{[p]},\\
P_h(\Phi_3)(\omega_h) &=& (1-\alpha_h V_3)(1-\beta_h V_3) g = h^{[p]}.
\end{eqnarray*}
 Let $G^{[p]}$ and $H^{[p]}$ denote the overconvergent sections of
 $\cL_{r_2}$ and $\cL_{r_3}$   satisfying
 $$ \nabla G^{[p]} =   \omega_{g^{[p]}}, \qquad
  \nabla  H^{[p]} =   \omega_{h^{[p]}}.$$
  The $q$-expansions of these sections are given in 
  equation \eqref{eqn:rigid-primitive}
 of Section \ref{sec:noc-mfs}, i.e.,
 \begin{eqnarray}
 \label{eqn:expand-G}
 G^{[p]}(q) &=&  \sum_{j=0}^{r_2} 
 (-1)^j  j! {r_2\choose j} d^{-1-j}g^{[p]}(q) \omega_{\can}^{r_2-j} \eta_{\can}^j,\\
\label{eqn:expand-H}
 H^{[p]}(q) &=&  \sum_{j=0}^{r_3} 
 (-1)^j  j! {r_3\choose j} d^{-1-j}h^{[p]}(q) \omega_{\can}^{r_3-j} \eta_{\can}^j.
 \end{eqnarray}
As in the weight two setting, we let   
\begin{eqnarray*}
P_{gh}(x) &= &  (1-\alpha_g\alpha_h p^{-r_2-r_3-2} x) (1-\alpha_g\beta_h p^{-r_2-r_3-2} x) (1-\beta_g\alpha_h p^{-r_2-r_3-2} x)     \\
& & \ \ \ \ \times 
 (1-\beta_g\beta_h p^{-r_2-r_3-2} x). 
 \end{eqnarray*}
Just as before, the operator $P_{gh}(\Phi_2\Phi_3)$ annihilates 
the class of $\omega_g\otimes \omega_h$  in the hypercohomology group
$H^2_{\dR}(X_1(N)^2, \cL_{r_2}\otimes \cL_{r_3})$,
 so  there is
  a rigid  $\cL_{r_2}\otimes \cL_{r_3}$-valued 
   one-form $\rho(P_{gh},\omega_g,\omega_h)$  on $\cW_\epsilon\times\cW_\epsilon$ 
satisfying
\begin{equation}
\label{eqn:def-rhoV-bis}
\nabla \rho(P_{gh},\omega_g,\omega_h) = P_{gh}(\Phi_2 \Phi_3) \omega_g\omega_h.
 \end{equation}

 The same manipulations as in the weight two case allow us to express
 $\rho(P_{gh},\omega_g,\omega_h)$ as a sum of four contributions:
  $$ \rho(P_{gh},\omega_g,\omega_h) = \rho_{\alpha\alpha} - \rho_{\alpha\beta} - \rho_{\beta\alpha} + \rho_{\beta\beta},$$
 where for instance
  $$ \rho_{\alpha\alpha}  =   -\frac{   \alpha_g \alpha_h P_{\alpha\alpha}(\Phi_2 \Phi_3)\left(G^{[p]}
  \otimes (1+\alpha_h V_3) \omega_{h_\alpha} - (1+\alpha_g V_2) \omega_{g_\alpha} \otimes H^{[p]}\right)}{2(\alpha_g-\beta_g) (\alpha_h-\beta_h)},$$
  just as in equations \eqref{eqn:introduce-rho-2} and \eqref{eqn:formula-rho-2}.
Let $\xi_{\alpha\alpha}$, $\xi_{\alpha\beta}$, $\xi_{\beta\alpha}$, and $\xi_{\beta\beta}$ 
  denote the pullbacks to the generalised  diagonal cycle $\cE^r$ 
  of the one-forms $\rho_{\alpha\alpha}$, $\rho_{\alpha\beta}$, $\rho_{\beta\alpha}$, and $\rho_{\beta\beta}$ via the map $\varphi_{BC}$, 
  viewed as overconvergent sections of  $\cL_A(-t)\otimes \Omega^1$  on 
  $\cW_\epsilon$. 
  Write 
  $$ \xi_{\alpha\alpha}^{\noc} = \spl_{\ur} (\xi_{\alpha\alpha}), \qquad
  \xi_{\alpha\alpha}^{\oc} = \Pi_N^{\oc} (\xi_{\alpha\alpha}^{\noc}),$$
  for the nearly overconvergent and overconvergent modular forms attached
  to $\xi_{\alpha\alpha}$. 
  By equation \eqref{eqn:overconvergent-projection} defining 
  $\Pi_N^{\oc}$, the elements $\xi_{\alpha\alpha}$ and $\xi_{\alpha\alpha}^{\oc}$ 
  have the same image in cohomology, and therefore the following equality holds in
  $H^1_{\dR}(X,\cL_{r_1}(-t))$:
  $$ \xi(P_{gh},\omega_g,\omega_h) = \xi_{\alpha\alpha}^{\oc} -\xi_{\alpha\beta}^{\oc} -
  \xi_{\beta\alpha}^{\oc} + \xi_{\beta\beta}^{\oc}.$$
  Applying $e_{f^*,\ord}$ to this equation and invoking Lemma
  \ref{lemma:ordinary-oc} gives
  $$ e_{f^*,\ord}(\xi(P_{gh},\omega_g,\omega_h)) = e_{f^*,\ord}(\xi_{\alpha\alpha}^{\noc}
  -\xi_{\alpha\beta}^{\noc} - \xi_{\beta\alpha}^{\noc} + \xi_{\beta\beta}^{\noc}),$$
and the
  same argument as in the proof of Proposition 
     \ref{prop:dtgh-bis}
  (cf. in particular equation \eqref{eqn:drgh}) shows that
\begin{equation}
\label{eqn:xi-alpha-alpha-bis}
 \xi_{\alpha\alpha}^{\noc} =   -  \frac{   \alpha_g \alpha_h P_{\alpha\alpha}(\Phi )\left(d^{-1-t}g^{[p]}  \times
 (1+\alpha_h V) h_\alpha - (1+\alpha_g V) g_\alpha  \times d^{-1-t} h^{[p]}\right)}{2(\alpha_g-\beta_g) (\alpha_h-\beta_h)}.
 \end{equation}
 By exactly the same reasoning used to obtain \eqref{eqn:xi-alpha-ord} 
 in the weight two case,
 and using the fact that $\Phi$ acts on $e_{f^*,\ord}(H^1_{\dR}(X,\cL_{r_1}(-t)))$ with eigenvalue 
 $ p^{r_1+1+t }\alpha_{f^*}^{-1} = \beta_f p^t$, 
 we find after 
  applying the projector $e_{f^*,\ord}$ to \eqref{eqn:xi-alpha-alpha-bis}    
 that
\begin{equation}
\label{eqn:xi-alpha-ord-bis} 
 e_{f^*,\ord}( \xi_{\alpha\alpha}^{\noc}) = -\frac{ (-1)^t  \cdot t!  \cdot \alpha_g \alpha_h P_{\alpha\alpha}(\beta_f p^t) }
{(\alpha_g-\beta_g) (\alpha_h-\beta_h)}
e_{f^*,\ord}(d^{-1-t} g^{[p]}\times h).
\end{equation}
It now follows 
from \eqref{eqn:def-xi-noP} 
that 
\begin{equation}
 e_{f^*,\ord}(\xi(\omega_g,\omega_h)) = \xi_{\alpha\alpha}' - \xi_{\alpha\beta}'-\xi_{\beta\alpha}' + \xi_{\beta\beta}',
 \end{equation}
 where 
 $$ \xi_{\alpha\alpha}' = - \frac{  (-1)^t t! \alpha_g \alpha_h   }
{(\alpha_g-\beta_g) (\alpha_h-\beta_h) ( 1- \alpha_g\alpha_h \beta_{f}p^{-c} ) }
e_{f^*,\ord}(d^{-1-t}g^{[p]}\times h),$$
and likewise for the other three contributions to $e_{f^*,\ord}(\xi(\omega_g,\omega_h))$. 
The result now follows from a simple direct calculation, as in the conclusion of the proof of
Theorem \ref{thm:aj-comp-prelim}.
\end{proof}

 
We can now conclude this section
with a (partial) formula for the image of the
generalised Gross-Kudla Schoen  cycle $\Delta_{k,\ell,m}$  under the 
$p$-adic Abel-Jacobi map.
  \begin{theorem} 
 \label{thm:main-AJ}
 With notations as in the statement of Theorems
 \ref{thm:aj-comp-prelim} and 
 \ref{thm:aj-comp-prelim-general},
 $$ \AJ_p(\Delta_{k,\ell,m})(\eta_f^{\ur} \omega_g \omega_h) = (-1)^{t+1}
  \frac{ t! \cdot \cE_1(f)}{ \cE(f,g,h)}   \langle \eta_f^{\ur}, d^{-1-t}g^{[p]} \times h \rangle,$$
 for all $\eta_f^{\ur} \in H^1_{\dR}(X, \cL_{r_1})^{\ur}[\pi_{f^*}]$.
    \end{theorem}
\begin{proof}
Assume first that $(k,\ell,m)=(2,2,2)$. 
By Proposition \ref{prop:depends-on-ord},
  the class $\eta_{f}^{\ur}$ is orthogonal to the kernel of $e_{f^*,\ord}$, and hence
  $$ \langle \eta_f^{\ur}, \xi(\omega_g,\omega_h)\rangle = \langle \eta_f^{\ur}, e_{f^*,\ord}\xi(\omega_g,\omega_h)\rangle.$$
  Theorem \ref{thm:main-AJ} therefore follows from 
  Theorem \ref{thm:aj-comp-prelim}. The case of general weights $(k,\ell,m)$
  follows from an identical
  argument using Theorem
   \ref{thm:aj-comp-prelim-general} instead of Theorem \ref{thm:aj-comp-prelim}.
  \end{proof}
 
 
  
  
\section{Garrett-Rankin triple product $L$-functions}
\label{sec:p-adic-Lfct}

\subsection{Classical $L$-functions}
\label{3L}



As in the introduction, let
$$f\in S_{k}(N_f,\chi_f), \quad  g\in S_{\ell}(N_g,\chi_g), \quad
h\in S_m(N_h,\chi_h)$$
be a triplet of normalized primitive cuspidal eigenforms such that
$\chi_f\cdot \chi_g \cdot \chi_h=1$, and
let $$\Q_{f,g,h}=\Q_f\cdot \Q_g\cdot \Q_h=\Q(\{a_n(f), a_n(g), a_n(h)\}_{n\geq 1})$$
denote the field generated by the fourier coefficients of $f$, $g$ and $h$. Write also $N = \lcm(N_f,N_g,N_h)$.



The Garrett-Rankin triple product $L$-function
$L(f,g,h; s)$ is defined  by an  Euler product
\[
L(f,g,h; s) = \prod_{p} L^{(p)}(f,g,h; p^{-s})^{-1},
\]
where, for $p\nmid N$ the local factor
$L^{(p)}(f,g,h; T)$ is the    degree $8$ polynomial
\begin{eqnarray}
\label{euler-factor}
 L^{(p)}(f,g,h; T)  &= &
(1-\alpha_{f,p} \alpha_{g,p} \alpha_{h,p} T)\times 
(1-\alpha_{f,p} \alpha_{g,p} \beta_{h,p} T) \\
\nonumber
& & \times (1-\alpha_{f,p} \beta_{g,p} \alpha_{h,p} T) \times
(1-\alpha_{f,p} \beta_{g,p} \beta_{h,p} T) \\
\nonumber
   & &  \times (1-\beta_{f,p} \alpha_{g,p} \alpha_{h,p} T)\times
(1-\beta_{f,p} \alpha_{g,p} \beta_{h,p} T) \\
\nonumber
& & \times (1-\beta_{f,p} \beta_{g,p} \alpha_{h,p} T)\times
(1-\beta_{f,p} \beta_{g,p} \beta_{h,p} T).
\end{eqnarray}
Piatetski-Shapiro and Rallis have given a
precise recipe    \cite{PSR}
for the local Euler factors $L^{(p)}(f,g,h; s)$
at the bad primes $p\mid N$ and have shown that there exists an
archimedean factor $L^{(\infty)}(f,g,h; s)$
for which the completed
$L$-function 
$$\Lambda(f,g,h; s)=L(f,g,h; s)
 \cdot L^{(\infty)}(f,g,h; s)$$
satisfies the functional equation
\begin{equation}
\label{functionalequation}
\Lambda(f,g,h; s) =
\varepsilon(f,g,h) \Lambda(f,g,h; k+\ell+m-2-s),
\end{equation}
where $\varepsilon(f,g,h)\in \{ \pm 1\}$. The sign in this functional
equation determines the parity of the
order of vanishing of $L(f,g,h,s)$  at the center of symmetry
\begin{equation}
\label{center}
c=c_{f,g,h}=\frac{k+\ell+m-2}{2},
\end{equation}
at which there is no pole (cf.\,\cite[Theorem 5.2]{PSR}). The sign
$\varepsilon(f,g,h)$
can be expressed as a product
$$\varepsilon(f,g,h) = \prod_{q} \varepsilon_q(f,g,h)$$
of local root numbers $\varepsilon_q(f,g,h) \in \{\pm 1\}$ indexed by the places
$q\leq \infty$ of $\Q$. As already anticipated in the introduction, we assume throughout that $\varepsilon_q(f,g,h) = +1$ for all finite primes. According to e.\,g.\,\cite{Pr} and the references therein, we then have
\begin{equation}
\label{sign-infty}
\varepsilon(f,g,h) = \varepsilon_{\infty}(f,g,h)=\begin{cases}
-1 & \mbox{ if } (k,\ell,m) \,\mbox{ are balanced.}  \\
+1 & \mbox{ if } (k,\ell,m) \,\mbox{ are unbalanced.} \end{cases}
\end{equation}


We now recall a fundamental result which relates the
central critical value of $L(f,g,h,s)$ to certain
{\em trilinear period integrals}. For this, assume that $(k,\ell,m)$ is unbalanced, namely (without loss
of generality, by eventually permuting $f$, $g$ and $h$), that
$k = \ell+m + 2t$ with $t\ge 0$. Recall also the Shimura-Maass operators $\delta_\ell$ defined in \S \ref{sec:nearly-holomorphic} 
and the space  $S_k(N)[\pi_f]$  introduced  in  \S \ref{sec:periods-mf}.

For any eigenform  $\phi\in S_k(N)$ with character $\chi$ (not 
necessarily new at $N$), we write 
$\phi^*$ for the dual form obtained by twisting $\phi$ by the character 
$\chi^{-1}$. The eigenform $\phi^*$ has nebentype character $\chi^{-1}$,
and its Hecke eigenvalues are complex conjugate to the Hecke eigenvalues attached to
$\phi$. 
 
\begin{definition}
Assume that $k=\ell+m + 2t $ with $t\ge 0$.
The {\em trilinear period} attached to
$$(\testf,\testg,\testh) \in
S_k(N)[\pi_f] \times
S_\ell(N)[\pi_g]\times
S_m(N)[\pi_h] $$ is the expression
$$ I(\testf,\testg,\testh) :=  ( \testf^*, \delta_\ell^t \testg  \times \testh)_N.$$
\end{definition}
One of the main results of M. Harris and S. Kudla \cite{HaKu}, conjectured
by H. Jacquet and refined recently by A. Ichino \cite{I} and
T. C. Watson \cite{Wa} is:



\begin{theorem}
\label{thm:explicit-hk}
Let $(f,g,h)$ be a triple of modular forms of unbalanced weights $(k,\ell,m)$
with $k = \ell+m + 2t$ and $t\ge 0$.
Then there exist
\begin{itemize}
\item holomorphic modular forms $\testf\in S_{k}(N)[\pi_f]$,
$\testg\in S_{\ell}(N)[\pi_g]$, and
$\testh\in S_{m}(N)[\pi_h]$,


\item for each prime $q\mid N\infty$, a constant $C_q\in \Q_{f,g,h}$
which depends only on the local components at $q$
of the vectors $\testf$, $\testg$ and $\testh$ in the 
admissible representations of $\GL_2(\Q_q)$ associated
to $\pi_f$, $\pi_g$ and $\pi_h$;
\end{itemize}
such that
\begin{equation}
\label{hk2}
\frac{\prod_{q\mid N\infty} C_q}{\pi^{2k}} \cdot L(f,g,h,c) =
|I(\testf,\testg,\testh)|^2.
\end{equation}
Furthermore, there is a choice of $(\testf,\testg,\testh)$ for which the constants 
$C_q$ are all non-zero.

\end{theorem} 


\begin{remark}
If $N_f=N_g=N_h=N$,  then the space $S_{k}(N)[\pi_f]$ is one-dimensional,
and likewise for $g$ and $h$.
In that case   there is only one choice (up to scaling)
for the vectors $\testf$, $\testg$ and $\testh$.
 Otherwise, the triplet $(\testf, \testg, \testh)$
has to be chosen more carefully:
see \cite{GrPr} and \cite{DiNy} for explicit recipes when at least one
of $\pi_f$, $\pi_g$ or $\pi_h$ is not supercuspidal at the primes $q\mid \gcd(N_f, N_g, N_h)$.
It could be tempting to choose $\testf$, $\testg$ and 
$\testh$ to be the new vectors in $S_k(N_f)$, $S_\ell(N_g)$ 
and $S_m(N_h)$ attached to $f$, $g$ and $h$ respectively, but such a choice may not
always be suitable. For example, if there is a prime $q$ dividing 
$N_f $ but not $N_g$ or $N_h$, then $C_q=0$ for this choice of test vectors.
\end{remark}


\subsection{$p$-adic $L$-functions}
\label{sec:trilinear-periods}
Let $\bar\Q$ denote the algebraic closure of $\Q$ in $\C$
and fix throughout an odd prime $p\nmid N$, an algebraic closure
$\bar\Q_p$ of $\Q_p$ and an embedding
$\iota_p: \bar\Q \hookrightarrow \bar\Q_p$.
Let $\ord_p: \bar\Q_p^{\times }\ra \Q$ be the
valuation on $\bar\Q_p$ normalized so that $\ord_p(p)=1$.

Fix a triple $(f,g,h)$ of newforms and keep the notations of the previous section.  As before we assume that $\chi_f \chi_g \chi_h=1$, $\varepsilon_q(f,g,h)=+1$ for all finite primes $q\mid N$, and the triple $(k, \ell, m)$ of weights is unbalanced.

Let $\testf\in S_k(N;K_f)[\pi_f]$, $\testg\in S_\ell(N;K_g)[\pi_g]$ 
and $\testh\in S_m(N;K_h)[\pi_h]$ be test vectors for which the
local constants $C_q$ of Theorem \ref{thm:explicit-hk} are non-zero and the central critical value
of $L(\pi_f,\pi_g,\pi_h,s)$ is (up to elementary non-zero fudge factors) equal
to the square  of $I(\testf,\testg,\testh)$. 

Assume in addition that $f$, $g$ and $h$ are ordinary with respect to $\iota_p$ and let
$$\htf = (\Lambda_f,\Omega_f,\Omega_{f,\cl},\htf), \quad \htg = (\Lambda_g,\Omega_g,\Omega_{g,\cl},\htg), 
\quad \hth= (\Lambda_h,\Omega_h,\Omega_{h,\cl},\hth)$$  
be the Hida families of
(not necessarily new) forms on $\Gamma_1(N)$ interpolating $\testf$,
$\testg$ and $\testh$ in weights $k$, $\ell$ and $m$ respectively, 
as described in \eqref{eqn:hida-family-oldforms}.
Adapting the notations of the introduction, we write
$$ \Sigma:= \{ (x,y,z) \in \Omega_{f,\cl}\times\Omega_{g,\cl}\times \Omega_{h,\cl}    \},$$
and   set 
\begin{eqnarray*}
\Sigma_f &=&  \{   (x,y,z)\in \Sigma,  \quad \mbox{ such that } 2 t:= \kappa(x) - \kappa(y)-\kappa(z)\ge 0 \}, \\
\Sigma_{\bal} &=& \{ (x,y,z) \in \Sigma, \quad \mbox{ such that }  (\kappa(x),\kappa(y),\kappa(z)) 
\mbox{ is balanced.}  \}.
\end{eqnarray*}

For each $(x,y,z)\in\Sigma_f$, we may  consider the algebraic number
$$J(\testf_x,\testg_y,\testh_z) := \frac{ I(\testf_x,\testg_y, \testh_z  )}{(f_x^{*},f_x^{*})_{N} }
 \in \bar\Q,$$
which  we view in $\C_p$ via $\iota_p$.
In light of the discussion in the previous section, our approach to defining  
the $p$-adic $L$-function attached to $\pi_f\otimes\pi_g\otimes\pi_h$ 
will be to interpolate (suitable multiples of) the ratios 
$J(\testf_x   ,\testg_y , \testh_z)$ as $(x,y,z)$ ranges over $\Sigma_f$.
In order to do this,  we let $\hphi:= e_{\ord}(d^\bullet \htg^{[p]}\times\hth)$ be the ordinary
family of modular forms attached to $\htg$ and $\hth$ following the recipe
in Proposition \ref{prop:prod-deriv-family}.

Furthermore, define the Hida family $\htf^*=\htf\otimes \chi^{-1}_f$; note that $(\testf^*)_x = (\testf_x)^*$ for all $x\in \Omega_{f,\cl}$. Recall that according to the notations settled in \S \ref{hidatheory}, a classical point corresponds to a character of the form $\gamma \mapsto \gamma^k$ for some $k\in \Z_{\geq 2}$. We warn the reader that the equality $(\testf^*)_x = (\testf_x)^*$ does not hold true for arithmetic points corresponding to characters  $\gamma \mapsto \psi(\gamma)\gamma^k$ for some Dirichlet character $\psi$ of non-trivial $p$-power conductor.

 \begin{definition} 
\label{def:garrett-rankin}
The  {\em Garrett-Rankin triple product $p$-adic $L$-function} attached to the
triple $(\htf,\htg,\hth)$ of $\Lambda$-adic modular forms is the element
$$ \Lp^f(\htf,\htg,\hth) := J(\htf^*, e_{\ord}(d^\bullet \htg^{[p]}\times\hth)) 
\in \Lambda_f'\otimes_{\Lambda}(\Lambda_g\otimes\Lambda_h\otimes\Lambda)$$
  attached to the families 
$\htf$ and $\hphi = e_{\ord}(d^\bullet \htg^{[p]}\times\hth)$ following the notations of 
Lemma \ref{lemma:Lambda-period}. 
\end{definition}
\begin{remark}
The definition of $\Lp^f(\htf,\htg,\hth)$ 
depends not just on the $p$-adic families of automorphic representations  interpolating
$\pi_f$,  $\pi_g$, and $\pi_h$, but also
on the choice of a triple $(\testf, \testg,\testh)$ of test vectors in these automorphic
representations. Note also that while 
$$ \Lp^f(\htf,\htg,\hth) = \Lp^f(\htf,\hth,\htg),$$
 the $\Lambda$-adic family $\htf$ 
  plays an essentially different role from the other two in the definition of
  $\Lp^f(\htf,\htg,\hth)$. There are thus
three {\em a priori distinct} $p$-adic $L$-functions attached to $(\htf,\htg,\hth)$, namely,
$\Lp^f(\htf,\htg,\hth)$, $\Lp^g(\htf,\htg,\hth):= \Lp^g(\htg,\htf,\hth)$,
and $\Lp^h(\htf,\htg,\hth)$. 
 \end{remark}
 
Any element $\LL\in \Lambda_f'\otimes_{\Lambda}(\Lambda_g\otimes\Lambda_h\otimes\Lambda) $ as in Definition 
\ref{def:garrett-rankin}
 has   poles at $(x,y,z)$ for only finitely many $x\in \Omega_f$,
and hence is completely determined by its values at the points of 
$\Omega_{f,\cl}\times_{\Omega}(\Omega_{g,\cl}\times \Omega_{h,\cl}\times\Omega)$
where it is defined.  Furthermore, it is always defined at $(x,y,z)$ when $x$ belongs to
$\Omega_{f,\cl}$. 
 By definition, 
  for all $(x,y,z)\in\Sigma_f$, after setting $\kappa(x) = \kappa(y)+\kappa(z) + 2t$,
 \begin{equation}
 \label{eqn:eval-raw}
 \Lp^f(\htf,\htg,\hth)(x,y,z) = \frac{(\testf_x^{*(p)}, e_{\ord}(d^t \testg_y^{[p]}\times \testh_z))_{N,p}}
  {(f_x^{*(p)}, f_x^{*(p)})_{N,p}}.
  \end{equation}
  In particular, 
  the special value $\Lp^f(\htf,\htg,\hth)(x,y,z)$ is
  algebraic and belongs to the field $K$  generated by $\alpha_{f_x}$ and by
  the fourier coefficients of $\testf_x$, $\testg_y$ and $\testh_z$.
 
 

 The following proposition supplements \eqref{eqn:eval-raw} with a formula for the $p$-adic special value
 $\Lp^f(\htf,\htg,\hth)$ at a point $(x,y,z)\in \Sigma_{\bal}$. 
 \begin{proposition}
 \label{prop:eval-balanced}
 For all $(x,y,z)\in \Sigma_{\bal}$,  let $(f,g,h):= (f_x,g_y, h_z)$ and define $(k,\ell,m,t)$ by
 setting 
$$(k,\ell,m) = (\kappa(x), \kappa(y),\kappa(z)), \qquad k = \ell+m -2-2t.$$
Then
 $$ \Lp^f(\htf,\htg,\hth)(x,y,z) =
 \E_0(f)^{-1}  \langle \eta_{\testf_x}^{\ur}, e_{\ord}(d^{-1-t} \testg_y^{[p]}\times
\testh_z) \rangle,$$
where 
\begin{itemize}
\item $\E_0(f)$ is the local factor given in \eqref{eqn:defE0};
\item $\eta_{\testf_x}^{\ur}\in H^1_{\para}(X_{\C_p}, \cL_{r})^{\ur}$ is the 
unique lift to the unit root subspace of the  cohomology class  in
 $ H^1(X_{K_{f_x}},\underline{\omega}^{-r})$   attached to $\testf_x^*$ as in 
 Corollary \ref{cor:def-eta-f}. 
 \item the classical modular form $e_{\ord}(d^t \testg_y^{[p]}\times
\testh_z)$   on $\Gamma_1(N)\cap\Gamma_0(p)$ is viewed as a class in 
$H^0(\cW_\epsilon, \cL_r\otimes \Omega^1_X)\subset H^1_{\para}(X_{\C_p},\cL_r)$;
 \item  $\langle \ ,\ \rangle_{X}$ denotes the Poincar\'e duality on
$H^1_{\para}(X_{\C_p},\cL_r)$.
\end{itemize}
\end{proposition}
  \begin{proof}
  Let $e_{f_x^*}$ denote the idempotent attached to the eigenform $f_x^*$,
   set  
  $$ \phi_{xyz}^{(p)} := e_{f_x^*,\ord}(d^t g_y^{[p]}\times h_z),$$
  and let $\phi_{xyz} \in S_k(N;\C_p)[\pi_{f_x^*}]$ be the classical modular form 
  whose $p$-ordinary stabilisation is equal to $\phi_{xyz}^{(p)}$. 
  The  definition of 
  $\Lp^f(\htf,\htg,\hth)$, in view of  the last equality in 
  equation \eqref{eqn:period-formulae} 
  of Lemma \ref{lemma:Lambda-period},   implies that, for all $(x,y,z)\in \Sigma_f\cup \Sigma_{\bal}$, 
  \begin{equation}\label{aaaa}
 \Lp^f(\htf,\htg,\hth)(x,y,z) = \langle \eta_{\testf_x},\phi_{xyz}\rangle.
   \end{equation}
   Since $\phi_{xyz}$ belongs to $\Fil^{r+1} H^1_{\para}(X_{\C_p},\cL_r)$,
   we can also express this identity in terms of the Poincar\'e pairing 
   on $H^1_{\para}(X_{\C_p},\cL_r)$  by replacing $\eta_{\testf_x}$ by its lift to 
   $H^1_{\para}(X_{\C_p},\cL_r)$ under the unit root splitting:
    \begin{equation}
 \Lp^f(\htf,\htg,\hth)(x,y,z) = \langle \eta_{\testf_x}^{\ur},\phi_{xyz}\rangle.
   \end{equation}
  By Proposition     \ref{prop:depends-on-ord-k}, we then have
   \begin{equation}
 \Lp^f(\htf,\htg,\hth)(x,y,z) = \langle \eta_{\testf_x}^{\ur},e_{\ord}\phi_{xyz}\rangle.
   \end{equation}
On the other hand, applying the ordinary projector to the identity $\phi_{xyz}^{(p)} = \phi_{xyz} - \beta_{f_x^*} V\phi_{xyz}$
shows that
\begin{equation}
\label{eqn:pstab-ordproj}
 \phi_{xyz}^{(p)} = (1-\frac{\beta_{f_x^*}}{\alpha_{f_x^*}}) e_{\ord} \phi_{xyz} = 
 (1-\frac{\beta_{f_x}}{\alpha_{f_x}}) e_{\ord} \phi_{xyz}  =
\E_0(f_x) e_{\ord} \phi_{xyz},
\end{equation}
and therefore
\begin{eqnarray*}
\Lp^f(\htf,\htg,\hth)(x,y,z) & = &\E_0(f_x)^{-1}  \langle \eta_{\testf_x}^{\ur}, \phi_{xyz}^{(p)}  \rangle  
=  \E_0(f_x)^{-1}  \langle \eta_{\testf_x}^{\ur}, e_{f_x^*,\ord}(d^t \testg_y^{[p]}\times
\testh_z) \rangle   \\
  & =   &\E_0(f_x)^{-1}  \langle \eta_{\testf_x}^{\ur},  e_{\ord}(d^t \testg_y^{[p]}\times
\testh_z) \rangle.
\end{eqnarray*}
The proposition follows.
\end{proof}

      
The next theorem evaluates $\Lp^f(\htf,\htg,\hth)$ at   points $(x,y,z)\in\Sigma_f$ and relates these values to the complex periods $I(\testf_x, \testg_y,\testh_z)$. 

\begin{theorem}
\label{sec3:main}
Let $(x,y,z)$ be a point of $\Sigma_f$ 
and set 
$$ (f,g,h) := (f_x,g_y,h_z), \qquad 
(\testf,\testg,\testh):= (\testf_x,\testg_y,\testh_z), \qquad
 (k,\ell,m) = (\kappa(x), \kappa(y),\kappa(z)).$$
 Then
\begin{equation}
\label{inter}
\Lp^f(\htf,\htg,\hth)(x,y,z) =
\frac{\E(f,g,h)}{\E_0(f) \E_1(f) } \times \frac{I(\testf,\testg,\testh)}{(f^*,f^*)_N},
\end{equation}
where $\E(f, g, h)$, $\E_0(f)$ and $\E_1(f)$ are   given in equations \eqref{eqn:defEE},
\eqref{eqn:defE0} and \eqref{eqn:defE1} of
Theorem \ref{mainDR}.
 \end{theorem}

\begin{remark}\label{variation-Prasad}  Theorems \ref{thm:explicit-hk} and \ref{sec3:main} above justify the designation of $\Lp^f(\htf,\htg,\hth)$ as a $p$-adic   Garrett-Rankin triple product $L$-function in that it interpolates the square-roots of the central critical values of the complex L-series $L(f_x,g_y,h_z;s)$ for $(x,y,z)\in \Sigma_f$. Indeed, assume that $$L(f,g,h;c) \ne 0,$$ so that Theorems \ref{thm:explicit-hk} and \ref{sec3:main} ensure that $\Lp^f(\htf,\htg,\hth)$ is non-zero in $\mathcal L_{f}\otimes \Lambda_g\otimes \Lambda_h$. By the Weierstrass preparation theorem, $\Lp^f(\htf,\htg,\hth)$ vanishes at a finite number of points and therefore $\langle \testf_x,\,\testg_y \cdot \delta^n(\testh_z)\rangle_N^2 \ne 0$ for all but finitely many $(x,y,z)\in\Sigma_{f}$. In addition, Jacquet's conjecture as formulated and proved in \cite{HaKu}, imply that the hypothesis $\varepsilon_q(f_x,g_y,h_z)=+1$ for all finite primes $q$ still holds true for all such $(x,y,z)$. Hence Theorem \ref{thm:explicit-hk} can again be applied for the triple $(f_x,g_y,h_z)$, which implies that \eqref{inter} expresses $\Lp^f(\htf,\htg,\hth)(x,y,z)$ as a non-zero multiple of the square-root of $L(f_x,g_x,h_x;c_{f_x,g_y,h_z})$.  $\Box$
\end{remark}



We now turn to the  proof of Theorem \ref{sec3:main}. 
As before, $p$ is a prime which does not divide $N$, and 
$S_k^{\noc}(N;\C_p)$ denotes the space of  nearly overconvergent 
$p$-adic modular forms of level $N$, as described in Section 
\ref{sec:noc-mfs}.
Given a classical newform $f = \sum_n a_nq^n$ of some level $N_f|N$, recall that  
 $$ e_{f^*}: S_k^{\ord}(N;\C_p) \lra S_k^{\ord}(N;\C_p)[\pi_{f^*}]$$
 $$ e_{f^\ast,\ord} = e_{f^*} e_{\ord}: S_k^{\noc}(N;\C_p) \lra S_k^{\ord}(N;\C_p)[\pi_{f^*}]$$
denote  the associated projectors to the $f^*$-isotypic component  of the ordinary subspace in the space of overconvergent $p$-adic modular forms.
The operators $U$ and $V$ whose action on $q$-expansions is given in 
\eqref{eqn:defUV} also act on the spaces
 of nearly overconvergent modular forms of a given level.
   \begin{lemma}
  \label{lemma:ghpf}
Let $g\in S_\ell^{\noc}(N;\C) $ and $h\in S_m^{\noc}(N;\C) $ be nearly
overconvergent modular forms of weights $\ell,m\ge 2$ which are eigenvectors for all
the good Hecke operators $T_q$ with $q\nmid N$. (They are not  assumed to be new 
or  to be  eigenvectors for the operators $T_q$ with $q|N$.)   Let
$$ \phi_{fgh}:= e_{f^*,\ord} (gh)  \in S_k^{\\ord}(N;\C)[\pi_{f^*}], \qquad (\mbox{with   }
  k=\ell+m). $$ 
   For each $r\ge 0$, the modular form
$$   e_{f^*,\ord} ((V^r g)\times  h) \in S_k^{\ord}(N;\C)[\pi_{f^*}]  $$
is a multiple of $\phi_{fgh}$. 
\end{lemma}
\begin{proof}  By Lemma \ref{lemma:ignore-p},
\begin{equation}
\label{eqn:gvhvgh}
 0= e_{\ord}(g^{[p]} \times Vh) = e_{\ord}(g\times Vh) - a_p(g) e_{\ord}(Vg\times Vh) + \chi_g(p)p^{\ell-1} e_{\ord}(V^2 g\times Vh).
 \end{equation}
But since
$$ e_{\ord} V = U^{-1} e_{\ord}, \qquad e_{f^*,\ord} V = \alpha_{f^*}^{-1} e_{f^*,\ord},$$
it follows  after applying the projector $e_{f^*}$ to \eqref{eqn:gvhvgh} that 
\begin{equation}
\label{eqn:lin-eq-gh-one}
 e_{f^*,\ord}(g\times Vh) + \chi_g(p)p^{\ell-1} \alpha_{f^*}^{-1}  e_{f^*,\ord}(V g\times h) =
  a_p(g) \alpha_{f^*}^{-1}  \phi_{fgh}.
  \end{equation}
 The same argument with the roles of $g$ and $h$ interchanged shows that
\begin{equation}
\label{eqn:lin-eq-gh-two}
  \chi_h(p)p^{m-1} \alpha_{f^*}^{-1}  e_{f^*,\ord}(g \times Vh)   +  e_{f^*,\ord}(Vg \times h)=
  a_p(h) \alpha_{f^*}^{-1}  \phi_{fgh}.
  \end{equation}
The case $r=1$ of the proposition is obtained  by simultaneously solving   equations
\eqref{eqn:lin-eq-gh-one} and \eqref{eqn:lin-eq-gh-two} 
 above.
The case of general $r>1$ can then be treated by induction on $r$ using the identity
\begin{equation}
\label{eqn:gvhvgh-bis}
  e_{f^*,\ord}(V^r g\times   h)=  \alpha_{f^*}^{-1} a_p(g) e_{f^*,\ord}(V^{r-1} g\times  h) - \alpha_{f^*}^{-2}\chi_h(p)p^{m-1} e_{f^*,\ord}(V^{r-1}g\times  h),
 \end{equation}
which follows from  Lemma \ref{lemma:ignore-p}, more precisely from the fact that
$e_{\ord}(V^r g\times h^{[p]}) =0.$ 
 \end{proof}
    
 \begin{lemma} 
\label{lemma:proj-galpha-halpha}
The following identities, as well as  their counterparts with  $(\alpha_g,\alpha_h)$ replaced
by $(\alpha_g, \beta_h)$, $(\beta_g,\alpha_h$, and $(\beta_g,\beta_h)$,
are satisfied:
\begin{enumerate}
\item 
$e_{f^*,\ord}( (Vg_\alpha)\times (Vh_\alpha)) = \alpha_{f^*}^{-1} e_{f^*,\ord}(g_\alpha h_\alpha);$
\item
$e_{f^*,\ord}( g_\alpha \times Vh_\alpha) = \alpha_g \alpha_{f^*}^{-1} e_{f^*,\ord}(g_\alpha h_\alpha) ;$
\item
$e_{f^*,\ord}( V g_\alpha \times h_\alpha) = \alpha_h \alpha_{f^*}^{-1}  e_{f^*,\ord}(g_\alpha h_\alpha);$
\item
$ e_{f^*,\ord}(g^{[p]}\times h) = e_{f^*,\ord}(g \times h^{[p]}) = 
(1-\alpha_g\alpha_h \alpha_{f^*}^{-1}) e_{f^*,\ord}(g_\alpha h_\alpha).$
\end{enumerate}
\end{lemma}
\begin{proof}
To prove the first assertion, note that
$$ e_{\ord}( (Vg_\alpha) \times (Vh_\alpha) ) = e_{\ord}\circ V(g_\alpha h_\alpha),$$
and that 
$$ e_{\ord} \circ V = \lim U_p^{n!} \circ V = \lim U_p^{n!-1} = U_p^{-1} e_{\ord}.$$
The first assertion now follows from the fact that $U_p$ operates via multiplication by
$\alpha_{f^*}$ on $S_k^{\ord}(N;\C_p)[\pi_f^*]$.
For the second assertion, we invoke Lemma  \ref{lemma:ignore-p} 
to assert that
$$(g^{[p]} \times (Vh_\alpha)) =  (g - a_p(g) Vg ) \times (Vh_\alpha)$$
is in the kernel of the ordinary projection to  conclude  that
$$ e_{\ord}(g\times Vh_\alpha) = a_p(g) e_{f^*,\ord}( (Vg)\times (Vh)),$$
and the second assertion now follows directly from
the first.
The third assertion follows from the identical argument with the roles of $g$ and $h$ interchanged.
The last identity then follows from the previous ones by  a direct calculation using the fact that
$g^{[p]} = g_\alpha - \alpha_g V g_\alpha$. 
\end{proof}
 
  

      
 \begin{proposition}
 \label{prop:computer}
 Let $f\in S_k(N)$ be a holomorphic  form  of weight $k$  and let 
 $g\in S_\ell^{\noc}(N)$  and $h\in S_m^{\noc}(N)$ be nearly holomorphic   modular forms, with
 $k=\ell+m$.
 Assume that $f$, $g$ and $h$ are eigenvectors for the good Hecke operators
 of level $N$ (but are not necessarily new of this level.)
 Then for all primes  $p\nmid N$,
 \begin{equation}
\label{eqn:harris-tilouine-correct}
 e_{f^*,\ord}(g^{[p]} h) = 
\frac{\E(f,g,h)}{\E_1(f)   } e_{f^*, \ord}(gh),
\end{equation}
where   $\E(f,g,h)$ is  as in equation \eqref{eqn:defEE} of
Theorem \ref{mainDR} (with $c=k-1$).
\end{proposition}
\begin{proof}
The last identity  of Lemma \ref{lemma:proj-galpha-halpha}
shows, after setting $\phi_{fg^{[p]}h} := e_{f^*,\ord}(g^{[p]}h)$,  that
\begin{eqnarray}
\label{eqn:alpha-alpha}
 e_{f^*,\ord}(g_\alpha h_\alpha)  & = &  
(1-\alpha_g\alpha_h \alpha_{f^*}^{-1})^{-1} \phi_{fg^{[p]}h}; \\
\label{eqn:alpha-beta}
 e_{f^*,\ord}(g_\alpha h_\beta)  & = &  
(1-\alpha_g\beta_h \alpha_{f^*}^{-1})^{-1} \phi_{fg^{[p]}h}; \\
\label{eqn:beta-alpha}
 e_{f^*,\ord}(g_\beta h_\alpha)  & = &  
(1-\beta_g\alpha_h \alpha_{f^*}^{-1})^{-1} \phi_{fg^{[p]}h}; \\
\label{eqn:beta-beta}
 e_{f^*,\ord}(g_\beta h_\beta)  & = &  
(1-\beta_g\beta_h \alpha_{f^*}^{-1})^{-1} \phi_{fg^{[p]}h}.
\end{eqnarray}
Combining \eqref{eqn:alpha-alpha} and \eqref{eqn:alpha-beta} with the identity
$$h = (\alpha_h-\beta_h)^{-1} (\alpha_h h_\alpha - \beta_h h_\beta),$$
and similarly with \eqref{eqn:beta-alpha} and \eqref{eqn:beta-beta}, we obtain
\begin{eqnarray}
\label{eqn:alpha-h}
 e_{f^*,\ord}(g_\alpha h )  & = &  
((1-\alpha_g\alpha_h \alpha_{f^*}^{-1})(1-\alpha_g\beta_h\alpha_{f^*}^{-1}))^{-1} 
\phi_{fg^{[p]}h}; \\
\label{eqn:beta-h}
 e_{f^*,\ord}(g_\beta h )  & = &  
((1-\beta_g\alpha_h \alpha_f^{-1})(1-\beta_g\beta_h\alpha_{f^*}^{-1}))^{-1} 
\phi_{fg^{[p]}h}.
\end{eqnarray}
 The result now follows from these two equations by a direct calculation using the fact that
 $$g = (\alpha_g - \beta_g)^{-1} (\alpha_g g_\alpha - \beta_g g_\beta).$$
\end{proof}

 \begin{remark}  A formula similar to Proposition \ref{prop:computer}
can be found  in Proposition 2.2.2. of 
\cite{HaTi}. The approach followed there is conceptually sound but more
  complicated  than the one followed above;  possibly for this reason, 
 an  error seems to have
crept into the roughly five pages of elementary but tedious calculations in the proof
of Prop. 2.2.2. of loc.cit,  
and  the factor denoted there by $E_P(f,g,h)$   does not agree with the 
factor $\E(f,g,h)$ of Proposition \ref{prop:computer}.  
We note that the 
factor   $\E(f,g,h)$ occuring in Proposition 
\ref{prop:computer}  is consistent with the conjectural recipe for
the ``correction term at $p$" arising in the theory of $p$-adic $L$-functions, as described in e.\,g.\,in \cite[p.\,285]{Pan2}.
\end{remark}


\begin{corollary}
\label{cor:computer}
Let $f\in S_k(N)$, $g\in  S_\ell(N)$ and
$h\in S_m(N)$  be   holomorphic  forms, and assume that 
 $k=\ell+m+2t$ with $t\in \Z^{\ge 0}$.
 Assume that $f$, $g$ and $h$ are eigenvectors for the good Hecke operators
 in level $N$ (but are not necessarily new in this level.)
 Then for all primes  $p\nmid N$,
 $$ e_{f^*,\ord}  (d^t g^{[p]} \times h) = 
\frac{\E(f,g,h)}{ \E_1(f) } e_{f^*,\ord} (d^t g\times h).$$
 \end{corollary}
\begin{proof}
This follows from Proposition \ref{prop:computer} with $(f,g,h)$ 
replaced by 
$$(f, d ^t g,h) \in S_k(N)\times S_{\ell+2t}^{\noc}(N) \times S_m(N),$$
     in light of the fact that $d^t(g^{[p]}) =  (d^t g)^{[p]}$, $\alpha_{d^t g} = p^t \alpha_g$ and $\beta_{d^t g} = p^t \beta_g.$
\end{proof} 


\medskip
\noindent
{\em Proof of Theorem   \ref{sec3:main}}. 
 By  \eqref{eqn:eval-raw}, 
the value of $\Lp^f(\htf,\htg,\hth)$  at   $(x,y,z) \in \Sigma_f$ is
\begin{eqnarray}
\label{eqn:Lpf-1}
\Lp^f(\htf,\htg,\hth)(x,y,z)
& =& 
\frac{ (\testf_x^{*(p)}, e_{f_x^*,\ord}(d^t\testg_y^{[p]} \times \testh_z) )_{N,p}  }
{  (f_x^{*(p)}, f_x^{*(p)})_{N,p}}\\
&=& 
\frac{\E(f_x, g_y, h_z)}{ \E_1(f_x) } \frac{ (\testf_x^{*(p)}, e_{f_x^*,\ord}(d^t\testg_y \times \testh_z) )_{N,p}  }
{  (f_x^{*(p)}, f_x^{*(p)})_{N,p}},
\end{eqnarray}
where the second equality follows from Corollary \ref{cor:computer}.
But then by 
  Proposition 
 \ref{prop:hida-book},
 \begin{equation}
  \frac{ (\testf_x^{*(p)}, e_{f_x^*,\ord}(d^t\testg_y \times \testh_z) )_{N,p}  }
{  (f_x^{*(p)}, f_x^{*(p)})_{N,p}} =
 \frac{ (\testf_x^{*(p)}, e_{f_x^*,\ord} \Pi_{N}^{\hol}(\delta^t\testg_y \times \testh_z) )_{N,p}  }
{  (f_x^{*(p)}, f_x^{*(p)})_{N,p}}.
 \end{equation}
 On the other hand, by 
 equation \eqref{eqn:pstab-ordproj},
\begin{eqnarray}
\nonumber
\frac{ (\testf_x^{*(p)},  e_{f_x^*,\ord} \Pi_N^{\hol}(\delta_\ell^t\testg_y\times \testh_z) )_{N,p}} { (f_x^{*(p)},f_x^{*(p)} )_{N,p}} &=& 
\frac{ (\testf_x^{*(p)}, (e_{f_x^*} \Pi_N^{\hol}(\delta_\ell^t\testg_y\times \testh_z))^{(p)} )_{N,p}} {  \E_0(f_x) (f_x^{*(p)},f_x^{*(p)} )_{N,p}} \\ 
&=& 
\frac{ (\testf_x^*,  e_{f_x^*} \Pi_N^{\hol}(\delta_\ell^t\testg_y\times \testh_z) )_{N}} {\E_0(f_x) (f_x^*,f_x^*)_{N}} \\
 &=&
 \frac{ (\testf_x^*, \delta_\ell^t\testg_y\times \testh_z)_{N}} { \E_0(f_x) (f_x^*,f_x^* )_{N}} \\
&=& 
 \frac{ I(\testf_x,\testg_y,\testh_z)} { \E_0(f_x) (f_x^*,f_x^*)_{N}}.
\end{eqnarray}
Theorem \ref{sec3:main}  follows.
 
   
%We conclude that
%for almost all $x\in \Omega_{f,\cl}$ we have the   interpolation formula
%\begin{equation}\label{interpolation-formula}
%\Lp^f(\htf,\htg,\hth)(x,y,z)^2 = \frac{\E(f_x,g_y,h_z)^2}{\E_0(f_x)^2\E_1(f_x)^2}  \frac{\pi^3 \prod_{q\mid N\infty}C_q}{2\zeta(2)^2 \langle f_x^*,\, f_x^*)\rangle_N^2}  \cdot L(f_x,g_y,h_z,c_{(x,y,z)}).
%\end{equation}

  
\section{The $p$-adic Gross-Zagier formula}
Recall the   class $\eta_{\testf}\in H^1(X_{K_f},\underline{\omega}^{-r})$
attached to the test vector $\testf\in S_k(N;K_f)[\pi_f]$ 
following the discussion after   \eqref{eqn:def-eta-f-ah}.
Thanks to the chosen embedding of $K_f$ into $\C_p$, the class
$\eta_{\testf}$ can be viewed 
as belonging to $H^1(X_{\C_p},\underline{\omega}^{-r})[\pi_f]$. Let 
$$ \eta_{\testf}^{\ur} \in H^1_{\dR}(X_{\C_p},\cL_r)$$
denote its unique lift  to the unit root subspace.
We  can now state and prove the $p$-adic Gross-Zagier formula of this paper,
   relating the image of the generalised diagonal  cycles under the $p$-adic Abel-Jacobi map to the value of the Garrett-Rankin  triple product $p$-adic  L-function at points  corresponding to {\em balanced} triples of classical modular forms.
\begin{theorem}
\label{main-general}
Given  $(x,y,z)\in \Sigma_{\bal}$, set
$$(f,g,h) = (f_x,g_y,h_z), \qquad (\testf,\testg,\testh)  = (\testf_x,\testg_y,\testh_z), 
\qquad   (k,\ell,m)  = (\kappa(x),\kappa(y),\kappa(z)),  $$
 and let $\Delta := \Delta_{k,\ell,m} \subset
  W$ 
be  the generalised diagonal cycle attached to the weights $(k,\ell,m)$.  
Then after writing $k = \ell+m -2-2t$ with $t\ge 0$, 
$$\Lp^f(\htf,\htg,\hth)(x,y,z) = (-1)^t  
 \frac{\E(f,g,h)}{t!\cdot \E_0(f) \E_1(f)}  \times \AJ_p(\Delta)(\eta_{\testf}^{\ur}\otimes \omega_{\testg}\otimes \omega_{\testh}).$$
\end{theorem}
\begin{proof}
This follows directly from 
Theorem  \ref{thm:main-AJ}
and
Proposition 
  \ref{prop:eval-balanced}.
\end{proof}
    
    
     

\begin{thebibliography}{99}


 


\bibitem[BD]{BD-kato}
M. Bertolini, H. Darmon, 
{\em Kato's Euler system and rational points on elliptic curves I: A $p$-adic Beilinson formula}, Israel J. of Math., 
to appear.


\bibitem[BDP]{BDP1}
M. Bertolini, H. Darmon, K. Prasanna, {\em  Generalised Heegner cycles and $p$-adic
Rankin L-series}, Duke Math Journal, Vol. 162, No. 6, pp. 1033-1148.

\bibitem[BDR]{BDR}
M.~Bertolini, H.~Darmon and V.~Rotger, 
{\em Beilinson-Flach elements and Euler Systems I: syntomic regulators and $p$-adic Rankin L-series},
submitted.



\bibitem[Bes00]{Bes-inv} A. Besser, {\em A generalization of Coleman's $p$-adic integration theory}, Invent. Math. {\bf 142} (2000), 397--434.


\bibitem[BoPa]{Pan} S. B\"ocherer, A. A. Panciskin, {\em Admissible $p$-adic measures attached to triple products of elliptic cusp forms}, Documenta Math., Extra volume: John H.Coates' Sixtieth Birthday (2006), 77--132.
 
\bibitem[Br]{Br} R. Brasca, {\em $p$-adic modular forms of non-integral weight over Shimura curves}, arXiv:1106.2712v1.

\bibitem[Ca86]{Ca86} H. Carayol, {\em Sur les repr\'esentations $\ell$-adiques associ\'ees aux formes modulaires de Hilbert},
Ann. Sci. \'Ecole Norm. Sup. (4) {\bf 19} (1986), 409--468.




\bibitem[CGJ]{coleman-gouvea-jochnowitz}
R. F. Coleman, F. Q. Gouv{\^e}a, N. Jochnowitz,  {\em $E_2$, $\Theta$, and overconvergence}, Internat. Math. Res. Notices {\bf 1} (1995), 23--41.

 
 \bibitem[Coa88]{Coa} J. Coates, {\em $p$-adic $L$-functions}, S\'em. Bourbaki (1988), exp. {\bf 701},
Ast\'erisque {\bf 177--178} (1989), 33--59.

 \bibitem[Cole94]{coleman-bu}
R.\,F.\,Coleman, {\em A $p$-adic Shimura isomorphism and $p$-adic periods of
modular forms}, in $p$-adic monodromy and the Birch and Swinnerton-Dyer conjecture
(Boston, MA, 1991), 21--51, Contemp. Math. {\bf 165}, Amer. Math. Soc.,
Providence, RI, 1994.

\bibitem[Cole95]{coleman-classical-overconvergent}
R.\,F. Coleman, {\em Classical and overconvergent modular forms}. 
Les Dix-huiti\`emes Journ\'ees Arithm\'etiques (Bordeaux, 1993). J. Th\'eor. Nombres Bordeaux {\bf 7:1} (1995), 333--365. 
 
 
\bibitem[Colz00]{Colmez}
P. Colmez, {\em S\'em. Bourbaki 1998-99}, exp. {\bf 851},
Ast\'erisque {\bf 266} (2000), 21--58.

\bibitem[DR]{DR2}
H.~Darmon and V.~Rotger,  {\em Diagonal cycles and Euler systems II: The Birch and Swinnerton-Dyer conjecture for Hasse-Weil-Artin $L$-functions}, submitted for publication.



 \bibitem[DRS]{DRS1} H. Darmon, V. Rotger, I. Sols, 
 {\em Iterated integrals, diagonal cycles,  and rational points on elliptic curves}, Publications 
 Math\'ematiques de Besan\c{c}on, vol.2, 2012, pp. 19-46. 



\bibitem[Da]{DaubPhD} M. Daub, Berkeley Ph.\,D thesis, in progress. 

\bibitem[DDLR]{DDLR}
H.~Darmon, M.~Daub, S.~Lichtenstein, and V.~Rotger
(with an appendix by W. Stein) 
{\em Algorithms for Chow-Heegner points via iterated integrals. }
Submitted.


\bibitem[DiNy]{DiNy}
M. Dimitrov, L. Nyssen,  {\em Test vectors for trilinear forms when at least one representation is not supercuspidal}, Manuscripta Math. {\bf 133: 3-4} (2010), 479--504.

 \bibitem[Gar]{Gar}
P. Garrett, {\em Decomposition of Eisenstein series:\,Rankin triple products}, Annals Math. {\bf 125} (1987), 209-235.

 \bibitem[GrKu]{GrKu}
B. Gross, S. Kudla, {\em Heights and the central critical values of triple
product $L$-functions}, Compositio Math. {\bf 81} (1992), no. 2, 143--209.

\bibitem[GrPr]{GrPr}
B. Gross and D. Prasad, {\em Test vectors for linear forms}, Math. Annalen {\bf 291} (1991), 343--355.

\bibitem[GrSc]{GrSc}
B. Gross, C. Schoen, {\em The modified diagonal cycle on the triple product of a pointed curve}, Ann. Inst. Fourier (Grenoble) {\bf 45} (1995), no.
3, 649--679.
 
\bibitem[HaKu]{HaKu} M. Harris, S. Kudla, {\em The central critical value of a triple product $L$-function},
Ann. Math. (2) {\bf 133} (1991), 605--672.

\bibitem[HaTi]{HaTi}
M. Harris and  J. Tilouine, {\em $p$-adic measures and square roots of special values of
triple product $L$-functions}, Math. Annalen {\bf 320} (2001), 127--147.


\bibitem[Hi86a]{Hi86a}  
H. Hida, {\em Iwasawa modules attached to congruences of cusp forms}, 
Ann. Sci. \'Ecole Norm. Sup. (4) {\bf 9} (1986), 231--273.

\bibitem[Hi86b]{Hi86}  
H. Hida, {\em Galois representations into $\GL_2(\Z_p[[X]])$ attached to ordinary 
cuspforms}, Invent. Math. {\bf 85} (1986), 545--613.

\bibitem[Hi88]{Hi88}  
H. Hida, {\em On $p$-adic Hecke algebras for $\GL_2$ over totally real fields}, Ann. Math. {\bf 128} (1988), 295--384.

\bibitem[Hi88b]{Hi88b}  H. Hida, {\em A $p$-adic measure attached to the zeta functions associated with two
elliptic modular forms II}, Ann. Inst. Fourier (Grenoble) {\bf 38} (1988) 1--83.

\bibitem[Hi93]{hida-book}
H. Hida, Elementary theory of $L$-functions and Eisenstein series, {\em London Math. Soc. St. Texts} {\bf 26}, 1993.


\bibitem[I]{I} A. Ichino, {\em Trilinear forms and the central values of triple product $L$-functions}, Duke Math. J. {\bf 145} (2008), no. 2, 281--307.


\bibitem[Ja]{Ja} U. Jannsen, Continuous \'etale cohomology, {\em Math. Ann.} {\bf 280} (1988),
207--245.

\bibitem[Kas99]{PaymanPhD} P. Kassaei, {\em $p$-adic modular forms over Shimura curves over $\Q$}, M.I.T. Ph.D thesis, 1999.

\bibitem[Kat73]{katz}
N. M. Katz, {\em  $p$-adic properties of modular schemes and modular forms}, in
{\em Modular functions of one variable, III},  Lecture Notes Math. {\bf 350} (1973), 69--190.



\bibitem[Kat78]{Katz2}
N. M. Katz, {\em $p$-adic $L$-functions for CM fields}, Invent. Math. {\bf 49} (1978), 199--297.


\bibitem[Ki]{Ki} K.~Kitagawa, {\em On standard $p$-adic $L$-functions of families of elliptic
cusp forms}, in {\em $p$-adic monodromy and the Birch and Swinnerton-Dyer conjecture}
(Boston, MA, 1991), 81--110, Contemp. Math. {\bf 165}, Amer. Math. Soc., Providence, RI, 1994.
 
 \bibitem[La1]{lauder-alg}
 A.G.B. Lauder, {\em  Computations with classical and p-adic modular forms},
LMS J. Comput. Math. {\bf 14} (2011) 214--231.
 
 \bibitem[La2]{lauder-heidelberg}
 A.G.B. Lauder, {\em Efficient computation of $p$-adic Rankin $L$-functions},  in 
Boeckle, G. and Wiese, G. (eds.) Computation with Modular Forms, Springer 
Verlag, to appear.
 
 
 

 \bibitem[Ne1]{nekovar-gz}
 J. Nekov\'a$\mathrm{\check{r}}$,
 {\em  On the p-adic height of Heegner cycles}. Math. Ann. {\bf 302} (1995), no. 4, 
 609--686.  
 

\bibitem[Ne2]{Nek-survey} 
J. Nekov\'a$\mathrm{\check{r}}$, 
{\em $p$-adic Abel-Jacobi maps and $p$-adic heights}, in {\em The Arithmetic and Geometry of Algebraic Cycles} (Banff, Canada, 1998), CRM Proc. Lect. Notes {\bf 24} (2000), 367--379.
 

\bibitem[Pan]{Pan2} A. A. Panciskin, {\em Admissible non-archimedean standard zeta functions associated with Siegel modular forms}, in J.-P. Serre, S. L. Kleiman, U. Jannsen, {\em Motives}, AMS Proc. Symp. Pure Math. {\bf 55: II}, 1994.

\bibitem[Pau]{Pa} A. Paulin, {\em Local to Global Compatibility on the Eigencurve}, to appear in the Proc. London Math. Soc.

\bibitem[PR]{perrin-riou-gz}
B.~Perrin-Riou. {\em  Points de Heegner et d\'eriv\'ees de fonctions $L$ $p$-adiques.} 
 Invent. Math. {\bf 89} (1987), no. 3, 455--510. 

\bibitem[PSR]{PSR} I. I. Piatetski-Shapiro, S. Rallis, {\em Rankin triple $L$-functions}, Compositio Math. {\bf 64} (1987), 31-115.

\bibitem[Pr90]{Pr} D. Prasad, {\em Trilinear forms for representations of $\GL(2)$ and local epsilon factors}, Compositio Math. {\bf 75} (1990), 1--46.

\bibitem[Pr07]{Pr07} D. Prasad, {\em Relating invariant linear form and local epsilon factors via global methods}, with an appendix by H. Saito, Duke J. Math. {\bf 138:2} (2007), 233--261.

\bibitem[Sc]{Sc}  A. J. Scholl, {\em Motives for modular forms}, Invent. Math. {\bf 100} (1990), 419--430.

\bibitem[Se]{serre-padic}
J.-P. Serre, Formes modulaires et fonctions z{\^e}ta $p$-adiques, {\em Lecture Notes Math.} {\bf 350} (1973), 191--268.
 
 
\bibitem[Sh86]{Sh86} G. Shimura, {\em On a class of nearly holomorphic automorphic forms}, Ann. Math. {\bf 123} (1986), 347--406.

\bibitem[Ur]{Ur} E. Urban, {\em Nearly overconvergent modular forms}, to appear.


\bibitem[YZZ]{YZZ}
X. Yuan, S. Zhang, W. Zhang, {\em Triple product L-series and Gross--Schoen cycles I: split case}, preprint.

\bibitem[Wa]{Wa} T. C. Watson, {\em Rankin triple products and quantum chaos}, to appear in Ann. Math.

\end{thebibliography}

\end{document}
