\begin{document}

\title{On Petersson norms of generic cusp forms and special values of adjoint $L$-functions for $\GSp_4$}
\begin{abstract}
We prove an explicit formula for the Petersson norms of some normalized generic cuspidal newforms
on $\frak{o}peratorname{GSp}_4$ whose archimedean components belong to either discrete series representations or spherical principal series representations. Our formula expresses the Petersson norms in terms of special values of adjoint $L$-functions and some elementary constants depending only on local representations.
\end{abstract}

\mathbf{t}ableofcontents
\section{Introduction}\label{s:intro}
In the study of automorphic forms, it is natural and important to measure their size.
For example, let $f \in S_\kappa(\frak{o}peratorname{SL}_2({\mathbb Z}))$ be a normalized Hecke eigenform and consider its Petersson norm 
\[
 \langle f, f \rangle = \int_{\frak{o}peratorname{SL}_2({\mathbb Z}) \backslash \mathfrak{H}}
 |f(\mathbf{t}au)|^2 \frak{o}peratorname{Im}(\mathbf{t}au)^{\kappa-2} \, d \mathbf{t}au.
\]
Then
\[
 \langle f, f \rangle = 2^{-\kappa} L(1, f, {\mathbb A}d),
\]
where $L(s, f, {\mathbb A}d)$ is the (completed) adjoint $L$-function of $f$, and this formula has many applications in analytic number theory and arithmetic geometry.

More generally, let $k$ be a number field with adele ring ${\mathbb A}_k$ and $G$ a connected reductive linear algebraic group over $k$.
Let $\pi = \bigotimes_v \pi_v$ be an irreducible cuspidal automorphic representation of $G({\mathbb A}_k)$.
We assume that $G$ is quasi-split over $k$, $\pi$ occurs with multiplicity one in the automorphic discrete spectrum of $G$, and $\pi$ is globally generic, i.e. the Whittaker function $W_f$ is non-zero for some $f \in \pi$.
Then the Lapid-Mao conjecture \frak{c}ite{LM2015} predicts that
\[
 \langle f, f \rangle = |\mathcal{S}_\pi| \frak{c}dot \frac{L^S(1, \pi, {\mathbb A}d)}{\Delta_G^S} \frak{c}dot \operatorname{pr}od_{v \in S} \alpha_v(f_v)^{-1}
\]
for any $f = \bigotimes_v f_v \in \pi$ normalized so that $W_f(1) = 1$.
Here $\langle f, f \rangle$ is the Petersson norm of $f$, $\mathcal{S}_\pi$ is the global component group of the (conjectural) Arthur parameter of $\pi$, $S$ is a sufficiently large finite set of places of $k$, $L^S(s, \pi, {\mathbb A}d)$ is the partial adjoint $L$-function of $\pi$, $\Delta_G^S$ is a special value of some partial $L$-function depending only on $G$, and $\alpha_v(f_v)$ is the Whittaker integral of the matrix coefficient associated to $f_v \in \pi_v$.
In fact, Lapid and Mao deduced the conjecture for $G = \frak{o}peratorname{GL}_n$ from the theory of Rankin-Selberg integrals developed by Jacquet, Piatetski-Shapiro, and Shalika.
Moreover, in \frak{c}ite{LM2017}, they established an analogous formula when $G$ is the metaplectic group $\mathrm{Mp}_{2n}$ (which is a nonlinear two-fold cover of the symplectic group $\frak{o}peratorname{Sp}_{2n}$) under the assumption that $\pi_v$ is a discrete series representation for all archimedean places $v$ of $k$.
However, to derive from the Lapid-Mao conjecture an explicit formula for $\langle f, f \rangle$ suitable for applications, it is necessary to carry out the computation of the local integral $\alpha_v(f_v)$, which is extremely hard when $v$ is archimedean.

The purpose of this paper is to prove some explicit formula for Petersson norms when $G = {\rm PGSp}_4$.
For simplicity, we assume in the introduction that $k={\mathbb Q}$, $\pi_p$ is unramified for all primes $p$, $\pi_\infty$ is either a discrete series representation or a spherical principal series representation, and $f \in \pi$ is the normalized new vector (see below for the details).
Even in this special case, the Lapid-Mao conjecture has not been proved yet, and even worse, it seems impossible to compute $\alpha_\infty(f_\infty)$ directly.
Nevertheless, by adopting a different approach and using reduction to the endoscopic case, we establish an explicit formula for $\langle f, f \rangle$, which we now describe in more detail.

\subsection{An explicit formula for Petersson norms}

Let $\pi=\bigotimes_v\pi_v$ be an irreducible globally generic cuspidal automorphic representation of $\frak{o}peratorname{GSp}_4({\mathbb A}_{\mathbb Q})$ with trivial central character. By \frak{c}ite{CKPS2004}, \frak{c}ite{AH2006},
$\pi$ has a functorial lift ${\bf P}i$ to $\frak{o}peratorname{GL}_4({\mathbb A}A_{\mathbb Q})$.
We say that $\pi$ is stable (resp.~endoscopic)
if ${\bf P}i$ is cuspidal (resp.~non-cuspidal).
We assume $\pi_p$ is unramified for all primes $p$, and consider the following two cases:
\begin{itemize}
\item[(DS)] $$\pi_{\infty}\vert_{\frak{o}peratorname{Sp}_4({\mathbb R})} = D_{(\lambda_1,\lambda_2)}\frak{o}plus D_{(-\lambda_2,-\lambda_1)},$$
where $D_{(\lambda_1,\lambda_2)}$ is the (limit of) discrete series representation of $\frak{o}peratorname{Sp}_4({\mathbb R})$ with Blattner parameter $(\lambda_1,\lambda_2) \in {\mathbb Z}^2$ such that $1-\lambda_1 \leq \lambda_2 \leq 0$. 
\item[(PS)] $$\pi_\infty \vert_{\frak{o}peratorname{Sp}_4({\mathbb R})} = {\rm Ind}_{\frak{o}peratorname{Sp}_4({\mathbb R})\frak{c}ap {\bf B}({\mathbb R})}^{\frak{o}peratorname{Sp}_4({\mathbb R})}(|\mbox{ }|^{\lambda_1}\boxtimes|\mbox{ }|^{\lambda_2})$$ for some $\lambda_1, \lambda_2 \in {\mathbb C}$. Here ${\bf B}$ is the standard Borel subgroup of $\frak{o}peratorname{GSp}_4$.
\end{itemize}

Let $f=\bigotimes_v f_v \in \pi$ be a non-zero cusp form satisfying the following conditions:
\begin{align}\label{E:K-type}
\begin{split}
&f_p\mbox{ is }\frak{o}peratorname{GSp}_4({\mathbb Z}_p)\mbox{-invariant for all primes }p.\\
&\mbox{In Case (DS), }f_{\infty}\mbox{ is a lowest weight vector of the minimal }{\rm U}(2)\mbox{-type of }D_{(-\lambda_2,-\lambda_1)}.\\
&\mbox{In Case (PS), }f_\infty \mbox{ is an $(\frak{o}peratorname{Sp}_4({\mathbb R})\frak{c}ap {\rm O}(4))$-invariant vector.}
\end{split}
\end{align}
For the choice of $f_\infty$ in Case (DS), we refer to \S\,\ref{SS:main thm} for more detail. 
By \frak{c}ite{JS2007}, the multiplicity of $\pi$
in the space of cusp forms on $\frak{o}peratorname{GSp}_4({\mathbb A}A_{\mathbb Q})$ is one.
Hence the conditions in (\ref{E:K-type}) uniquely determine $f \in \pi$ up to scalars.
Let $U$ be the unipotent radical of ${\bf B}$ and $\psi_U$ the standard non-degenerate character of $U({\mathbb Q})\backslash U({\mathbb A}_{\mathbb Q})$ (see \S\,\ref{S:notation} for precise definition).
The Whittaker function of $f$ with respect to $\psi_U$ is defined by
\[W(g)=\int_{U({\mathbb Q})\backslash U({\mathbb A}_{\mathbb Q})}f(ug)\frak{o}verline{\psi_U(u)}\,du.\]
Here $du$ is the Tamagawa measure on $U({\mathbb A}_{\mathbb Q})$. We may decompose $W$ into a product of local Whittaker functions $W=\operatorname{pr}od_v W_v$. By explicit formulae for Whittaker functions
\frak{c}ite{CS1980}, \frak{c}ite{Oda1994}, \frak{c}ite{Moriyama2004}, \frak{c}ite{Ishii2005}, and \frak{c}ite{RS2007},
$W_v(1) \ne 0$ for all places $v$. We normalize $f$ as follows (see also Remark \ref{R:normalization} below): Let $W_p(1)=1$ for all primes $p$.
In Case (DS), let
\begin{align}\label{E:normalization DS}
\begin{split}
W_\infty(1)&=
e^{-2\pi}\int_{c_1-\sqrt{-1}\infty}^{c_1+\sqrt{-1}\infty}\frac{ds_1}{2\pi \sqrt{-1}}\,\int_{c_2-\sqrt{-1}\infty}^{c_2+\sqrt{-1}\infty}\frac{ds_2}{2\pi \sqrt{-1}}\,(4\pi^{3})^{(-s_1+\lambda_{1}+1)/2}(4\pi )^{(-s_2+\lambda_{2})/2}\\
&\quad\quad\quad\quad\quad\quad\quad\quad\quad\mathbf{t}imes {G}amma\left(\frac{s_1+s_2-2\lambda_{2}+1}{2}\right){G}amma\left(\frac{s_1+s_2+1}{2}\right){G}amma\left(\frac{s_1}{2}\right){G}amma\left(\frac{-s_2}{2}\right),
\end{split}
\end{align}
where $c_1,c_2 \in {\mathbb R}$ satisfy 
$c_1+c_2+1>0$ and $c_1>0>c_2.$ In Case (PS), let
\begin{align}\label{E:normalization PS}
\begin{split}
W_\infty(1) &= \int_{c_1-\sqrt{-1}\infty}^{c_1+\sqrt{-1}\infty}\frac{ds_1}{2\pi \sqrt{-1}}\,\int_{c_2-\sqrt{-1}\infty}^{c_2+\sqrt{-1}\infty}\frac{ds_2}{2\pi \sqrt{-1}}\,2^{-4}\pi^{-s_1-s_2}\\
&\mathbf{t}imes{G}amma\left(\frac{s_1+\lambda_{1}}{2}\right){G}amma\left(\frac{s_1-\lambda_{1}}{2}\right){G}amma\left(\frac{s_1+\lambda_{2}}{2}\right){G}amma\left(\frac{s_1-\lambda_{2}}{2}\right)\\
&\mathbf{t}imes{G}amma\left(\frac{s_2}{2}+\frac{\lambda_{1}+\lambda_{2}}{4}\right){G}amma\left(\frac{s_2}{2}-\frac{\lambda_{1}+\lambda_{2}}{4}\right){G}amma\left(\frac{s_2}{2}+\frac{\lambda_{1}-\lambda_{2}}{4}\right){G}amma\left(\frac{s_2}{2}-\frac{\lambda_{1}-\lambda_{2}}{4}\right)\\
&\mathbf{t}imes{G}amma\left(\frac{s_1+s_2}{2}+\frac{\lambda_{1}+\lambda_{2}}{4}\right)^{-1}{G}amma\left(\frac{s_1+s_2}{2}-\frac{\lambda_{1}+\lambda_{2}}{4}\right)^{-1}\\
&\mathbf{t}imes {}_3F_2\left(\frac{s_1}{2},\frac{s_2}{2}+\frac{\lambda_{1}-\lambda_{2}}{4}, \frac{s_2}{2}-\frac{\lambda_{1}-\lambda_{2}}{4} ;\, \frac{s_1+s_2}{2}+\frac{\lambda_{1}+\lambda_{2}}{4},\frac{s_1+s_2}{2}-\frac{\lambda_{1}+\lambda_{2}}{4};\,1           \right),
\end{split}
\end{align}
where ${}_3F_2$ is a generalized hypergeometric function and $c_1,c_2 \in {\mathbb R}$ satisfy
\[
c_1>\max\left\{ |{\rm Re}(\lambda_{1})|,\,|{\rm Re}(\lambda_{2})|\right\},\quad c_2>\max\left\{\left\vert{\rm Re}\left(\frac{\lambda_{1}+\lambda_{2}}{2}\right)\right\vert,\,\left\vert{\rm Re}\left(\frac{\lambda_{1}-\lambda_{2}}{2}\right)\right\vert\right\}.
\]
Note that by \frak{c}ite[Theorem 3.2 and Proposition 3.5]{Ishii2005}, the right-hand side of (\ref{E:normalization PS}) depends only on the orbit of $(\lambda_1,\lambda_2)$ under the action of the Weyl group.
Let $\langlef,f\rangle$ be the Petersson norm of $f$ defined by 
\[\langlef,f\rangle=\int_{{\mathbb A}_{\mathbb Q}^\mathbf{t}imes\frak{o}peratorname{GSp}_4({\mathbb Q})\backslash \frak{o}peratorname{GSp}_4({\mathbb A}_{\mathbb Q})}|f(g)|^2\,dg.\]
Here $dg$ is the Tamagawa measure on $\frak{o}peratorname{GSp}_4({\mathbb A}_{\mathbb Q})$. 

\begin{thm}\label{T:intro}
We have
\[\langlef,f\rangle=2^c\frak{c}dot \frac{L(1,\pi,{\rm Ad})}{\Delta_{{\rm PGSp}_4}}\frak{c}dot C_\infty.\]
Here ${\rm Ad}$ is the adjoint representation of $\frak{o}peratorname{GSp}_4({\mathbb C})$ on $\frak{pgsp}_4({\mathbb C})$ and
\begin{align*}
\Delta_{{\rm PGSp}_4} &= \zeta(2)\zeta(4),\\
c&=\begin{cases}1 & \mbox{ if $\pi$ is stable},\\
2 & \mbox{ if $\pi$ is endoscopic},\end{cases}\\
C_\infty & = \begin{cases}
\displaystyle{2^{\lambda_{1}-\lambda_{2}+5}\pi^{3\lambda_{1}-\lambda_{2}+5}(1+\lambda_{1}-\lambda_{2})^{-1}}  & \mbox{ in Case (DS)},\\
\displaystyle{2^{-4}} & \mbox{ in Case (PS)},
\end{cases}
\end{align*}
where $\zeta(s)$ is the completed Riemann zeta function.
\end{thm}

\begin{rmk}
In Case (DS), $1 + \lambda_1 - \lambda_2$ is the dimension of the minimal $\operatorname{U}(2)$-type of $D_{(-\lambda_2,-\lambda_1)}$.
\end{rmk}

\begin{rmk}\label{R:normalization}
Recall that, in the case of $\frak{o}peratorname{GL}_2({\mathbb R})$, we may normalize the Whittaker function so that its value at $\operatorname{diag}(a,1)$ with $a > 0$ is given by 
\[
 a^{\kappa/2} e^{- 2 \pi a} = \frac{1}{2 \pi \sqrt{-1}} \int_{c-\sqrt{-1} \infty}^{c+\sqrt{-1} \infty} (2 \pi)^{-s-\kappa/2} {G}amma\left(s+\frac{\kappa}{2} \right) a^{-s} \, ds
\]
for the (limit of) discrete series representation with minimal weight $\kappa \in {\mathbb Z}_{\ge 1}$ and 
\[
 a^{1/2} K_\lambda(2 \pi a) = \frac{1}{2 \pi \sqrt{-1}} \int_{c-\sqrt{-1} \infty}^{c+\sqrt{-1} \infty} 2^{-2} \pi^{-s-1/2} {G}amma\left( \frac{s+\lambda}{2} + \frac{1}{4} \right) {G}amma\left( \frac{s-\lambda}{2} + \frac{1}{4} \right) a^{-s} \, ds
\]
for the spherical principal series representation $\mathrm{I}nd^{\frak{o}peratorname{GL}_2({\mathbb R})}_{B({\mathbb R})}(|\ |^\lambda \boxtimes |\ |^{-\lambda})$, where $B$ is the standard Borel subgroup of $\frak{o}peratorname{GL}_2$. 
Thus (\ref{E:normalization DS}) and (\ref{E:normalization PS}) can be regarded as a generalization of this normalization to the case of $\frak{o}peratorname{GSp}_4({\mathbb R})$.
It would also be interesting to compare our normalization in Case (DS) with the rational structures studied by Harris and Kudla \frak{c}ite{HK1992}. 
\end{rmk}

\begin{rmk}
In Case (DS), Theorem \ref{T:intro} plays an important role in the result of Lemma and Ochiai \frak{c}ite{LO2018} on the congruence between a fixed irreducible globally generic endoscopic cuspidal automorphic representation of $\frak{o}peratorname{GSp}_4({\mathbb A}_{\mathbb Q})$ and irreducible stable cuspidal automorphic representations of $\frak{o}peratorname{GSp}_4({\mathbb A}_{\mathbb Q})$.

\end{rmk}

\subsection{An outline of the proof}
The proof of Theorem \ref{T:intro} consists of two steps.
\begin{itemize}
\item
We first prove that there exists a constant $\widetilde{C}_\infty$ depending only on $\pi_\infty$ such that 
\begin{equation}
\label{eq:pf1}
 \langle f, f \rangle = 2^c \frak{c}dot \frac{L(1, \pi, {\mathbb A}d)}{\Delta_{{\rm PGSp}_4}} \frak{c}dot \widetilde{C}_\infty.
\end{equation}
For this, we consider the automorphic $L$-function
\[
 L(s, \pi \mathbf{t}imes \pi^{\vee}) = \zeta(s) \frak{c}dot L(s, \pi, {\rm std}) \frak{c}dot L(s, \pi, {\mathbb A}d),
\]
where $\pi^{\vee}$ is the contragredient representation of $\pi$ and $L(s, \pi, {\rm std})$ is the standard $L$-function of $\pi$.
Recall the integral representations (ignoring factors which do not depend on $\pi$)
\begin{align*}
 \langle \mathcal{E}(s), \bar{f} \frak{o}times f \rangle 
 & = L_{\mathrm{fin}} \left( \frac{s+1}{2}, \pi \mathbf{t}imes \pi^{\vee} \right) \frak{c}dot \mathcal{Z}(s, \pi_\infty), \\
 \langle E(s), \bar{f} \frak{o}times f \rangle  
 & = \langle f, f \rangle \frak{c}dot L_{\mathrm{fin}}\left( s+\frac{1}{2}, \pi, {\rm std} \right) \frak{c}dot Z(s, \pi_\infty)
\end{align*}
due to Jiang \frak{c}ite{Jiang1996} and Piatetski-Shapiro and Rallis \frak{c}ite{LNM1254}, respectively. 
Here $\mathcal{E}(s)$ and $E(s)$ are Eisenstein series on $\frak{o}peratorname{GSp}_8$ induced from characters of Levi subgroups $\frak{o}peratorname{GL}_3 \mathbf{t}imes \frak{o}peratorname{GSp}_2$ and $\frak{o}peratorname{GL}_4 \mathbf{t}imes \frak{o}peratorname{GL}_1$, respectively, $L_{\mathrm{fin}}(s,\dots)$ denotes the $L$-function without the archimedean factor, and $\mathcal{Z}(s, \pi_\infty)$ and $Z(s, \pi_\infty)$ are the associated archimedean zeta integrals.
Recall also that these Eisenstein series have Laurent expansions of the form
\begin{align*}
 \mathcal{E}(s) & = \frac{\mathcal{E}_{-2}(1)}{(s-1)^2} + \frac{\mathcal{E}_{-1}(1)}{s-1} + \frak{c}dots, \\
 E(s) & = \frac{E_{-1}(\frac{1}{2})}{s-\frac{1}{2}} + E_0\left( \frac{1}{2} \right) + \frak{c}dots.
\end{align*}
Then it follows from the Siegel-Weil formula \frak{c}ite{GQT2014} that 
\begin{align*}
 \langle \mathcal{E}_{-2}(1), \bar{f} \frak{o}times f \rangle 
 & = \left\langle  E_{-1} \left( \frac{1}{2} \right), \bar{f} \frak{o}times f \right\rangle, \\
 \langle \mathcal{E}_{-1}(1), \bar{f} \frak{o}times f \rangle 
 & = \left\langle E_{0} \left( \frac{1}{2} \right), \bar{f} \frak{o}times f \right\rangle, 
\end{align*}
where the first identity says $0=0$ when $\pi$ is stable and the second identity holds only when $\pi$ is stable.
Combining this with the integral representations, and noting that $L(s, \pi, {\rm std})$ is holomorphic and non-zero (resp.~has a simple pole) at $s=1$ if $\pi$ is stable (resp.~endoscopic), we can deduce \eqref{eq:pf1} with 
\[
 \widetilde{C}_\infty = \frac{1}{L(1, \pi_\infty, {\mathbb A}d)} \frak{c}dot 
 \frac{\mathcal{Z}(1, \pi_\infty)}{Z(\frac{1}{2}, \pi_\infty)}.
\]
\item
We next show that 
\begin{equation}
\label{eq:pf2}
 \widetilde{C}_\infty = C_\infty.
\end{equation}
This is a local problem, but we address it by a global argument.
If $\pi$ is endoscopic, then $\pi$ can be realized as a global theta lift from the orthogonal similitude group ${\rm GO}_{2,2}$.
Hence, by using the Rallis inner product formula \frak{c}ite{GQT2014}, we can compute $\langle f, f \rangle$ explicitly to deduce \eqref{eq:pf2} in this case.
On the other hand, it follows from the limit multiplicity formula \frak{c}ite{Shin2012} that the set of the archimedean components $\pi_\infty$ of such endoscopic representations $\pi$ is dense in the set of tempered representations of $\frak{o}peratorname{GSp}_4({\mathbb R})$ of type (DS) or (PS).
(Strictly speaking, we need to consider cusp forms of square-free level over totally real number fields.)
Thus we may conclude \eqref{eq:pf2} for any $\pi_\infty$ by showing that $\widetilde{C}_\infty = \widetilde{C}_\infty(\pi_\infty)$ is analytic as a function of $\pi_\infty$.
\end{itemize}

\section{Main result}\label{Main results}
\subsection{Notation}\label{S:notation}

Fix a totally real number field $k$. Let $\frak{o}$, $\frak d$, and $\frak{D}$ be the ring of integers, the different ideal, and the absolute discriminant of $k$, respectively.
Let ${\mathbb A}={\mathbb A}_k$ be the ring of adeles of $k$ and ${\mathbb A}_f$ its finite part. For a finite dimensional vector space $V$ over $k$, let $\mathcal{S}(V({\mathbb A}))$ be the space of Schwartz functions on $V({\mathbb A})$. Let $\psi_0=\bigotimes_v\psi_{v,0}$ be the standard additive character of ${\mathbb Q}\backslash {\mathbb A}_{\mathbb Q}$ defined so that
\begin{align*}
\psi_{p,0}(x) & = e^{-2\pi \sqrt{-1}x} \mbox{ for }x \in {\mathbb Z}[p^{-1}],\\
\psi_{\infty,0}(x) & = e^{2\pi \sqrt{-1}x} \mbox{ for }x \in {\mathbb R}.
\end{align*}
Let $\psi= \psi_k = \psi_0\frak{c}irc{\rm tr}_{k/{\mathbb Q}}$ be the standard additive character of $k \backslash {\mathbb A}$.

Let $v$ be a place of $k$. We denote by $\psi_v$ the $v$-component of $\psi$. If $v$ is a finite place, let $\frak{o}_v$, $\varpi_v$, and $q_v$ be the maximal compact subring of $k_v$, a generator of the maximal ideal of $\frak{o}_v$, and the cardinality of $\frak{o}_v / \varpi_v\frak{o}_v$. Let $|\mbox{ }|_v$ be the absolute value on $k_v$ normalized so that $|\varpi_v|_v = q_v^{-1}$. Let $\frak{c}_v$ be the integer such that $\frak{d}_v = \varpi_v^{\frak{c}_v}\frak{o}_v$. Note that $\frak{c}_v$ is the largest integer so that $\psi_v$ is trivial on $\varpi_v^{-\frak{c}_v}\frak{o}_v$. If $v$ is a real place, let $|\mbox{ }|_v$ be the ordinary absolute value on $k_v$.

Let $\zeta(s) = \zeta_k(s) = \operatorname{pr}od_{v}\zeta_v(s)$ be the completed Dedekind zeta function of $k$, where $v$ ranges over the places of $k$ and 
\[\zeta_v(s) = \begin{cases}
(1-q_v^{-s})^{-1} & \mbox{ if $v$ is finite},\\
\pi^{-s/2}{G}amma(s/2) & \mbox{ if $v$ is real}.
\end{cases}
\]
Here ${G}amma(s)$ is the gamma function. Define $\rho = {\rm Res}_{s=1}\zeta(s)$.

If $S$ is a set, then we let $\mathbb{I}_S$ be the characteristic function of $S$. Let ${\rm M}_{n , m}$ be the matrix algebra of $n$ by $m$ matrices.
Let $\frak{o}peratorname{GSp}_{2n}$ denote the symplectic similitude group of rank $n+1$ defined by
\[
 \frak{o}peratorname{GSp}_{2n} =
 \left\{ g \in \frak{o}peratorname{GL}_{2n} \, \left| \, g
 \begin{pmatrix}
  0      & \mathbf{1}_n \\
  - \mathbf{1}_n & 0
 \end{pmatrix}
 {}^t \! g = 
  \nu(g) \begin{pmatrix}
  0      & \mathbf{1}_n \\
  - \mathbf{1}_n & 0
 \end{pmatrix}, \,\nu(g) \in \mathbb{G}_m
 \right. \right\}.
\]
Let $\frak{o}peratorname{Sp}_{2n} = {\rm ker}(\nu)$. Throughout this article, we write 
\[G= \frak{o}peratorname{GSp}_4\]
unless otherwise specified. Let $Z_G$ be the center of $G$. Let \[{\bf B}=\left.\left\{\begin{pmatrix} t_1 & * & *&* \\0&t_2&*&*\\0&0&\nu t_1^{-1}&0\\0&0& *&\nu t_2^{-1}  \end{pmatrix}\in {G}  \mbox{ }\right\vert\mbox{ } t_1,t_2,\nu \in {\mathbb G}_m\right\}\]
be the standard Borel subgroup of ${G}$, and let $U$ be its unipotent radical. Let $\psi_U$ be the non-degenerate character of $U(k)\backslash U({\mathbb A})$ defined by
\[\psi_U\left(\begin{pmatrix} 1 & x & *&* \\0&1&*&y\\0&0&1&0\\0&0&-x&1 \end{pmatrix}\right)= \psi(-x-y).\] Let $\bf T \subset {\bf B}$ be the standard maximal tours of $G$. In $\frak{o}peratorname{GL}_2$, let $B$ be the Borel subgroup consisting of upper triangular matrices, and put
\[{\bf a}(\nu) = \begin{pmatrix} \nu & 0 \\ 0 & 1 \end{pmatrix},\quad {\bf d}(\nu) =   \begin{pmatrix} 1 & 0 \\ 0 & \nu \end{pmatrix},\quad {\bf m}(t)= \begin{pmatrix} t & 0 \\ 0 & t^{-1}\end{pmatrix},\quad {\bf n}(x) = \begin{pmatrix} 1 & x \\ 0 & 1\end{pmatrix},\quad w = \begin{pmatrix} 0 & 1 \\ -1 & 0\end{pmatrix}\]
for $\nu,t \in \mathbb{G}_m$ and $x \in \mathbb{G}_a$. Let
\[{\rm SO}(2) = \left.\left\{ k_\mathbf{t}heta = \begin{pmatrix} \frak{c}os\mathbf{t}heta & \sin\mathbf{t}heta \\ -\sin\mathbf{t}heta & \frak{c}os\mathbf{t}heta \end{pmatrix} \mbox{ }\right\vert\mbox{ } \mathbf{t}heta \in {\mathbb R}/2\pi{\mathbb Z} \right\}.\]

Let $v$ be a finite place of $k$. Let $K_0(\varpi_v)$ be the Iwahori subgroup of $\frak{o}peratorname{GL}_2(k_v)$ defined by
\[K_0(\varpi_v) = \begin{pmatrix} \frak{o}_v & \frak{o}_v \\ \varpi_v\frak{o}_v & \frak{o}_v\end{pmatrix} \frak{c}ap \frak{o}peratorname{GL}_2(\frak{o}_v).\] The paramodular group ${\rm K}(\varpi_v)$ of level $\varpi_v\frak{o}_v$ is the subgroup of $G(k_v)$ consisting of $g \in G(k_v)$ such that $\nu(g) \in \frak{o}_v^\mathbf{t}imes$ and 
\[g \in \begin{pmatrix} \frak{o}_v & \frak{o}_v & \varpi_v^{-1}\frak{o}_v & \frak{o}_v\\
\varpi_v\frak{o}_v & \frak{o}_v & \frak{o}_v & \frak{o}_v\\
\varpi_v\frak{o}_v & \varpi_v\frak{o}_v & \frak{o}_v & \varpi_v\frak{o}_v\\
\varpi_v\frak{o}_v & \frak{o}_v & \frak{o}_v & \frak{o}_v
 \end{pmatrix}.\]

For $\nu \in {\mathbb C}$, let $K_{\nu}(z)$ be the modified Bessel function defined by
\begin{align}\label{E:K Bessel}
K_{\nu}(z) = \frac{1}{2}\int_{0}^{\infty}e^{-z(t+t^{-1})/2}t^{\nu-1}\,dt
\end{align}
if ${\rm Re}(z)>0$. 
\subsection{Measures}\label{SS:measures}
Let $v$ be a place of $k$. 
If $v$ is finite, we normalize the Haar measures on $k_v$ and $k_v^\mathbf{t}imes$ so that ${\rm vol}(\frak{o}_v)=1$ and ${\rm vol}(\frak{o}_v^\mathbf{t}imes)=1$, respectively. If $v$ is real, we normalize the Haar measures on $k_v \simeq {\mathbb R}$ and $k_v^\mathbf{t}imes \simeq {\mathbb R}^\mathbf{t}imes$ so that ${\rm vol}([1,2])=1$ and ${\rm vol}([1,2])=\log2$, respectively.
Let $m$ be a positive integer. Let $dg_v$ be the Haar measure on $\frak{o}peratorname{GL}_m(k_v)$ defined as follows: For $\phi \in L^1(\frak{o}peratorname{GL}_m(k_v))$, we have 
\begin{align}\label{E:standard measure on GL}
\int_{\frak{o}peratorname{GL}_m(k_v)}\phi(g_v)\,dg_v = \operatorname{pr}od_{1 \leq i<j \leq m}\int_{k_v}du_{ij}\operatorname{pr}od_{1\leq i \leq m}\int_{k_v^{\mathbf{t}imes}}d^{\mathbf{t}imes}t_i\int_{K_v}dk\,\phi\left(\begin{pmatrix} t_1 & u_{12} & \frak{c}dots &u_{1m} \\ 0 & t_2 & \frak{c}dots & u_{2m} \\ \vdots & \vdots & \ddots& \vdots \\ 0 & 0 & \frak{c}dots & t_m\end{pmatrix} k\right)\operatorname{pr}od_{1\leq i \leq m}|t_i|_v^{-m+i},
\end{align}
where 
\begin{align*}
K_v = \begin{cases}    
\frak{o}peratorname{GL}_m(\frak{o}_v)& \mbox{ if $v$ is finite},\\
{\rm O}(m) & \mbox{ if $v$ is real},
\end{cases}
\end{align*}
and ${\rm vol}(K_v)=1$. Let $H$ be a connected reductive linear algebraic group defined and split over $k_v$. Fix a Chevalley basis of ${\rm Lie}(H)$. The basis determines a top differential form on $H$ over ${\mathbb Z}$ which is unique up to $\pm 1$. The top differential form together with the self-dual Haar measure on $k_v$ with respect to $\psi_v$ determines a Haar measure on $H(k_v)$ as explained in \frak{c}ite[\S\,6]{Vos1996}. We call it the local Tamagawa measure on $H(k_v)$.

For a connected linear algebraic group $H$ over $k$, we take the Tamagawa measure on $H({\mathbb A})$ (cf.~\frak{c}ite[\S\,6]{Vos1996}). For any compact group $K$, we take the Haar measure on $K$ such that ${\rm vol}(K)=1$.
Let $dg$ be the Tamagawa measure on $\frak{o}peratorname{GL}_m({\mathbb A})$. Then (cf.\,\frak{c}ite[\S\,5]{Lai1980})
\begin{align}\label{Tamagawa measure on GL}
dg = \frak{D}^{-m^2/2}\rho^{-1}\operatorname{pr}od_{i=2}^m\zeta(i)^{-1} \frak{c}dot\operatorname{pr}od_v dg_v.
\end{align}

\subsection{Main result}\label{SS:main thm}
Let $\pi=\bigotimes_v \pi_v$ be an irreducible globally generic cuspidal automorphic representation of $G({\mathbb A})$ with trivial central character. Denote by $\frak{n} \unlhd \frak{o}$ the paramodular conductor of $\pi$ (cf.\,\frak{c}ite{RS2007}). We assume $\pi$ satisfies the following conditions:
\begin{itemize}
\item $\frak n$ is square-free.
\item For each real place $v$, $\pi_v$ is in one of the following two types:
\item[(DS)] $$\pi_{v}\vert_{\frak{o}peratorname{Sp}_4(k_v)} = D_{(\lambda_{1,v},\lambda_{2,v})}\frak{o}plus D_{(-\lambda_{2,v},-\lambda_{1,v})},$$
where $D_{(\lambda_{1,v},\lambda_{2,v})}$ is the (limit of) discrete series representation of $\frak{o}peratorname{Sp}_4(k_v)$ with Blattner parameter $(\lambda_{1,v},\lambda_{2,v}) \in {\mathbb Z}^2$ such that $1-\lambda_{1,v} \leq \lambda_{2,v} \leq 0$. 
\item[(PS)] $$\pi_v \vert_{\frak{o}peratorname{Sp}_4(k_v)} = {\rm Ind}_{\frak{o}peratorname{Sp}_4(k_v)\frak{c}ap {\bf B}(k_v)}^{\frak{o}peratorname{Sp}_4(k_v)}(|\mbox{ }|_v^{\lambda_{1,v}}\boxtimes|\mbox{ }|_v^{\lambda_{2,v}})$$ for some $\lambda_{1,v},\lambda_{2,v} \in {\mathbb C}$. 
\end{itemize}
In Case (DS), we follow \frak{c}ite{Moriyama2004} for the choice of the Cartan subalgebra in $\frak{sp}_4({\mathbb R})$ and the positive systems.

Denote by $S(\frak{n})$ the set of finite places dividing $\frak{n}$, by $S({\rm DS})$ and $S({\rm PS})$ the sets of real places of type (DS) and (PS), respectively.

Let $f=\bigotimes_v f_v \in \pi$ be a non-zero cusp form satisfying the following conditions:
\begin{align}\label{E:K-type2}
\begin{split}
&f_v\mbox{ is }{G}(\frak{o}_v)\mbox{-invariant for all finite places }v \notin S(\frak{n}).\\
&f_v\mbox{ is ${\rm K}(\varpi_v)$-invariant for all $v \in S(\frak{n})$}.\\
&f_{v}\mbox{ is a lowest weight vector of the minimal }{\rm U}(2)\mbox{-type of }D_{(-\lambda_{2,v},-\lambda_{1,v})}\mbox{ for all $v \in S({\rm DS})$.}\\
&f_v \mbox{ is an $(\frak{o}peratorname{Sp}_4(k_v)\frak{c}ap {\rm O}(4))$-invariant vector for all $v \in S({\rm PS})$}.
\end{split}
\end{align}
For $v \in S({\rm DS})$, the vector $f_v$ is proportional to the vector $v_0$ in the notation of \frak{c}ite[\S\,1.2]{Moriyama2004}. By \frak{c}ite{JS2007}, the multiplicity of $\pi$
in the space of cusp forms on ${G}({\mathbb A}A)$ is one. Therefore, the conditions (\ref{E:K-type2}) characterize $f \in \pi$ up to scalars. 
Let $W$ be the Whittaker function of $f$ with respect to $\psi_U$ defined by
\[W(g)=\int_{U(k)\backslash U({\mathbb A})}f(ug)\frak{o}verline{\psi_U(u)}\,du.\]
Here $du$ is the Tamagawa measure on $U({\mathbb A})$.
We may decompose $W = \operatorname{pr}od_v W_v$ as a product of local Whittaker functions of $\pi_v$ with respect to $\psi_{U,v}$. We normalize $f$ as follows:
\begin{align}\label{E:normalization}
\begin{split}
&W_v(\operatorname{diag}( \varpi_v^{-\frak{c}_v}, 1, \varpi^{2\frak{c}_v}, \varpi_v^{\frak{c}_v} ))=1\mbox{ for all finite places }v,\\
&W_v(1)\mbox{ is normalized as in (\ref{E:normalization DS}) for all $v \in S({\rm DS})$,}\\
&W_v(1)\mbox{ is normalized as in (\ref{E:normalization PS}) for all $v \in S({\rm PS})$.}
\end{split}
\end{align}
Let $\langlef,f\rangle$ be the Petersson norm of $f$ defined by
\[\langlef,f\rangle=\int_{Z_G({\mathbb A})G(k)\backslash G({\mathbb A})}|f(g)|^2\,dg.\]

Our main result is the following theorem.

\begin{thm}\label{T:main thm}
We have
\[\langlef,f\rangle=2^c\frak{c}dot\frac{L(1,\pi,{\rm Ad})}{\Delta_{{\rm PGSp}_4}}\frak{c}dot \operatorname{pr}od_vC(\pi_v).\]
Here ${\rm Ad}$ is the adjoint representation of $\frak{o}peratorname{GSp}_4({\mathbb C})$ on $\frak{pgsp}_4({\mathbb C})$ and
\begin{align*}
\Delta_{{\rm PGSp}_4} &= \zeta(2)\zeta(4),\\
c&=\begin{cases}1 & \mbox{ if $\pi$ is stable},\\
2 & \mbox{ if $\pi$ is endoscopic},\end{cases}\\
C(\pi_v) &= \begin{cases}
\displaystyle{q_v^{-5\frak{c}_v}} & \mbox{ if $v \nmid \infty \frak{n}$},\\
\displaystyle{q_v^{-1-5\frak{c}_v}\zeta_v(2)^{-1}\zeta_v(4)} & \mbox{ if $v \in S(\frak{n})$},\\
\displaystyle{2^{\lambda_{1,v}-\lambda_{2,v}+5}\pi^{3\lambda_{1,v}-\lambda_{2,v}+5}(1+\lambda_{1,v}-\lambda_{2,v})^{-1}}  & \mbox{ if $v \in S({\rm DS})$},\\
\displaystyle{2^{-4}} & \mbox{ if $v \in S({\rm PS})$}.
\end{cases}
\end{align*}
\end{thm}

\section{Siegel-Weil formula}\label{s:sw}
In this section, we introduce Eisenstein series on $\frak{o}peratorname{Sp}_{2n}({\mathbb A})$, theta integrals and its regularization, and recall the Siegel-Weil formula in the second term range for $n=4$. The results and notation in this section will be used in \S\,\ref{s:autom}.

\subsection{Eisenstein series} \label{ss:eisenstein}

Let $n$, $r$ be positive integers such that $n \ge r$.
Let
\[
 P_{n,r} =
 \left\{ \left. 
 \begin{pmatrix}
  a & *  & * & * \\
  0 & a' & * & b' \\
  0 & 0  & \nu(g){}^t  a^{-1} & 0 \\
  0 & c' & * & d' 
 \end{pmatrix}
 \in \frak{o}peratorname{GSp}_{2n} \, \right| \, 
  a \in \frak{o}peratorname{GL}_r, \,
  g = \begin{pmatrix}
        a' & b' \\
        c' & d' 
       \end{pmatrix}
  \in \frak{o}peratorname{GSp}_{2n - 2r}
 \right\}
\]
be a maximal parabolic subgroup of $\frak{o}peratorname{GSp}_{2n}$. 
We define a maximal compact subgroup ${\bf K} = \operatorname{pr}od_v {\bf K}_v$ of $\frak{o}peratorname{GSp}_{2n}({\mathbb A}A)$ by
\[
 {\bf K}_v =
 \begin{cases}
  \frak{o}peratorname{GSp}_{2n}(\frak{o}_v)         & \mathbf{t}ext{if $v$ is finite,} \\
  \frak{o}peratorname{GSp}_{2n}(k_v) \frak{c}ap \operatorname{O}(2n) & \mathbf{t}ext{if $v$ is real.}
 \end{cases}
\]
Let $K_v = {\bf K}_v \frak{c}ap \frak{o}peratorname{Sp}_{2n}(k_v)$ for each place $v$ of $k$, and $K = \operatorname{pr}od_vK_v$. Let $\mathfrak{g}_{\infty}$ be the complexified Lie algebra of $ \operatorname{pr}od_{v \mid \infty}\frak{o}peratorname{Sp}_{2n}(k_v)$ and $K_{\infty} = \operatorname{pr}od_{v \mid \infty}K_v$ a maximal compact subgroup of $\operatorname{pr}od_{v \mid \infty}\frak{o}peratorname{Sp}_{2n}(k_v)$.

For $s \in {\mathbb C}$, let $I_{n,r}(s) = \mathrm{I}nd^{\frak{o}peratorname{GSp}_{2n}({\mathbb A}A)}_{P_{n,r}({\mathbb A}A)} (\delta_{P_{n,r}}^{s/(2n-r+1)})$
denote the degenerate principal series representation of $\frak{o}peratorname{GSp}_{2n}({\mathbb A}A)$.
Here $\delta_{P_{n,r}}$ is the modulus character of $P_{n,r}({\mathbb A})$.
For a holomorphic section $F$ of $I_{n,r}(s)$,
define an Eisenstein series $E^{(n,r)}(s, F)$ by 
\[
 E^{(n,r)}(g; s,F) = \sum_{\gamma \in P_{n,r}(k) \backslash \frak{o}peratorname{GSp}_{2n}(k)} F(\gamma g, s)
\]
for ${\mathbb R}e(s) \gg 0$,
and by the meromorphic continuation otherwise.
Let 
\[
 E^{(n,r)}(s,F) = \sum_{d \gg - \infty} (s - s_0)^d E^{(n,r)}_d(s_0, F)
\]
be the Laurent expansion of $E^{(n,r)}(s, F)$ at $s = s_0$. 

\subsection{Theta integrals}\label{SS:Theta integrals}

In this section,
we review the result of Kudla and Rallis \frak{c}ite{KR1994}
on the regularization of theta integrals.

Assume that $r \geq 2$.
Let $V_{r,r} = k^{2r}$ be the space of column vectors
equipped with a non-degenerate symmetric bilinear form $(\ ,\ )$ given by
\[
 (x, y) = {}^t \! x 
 \begin{pmatrix}
  0    & \mathbf{1}_r \\
  \mathbf{1}_r & 0
 \end{pmatrix}
 y
\]
for $x,y \in V_{r,r}$.
Let $G' = {\rm GO}_{r,r}$ denote the orthogonal similitude group of $V_{r,r}$ defined by
\[
 {\rm GO}_{r,r} = \left\{ g' \in \frak{o}peratorname{GL}_{2r} \, \left| \, {}^t \! g'
 \begin{pmatrix}
  0    & \mathbf{1}_r \\
  \mathbf{1}_r & 0
 \end{pmatrix}
 g' =\nu(g') 
 \begin{pmatrix}
  0    & \mathbf{1}_r \\
  \mathbf{1}_r & 0
 \end{pmatrix},\,\nu(g') \in {\mathbb G}_m
 \right. \right\}.
\]
Let $G_1' = {\rm O}_{r,r}$. We define a maximal compact subgroup ${\bf K}' = \operatorname{pr}od_v {\bf K}'_v$ of $G'({\mathbb A}A)$ by
\[
 {\bf K}'_v =
 \begin{cases}
  \begin{pmatrix} {\bf 1}_r & 0 \\ 0 & \varpi_v^{\frak{c}_v} {\bf 1}_r\end{pmatrix} G'(\frak{o}_v)\begin{pmatrix} {\bf 1}_r & 0 \\ 0 & \varpi_v^{-\frak{c}_v} {\bf 1}_r\end{pmatrix} & \mathbf{t}ext{if $v$ is finite,} \\
  G'(k_v) \frak{c}ap \operatorname{O}(2r) & \mathbf{t}ext{if $v$ is real.}
 \end{cases}
\]
Let $K_v' = {\bf K}_v'\frak{c}ap G_1'(k_v)$ for each place $v$ of $k$, and $K_v' = \operatorname{pr}od_vK_v'$. Let $r' \leq r$ be a non-negative integer. Let
\[
 P'_{r'} =
 \left\{ \left. 
 \begin{pmatrix}
  a & *  & * & * \\
  0 & a' & * & b' \\
  0 & 0  & \nu(g){}^t  a^{-1} & 0 \\
  0 & c' & * & d' 
 \end{pmatrix}
 \in G' \, \right| \,  
  a \in \frak{o}peratorname{GL}_{r-r'},\,
  g=\begin{pmatrix}
   a' & b' \\
   c' & d' 
  \end{pmatrix}
  \in {\rm GO}_{r',r'}
 \right\}
\]
be a maximal parabolic subgroup of $G'$. We denote by $M'_{r'}$ and $N'_{r'}$ the standard Levi subgroup and unipotent radical of $P'_{r'}$, respectively.  
Let $d g'$ be the Haar measure on $G'_1({\mathbb A}A)$ such that
$\operatorname{vol}(G'_1(k) \backslash G'_1({\mathbb A}A)) = 1$,
$dm'$ (resp.~$dn'$) the Tamagawa measure on
$M'_{r'}({\mathbb A})$ (resp.~$N'_{r'}({\mathbb A}A)$),
and $d k'$ the Haar measure on $K'$ such that $\operatorname{vol}(K') = 1$.
Define a constant $\kappa_{r,r'}$ by
\[
 \int_{G'_1({\mathbb A}A)} \phi(g') \, dg'
 = \kappa_{r,r'} \int_{M'_{r'}({\mathbb A}) \mathbf{t}imes N'_{r'}({\mathbb A}A) \mathbf{t}imes K'} 
 \phi \left( 
 m'
 n' k' \right) \, dm' \, dn' \, dk'
\]
for $\phi \in L^1(G'_1({\mathbb A}A))$.

Assume $n \geq r$. Let $\frak{o}mega = \frak{o}mega_{\psi, V_{r,r}, n}$ denote the Weil representation
of $\frak{o}peratorname{Sp}_{2n}({\mathbb A}A) \mathbf{t}imes G'_1({\mathbb A}A)$
on $\frak{c}alS(V_{r,r}^n({\mathbb A}A)) = \frak{c}alS({\rm M}_{2r , n}({\mathbb A}A))$
with respect to $\psi$. Let 
\[{\rm G}(\frak{o}peratorname{Sp}_{2n} \mathbf{t}imes G'_1) = \left\{ (g,g') \in \frak{o}peratorname{GSp}_{2n}\mathbf{t}imes G' \mbox{ }\vert\mbox{ }\nu(g)=\nu(g') \right\}.\]
We extend $\frak{o}mega$ to a representation of ${\rm G}(\frak{o}peratorname{Sp}_{2n} \mathbf{t}imes G'_1)({\mathbb A})$ as follows:
\begin{align}\label{Weil rep on R}
\frak{o}mega(g,g')\varphi = \frak{o}mega\left (g \begin{pmatrix} {\bf 1}_n & 0 \\ 0 & \nu(g')^{-1}{\bf 1}_n\end{pmatrix},1 \right )L(g')\varphi
\end{align}
for $(g,g') \in {\rm G}(\frak{o}peratorname{Sp}_{2n} \mathbf{t}imes G'_1)({\mathbb A})$ and $\varphi \in \mathcal{S}(V_{r,r}^n({\mathbb A}))$. Here
\[L(g')\varphi(x)=\vert \nu(g')  \vert_{\mathbb A}^{-nr/2}\varphi(g'^{-1}x).\]
Let $S(V_{r,r}^n({\mathbb A}A))$ be the subspace of $\frak{c}alS(V_{r,r}^n({\mathbb A}A))$
consisting of functions which correspond to polynomials in the Fock model
at the archimedean places.
For $(g,g') \in {\rm G}(\frak{o}peratorname{Sp}_{2n} \mathbf{t}imes G'_1)({\mathbb A})$ and $\varphi \in S(V_{r,r}^n({\mathbb A}A))$, let
\[
 \Theta(g, g'; \varphi) = \sum_{x \in V_{r,r}^n(k)} \frak{o}mega(g, g') \varphi(x).
\]
Fix a real place $v$ of $k$ and 
let $z = z_{r-1, n} \in \mathfrak{z}(\mathfrak{g}_v)$ be
the regularizing differential operator as in \frak{c}ite[Corollary 5.1.2]{KR1994}, where $\mathfrak{z}(\mathfrak{g}_v)$ is the center of the universal enveloping algebra of $\frak{g}_v$.
By  \frak{c}ite[Proposition 5.3.1]{KR1994},
the function $g' \mapsto \Theta(g, g'; z \frak{c}dot \varphi)$
on $G_1'(k) \backslash G_1'({\mathbb A}A)$ is rapidly decreasing.
Here $\mathfrak{z}(\mathfrak{g}_v)$ acts on $S(V_{r,r}^n({\mathbb A}A))$ via 
the differential of $\frak{o}mega$.

Put $s'_0 = ({r-1})/{2}$.
Let $F$ be the ${\bf K}'$-invariant holomorphic section of
$\mathrm{I}nd^{G'({\mathbb A}A)}_{P'_0({\mathbb A}A)}(\delta_{P_0'}^{s/(r-1)})$ such that $F(1,s) = 1$. Here $\delta_{P_0'}$ is the modulus character of $P_0'({\mathbb A})$.
Define an auxiliary Eisenstein series $E(s)$ by
\[
 E(g'; s) = \sum_{\gamma' \in P'_0(k) \backslash G'(k)} F(\gamma' g', s)
\]
for ${\mathbb R}e(s) \gg 0$,
and by the meromorphic continuation otherwise.
Note that $E(s)$ has a simple pole at $s = s'_0$ with constant residue $\kappa_{r,0}$.
Following \frak{c}ite[\S 5.5]{KR1994},
we consider the integral
\[
 I^{(n,r)}(g; s, \varphi) = \kappa_{r,0}^{-1}Q_{n,r}(s)^{-1} 
 \int_{G_1'(k) \backslash G_1'({\mathbb A}A)}
 \Theta(g, g'h; z \frak{c}dot \varphi) E(g'h; s) \, dg',
\]
where $\nu(h)=\nu(g)$ and
\[
 Q_{n,r}(s) = \operatorname{pr}od_{i=0}^{r-1} ( (s - s_0' + i)^2 - (n+1-r)^2 ).
\]
Let
\[
 I^{(n,r)}(s, \varphi) =
 \sum_{d \gg - \infty} (s - s'_0)^d I^{(n,r)}_d(\varphi)
\]
be the Laurent expansion of $I^{(n,r)}(s, \varphi)$ at $s = s'_0$.
Note that $I^{(n,r)}(s, \varphi)$ has at most a simple (resp.~double) pole
at $s = s'_0$ if $r \le ({n+1})/{2}$ (resp.~$({n+1})/{2} < r \le n$).

Let $\hat{\frak{o}mega}$ be the Weil representation of ${\rm G}(\frak{o}peratorname{Sp}_{2n} \mathbf{t}imes G_1')({\mathbb A})$
on $\frak{c}alS({\rm M}_{r , 2n}({\mathbb A}A))$ defined via the partial Fourier transform
\[
 \frak{c}alS({\rm M}_{2r , n}({\mathbb A}A))
  \longrightarrow \frak{c}alS({\rm M}_{r , 2n}({\mathbb A}A)), \quad
 \varphi \longmapsto \hat{\varphi},
\]
where
\[
 \hat{\varphi}(u, v) = \int_{{\rm M}_{r , n}({\mathbb A}A)} \varphi
 \begin{pmatrix}
  x \\
  u
 \end{pmatrix}
 \psi( \mathbf{t}r(v {}^t \! x)) \, dx
\]
for $u, v \in {\rm M}_{r , n}({\mathbb A}A)$. Here $dx$ is the Tamagawa measure on ${\rm M}_{r, n}({\mathbb A})$. 
For ${\mathbb R}e(s) > s_0'-n + r$,
define a $(\mathfrak{g}_{\infty}, K_{\infty}) \mathbf{t}imes \frak{o}peratorname{Sp}_{2n}({\mathbb A}A_f)$-intertwining map
\[
 \frak{c}alF: S(V_{r,r}^n({\mathbb A}A)) \longrightarrow I_{n,r}(s)
\]
by
\[
 \frak{c}alF(\varphi)(g, s) = \int_{\frak{o}peratorname{GL}_r({\mathbb A}A)} \hat{\frak{o}mega}(g, g')
 \hat{\varphi}_{K'} (0_{r \mathbf{t}imes n}, {}^t \! a, 0_{r \mathbf{t}imes (n-r)})
 |\det (a)|_{{\mathbb A}}^{s-s_0'+n} \, da,
\]
where $\nu(g')=\nu(g)$ and
\[
 \varphi_{K'}(x) = \int_{K'} \frak{o}mega(1, k') \varphi(x) \, dk'.
\]
Then, by \frak{c}ite[\S 5.5]{KR1994},
\[
 I^{(n,r)}(s, \varphi) = E^{(n,r)}(s,\frak{c}alF(\varphi)).
\]

 We define the spherical Schwartz function $\varphi^o=\bigotimes_v\varphi_v^{o} \in S(V_{r,r}^n({\mathbb A}A))$ as follows:
\begin{itemize}
\item If $v$ is finite, then 
\begin{align*}
\varphi_v^o\begin{pmatrix} x \\ y \end{pmatrix} = q_v^{-\frak{c}_vnr/2}\frak{c}dot \mathbb{I}_{{\rm M}_{r, n}(\varpi_v^{-\frak{c}_v}\frak{o}_v)}(x)\mathbb{I}_{{\rm M}_{r, n}(\frak{o}_v)}(y).
\end{align*}
\item If $v$ is real, then
\begin{align*}
\varphi_v^o(x) = e^{-\pi\, {\rm tr}(x{}^tx)}.
\end{align*}
\end{itemize}
Note that
\begin{align}\label{E:spherical property}
\frak{o}mega_v(k,k')\varphi_v^o = \varphi_v^o 
\end{align}
for $(k,k') \in ({\bf K}_v \mathbf{t}imes {\bf K}_v')\frak{c}ap {\rm G}(\frak{o}peratorname{Sp}_{2n}\mathbf{t}imes G_1')(k_v)$. 

For ${\mathbb R}e(s) > s_0'-n + r-1$,
define an intertwining map
\[
 \frak{c}alF_v: S(V_{r,r}^n(k_v)) \longrightarrow I_{n,r,v}(s)
\]
by
\[
 \frak{c}alF_v(\varphi)(g, s) = \int_{\frak{o}peratorname{GL}_r(k_v)} \hat{\frak{o}mega}_v(g, g')
 \hat{\varphi}_{K_v'} (0_{r \mathbf{t}imes n}, {}^t \! a_v, 0_{r \mathbf{t}imes (n-r)})
 |\det (a)|_{v}^{s-s_0'+n} \, da_v,
\]
where $\nu(g')=\nu(g)$ and 
\[
 \varphi_{K_v'}(x) = \int_{K_v'} \frak{o}mega(1, k') \varphi(x) \, dk'.
\]
The Haar measure $da_v$ on $\frak{o}peratorname{GL}_r(k_v)$ is normalized as in (\ref{E:standard measure on GL}). By a direct calculation, 
\begin{align}\label{E:spherical section}
\frak{c}alF_v(\varphi_v^o)(1,s) = \operatorname{pr}od_{j=0}^{r-1}\zeta_v(s-s_0'+n-j).
\end{align}
By (\ref{Tamagawa measure on GL}), for $\varphi = \bigotimes_v\varphi_v \in S(V_{r,r}^n({\mathbb A}A))$, we have
\begin{align}\label{E:local global ratio}
\frak{c}alF(\varphi) = \frak{D}^{-r^2/2}\rho^{-1}\operatorname{pr}od_{i=2}^r\zeta(i)^{-1} \frak{c}dot\bigotimes_v \frak{c}alF_v(\varphi_v).
\end{align}

\subsection{First and second term identities}\label{SS:First and second term identities}

In this section,
we recall certain identities relating the terms in the Laurent expansions
of regularized theta integrals to those of Siegel Eisenstein series,
which were proved by Gan, Qiu, and Takeda in \frak{c}ite{GQT2014}.

Let $n=4$.
Let $\frak{c}alR$ be the space of automorphic forms on $\frak{o}peratorname{GSp}_8({\mathbb A})$ spanned by residues
$E^{(4,4)}_{-1}({1}/{2}, F)$
for all holomorphic sections $F$ of $I_{4,4}(s)$.
Define a $(\mathfrak{g}_{\infty}, K_{\infty}) \mathbf{t}imes \frak{o}peratorname{Sp}_8({\mathbb A}A_f)$-intertwining map
\[
 S(V_{3,3}^4({\mathbb A}A))  \longrightarrow I_{4,4} \left(\frac{1}{2}\right), \quad
 \varphi  \longmapsto F(\varphi)
\]
by 
\[
 F({\varphi}) \left(g, \frac{1}{2}\right) = \frak{o}mega(g, g') \varphi(0),
\]
where $\nu(g')=\nu(g)$. We extend $F({\varphi})$ to the holomorphic section $F({\varphi})$ of $I_{4,4}(s)$
such that its restriction to ${\bf K}$ is independent of $s$.

As in \frak{c}ite[\S 5]{Ikeda1996},
define a $(\mathfrak{g}_{\infty}, K_{\infty}) \mathbf{t}imes \frak{o}peratorname{Sp}_8({\mathbb A}A_f)$-intertwining map
\[
 \operatorname{pr}: S(V_{3,3}^4({\mathbb A}A)) \longrightarrow S(V_{2,2}^4({\mathbb A}A))
\]
by
\[
 \operatorname{pr}(\varphi)
 \begin{pmatrix}
  x \\
  y
 \end{pmatrix}
 = \int_{{\mathbb A}A^4} \varphi_{K'}
 \begin{pmatrix}
  u \\
  x \\
  0 \\
  y
 \end{pmatrix}
 \, du
\]
for $x, y \in {\rm M}_{2 , 4}({\mathbb A}A)$, where $du$ is the Tamagawa measure on ${\mathbb A}^4$. Then, as a special case of the Siegel-Weil formula proved by Gan, Qiu, and Takeda [GQT14, Theorem 1.1], we have
\begin{align}
 &E^{(4,4)}_{-1} \left(\frac{1}{2}, F({\varphi})\right) = I^{(4,3)}_{-2}(\varphi), \label{E:1st identity}\\
 &E^{(4,4)}_0 \left(\frac{1}{2}, F({\varphi})\right) = I^{(4,3)}_{-1}(\varphi)
 - \kappa_{3,2} \frak{c}dot I^{(4,2)}_0(\operatorname{pr}(\varphi))
  \mbox{ \rm mod } \frak{c}alR \label{E:2nd identity}
\end{align}
for all $\varphi \in S(V_{3,3}^4({\mathbb A}A))$.

\section{Automorphic $L$-functions}
\label{s:autom}
In this section, we introduce integral representations of two automorphic $L$-functions, namely the standard $L$-function for $\frak{o}peratorname{GSp}_4$ and the Rankin-Selberg $L$-function for $\frak{o}peratorname{GSp}_4 \mathbf{t}imes \frak{o}peratorname{GSp}_4$. We keep the notation of \S\,\ref{s:sw} with $n=4$. 

\subsection{Preliminaries}  

Recall that $G=\frak{o}peratorname{GSp}_4$. Let $H = \frak{o}peratorname{GSp}_8$ and
\[
 {\bf G} = \{ (g_1, g_2) \in G \mathbf{t}imes G \, | \, \nu(g_1) = \nu(g_2) \}.
\]
Let $Z_{H}$ be the center of $H$.
We identify $\bf G$ with its image under the embedding
\[
 {\bf G}  \longrightarrow H, \quad
 \left(
 \begin{pmatrix}
  a_1 & b_1 \\
  c_1 & d_1
 \end{pmatrix},
 \begin{pmatrix}
  a_2 & b_2 \\
  c_2 & d_2
 \end{pmatrix}
 \right)  \longmapsto
 \begin{pmatrix}
  a_1 & 0    & b_1 & 0 \\
  0   & a_2  & 0   & -b_2 \\
  c_1 & 0    & d_1 & 0 \\
  0   & -c_2 & 0   & d_2 
 \end{pmatrix}.
\]

Let $\pi$ be an irreducible globally generic cuspidal automorphic representation of $G({\mathbb A})$ with trivial central character and paramodular conductor $\frak{n}$ satisfying the conditions in \S\,\ref{SS:main thm}. By \frak{c}ite{CKPS2004} and \frak{c}ite{AH2006},
$\pi$ has a functorial lift ${\bf P}i$ to $\frak{o}peratorname{GL}_4({\mathbb A})$.
By \frak{c}ite{GRS2001},
either ${\bf P}i$ is cuspidal or ${\bf P}i = \sigma_1 \boxplus \sigma_2$ for some irreducible cuspidal automorphic representations $\sigma_1$ and $\sigma_2$
of $\frak{o}peratorname{GL}_2({\mathbb A}A)$ with trivial central character such that $\sigma_1 \neq \sigma_2$.
We say that $\pi$ is stable (resp.~endoscopic)
if ${\bf P}i$ is cuspidal (resp.~non-cuspidal).
Let $S$ be a finite set of places of $k$
including the archimedean places such that,
for $v \notin S$, $\pi_v$ is unramified.
Let $\rm std$ denote the composition of the projection $\frak{o}peratorname{GSp}_4({\mathbb C}) \rightarrow {\rm PGSp}_4({\mathbb C})$ with the standard
representation of ${\rm PGSp}_4({\mathbb C}) \simeq {\rm SO}_5({\mathbb C})$ on ${\mathbb C}^5$, and ${\rm Ad}$ the adjoint representation of $\frak{o}peratorname{GSp}_4({\mathbb C})$ on $\frak{pgsp}_4({\mathbb C})$.
Then
\begin{align*}
 L^S(s, {\bf P}i, \wedge^2) & = \zeta^S(s) L^S(s, \pi, {\rm std}), \\
 L^S(s, {\bf P}i, \operatorname{Sym}^2) & = L^S(s, \pi, {\mathbb A}d). 
\end{align*}
By \frak{c}ite{GRS2001},
$L^S(s, {\bf P}i, \wedge^2)$ has a simple (resp.~double) pole at $s=1$
if $\pi$ is stable (resp.~endoscopic).
Hence $L^S(s, \pi, {\rm std})$ is holomorphic and non-zero
(resp.~has a simple pole) at $s=1$ if $\pi$ is stable (resp.~endoscopic).
Moreover, $L^S(s, \pi, {\mathbb A}d)$ is holomorphic and non-zero at $s=1$.

When $v \nmid \infty\frak{n}$ or $v\in S({\rm PS})$, there exist $\lambda_{1,v},\lambda_{2,v} \in {\mathbb C}$ 
such that
\begin{align}\label{E:unram. para.}
\pi_v \vert_{\frak{o}peratorname{Sp}_4(k_v)} = {\rm Ind}_{\frak{o}peratorname{Sp}_4(k_v)\frak{c}ap {\bf B}(k_v)}^{\frak{o}peratorname{Sp}_4(k_v)}(|\mbox{ }|_v^{\lambda_{1,v}}\boxtimes|\mbox{ }|_v^{\lambda_{2,v}}).
\end{align}

When $v \mid \frak{n}$, there exist $\varepsilon_v \in \{0,1\}$ and $\lambda_v \in {\mathbb C}$ such that
\begin{align}\label{E:IIa para.}
\pi_v = {\rm Ind}_{P_{2,2}(k_v)}^{G(k_v)}\left(({\rm St}_v\frak{o}times |\mbox{ }|_v^{\lambda_v})\boxtimes \mathbf{t}imesi_v^{\varepsilon_v} |\mbox{ }|_v^{-\lambda_v}\right),
\end{align}
where ${\rm St}_v$ is the Steinberg representation of $\frak{o}peratorname{GL}_2(k_v)$ and $\mathbf{t}imesi_v$ is the non-trivial unramified quadratic character of $k_v^\mathbf{t}imes$. Indeed, by the results in \frak{c}ite{RS2007}, any irreducible generic admissible representation of $G(k_v)$ with trivial central character and paramodular conductor $\varpi_v\frak{o}_v$ is of this form.

Since $\pi_v$ is unitary and generic, by the unitarizability criterion in \frak{c}ite[Theorem 1.1]{LMT2004}, we have
\begin{align}\label{eq:satake}
\begin{cases}
|{\rm Re}(\lambda_{1,v})|+|{\rm Re}(\lambda_{2,v})|<1 & \mbox{ if $v \nmid \infty\frak{n}$},\\
|{\rm Re}(\lambda_{v})|<1/2 & \mbox{ if $v \mid \frak{n}$},\\
|{\rm Re}(\lambda_{1,v})|+|{\rm Re}(\lambda_{2,v})|<1 & \mbox{ if $v \in S({\rm PS})$}.
\end{cases}
\end{align}

\subsection{Standard $L$-functions}

In this section,
we review the doubling method of Piatetski-Shapiro and Rallis
\frak{c}ite{LNM1254}, \frak{c}ite[\S 6.2]{Harris1993}.

Let $P=P_{4,4}$
be the standard Siegel parabolic subgroup of $H$, and put \[d_P(s) = \zeta\left(s + \frac{5}{2}\right) \zeta(2s+1) \zeta(2s+3).\] Let $I(s) = I_{4,4}(s)$
denote a degenerate principal series representation of $H({\mathbb A}A)$.
For a holomorphic section $F$ of $I(s)$,
we write $E(s, F)=E^{(4,4)}(s,F).$ 
By \frak{c}ite[Theorem 1.1]{KR1994},
the Eisenstein series $E(s,F)$ has at most a simple pole at $s = {1}/{2}$.

For $f \in \pi$,
let
\[
 Z(s, f, F) = 
 \int_{Z_H({\mathbb A}A) {\bf G}(k) \backslash {\bf G}({\mathbb A}A)}
 E( g; s, F) (f\frak{o}times\bar{f})(g) \, dg.
\]
We assume that $f = \bigotimes_v f_v$ and $F = \bigotimes_v F_v$.
Choose local Hermitian pairings $\langle \ , \ \rangle_v$ on $\pi_v \mathbf{t}imes \pi_v$ such that
$\langle f, f \rangle = \operatorname{pr}od_v \langle f_v, f_v \rangle_v$,
and define a matrix coefficient $\phi_v$ of $\pi_v$ by
\[
 \phi_v(g) = \frac{\langle \pi_v (g) f_v, f_v \rangle_v}{\langle f_v, f_v \rangle_v}.
\]
Note that $\phi_v$ does not depend on the choice of 
$\langle \ , \ \rangle_v$.
Define a local zeta integral $Z_v(s, \phi_v, F_v)$ by
\begin{align}\label{E:local zeta1}
 Z_v(s, \phi_v, F_v)
 = \int_{\frak{o}peratorname{Sp}_4(k_v)} F_v(\delta (g_v,1), s) \phi_v(g_v) \, dg_v^{\rm Tam},
\end{align}
where
\[
 \delta =
 \begin{pmatrix}
  0 & 0 & -\frac{1}{2} \mathbf{1}_2 & \frac{1}{2} \mathbf{1}_2 \\
  \frac{1}{2} \mathbf{1}_2 & \frac{1}{2} \mathbf{1}_2 & 0 & 0 \\
  \mathbf{1}_2 & - \mathbf{1}_2 & 0 & 0 \\
  0 & 0 & \mathbf{1}_2 & \mathbf{1}_2
 \end{pmatrix}.
\]
Here $dg_v^{\rm Tam}$ is the local Tamagawa measure on $\frak{o}peratorname{Sp}_4(k_v)$. Then, by \frak{c}ite{LNM1254}, \frak{c}ite[\S 6.2]{Harris1993},
\[
 Z(s,f, F) = \langle f, f \rangle \operatorname{pr}od_{v} Z_v(s, \phi_v, F_v)
\]
for ${\mathbb R}e(s) \gg 0$.

\begin{lemma}\label{L:unram PSR} 
Let $v$ be a finite place of $k$ satisfying the following conditions: 
\begin{itemize}
\item $\pi_v$ is unramified.
\item $f_v$ is $G(\frak{o}_v)$-invariant.
\item $F_v$ is $H(\frak{o}_v)$-invariant.
\end{itemize}
We have
\[Z_v(s,\phi_v,F_v) = F_v(1,s)q_v^{-5\frak{c}_v}\zeta_v(2)^{-1}\zeta_v(4)^{-1}d_{P,v}(s)^{-1}L\left(s+\frac{1}{2},\pi_v,{\rm std}\right).\]
\end{lemma}

\begin{proof}
Let $dg_v^{\rm std}$ be the Haar measure on $\frak{o}peratorname{Sp}_4(k_v)$ normalized so that
\[{\rm vol}(\frak{o}peratorname{Sp}_4(\frak{o}_v),dg_v^{\rm std}) = 1. \]
By \frak{c}ite[Proposition 6.2]{LNM1254}, 
\[
 \int_{\frak{o}peratorname{Sp}_4(k_v)} F_v(\delta (g_v,1), s) \phi_v(g_v) \, dg_v^{\rm std} = F_v(1,s)d_{P,v}(s)^{-1}L\left(s+\frac{1}{2},\pi_v,{\rm std}\right).
\]
Since
\[
{\rm vol}(\frak{o}peratorname{Sp}_4(\frak{o}_v),dg_v^{\rm Tam}) = q_v^{-5\frak{c}_v}\frak{c}dot q_v^{-10}\frak{c}dot \left| \frak{o}peratorname{Sp}_4(\mathbb{F}_{q_v})\right| = q_v^{-5\frak{c}_v}\zeta_v(2)^{-1}\zeta_v(4)^{-1},
\]
it follows that
\[dg_v^{\rm Tam} = q_v^{-5\frak{c}_v}\zeta_v(2)^{-1}\zeta_v(4)^{-1}\frak{c}dot dg_v^{\rm std}.\]
This completes the proof.
\end{proof}

\begin{lemma}\label{L:ab doubling}
Let $v$ be a place of $k$. 
The integral $Z_v(s, \phi_v, F_v)$ is absolutely convergent for 
\begin{align*}
\begin{cases}
{\mathbb R}e(s)> -1/2 + \max\{|{\rm Re}(\lambda_{1,v})|, |{\rm Re}(\lambda_{2,v})|\} & \mbox{ if $v \nmid \infty\frak{n}$},\\
{\mathbb R}e(s)> -1/2+\max\{0,|{\rm Re}(\lambda_v)|-1/2\} & \mbox{ if $v \in S(\frak{n})$},\\
{\mathbb R}e(s) > -1/2 & \mbox{ if $v \in S({\rm DS})$},\\ 
{\mathbb R}e(s)> -1/2 + \max\{|{\rm Re}(\lambda_{1,v})|, |{\rm Re}(\lambda_{2,v})|\} & \mbox{ if $v \in S({\rm PS})$}.
\end{cases} 
\end{align*}
In particular, the integral is absolutely convergent for ${\rm Re}(s) \geq 1/2$.
\end{lemma}

\begin{proof}
The assertions will be proved in Lemmas \ref{L:local zeta Ur}-\ref{L:ab1} below. 
\end{proof}

\subsection{$L$-functions for $\frak{o}peratorname{GSp}_4 \mathbf{t}imes \frak{o}peratorname{GSp}_4$}

In this section,
we review Jiang's integral representation
of the $L$-function for $G \mathbf{t}imes G$ \frak{c}ite{Jiang1996}.

Let $\mathcal{P}=P_{4,3}$ be a maximal parabolic subgroup of $H$, and put \[d_{\mathcal{P}}(s) = \zeta(s+1) \zeta(s+2) \zeta(s+3) \zeta(2s+2).\] Let $\frak{c}alI(s)=I_{4,3}(s)$
denote a degenerate principal series representation of $H({\mathbb A}A)$.
For a holomorphic section $\frak{c}alF$ of $\frak{c}alI(s)$,
we write $\frak{c}alE(s, \frak{c}alF) = E^{(4,3)}(s,\frak{c}alF)$. 
By \frak{c}ite[Chapter 3, Theorem 4.0.1]{Jiang1996},
the Eisenstein series $\frak{c}alE(s, \frak{c}alF)$ has at most a double pole at $s = 1$.

For $f \in \pi$,
let
\[
 \frak{c}alZ(s, f, \frak{c}alF) = \int_{Z_H({\mathbb A}A) {\bf G}(k) \backslash {\bf G}({\mathbb A}A)}
 \frak{c}alE( g; s, \frak{c}alF) (f\frak{o}times \bar{f})(g) \, dg .
\]
We assume that $f = \bigotimes_v f_v$ and $\frak{c}alF = \bigotimes_v \frak{c}alF_v$.
Let $W = \bigotimes_v W_v$ be the Whittaker function of $f$.
Define a local zeta integral $\frak{c}alZ_v(s, W_v, \frak{c}alF_v)$ by
\begin{align}\label{E:local zeta2}
 \frak{c}alZ_v(s, W_v, \frak{c}alF_v) = 
 \int_{Z_H(k_v) \mathbf{t}ilde{U}(k_v) \backslash {\bf G}(k_v)}
 \frak{c}alF_v(\eta g_v, s) (W_v\frak{o}times \frak{o}verline{W_v})(g_v) \, d\bar{g}_v^{\rm Tam},
\end{align}
where
\[
 \mathbf{t}ilde{U} = \left\{ \left. \left( u
  \begin{pmatrix}
   1 & 0 & x & 0 \\
   0 & 1 & 0 & 0 \\
   0 & 0 & 1 & 0 \\
   0 & 0 & 0 & 1
 \end{pmatrix},
 u \right) \, \right| \, u \in U, \, x \in {G}G_a \right\}
\]
and 
\[
 \eta =
 \begin{pmatrix}
   1 & 0 & 0  & 0  & 0 & 0 & 0 & 0 \\
   0 & 1 & 0  & 0  & 0 & 0 & 0 & 0 \\
   0 & 0 & 0  & 0  & 0 & 0 & 0 & 1 \\
   0 & 0 & 0  & 0  & 0 & 0 & 1 & 0 \\
   0 & 0 & 0  & 0  & 1 & 0 & 1 & 0 \\
   0 & 0 & 0  & 0  & 0 & 1 & 0 & 1 \\
   0 & 1 & 0  & -1 & 0 & 0 & 0 & 0 \\
   1 & 0 & -1 & 0  & 0 & 0 & 0 & 0
 \end{pmatrix}.
\]
Here $d\bar{g}_v^{\rm Tam}$ is the quotient measure defined by the local Tamagawa measures on $Z_H(k_v)\backslash {\bf G}(k_v)$ and $\mathbf{t}ilde{U}(k_v)$. Then, by \frak{c}ite{Jiang1996},
\[
 \frak{c}alZ(s, f, \frak{c}alF)
 = 
 \operatorname{pr}od_{v} \frak{c}alZ_v(s, W_v, \frak{c}alF_v)
\]
for ${\mathbb R}e(s) \gg 0$.

\begin{lemma}\label{L:unram Jiang}
Let $v$ be a finite place of $k$ satisfying the following conditions:
\begin{itemize}
 \item $\pi_v$ is unramified.
 \item $W_v$ is $G(\frak{o}_v)$-invariant.
 \item $\frak{c}alF_v$ is $H(\frak{o}_v)$-invariant.
\end{itemize}
We have
\begin{align*}
\frak{c}alZ_v(s, W_v,\frak{c}alF_v) &= \frak{c}alF_v(1,s)\vert W_v(\operatorname{diag}( \varpi_v^{-\frak{c}_v}, 1, \varpi_v^{2\frak{c}_v}, \varpi_v^{\frak{c}_v} ))\vert^2\\
&\mathbf{t}imes q_v^{(3s/2-13)\frak{c}_v}\zeta_v(2)^{-2}\zeta_v(4)^{-2} d_{{\mathcal P},v}(s)^{-1}L\left(\frac{s+1}{2},\pi_v\mathbf{t}imes\pi_v^\vee\right).
\end{align*}
\end{lemma}

\begin{proof}
Let 
\[g_0 = \operatorname{diag}( \varpi_v^{\frak{c}_v}, 1, \varpi_v^{-2\frak{c}_v}, \varpi_v^{-\frak{c}_v} ).\]
Let $\psi_v'(x) = \psi_v(\varpi_v^{-\frak{c}_v}x)$ be an additive character of $k_v$ of conductor $\frak{o}_v$. Let $W_v'$ be the $G(\frak{o}_v)$-invariant Whittaker function of $\pi_v$ with respect to $\psi_v'$ such that $W_v'(1)=1$. Then
\[W_v(g) = W_v(g_0^{-1})W_v'(g_0g)\]
for $g \in G(k_v)$. Let $dg_v^{\rm std}$ and $du_v^{\rm std}$ be the Haar measures on $Z_H(k_v)\backslash {\bf G}(k_v)$ and $\mathbf{t}ilde{U}(k_v)$ normalized so that
\[{\rm vol}(Z_H(\frak{o}_v)\backslash G(\frak{o}_v),dg_v^{\rm std})={\rm vol}(\mathbf{t}ilde{U}(\frak{o}_v),du_v^{\rm std})=1.\]
Let $d\bar{g}_v^{\rm std}$ be the corresponding quotient measure on $Z_H(k_v) \mathbf{t}ilde{U}(k_v) \backslash {\bf G}(k_v)$. By \frak{c}ite[Theorem 3.3.3]{Jiang1996}, 
\[\int_{Z_H(k_v) \mathbf{t}ilde{U}(k_v) \backslash {\bf G}(k_v)}
 \frak{c}alF_v(\eta g_v, s) (W_v'\frak{o}times \frak{o}verline{W_v'})(g_v) \, d\bar{g}_v^{\rm std} = \frak{c}alF_v(1,s)d_{\mathcal{P},v}(s)^{-1}L\left(\frac{s+1}{2},\pi_v\mathbf{t}imes\pi_v^\vee\right).\]
 On the other hand, 
\[\frak{c}alF_v(\eta(g_0^{-1},g_0^{-1})g,s) = q_v^{(3s/2+9/2)\frak{c}_v}\frak{c}alF_v(\eta g,s)\]
 for $g \in {\bf G}(k_v).$ Therefore, 
 \begin{align*}
 &\int_{Z_H(k_v) \mathbf{t}ilde{U}(k_v) \backslash {\bf G}(k_v)}
 \frak{c}alF_v(\eta g_v, s) (W_v\frak{o}times \frak{o}verline{W_v})(g_v) \, d\bar{g}_v^{\rm std}\\
 &=q_v^{-10\frak{c}_v}|W_v(g_0^{-1})|^2\int_{Z_H(k_v) \mathbf{t}ilde{U}(k_v) \backslash {\bf G}(k_v)}
 \frak{c}alF_v(\eta (g_0^{-1},g_0^{-1})g_v, s) (W_v'\frak{o}times \frak{o}verline{W_v'})(g_v) \, d\bar{g}_v^{\rm std}\\
 &=q_v^{(3s/2-11/2)\frak{c}_v}|W_v(g_0^{-1})|^2\frak{c}alF_v(1,s)d_{\mathcal{P},v}(s)^{-1}L\left(\frac{s+1}{2},\pi_v\mathbf{t}imes\pi_v^\vee\right).
 \end{align*}
 It suffices to show that
 \[d\bar{g}_v^{\rm Tam} = q_v^{-15\frak{c}_v/2}\zeta_v(2)^{-2}\zeta_v(4)^{-2}\frak{c}dot d\bar{g}_v^{\rm std}.\]
 Let $dg_{v}^{\rm Tam}$, $dg_{1,v}^{\rm Tam}$, and $dg_{2,v}^{\rm Tam}$ be the local Tamagawa measures on $Z_H(k_v)\backslash{\bf G}(k_v)$, ${\rm PGSp}_4(k_v)$, and $\frak{o}peratorname{Sp}_4(k_v)$, respectively. Under the isomorphism
 \begin{align*}
 {\rm PGSp}_4(k_v) \ltimes \frak{o}peratorname{Sp}_4(k_v)  &\longrightarrow Z_H(k_v)\backslash {\bf G}(k_v),\\ (g_1,g_2) &\longmapsto (g_1g_2,g_1),
 \end{align*}
 we have
 \[dg_{1,v}^{\rm Tam} \mathbf{t}imes dg_{2,v}^{\rm Tam} = dg_{v}^{\rm Tam}.\]
 Let \[U' = \left\{ \left.\begin{pmatrix}
   1 & 0 & x & 0 \\
   0 & 1 & 0 & 0 \\
   0 & 0 & 1 & 0 \\
   0 & 0 & 0 & 1
 \end{pmatrix}\mbox{ } \right\vert\mbox{ }x \in {\mathbb G}_a\right\}\]
 be a unipotent subgroup of $\frak{o}peratorname{Sp}_4$. Let $du_{v}^{\rm Tam}$, $du_{1,v}^{\rm Tam}$, and $du_{2,v}^{\rm Tam}$ be the local Tamagawa measures on $\mathbf{t}ilde{U}(k_v)$, $U(k_v)$, and $U'(k_v)$, respectively. Then
 \[U(k_v)\ltimes U'(k_v) \simeq \mathbf{t}ilde{U}(k_v)\]
 under the above isomorphism and
 \[du_{1,v}^{\rm Tam} \mathbf{t}imes du_{2,v}^{\rm Tam} = du_{v}^{\rm Tam}.\]
 Note that
 \begin{align*}
 {\rm vol}(Z_H(\frak{o}_v)\mathbf{t}ilde{U}(\frak{o}_v)\backslash {\bf G}(\frak{o}_v),d\bar{g}_v^{\rm Tam}) &= \frac{{\rm vol}({\rm PGSp}_4(\frak{o}_v),dg_{1,v}^{\rm Tam})}{{\rm vol}(U(\frak{o}_v),du_{1,v}^{\rm Tam})} \frak{c}dot \frac{{\rm vol}(\frak{o}peratorname{Sp}_4(\frak{o}_v),dg_{2,v}^{\rm Tam})}{{\rm vol}(U'(\frak{o}_v),du_{2,v}^{\rm Tam})}\\
 &= \frac{q_v^{-5\frak{c}_v}\frak{c}dot q_v^{-10}\frak{c}dot \left| {\rm PGSp}_4(\mathbb{F}_{q_v})\right|}{q_v^{-2\frak{c}_v}}\frak{c}dot \frac{q_v^{-5\frak{c}_v}\frak{c}dot q_v^{-10}\frak{c}dot \left| \frak{o}peratorname{Sp}_4(\mathbb{F}_{q_v})\right|}{q_v^{-\frak{c}_v/2}}\\
 &=q_v^{-15\frak{c}_v/2}\zeta_v(2)^{-2}\zeta_v(4)^{-2}.
 \end{align*}
 This completes the proof.
\end{proof}

\begin{lemma}\label{L:ab2}
Let $v$ be a place of k such that $v \mid \infty\frak{n}$. The integral
$\frak{c}alZ_{v}(s, W_{v}, \frak{c}alF_v)$
is absolutely convergent for 
\begin{align*}
\begin{cases}
{\rm Re}(s) > -1 + 4|{\rm Re}(\lambda_v)|  & \mbox{ if $v \in S(\frak{n})$},\\ 
{\rm Re}(s) > -1 & \mbox{ if $v \in S({\rm DS})$},\\
{\rm Re}(s) > -1+ 2(|{\rm Re}(\lambda_{1,v})|+|{\rm Re}(\lambda_{2,v})|)  & \mbox{ if $v \in S({\rm PS})$},
\end{cases}
\end{align*}
In particular, the integral is absolutely convergent for ${\rm Re}(s) \geq 1$.
\end{lemma}

\begin{proof}
The assertion will be proved in Lemma \ref{L:uniform2} below.
\end{proof}

\section{Proof of Main Theorem}
\label{s:proof}

\subsection{Crude form of the formula for Petersson norms}
In this section, we keep the notation of \S\,\ref{s:sw} and \S\,\ref{s:autom}. Let $\pi$ be an irreducible globally generic cuspidal automorphic representation of $G({\mathbb A})$ with trivial central character and paramodular conductor $\frak{n}$ satisfying the conditions in \S\,\ref{SS:main thm}.
Let $f \in \pi$ be the cusp form satisfying the conditions (\ref{E:K-type2}) and (\ref{E:normalization}). Let $S$ be the set of places of $k$ defined by
\[S= \{v \mid \infty \frak{n}\}.\]
For an automorphic form $\phi$ on $H({\mathbb A})=\frak{o}peratorname{GSp}_8({\mathbb A}A)$, let
\[
 \langle \phi, \bar{f} \frak{o}times f \rangle 
 = \int_{Z_H({\mathbb A}){\bf G}(k) \backslash {\bf G}({\mathbb A}A)}
 \phi( g) (f \frak{o}times\bar{f})(g) \, dg.
\]

\begin{lemma} \label{lem:vanish_res}
Assume that $\pi$ is stable.
For all $\phi \in \frak{c}alR$,
\[
 \langle \phi, \bar{f} \frak{o}times f \rangle = 0.
\]
\end{lemma}

\begin{proof}
By Lemma \ref{L:unram PSR}, we have
\[
 \langle E(s, F), \bar{f} \frak{o}times f \rangle = \langle f, f \rangle \frak{c}dot
 \zeta^T(2)^{-1} \zeta^T(4)^{-1} \frak{c}dot d_P^T(s)^{-1} \frak{c}dot 
 L^T \left( s + \frac{1}{2}, \pi, {\rm std} \right)
 \operatorname{pr}od_{v \in T} Z_v(s, \phi_v, F_v)
\]
for any holomorphic section $F = \bigotimes_v F_v$ such that $F_v(1,s) = 1$ for all $v \notin T$, where $T$ is a sufficiently large finite set of places of $k$ depending on $F$.
Since $\pi$ is stable and hence $L^T(s, \pi, {\rm std})$ is holomorphic at $s = 1$, this together with Lemma \ref{L:ab doubling} implies that $\langle E(s, F), \bar{f} \frak{o}times f \rangle$ is holomorphic at $s = 1$.
This completes the proof.
\end{proof}

\begin{lemma} \label{lem:vanish_theta}
Assume that $\pi$ is stable.
For all $d \in {\mathbb Z}Z$ and all $\varphi \in S(V_{2,2}^4({\mathbb A}A))$,
\[
 \langle I^{(4,2)}_d(\varphi), \bar{f} \frak{o}times f \rangle = 0.
\]
\end{lemma}

\begin{proof}
Let $\mathbf{t}heta_{r,r}(\pi)$ be the global theta lift of $\pi$ to ${\rm GO}_{r,r}({\mathbb A}A)$.
By (\ref{E:unram. para.}), \eqref{eq:satake}, and the local theta corre- spondence for unramified representations, we have
$\mathbf{t}heta_{1,1}(\pi) = 0$.
If $\mathbf{t}heta_{2,2}(\pi) \ne 0$,
then there exist irreducible cuspidal automorphic representations $\sigma_1$ and $\sigma_2$
of $\frak{o}peratorname{GL}_2({\mathbb A}A)$ such that
\[
 L^T(s, \pi, {\rm std}) = \zeta^T(s) L^T(s, \sigma_1 \mathbf{t}imes \sigma_2),
\]
where $T$ is a sufficiently large finite set of places of $k$.
This contradicts the holomorphy of $L^T(s, \pi, {\rm std})$ at $s=1$.
Hence 
\begin{equation} \label{eq:vanish_theta}
 \mathbf{t}heta_{2,2}(\pi) = 0. 
\end{equation}

Write $G' = {\rm GO}_{2,2}$ and $G'_1 = {\rm O}_{2,2}$. Let $\mathcal{C} = {\mathbb A}^{\mathbf{t}imes, 2}k^{\mathbf{t}imes}\backslash {\mathbb A}^{\mathbf{t}imes}$. The similitude characters induce isomorphisms
$$Z_G({\mathbb A})G(k)\backslash G({\mathbb A}) \simeq \mathcal{C},\quad Z_{G'}({\mathbb A})G'(k)\backslash G'({\mathbb A}) \simeq \mathcal{C}.$$
Fix cross-sections $c \mapsto g_c$ and $c \mapsto g_c'$ of $G({\mathbb A}) \rightarrow \mathcal{C}$ and $G'({\mathbb A}) \rightarrow \mathcal{C}$, respectively.
For $\varphi \in S(V_{2,2}^4({\mathbb A}A))$, write $z \frak{c}dot \varphi = \sum_j \varphi_{1j} \frak{o}times \frak{o}verline{\varphi_{2j}} \in S(V_{2,2}^4({\mathbb A}A))$
with $\varphi_{ij} \in S(V_{2,2}^2({\mathbb A}A))$, where $z$ is the regularizing differential operator as in \S\,\ref{SS:Theta integrals}.
Then
\[
 \Theta( (g_1g_c, g_2g_c), g'g_c'; z \frak{c}dot \varphi)
 = \sum_j \Theta(g_1g_c, g'g_c'; \varphi_{1j}) \frak{o}verline{\Theta(g_2g_c, g'g_c'; \varphi_{2j})}
\]
for $c \in \mathcal{C}$, $(g_1,g_2) \in \frak{o}peratorname{Sp}_4({\mathbb A})\mathbf{t}imes \frak{o}peratorname{Sp}_4({\mathbb A})$, and $g' \in G_1'({\mathbb A})$. By \eqref{eq:vanish_theta},
the theta lift $\mathbf{t}heta(f, \varphi_{ij})$ is identically zero, where
\[
 \mathbf{t}heta(g'g_c'; f, \varphi_{ij})
 = \int_{\frak{o}peratorname{Sp}_4(k) \backslash \frak{o}peratorname{Sp}_4({\mathbb A}A)} \Theta(gg_c, g'g_c'; \varphi_{ij}) f(g) \, dg
\]
for $c \in \mathcal{C}$ and $g' \in G_1'({\mathbb A}A)$.
Hence $\langle I^{(4,2)}(s, \varphi), \bar{f} \frak{o}times f \rangle$ is equal to
\begin{align*}
& \int_{Z_H({\mathbb A}){\bf G}(k)\backslash {\bf G}({\mathbb A})}
 I^{(4,2)}(g;s,\varphi)(f\frak{o}times \bar{f})(g)\,
 dg\\
 &=  \kappa_{2,0}^{-1}Q_{4,2}(s)^{-1} \int_{\mathcal{C}}\int_{(\frak{o}peratorname{Sp}_4(k) \backslash \frak{o}peratorname{Sp}_4({\mathbb A}A))^2}
 \int_{G_1'(k) \backslash G_1'({\mathbb A}A)}\Theta( (g_1g_c, g_2g_c), g'g_c'; z \frak{c}dot \varphi) E(g'; s)
 f(g_1g_c) \frak{o}verline{f(g_2g_c)} \, dg' \, dg_1 \, dg_2\, dc \\
 & = \kappa_{2,0}^{-1}Q_{4,2}(s)^{-1} \int_{Z_{G'}({\mathbb A})G'(k) \backslash G'({\mathbb A}A)} \sum_j
 \mathbf{t}heta(g'; f, \varphi_{1j}) \frak{o}verline{\mathbf{t}heta(g'; f, \varphi_{2j})} E(g'; s)
 \, dg' \\
 & = 0.
\end{align*}
This completes the proof.
\end{proof}

\begin{lemma} \label{lem:nonvanish}
Let $v \in S$. There exists $\varphi_v \in S(V_{3,3}^4(k_v))$ such that 
\[
 Z_{v} \left(\frac{1}{2}, \phi_{v}, F({\varphi_v})\right) \ne 0.
\]
Moreover, if $v \mid \frak{n}$ or $v \in S({\rm PS})$, then we can find such $\varphi_v$ which does not depend on $\pi_v$.
\end{lemma}

\begin{proof}
For convenience,
we suppress the subscript $v$ from the notation and identify $k_v={\mathbb R}$ if $v$ is a real place. Let $\pi_0$ be an irreducible component of $\pi\vert_{\frak{o}peratorname{Sp}_4(k_v)}$.
Fix a pairing $\langle \ , \ \rangle$ on $\pi_0$.
For $f_1, f_2 \in \pi_0$,
define a matrix coefficient $\phi_{f_1 \frak{o}times f_2}$ of $\pi_0$ by
\[
 \phi_{f_1 \frak{o}times f_2}(g) = \langle \pi_0 (g) f_1, f_2 \rangle.
\]
Then the local zeta integral $Z({1}/{2}, \phi_{f_1 \frak{o}times f_2}, F)$
is absolutely convergent by Lemma \ref{L:ab doubling}, and defines
an $\frak{o}peratorname{Sp}_4(k_v) \mathbf{t}imes \frak{o}peratorname{Sp}_4(k_v)$-intertwining map (resp.~$(\mathfrak{sp}_4({\mathbb R}R), \operatorname{U}(2)) \mathbf{t}imes (\mathfrak{sp}_4({\mathbb R}R), \operatorname{U}(2))$-intertwining map)
\[
 I_{4,4} \left(\frac{1}{2}\right)
  \longrightarrow \pi_0^{\vee} \frak{o}times \pi_0, \quad
 F  \longmapsto \left[ f_1 \frak{o}times f_2 \mapsto
 Z \left(\frac{1}{2}, \phi_{f_1 \frak{o}times f_2}, F\right) \right]
\]
if $v$ is finite (resp.~$v$ is real).
By \frak{c}ite[Corollary 3.2.3]{KRbook} and \frak{c}ite[Proposition 7.2.1]{KR1994},
for fixed non-zero elements $f_1, f_2 \in \pi_0$,
there exists $F \in I_{4,4}(1/2)$ such that 
\begin{align}\label{E:non-vanishing}
Z\left(\frac{1}{2}, \phi_{f_1 \frak{o}times f_2}, F\right) \ne 0.
\end{align}
Moreover, if $v \mid \frak{n}$, then by the proof of \frak{c}ite[Proposition 7.2.1]{KR1994}, we can find such $F$ which depends only on the stabilizers of $f_1$ and $f_2$ in $\frak{o}peratorname{Sp}_4(k_v)$.

Assume $v \mid \frak{n}$. Let $V_0$ be the split quadratic space of dimension $4$ over $k_v$. Let $V_1$ (resp.~$V_2$) be the split quadratic space (resp.~quaternionic quadratic space) of dimension $6$ over $k_v$ and $\frak{o}mega_{\psi,V_i,4}$ the Weil representation of $\frak{o}peratorname{Sp}_8(k_v)\mathbf{t}imes {\rm O}(V_i)(k_v)$ on $S(V_i^4(k_v))$ with respect to $\psi$. For $i=1,2$, let $R(V_i)$ be the image of the $\frak{o}peratorname{Sp}_8(k_v)$-intertwining map
\[
 S(V_i^4(k_v))  \longrightarrow I_{4,4} \left(\frac{1}{2}\right), \quad \varphi  \longmapsto F({\varphi}),
\]
where $F({\varphi})(g, \frac{1}{2}) = \frak{o}mega_{\psi, V_i, 4}(g, 1) \varphi(0)$. By \frak{c}ite{KR1992}, 
\begin{align}\label{E:deg. prin. finite}
I_{4,4}\left(\frac{1}{2}\right) = R(V_1)+R(V_2).
\end{align}

For $i=0,1,2$, let $\mathbf{t}heta_i(\pi_0^\vee)$ be the theta lift of $\pi_0^\vee$ to ${\rm O}(V_i)(k_v)$. By our assumption on $\pi_0$  and \frak{c}ite[Theorem A.10]{GI2011}, $\mathbf{t}heta_0(\pi_0^\vee) \neq 0$. Therefore, by the conservation relation \frak{c}ite{SZ2015} (see also \frak{c}ite[Theorem 3.8]{KR2005}), $\mathbf{t}heta_2(\pi_0^\vee)=0$. By \frak{c}ite[Proposition 3.1]{HKS1996}, this is equivalent to 
\[{\rm Hom}_{\frak{o}peratorname{Sp}_4(k_v)\mathbf{t}imes \frak{o}peratorname{Sp}_4(k_v)}(R(V_2),\pi_0^\vee \frak{o}times \pi_0)=0.\]
From this together with (\ref{E:non-vanishing}) and (\ref{E:deg. prin. finite}), we deduce that $Z(1/2,\phi_{f_1\frak{o}times f_2},F) \neq 0$ for some $F \in R(V_1)$ which depends only on the stabilizers of $f_1$ and $f_2$ in $\frak{o}peratorname{Sp}_4(k_v)$. 
This completes the proof for $v \mid \frak{n}$.

Assume $v \in S({\rm DS})$.
For non-negative integers $p,q$, let $V_{p,q}$ denote the quadratic space over ${\mathbb R}R$ of signature $(p,q)$
and $\frak{o}mega_{\psi,V_{p,q},4}$ the Weil representation of 
$\frak{o}peratorname{Sp}_8({\mathbb R}R) \mathbf{t}imes \operatorname{O}_{p,q}({\mathbb R})$ on $S(V_{p,q}^4({\mathbb R}))$ with respect to $\psi$.
When $p$, $q$ are positive odd integers such that $p+q = 6$, let $R(p,q)$ be the image of the $(\mathfrak{sp}_8({\mathbb R}R), \operatorname{U}(4))$-intertwining map
\[
 S(V_{p,q}^4({\mathbb R}))  \longrightarrow I_{4,4} \left(\frac{1}{2}\right), \quad \varphi  \longmapsto F({\varphi}),
\]
where $F({\varphi})(g, \frac{1}{2}) = \frak{o}mega_{\psi, V_{p,q}, 4}(g, 1) \varphi(0)$.
By \frak{c}ite{KR1990}, \frak{c}ite{LZ1997},
\begin{align}\label{E:deg. prin. infty}
 I_{4,4} \left(\frac{1}{2}\right) = R(5,1) + R(3,3) + R(1,5).
\end{align}

Let $\mathbf{t}heta_{p,q}(\pi_0^{\vee})$ be the theta lift of $\pi_0^{\vee}$ 
to $\operatorname{O}_{p,q}({\mathbb R})$. By our assumption on $\pi_0$ and \frak{c}ite[Theorem 18]{Paul2005}, $\mathbf{t}heta_{2,2}(\pi_0^\vee) \neq 0$. Therefore, 
by the conservation relation \frak{c}ite{SZ2015} (see also \frak{c}ite[Proposition 22]{Paul2005}),
$\mathbf{t}heta_{5,1}(\pi_0^{\vee}) = \mathbf{t}heta_{1,5}(\pi_0^{\vee}) = 0$.
Hence,
as in the proof of \frak{c}ite[Proposition 3.1]{HKS1996},
\begin{align*}
 \operatorname{Hom}_{(\mathfrak{sp}_4({\mathbb R}R), \operatorname{U}(2)) \mathbf{t}imes (\mathfrak{sp}_4({\mathbb R}R), \operatorname{U}(2))}
 (R(5,1), \pi_0^{\vee} \frak{o}times \pi_0) & = 0, \\
 \operatorname{Hom}_{(\mathfrak{sp}_4({\mathbb R}R), \operatorname{U}(2)) \mathbf{t}imes (\mathfrak{sp}_4({\mathbb R}R), \operatorname{U}(2))}
 (R(1,5), \pi_0^{\vee} \frak{o}times \pi_0) & = 0.
\end{align*}
From this together with (\ref{E:non-vanishing}) and (\ref{E:deg. prin. infty}), we deduce that $Z(1/2,\phi_{f_1\frak{o}times f_2},F) \neq 0$ for some $F \in R(3,3)$. 
This completes the proof for $v \in S({\rm DS})$.

Assume $v \in S({\rm PS})$. Let $\varphi_v \in S(V_{3,3}^4(k_v))$ be the Gaussian function. Proceeding similarly as in the proof of \frak{c}ite[Proposition 6.2]{LNM1254} or Lemma \ref{L:archi. spherical local zeta integral} below, we see that
\[Z_v\left(\frac{1}{2},\phi_{v},F(\varphi_v)\right) \neq 0.\]
This completes the proof.
\end{proof}

\begin{prop}\label{P:main identity1}
We have 
\[
\langlef,f\rangle = 2^c \frak{c}dot \frac{L(1,\pi,{\rm Ad})}{\Delta_{{\rm PGSp}_4}}\frak{c}dot\operatorname{pr}od_v C(\pi_v).
\]
Here $C(\pi_v)$ is a non-zero constant depending only on $\pi_v$ for each place $v$, and 
\begin{align*}
\Delta_{{\rm PGSp}_4} & = \zeta(2)\zeta(4),\\
c & =\begin{cases}
      1 & \mbox{ if $\pi$ is stable},\\
      2 & \mbox{ if $\pi$ is endoscopic}.
     \end{cases}
\end{align*}
In fact, $C(\pi_v)=q_v^{-5\frak{c}_v}$ if $v \notin S$ and 
\begin{align}\label{E:local constants1}
C(\pi_v) & =  \zeta_v(1)^{-1}\zeta_v(3)^{-1}\zeta_v(4) L(1,\pi_v,{\rm Ad})^{-1}\frak{c}dot\frac{\frak{c}alZ_v(1, W_v, \frak{c}alF_v({\varphi_v}))}{Z_v \left(1/2, \phi_{v}, F_v(\varphi_{v})\right)}\frak{c}dot \begin{cases}
q_v^{-9\frak{c}_v/2} & \mbox{ if $v\mid\frak{n}$},\\
1 & \mbox{ if $v \mid \infty$},
\end{cases}
\end{align}
where $\varphi_v \in S(V_{3,3}^4(k_v))$ is any Schwartz function such that $Z_v(1/2,\phi_v,F_v(\varphi_v)) \neq 0$.
\end{prop}

\begin{proof}
Let $\varphi = \bigotimes_v \varphi_v \in S(V_{3,3}^4({\mathbb A}A))$
be such that $\varphi_v = \varphi_v^o$ for all places $v \notin S$.
Then the holomorphic section $F(\varphi) = \bigotimes_v F_v(\varphi_v)$ of $I(s)$
satisfies the following conditions:
\begin{itemize}
 \item $F_v(\varphi_v)$ is $H(\frak{o}_v)$-invariant and $F_v(\varphi_v)(1,s) = q_v^{-6\frak{c}_v}$
 for all places $v \notin S$,
 \item $F_{v}(\varphi_v)$ depends only on $\varphi_v$ for all places $v \in S$.
\end{itemize}
Also,
the holomorphic section $\frak{c}alF(\varphi) = \frak{D}^{-9/2}\rho^{-1}\zeta(2)^{-1}\zeta(3)^{-1} \frak{c}dot\bigotimes_v \frak{c}alF_v(\varphi_v)$ of $\frak{c}alI(s)$
for ${\mathbb R}e(s) > -1$ satisfies the following conditions:
\begin{itemize}
 \item $\frak{c}alF_v(\varphi_v)$ is $H(\frak{o}_v)$-invariant and $\frak{c}alF_v(\varphi_v)(1,s) = \zeta_v(s+1)\zeta_v(s+2)\zeta_v(s+3)$ for all places $v \notin S$,
 \item $\frak{c}alF_{v}(\varphi_v)$ depends only on $\varphi_{v}$ for all places $v \in S$.
\end{itemize}
Let $T = \{v \mid \infty\frak{nd}\}.$ By Lemmas \ref{L:unram PSR} and \ref{L:unram Jiang}, we have
\begin{align*}
 \langle E(s, F({\varphi})), \bar{f} \frak{o}times f \rangle 
 & = \langle f, f \rangle \frak{c}dot \zeta^T(2)^{-1}\zeta^T(4)^{-1}\frak{c}dot d_{P}^{T}(s)^{-1}\frak{c}dot
 L^{T}\left(s+\frac{1}{2}, \pi, {\rm std}\right)
 \operatorname{pr}od_{v \in T}Z_{v}(s, \phi_{v}, F_v({\varphi_{v}})), \\
 \langle \frak{c}alE(s, \frak{c}alF(\varphi)), \bar{f} \frak{o}times f \rangle
 & = \frak{D}^{-9/2}\rho^{-1}\zeta(2)^{-1}\zeta(3)^{-1}\frak{c}dot \zeta^T(2)^{-2}\zeta^T(4)^{-2}\frak{c}dot d_{\mathcal{P}}^{T}(s)^{-1}\frak{c}dot \zeta^{T}(s+1)\zeta^{T}(s+2)\zeta^{T}(s+3)\\
&\mathbf{t}imes L^{T}\left(\frac{s+1}{2}, \pi \mathbf{t}imes \pi^{\vee}\right)
 \operatorname{pr}od_{v \in T}\frak{c}alZ_{v}(s, W_{v}, \frak{c}alF_v({\varphi_{v}})).
\end{align*}
On the other hand, by the first term identity \eqref{E:1st identity},
\[
 \langle \frak{c}alE_{-2}(1,\frak{c}alF(\varphi)), \bar{f} \frak{o}times f \rangle
 = \left\langle
 E_{-1} \left(\frac{1}{2}, F(\varphi)\right), \bar{f} \frak{o}times f \right\rangle.
\]
Hence, noting that $d_P^T(1/2) = \zeta^T(2)\zeta^T(3)\zeta^T(4)$, $d_{\mathcal{P}}^T(1) = \zeta^T(2)\zeta^T(3)\zeta^T(4)^2$, and
\[L^T(s,\pi\mathbf{t}imes\pi^\vee) = \zeta^T(s)L^T(s,\pi,{\rm std})L^T(s,\pi,{\rm Ad}),\]
we have
\begin{align}\label{E:general iden.}
\begin{split}
 & 4 \frak{D}^{-9/2}\zeta(2)^{-1}\zeta(3)^{-1}\zeta^{T}(4)^{-1} \frak{c}dot {\mathbb R}es_{s=1}L^{T}(1, \pi, {\rm std})\frak{c}dot \frac{L^{T}(1, \pi, {\mathbb A}d)}{\zeta^T(2)\zeta^T(4)}
 \operatorname{pr}od_{v \in T}\zeta_v(1)^{-1}\frak{c}alZ_v(1, W_v, \frak{c}alF_v({\varphi_{v}})) \\
 & = 
 \langle f, f \rangle  \zeta^{T}(2)^{-1}\zeta^{T}(3)^{-1}\zeta^{T}(4)^{-1}\frak{c}dot
 {\mathbb R}es_{s=1}L^{T}(1, \pi, {\rm std}) 
 \operatorname{pr}od_{v \in T}Z_v \left(\frac{1}{2}, \phi_{v}, F_v({\varphi_v})\right).
\end{split}
\end{align}
If $\pi$ is endoscopic, then since ${\rm Res}_{s=1}L^T(s,\pi,{\rm std}) \neq 0$ and $\operatorname{pr}od_{v \in T}L(s,\pi_v,{\rm Ad})$ is holomorphic and non-zero at $s=1$, we deduce that
\begin{align}\label{E:endoscopic iden.}
\begin{split}
&\langle f, f \rangle
 \operatorname{pr}od_{v \in T}Z_v \left(\frac{1}{2}, \phi_{v}, F_v(\varphi_{v})\right)\\
&= 4 \frak{D}^{-9/2}\frak{c}dot\frac{L(1, \pi, {\mathbb A}d)}{\Delta_{{\rm PGSp}_4}} \operatorname{pr}od_{v \in T} \zeta_v(1)^{-1}\zeta_v(3)^{-1}\zeta_v(4)L(1,\pi_v,{\rm Ad})^{-1}\frak{c}alZ_v(1, W_v, \frak{c}alF_v({\varphi_v})).
\end{split}
\end{align}
If $\pi$ is stable, then $L^T(s,\pi,{\rm std})$ is holomorphic and non-zero at $s=1$, so that both sides of (\ref{E:general iden.}) vanish. However, by the second term identity (\ref{E:2nd identity}) and Lemmas \ref{lem:vanish_res}, \ref{lem:vanish_theta},
\[
 \langle \frak{c}alE_{-1}(1,\frak{c}alF(\varphi)), \bar{f} \frak{o}times f \rangle
 = \left\langle
 E_{0} \left(\frac{1}{2}, F(\varphi)\right), \bar{f} \frak{o}times f \right\rangle.
\]
Hence, similarly as above, we have
\begin{align*}
 & 2 \frak{D}^{-9/2}\zeta(2)^{-1}\zeta(3)^{-1}\zeta^{T}(4)^{-1} \frak{c}dot L^{T}(1, \pi, {\rm std}) \frak{c}dot\frac{L^{T}(1, \pi, {\mathbb A}d)}{\zeta^T(2)\zeta^T(4)}
 \operatorname{pr}od_{v \in T}\zeta_v(1)^{-1}\frak{c}alZ_v(1, W_v, \frak{c}alF_v({\varphi_{v}})) \\
 & = 
 \langle f, f \rangle  \zeta^{T}(2)^{-1}\zeta^{T}(3)^{-1}\zeta^{T}(4)^{-1}\frak{c}dot
 L^{T}(1, \pi, {\rm std}) 
 \operatorname{pr}od_{v \in T}Z_v \left(\frac{1}{2}, \phi_{v}, F_v({\varphi_v})\right),
\end{align*}
and deduce that 
\begin{align}\label{E:stable iden.}
\begin{split}
&\langle f, f \rangle
 \operatorname{pr}od_{v \in T}Z_v \left(\frac{1}{2}, \phi_{v}, F_v(\varphi_{v})\right)\\
&= 2 \frak{D}^{-9/2}\frak{c}dot\frac{L(1, \pi, {\mathbb A}d)}{\Delta_{{\rm PGSp}_4}} \operatorname{pr}od_{v \in T} \zeta_v(1)^{-1}\zeta_v(3)^{-1}\zeta_v(4)L(1,\pi_v,{\rm Ad})^{-1}\frak{c}alZ_v(1, W_v, \frak{c}alF_v({\varphi_v})).
\end{split}
\end{align}

Now recall that $\varphi_v=\varphi_v^o$ and hence $Z_v(1/2,\phi_v,F_v(\varphi_v)) \neq 0$ for all $v \notin S$ by Lemma \ref{L:unram PSR}. Also, we may choose $\varphi_v$ such that $Z_v(1/2,\phi_v,F_v(\varphi_v)) \neq 0$ for all $v \in S$ by Lemma \ref{lem:nonvanish}. For each place $v$ of $k$, let
\[
 C(\pi_v) = \zeta_v(1)^{-1}\zeta_v(3)^{-1}\zeta_v(4) L(1,\pi_v,{\rm Ad})^{-1}\frak{c}dot\frac{\frak{c}alZ_v(1, W_v, \frak{c}alF_v({\varphi_v}))}{Z_v \left(1/2, \phi_{v}, F_v(\varphi_{v})\right)}\frak{c}dot \begin{cases}
q_v^{-9\frak{c}_v/2} & \mbox{ if $v$ is finite},\\
1 & \mbox{ if $v$ is real}.
\end{cases}
\]
Note that $C(\pi_v)$ is a purely local constant depending only on $\pi_v$ and $\varphi_v$. By Lemma \ref{L:unram PSR} and \ref{L:unram Jiang}, $C(\pi_v) = q_v^{-5\frak{c}_v}$ for all $v \notin S$. In particular, $C(\pi_v) = 1$ for all $v \notin T$. Finally, by (\ref{E:endoscopic iden.}) and (\ref{E:stable iden.}), we have
\[
\langlef,f\rangle = 2^c \frak{c}dot\frac{L(1,\pi,{\rm Ad})}{\Delta_{{\rm PGSp}_4}}\frak{c}dot\operatorname{pr}od_v C(\pi_v).
\]
Since the left-hand side is non-zero and independent of $\varphi_v$, so is $C(\pi_v)$ for all $v \in S$. This completes the proof. 
\end{proof}

In the following proposition, we give an explicit Rallis inner product formula.
\begin{prop}\label{P:main identity2}
Assume $\pi$ is endoscopic. We have 
\[
\langlef,f\rangle = 4 \frak{c}dot\frac{L(1,\pi,{\rm Ad})}{\Delta_{{\rm PGSp}_4}}\frak{c}dot\operatorname{pr}od_v C'(\pi_v),
\]
where 
\begin{align}\label{E:local constants2}
C'(\pi_v) = \begin{cases}
\displaystyle{q_v^{-5\frak{c}_v}} & \mbox{ if $v \notin S$},\\
\displaystyle{q_v^{-1-5\frak{c}_v}\zeta_v(2)^{-1}\zeta_v(4)} & \mbox{ if $v \mid \frak{n}$},\\
\displaystyle{2^{\lambda_{1,v}-\lambda_{2,v}+5}\pi^{3\lambda_{1,v}-\lambda_{2,v}+5}(1+\lambda_{1,v}-\lambda_{2,v})^{-1}}  & \mbox{ if $v \in S({\rm DS})$},\\
\displaystyle{2^{-4}} & \mbox{ if $v \in S({\rm PS})$}.
\end{cases}
\end{align}
\end{prop}

\begin{proof}
The assertion follows from Propositions \ref{P:W(1)} and \ref{P:Rallis inner product}, whose proofs will be given in \S\,\ref{S:cal1} and \S\,\ref{S:cal2}.
\end{proof}

\begin{corollary}\label{C:endoscopic case}
Assume $\pi$ is endoscopic. We have
\[\operatorname{pr}od_{v \in S} C(\pi_v) = \operatorname{pr}od_{v \in S}C'(\pi_v).\]
\end{corollary}

\begin{proof}
The assertion follows from Propositions \ref{P:main identity1} and \ref{P:main identity2}.
\end{proof}

\subsection{Families of local representations of $\frak{o}peratorname{GSp}_4$}\label{SS:analytic family}
In this section, we switch to a local setting. Let $F$ be a local field of characteristic zero. When $F$ is non-archimedean, let $\frak{o}$, $\frak{c}$, $\varpi$, $q$, $|\mbox{ }|$ be the notation defined as in $\S\,\ref{S:notation}$, and fix a non-trivial additive character $\psi$ of $F$ with conductor $\varpi^{-\frak{c}}\frak{o}$. When $F={\mathbb R}$, let $\psi(x)=e^{2\pi\sqrt{-1}x}$.

Consider the split orthogonal similitude group ${\rm GO}_{2,2}$. Put
\[H= {\rm GO}_{2,2},\quad H^\frak{c}irc = {\rm GSO}_{2,2}.\]
There is an isomorphism (cf.\,\S\,\ref{SS:theta lifts})
\[{\mathbb G}_m \backslash (\frak{o}peratorname{GL}_2\mathbf{t}imes\frak{o}peratorname{GL}_2) \simeq H^\frak{c}irc.\]
We write $[h_1,h_2]\in H^\frak{c}irc$ for the image of $(h_1,h_2)\in \frak{o}peratorname{GL}_2\mathbf{t}imes\frak{o}peratorname{GL}_2$ under the above isomorphism. Let ${\bf t} \in H \setminus H^\frak{c}irc$ be an involution so that ${\rm Ad}({\bf t})[h_1,h_2] = [\det(h_2)^{-1}h_2,\det(h_1)^{-1}h_1]$. Let $\sigma_1$ and $\sigma_2$ be irreducible admissible representations of $\frak{o}peratorname{GL}_2(F)$ with equal central character. Let $\mathcal{V}_{\sigma_i}$ be the space of $\sigma_i$ for $i=1,2$. Let $\sigma_1 \mathbf{t}imes \sigma_2$ be the representation of $H^\frak{c}irc(F)$ on $\mathcal{V}_{\sigma_1}\frak{o}times \mathcal{V}_{\sigma_2}$ defined by
\[[h_1,h_2]\frak{c}dot (v_1\frak{o}times v_2) = \sigma_1(h_1)v_1\frak{o}times \sigma_2(h_2)v_2\]
for $h_1,h_2 \in \frak{o}peratorname{GL}_2(F)$ and $v_1\in \mathcal{V}_{\sigma_1}$, $v_2 \in \mathcal{V}_{\sigma_2}$.
 We define an irreducible admissible representation $(\sigma_1\mathbf{t}imes\sigma_2)^{\sharp}$ of $H(F)$ as follows:
\begin{itemize}
\item If $\sigma_1 \not\simeq \sigma_2^\vee$, then $(\sigma_1\mathbf{t}imes\sigma_2)^{\sharp} = {\rm Ind}_{H^\frak{c}irc(F)}^{H(F)}(\sigma_1 \mathbf{t}imes \sigma_2)$.
\item If $\sigma_1 \simeq \sigma_2^\vee$, then since $\sigma_2^\vee \simeq \sigma_2 \frak{o}times \frak{o}mega_{\sigma_2}^{-1}$, we may assume $\mathcal{V}_{\sigma_1} = \mathcal{V}_{\sigma_2}$. Let $\mathcal{V}^\sharp = \mathcal{V}_{\sigma_1} \frak{o}times \mathcal{V}_{\sigma_1}$. Let $(\sigma_1\mathbf{t}imes\sigma_2)^{\sharp}$ be the representation of $H(F)$ on $\mathcal{V}^\sharp$ defined by
\begin{align*}
\begin{split}
[h_1,h_2]\frak{c}dot(v_1\frak{o}times v_2) &= \sigma_1(h_1)v_1\frak{o}times \frak{o}mega_{\sigma_1}(\det(h_2)^{-1})\sigma_1(h_2)v_2,\\
{\bf t}\frak{c}dot(v_1\frak{o}times v_2) & = v_2\frak{o}times v_1
\end{split}
\end{align*}
for $h_1,h_2 \in \frak{o}peratorname{GL}_2(F)$ and $v_1,v_2 \in \mathcal{V}_{\sigma_1}.$
\end{itemize}

We consider three types of irreducible generic admissible representations $\pi$ of ${G}(F)$ with trivial central character:
\begin{itemize}
\item[(IIa)] $F$ is non-archimedean and $\pi$ is a  representation of ${G}(F)$ with paramodular conductor $\varpi\frak{o}$. 
\item[(DS)] $F={\mathbb R}$ and $\pi$ is a (limit of) discrete series representation of ${G}({\mathbb R})$.
\item[(PS)] $F={\mathbb R}$ and $\pi$ is a principle series representation of ${G}({\mathbb R})$ with non-zero $(\frak{o}peratorname{Sp}_4({\mathbb R})\frak{c}ap {\rm O}(4))$-invariant vectors.
\end{itemize}
Note that we do not require $\pi$ to be unitary.

Let $\pi$ be a representation of type (IIa). Then $\pi$ is induced from the following representation of the standard Siegel parabolic subgroup 
\begin{align}\label{E:induced repre IIa}
\begin{pmatrix} A & * \\ 0 & \nu {}^tA^{-1}\end{pmatrix} \longmapsto
({\rm St}\frak{o}times |\mbox{ }|^{\lambda})(A)\frak{c}dot \mathbf{t}imesi^\varepsilon|\nu|^{-\lambda}
\end{align}
for some $\varepsilon \in \{0,1\}$ and $\lambda \in {\mathbb C}$.
Here ${\rm St}$ is the Steinberg representation of $\frak{o}peratorname{GL}_2(F)$ and $\mathbf{t}imesi$ is the non-trivial unramified quadratic character of $F^\mathbf{t}imes$. Note that $\lambda \mbox{ mod }\frac{2\pi\sqrt{-1}}{ {\rm log}q}{\mathbb Z}$ is determined by $\pi$ up to sign. We call $\varepsilon$ and $\lambda$ the sign and the parameter of $\pi$, respectively. Note that $\pi$ is the theta lift of the representation 
\begin{align}\label{E:theta1}
\left(({\rm St}\frak{o}times \mathbf{t}imesi^\varepsilon) \mathbf{t}imes {\rm Ind}_{B(F)}^{\frak{o}peratorname{GL}_2(F)}(|\mbox{ }|^{\lambda}\mathbf{t}imesi^\varepsilon\boxtimes|\mbox{ }|^{-\lambda}\mathbf{t}imesi^\varepsilon)\right)^\sharp
\end{align}
of $H(F)$ to ${G}(F)$.

Let $\pi$ be a representation of type (DS). Then \[\pi\vert_{\frak{o}peratorname{Sp}_4({\mathbb R})} = D_{(\lambda_1,\lambda_2)}\frak{o}plus D_{(-\lambda_2,-\lambda_1)}.\]
Here $D_{(\lambda_1,\lambda_2)}$ is the (limit of) discrete series representation of $\frak{o}peratorname{Sp}_4({\mathbb R})$ with Blattner parameter $(\lambda_1,\lambda_2)$ such that $1-\lambda_1 \leq \lambda_2 \leq 0$. We call $\lambda=(\lambda_1,\lambda_2) \in {\mathbb Z}^2$ the parameter of $\pi$. Note that $\pi$ is the theta lift of the representation
\begin{align}\label{E:theta2}
\left({\rm DS}(\lambda_1-\lambda_2)\mathbf{t}imes{\rm DS}(\lambda_1+\lambda_2)\right)^\sharp
\end{align}
of $H({\mathbb R})$ to ${G}({\mathbb R})$. Here ${\rm DS}(\kappa)$ denotes the  (limit of) discrete series representation of $\frak{o}peratorname{GL}_2({\mathbb R})$ with minimal weight $\kappa \in {\mathbb Z}_{\geq 1}$. Since we assume $\pi$ has trivial central character, $\lambda_1-\lambda_2$ is an even integer.

Let $\pi$ be a representation of type (PS). Then $\pi$ is induced from the following representation of the standard Borel subgroup 
\begin{align}\label{E:induced repre PS}
\begin{pmatrix} t_1 & * & *&* \\0&t_2&*&*\\0&0&\nu t_1^{-1}&0\\0&0& *&\nu t_2^{-1}  \end{pmatrix} \longmapsto |t_1|^{\lambda_1}\frak{c}dot|t_2|^{\lambda_2}\frak{c}dot{\rm sgn}(\nu)^\varepsilon|\nu|^{-(\lambda_1+\lambda_2)/2}
\end{align}
for some $\varepsilon \in \{0,1\}$ and $\lambda = (\lambda_1,\lambda_2) \in {\mathbb C}^2$.
Note that $\lambda$ is determined by $\pi$ up to the action of the Weyl group. We call $\varepsilon$ and $\lambda$ the sign and the parameter of $\pi$, respectively. Note that $\pi$ is the theta lift of the representation
\begin{align}\label{E:theta3}
\left( {\rm Ind}_{B({\mathbb R})}^{\frak{o}peratorname{GL}_2({\mathbb R})}(|\mbox{ }|^{(\lambda_1+\lambda_2)/2}{\rm sgn}^\varepsilon\boxtimes|\mbox{ }|^{(-\lambda_1-\lambda_2)/2}{\rm sgn}^\varepsilon) \mathbf{t}imes {\rm Ind}_{B({\mathbb R})}^{\frak{o}peratorname{GL}_2({\mathbb R})}(|\mbox{ }|^{(\lambda_1-\lambda_2)/2}{\rm sgn}^\varepsilon\boxtimes |\mbox{ }|^{(-\lambda_1+\lambda_2)/2}{\rm sgn}^\varepsilon)\right)^\sharp
\end{align}
of $H({\mathbb R})$ to ${G}({\mathbb R})$. 

Let $\mathcal{D}$ be the domain defined by
\begin{align}\label{E:domain}
\mathcal{D} = 
\begin{cases}
\left\{\lambda \in {\mathbb C} \mbox{ }\vert\mbox{ } |{\rm Re}(\lambda) |<1/2 \right\} & \mbox{ in Case (IIa)},\\
\left\{\lambda=(\lambda_1,\lambda_2) \in {\mathbb C}^2 \mbox{ }\vert\mbox{ }|{\rm Re}(\lambda_1)|+|{\rm Re}(\lambda_2)|<1 \right\} & \mbox{ in Case (PS)}.
\end{cases}
\end{align}  
By the unitarizability criterion \frak{c}ite[Theorem 1.1]{LMT2004}, the domain $\mathcal D$ contains the set of parameters of unitary representations of type (IIa) or (PS).

Let $\pi$ be a representation of $G(F)$ in one of the three types. When $\pi$ is of type (IIa) or (PS), we assume its parameter is in $\mathcal{D}$. Let $W_\pi$ be the Whittaker function of $\pi$ with respect to $\psi_U$ defined as follows:
\begin{itemize}
\item In Case (IIa), $W_\pi$ is ${\rm K}(\varpi)$-invariant and $W_\pi(\operatorname{diag}( \varpi^{-\frak{c}}, 1, \varpi^{2\frak{c}}, \varpi^{\frak{c}} ))=1$.
\item In Case (DS), $W_\pi$ is a lowest weight vector of the minimal ${\rm U}(2)$-type of $D_{(-\lambda_2,-\lambda_1)}$ in the Whittaker model of $\pi$ with respect to $\psi_U$, and $W_\pi(1)$ is normalized as in (\ref{E:normalization DS}). We refer to \S\,\ref{SS:main thm} for the choice of the lowest weight vector.
\item In Case (PS), $W_\pi$ is $(\frak{o}peratorname{Sp}_4({\mathbb R})\frak{c}ap {\rm O}(4))$-invariant and $W_{\pi}(1)$ is normalized as in (\ref{E:normalization PS}).
\end{itemize}
Since $\pi$ has trivial central character, we have $\pi \simeq \pi^\vee$. Therefore $W_\pi = W_{\pi^\vee}$ when $\pi$ is of type (IIa) or (PS).

When $\pi$ is of type (IIa) or (PS), let $\phi_\pi$ be the matrix coefficient of $\pi$ defined by
\[\phi_\pi(g) = \frac{\langle\pi(g)W_\pi,W_{\pi^\vee}\rangle}{\langleW_\pi,W_{\pi^\vee}\rangle}.\]
Here $\langle \ , \ \rangle$ is an invariant bilinear pairing on $\pi \mathbf{t}imes \pi^\vee$. Note that if $\pi$ is unitary, then
\[\phi_\pi(g) = \frac{\langle\pi(g)W_\pi,W_{\pi}\rangle_h}{\langleW_\pi,W_{\pi}\rangle_h}\]
for any Hermitian pairing $\langle\ ,\ \rangle_h$ on $\pi \mathbf{t}imes \pi$, and
\[\frak{o}verline{W_\pi(g)} = W_\pi(\operatorname{diag} (-1,1,1,-1) g)\]
for all $g \in G(F)$.

When $\pi$ is of type (DS), let $\phi_\pi$ be the matrix coefficient of $\pi$ defined by
\[\phi_\pi(g) = \frac{\langle\pi(g)W_\pi,W_{\pi}\rangle}{\langleW_\pi,W_{\pi}\rangle}\]
for any Hermitian pairing $\langle\ ,\ \rangle$ on $\pi \mathbf{t}imes \pi$.

Let $I(s)=I_{4,4}(s)$ and $\frak{c}alI(s)=I_{4,3}(s)$ be the degenerate principal series representations of $\frak{o}peratorname{GSp}_8(F)$ defined as in $\S\,\ref{ss:eisenstein}$. If $F\in I(s)$ and $\frak{c}alF \in \frak{c}alI(s)$ are holomorphic sections, let $Z(s,\phi_\pi,F)$ and $\frak{c}alZ(s,W_\pi,\frak{c}alF)$ be the local zeta integals defined as in (\ref{E:local zeta1}) and (\ref{E:local zeta2}), respectively. Note that when $\pi$ is of type (IIa) or (PS), we replace $\frak{o}verline{W_\pi}$ by the left translation of $W_\pi$ by $\operatorname{diag}(-1,1,1,-1)$.

Recall the intertwining maps 
\begin{align*}
S({\rm M}_{6,4}(F)) &\longrightarrow \frak{c}alI(s),\quad \varphi \longmapsto \frak{c}alF(\varphi)\\
S({\rm M}_{6,4}(F)) &\longrightarrow I(s),\quad \varphi \longmapsto F(\varphi)
\end{align*}
defined in \S\,\ref{SS:Theta integrals} and \S\,\ref{SS:First and second term identities}, respectively.
By Lemma \ref{lem:nonvanish}, there exists a Schwartz function $\varphi \in S({\rm M}_{6,4}(F))$ such that
\[Z\left(\frac{1}{2},\phi_\pi,F(\varphi)\right)\neq 0,\]
and such that $\varphi$ does not depend on $\pi$ when $\pi$ is of type (IIa) or (PS).
We fix one such $\varphi$ and define constants $C(\pi)$ and $C'(\pi)$ as in (\ref{E:local constants1}) and (\ref{E:local constants2}), respectively. 

\begin{corollary}\label{C:analytic family}
Assume $\pi$ is of type (IIa) or (PS) with parameter $\lambda$ in $\mathcal{D}$.
The constants $C(\pi)$ and $C'(\pi)$ as functions of $\lambda$ are analytic.
\end{corollary}

\begin{proof}
It is easy to show that the maps $\lambda \mapsto \phi_\pi$ and $\lambda \mapsto W_\pi$ define $K$-finite analytic families of matrix coefficiens and Whittaker functions in the sense introduced in \S\,\ref{SS:Doubling local zeta integrals} and \S\,\ref{SS:local zeta for Rankin-Selberg} below, respectively.
The assertion then follows directly from Lemmas \ref{L:ab1} and \ref{L:uniform2}.
\end{proof}

\begin{prop}\label{P:main ide}
Let $\pi$ be a representation in one of the three types. When $\pi$ is of type (IIa) or (PS), we assume its parameter is in $\mathcal{D}$. We have
\begin{align}\label{E:main ide}
C(\pi) = C'(\pi).
\end{align}
\end{prop}
It is clear that Theorem \ref{T:main thm} follows from Propositions \ref{P:main identity1} and \ref{P:main ide}.
We divide the proof of Proposition \ref{P:main ide} into four steps as follows:
\begin{itemize}
\item[Step 1.] Establish (\ref{E:main ide}) in Case (DS) when $\lambda_1-\lambda_2$ and $\lambda_1+\lambda_2$ are sufficiently large.
\item[Step 2.] Establish (\ref{E:main ide}) in Case (IIa) when $F={\mathbb Q}_p$.
\item[Step 3.] Establish (\ref{E:main ide}) in Case (DS) for arbitrary parameter $\lambda$.
\item[Step 4.] Establish (\ref{E:main ide}) in Case (PS) and in Case (IIa) for arbitrary non-archimedean $F$.
\end{itemize}
The ingredients are Corollary \ref{C:endoscopic case}, explicit local theta correspondence (\ref{E:theta1}), (\ref{E:theta2}), (\ref{E:theta3}), and the limit multiplicity formula \frak{c}ite[\S\,5]{Shin2012}. 

\subsection{Proof of Proposition \ref{P:main ide}}
We need the following result on the existence of automorphic representations of $\frak{o}peratorname{GL}_2({\mathbb A}_k)$ for a totally real number field $k \neq {\mathbb Q}$. The proposition is a simple variant of the results in \frak{c}ite{Shin2012} and is well-known, but we give a proof for completeness. For simplicity, we assume $[k:{\mathbb Q}]$ is odd.

\begin{prop}\label{P:existence}
Assume $k\neq {\mathbb Q}$ is a totally real number field of odd degree. Let $v_0$ be a real place of $k$ and $\frak{c}hi$ a unitary character of ${\mathbb R}^{\mathbf{t}imes}$. For each open neighborhood $U$ of $0$ in ${\mathbb R}$, there exist infinitely many irreducible cuspidal automorphic representations $\sigma$ of $\frak{o}peratorname{GL}_2({\mathbb A}_k)$ with trivial central character satisfying the following conditions:
\begin{itemize}
\item $\sigma_v$ is unramified for all finite places $v$.
\item $\sigma_v$ is a discrete series representation for all real places $v \neq v_0$.
\item $\sigma_{v_0} = {\rm Ind}_{B({\mathbb R})}^{\frak{o}peratorname{GL}_2({\mathbb R})}(\frak{c}hi|\mbox{ }|^{\sqrt{-1}t}\boxtimes\frak{c}hi^{-1}|\mbox{ }|^{-\sqrt{-1}t})$ for some $t \in U$.
\end{itemize}
\end{prop}

\begin{proof}
Let $S_0$ be the set of real places $v \neq v_0$.
Since $[k:{\mathbb Q}]$ is odd and $k \ne {\mathbb Q}$, there exists a unique quaternion division algebra $D$ over $k$ which is ramified precisely at the places in $S_0$.
We write $G = D^\mathbf{t}imes / k^\mathbf{t}imes$ only in this proof and regard it as an algebraic group over $k$.
Note that $G$ is anisotropic over $k$ and $G(k_v)$ is compact for all $v \in S_0$.
For each finite place $v$, we denote by $K_v = {\rm PGL}_2(\mathfrak{o}_v)$ the standard maximal compact subgroup of $G(k_v) = {\rm PGL}_2(k_v)$, and put $K_{f} = \operatorname{pr}od_{v \nmid \infty} K_v$.
For each $v \in S_0$, fix a sequence $\{ \mathbf{t}imesi_{v,n} \}_{n \ge 1}$ of irreducible representations of $G(k_v)$, and put $\mathbf{t}imesi_n = \bigotimes_{v \in S_0} \mathbf{t}imesi_{v,n}$.
We assume that 
\[
 \lim_{n \rightarrow \infty} \dim \mathbf{t}imesi_n = \infty.
\]
We denote by $\widehat{G(k_{v_0})}$ the unitary dual of $G(k_{v_0})$ equipped with the Fell topology and by $\mu_{\mathrm{pl}}$ the Plancherel measure on $\widehat{G(k_{v_0})}$.
We define a subset $\mathcal{U}$ of $\widehat{G(k_{v_0})}$ by 
\[
 \mathcal{U} = \left\{ \left. \mathrm{I}nd^{\frak{o}peratorname{GL}_2({\mathbb R})}_{B({\mathbb R})}(\frak{c}hi|\ |^{\sqrt{-1} t} \boxtimes \frak{c}hi^{-1}|\ |^{-\sqrt{-1} t}) \, \right| \, t \in U \right\}.
\]
Then, by the Jacquet-Langlands correspondence, it suffices to show that for any sufficiently large $n$, there exists an irreducible automorphic representation $\pi$ of $G({\mathbb A}_k)$ satisfying the following conditions:
\begin{itemize}
\item $\pi_v$ has a non-zero $K_v$-invariant vector for all finite places $v$.
\item $\pi_v = \mathbf{t}imesi_{v,n}$ for all $v \in S_0$.
\item $\pi_{v_0} \in \mathcal{U}$.
\end{itemize}

We now consider a sequence $\{ \mu_n \}_{n \ge 1}$ of positive Borel measures on $\widehat{G(k_{v_0})}$ given by 
\[
 \mu_n = \frac{1}{\operatorname{vol}(G(k) \backslash G({\mathbb A}_k)) \dim \mathbf{t}imesi_n} \sum_{\rho} m_n(\rho) \delta_\rho,
\]
where $\rho$ runs over irreducible unitary representations of $G(k_{v_0})$, $m_n(\rho)$ is the multiplicity of $\rho \frak{o}times \mathbf{t}imesi_n$ in the space of $K_f$-invariant automorphic forms on $G({\mathbb A}_k)$, and $\delta_\rho$ is the Dirac measure at $\rho$.
Then we are reduced to showing that 
\[
 \lim_{n \rightarrow \infty} \mu_n(\mathbb{I}_{\mathcal{U}}) = \mu_{\mathrm{pl}}(\mathbb{I}_{\mathcal{U}}).
\]
By the density theorem of Sauvageot \frak{c}ite[Theorem 7.3]{sauvageot1997}, we are further reduced to showing that 
\[
 \lim_{n \rightarrow \infty} \mu_n(\widehat{\phi})
 = \mu_{\mathrm{pl}}(\widehat{\phi})
\]
for all $\phi \in C_c^\infty({G(k_{v_0})})$, where $\widehat{\phi}(\rho) = \mathbf{t}r(\rho(\phi))$ for $\rho \in \widehat{G(k_{v_0})}$.
To prove this, we use the trace formula
\[
 I_{\mathrm{geom}}(f) = I_{\mathrm{spec}}(f).
\]
Here, for a test function $f \in C_c^\infty(G({\mathbb A}_k))$, the geometric side $I_{\mathrm{geom}}(f)$ is given by 
\[
 I_{\mathrm{geom}}(f) = \sum_{\gamma} \operatorname{vol}(G_\gamma(k) \backslash G_\gamma({\mathbb A}_k)) O_\gamma(f), 
\]
where $\gamma$ runs over conjugacy classes of $G(k)$, $G_\gamma$ is the centralizer of $\gamma$ in $G$, and $O_\gamma(f)$ is the orbital integral of $f$ at $\gamma$.
Also, the spectral side $I_{\mathrm{spec}}(f)$ is given by 
\[
 I_{\mathrm{spec}}(f) = \sum_{\pi} m(\pi) \mathbf{t}r(\pi(f)),
\]
where $\pi$ runs over irreducible unitary representations of $G({\mathbb A}_k)$ and $m(\pi)$ is the multiplicity of $\pi$ in $L^2(G(k) \backslash G({\mathbb A}_k))$.
If we take a test function 
\[
 f_n = \frac{1}{\operatorname{vol}(G(k) \backslash G({\mathbb A}_k)) \dim \mathbf{t}imesi_n} \frak{c}dot \left( \bigotimes_{v \in S_0} f_{v,n} \right) \frak{o}times \left( \bigotimes_{v \notin S_0} f_v \right)
\]
given by 
\begin{itemize}
\item $f_v = \mathbb{I}_{K_v}$ for all finite places $v$,
\item $f_{v,n}(g) = \mathbf{t}r(\mathbf{t}imesi_{v,n}(g^{-1}))$ for all $v \in S_0$, 
\item $f_{v_0} = \phi$,
\end{itemize}
then
\[
 I_{\mathrm{spec}}(f_n) = \frac{1}{\operatorname{vol}(G(k) \backslash G({\mathbb A}_k)) \dim \mathbf{t}imesi_n} \sum_{\rho} m_n(\rho) \mathbf{t}r(\rho(\phi)) = \mu_n(\widehat{\phi}).
\]
On the other hand, we have
\[
 O_\gamma(f_n) = \frac{1}{\operatorname{vol}(G(k) \backslash G({\mathbb A}_k))} \frak{c}dot \operatorname{pr}od_{v \in S_0} \frac{\operatorname{vol}(G_{\gamma,v} \backslash G_v) \mathbf{t}r(\mathbf{t}imesi_{v,n}(\gamma^{-1}))}{\dim \mathbf{t}imesi_{v,n}} \frak{c}dot \operatorname{pr}od_{v \notin S_0} O_\gamma(f_v).
\]
If $\gamma \ne 1$, then by \frak{c}ite[Corollaire 1.12]{CC2009}, we have
\[
 \lim_{n\rightarrow \infty} \operatorname{pr}od_{v \in S_0} \frac{\mathbf{t}r(\mathbf{t}imesi_{v,n}(\gamma^{-1}))}{\dim \mathbf{t}imesi_{v,n}} = 0.
\]
Hence, noting that the sum in $I_{\mathrm{geom}}(f_n)$ can be taken over a finite set independent of $n$, we have
\[
 \lim_{n \rightarrow \infty} I_{\mathrm{geom}}(f_n) = \lim_{n \rightarrow \infty} \operatorname{vol}(G(k) \backslash G({\mathbb A}_k)) f_n(1) = \phi(1) = \mu_{\mathrm{pl}}(\widehat{\phi}).
\]
This implies the assertion. 
\end{proof}

Now we begin the proof of Proposition \ref{P:main ide}.
We will use a global-to-local argument repeatedly. When $k$ is a totally real number field, and $\sigma_1$, $\sigma_2$ are irreducible unitary cuspidal automorphic representations of $\frak{o}peratorname{GL}_2({\mathbb A}_k)$ with equal central characters, we put
\[(\sigma_1\mathbf{t}imes\sigma_2)^\sharp = \bigotimes_v(\sigma_{1,v}\mathbf{t}imes\sigma_{2,v})^\sharp.\]
By \frak{c}ite[Proposition 5.4]{Takeda2009}, $(\sigma_1\mathbf{t}imes\sigma_2)^\sharp$ is an irreducible cuspidal automorphic representation of $H({\mathbb A}_k)$. Let $\mathbf{t}heta((\sigma_1\mathbf{t}imes\sigma_2)^\sharp)$ be the global theta lift of $(\sigma_1\mathbf{t}imes\sigma_2)^\sharp$ to $G({\mathbb A}_k)$. If $\sigma_1 \not\simeq \sigma_2^\vee$, then $\mathbf{t}heta((\sigma_1\mathbf{t}imes\sigma_2)^\sharp)$ is an irreducible unitary endoscopic cuspidal automorphic representation of $G({\mathbb A}_k)$.

{\bf Step\,1.} Assume $\pi$ is of type (DS) such that $\lambda_1+\lambda_2$ and $\lambda_1-\lambda_2$ are sufficiently large positive even integers. By the dimension formulae for the space of holomorphic elliptic cusp forms of full level, there exist irreducible cuspidal automorphic representations $\sigma_1$ and $\sigma_2$ of $\frak{o}peratorname{GL}_2({\mathbb A}_{\mathbb Q})$ with trivial central character satisfying the following conditions:
\begin{itemize}
\item $\sigma_{1,p}$ and $\sigma_{2,p}$ are unramified for all primes $p$.
\item $\sigma_{1,\infty}={\rm DS}(\lambda_1-\lambda_2)$ and $\sigma_{2,\infty}={\rm DS}(\lambda_1+\lambda_2)$.
\end{itemize} 
Then $\mathbf{t}heta((\sigma_1\mathbf{t}imes\sigma_2)^\sharp)$ is an irreducible globally generic cuspidal automorphic representation of $G({\mathbb A}_{\mathbb Q})$ with trivial central character satisfying the following conditions:
\begin{itemize}
\item $\mathbf{t}heta((\sigma_1\mathbf{t}imes\sigma_2)^\sharp)_p$ is unramified for all primes $p$.
\item $\mathbf{t}heta((\sigma_1\mathbf{t}imes\sigma_2)^\sharp)_\infty = \pi$.
\end{itemize}
Therefore, (\ref{E:main ide}) follows from Corollary \ref{C:endoscopic case}.

{\bf Step\,2.} Assume $\pi$ is of type (IIa) with $F={\mathbb Q}_p$ for some prime $p$. By Corollary \ref{C:analytic family} and the identity theorem for holomorphic functions, we may assume $\pi$ is tempered, that is, ${\rm Re}(\lambda)=0$. Fix an irreducible cuspidal automorphic representation $\sigma_1$ of $\frak{o}peratorname{GL}_2({\mathbb A}_{\mathbb Q})$ with trivial central character such that
\begin{itemize}
\item $\sigma_{1,\ell}$ is unramified for all primes $\ell \neq p$.
\item $\sigma_{1,p} = {\rm St}\frak{o}times \mathbf{t}imesi^\varepsilon$.
\item $\sigma_{1,\infty}={\rm DS}(\kappa_1)$ for some sufficiently large $\kappa_1 \in {\mathbb Z}_{\geq 2}$.
\end{itemize}
Let $U$ be an open neighborhood of $0$ in ${\mathbb R}$. By \frak{c}ite[Theorem 5.8]{Shin2012}, there exist infinitely many irreducible cuspidal automorphic representations $\sigma_2$ of $\frak{o}peratorname{GL}_2({\mathbb A}_{\mathbb Q})$ with trivial central character such that
\begin{itemize}
\item $\sigma_{2,\ell}$ is unramified for all pimes $\ell \neq p$.
\item $\sigma_{2,p} = {\rm Ind}_{B({\mathbb Q}_p)}^{\frak{o}peratorname{GL}_2({\mathbb Q}_p)}(|\mbox{ }|^{\lambda+\sqrt{-1}t}\mathbf{t}imesi^\varepsilon\boxtimes|\mbox{ }|^{-\lambda-\sqrt{-1}t}\mathbf{t}imesi^\varepsilon)$ for some $t \in U$.
\item $\sigma_{2,\infty}$ is a discrete series representation.
\end{itemize}
We fix one such representation $\sigma_2$ such that $\sigma_{2,\infty}$ has sufficiently large weight $\kappa_2 \in {\mathbb Z}_{\geq 2}$. Then $\mathbf{t}heta((\sigma_1\mathbf{t}imes\sigma_2)^\sharp)$ is an irreducible globally generic cuspidal automorphic representation of $G({\mathbb A}_{\mathbb Q})$ with trivial central character satisfying the following conditions:
\begin{itemize}
\item $\mathbf{t}heta((\sigma_1\mathbf{t}imes\sigma_2)^\sharp)_\ell$ is unramified for all primes $\ell \neq p$. 
\item $\mathbf{t}heta((\sigma_1\mathbf{t}imes\sigma_2)^\sharp)_p$ is of type (IIa) with parameter $\lambda+t\sqrt{-1}$ for some $t \in U$ and sign $\varepsilon$.
\item $\mathbf{t}heta((\sigma_1\mathbf{t}imes\sigma_2)^\sharp)_\infty$ is of type (DS) with parameter $((\kappa_1+\kappa_2)/2,-|\kappa_1-\kappa_2|/2)$.
\end{itemize}
By Corollary \ref{C:endoscopic case}, 
\[C(\mathbf{t}heta((\sigma_1\mathbf{t}imes\sigma_2)^\sharp)_p)C(\mathbf{t}heta((\sigma_1\mathbf{t}imes\sigma_2)^\sharp)_\infty) = C'(\mathbf{t}heta((\sigma_1\mathbf{t}imes\sigma_2)^\sharp)_p)C'(\mathbf{t}heta((\sigma_1\mathbf{t}imes\sigma_2)^\sharp)_\infty).\]
On the other hand, since $\kappa_1$ and $\kappa_2$ are sufficiently large,
\[C(\mathbf{t}heta((\sigma_1\mathbf{t}imes\sigma_2)^\sharp)_\infty) = C'(\mathbf{t}heta((\sigma_1\mathbf{t}imes\sigma_2)^\sharp)_\infty)\]
by {\bf Step\,1}. We conclude that
\[C(\mathbf{t}heta((\sigma_1\mathbf{t}imes\sigma_2)^\sharp)_p) = C'(\mathbf{t}heta((\sigma_1\mathbf{t}imes\sigma_2)^\sharp)_p).\]
Therefore, (\ref{E:main ide}) follows from Corollary \ref{C:analytic family}.

{\bf Step\,3.} Assume $\pi$ is of type (DS) for arbitrary parameter $\lambda$. Recall that $\lambda_1+\lambda_2$ and $\lambda_1-\lambda_2$ are positive even integers. By the dimension formulae for the space of holomorphic elliptic cusp forms,  there exist two distinct primes $p_1$, $p_2$, and irreducible cuspidal automorphic representations $\sigma_1$ and $\sigma_2$ of $\frak{o}peratorname{GL}_2({\mathbb A}_{\mathbb Q})$ with trivial central character such that
\begin{itemize}
\item $\sigma_{1,\ell}$ is unramified for all primes $\ell \neq p_1$.
\item $\sigma_{2,\ell}$ is unramified for all primes $\ell \neq p_2$.
\item $\sigma_{1,p_1}$ and $\sigma_{2,p_2}$ are special representations of conductor $p_1{\mathbb Z}_{p_1}$ and $p_2{\mathbb Z}_{p_2}$, respectively.
\item $\sigma_{1,\infty} = {\rm DS}(\lambda_1-\lambda_2)$ and $\sigma_{2,\infty}= {\rm DS}(\lambda_1+\lambda_2)$ are discrete series representations. 
\end{itemize}
Then $\mathbf{t}heta((\sigma_1\mathbf{t}imes\sigma_2)^\sharp)$ is an irreducible globally generic cuspidal automorphic representation of $G({\mathbb A}_{\mathbb Q})$ with trivial central character satisfying the following conditions:
\begin{itemize}
\item $\mathbf{t}heta((\sigma_1\mathbf{t}imes\sigma_2)^\sharp)_\ell$ is unramified for all primes $\ell \notin \{p_1,p_2\}$.
\item $\mathbf{t}heta((\sigma_1\mathbf{t}imes\sigma_2)^\sharp)_{p_i}$ is of type (IIa) for $i=1,2$.
\item $\mathbf{t}heta((\sigma_1\mathbf{t}imes\sigma_2)^\sharp)_\infty = \pi$.
\end{itemize}
By Corollary \ref{C:endoscopic case}, 
\[C(\mathbf{t}heta((\sigma_1\mathbf{t}imes\sigma_2)^\sharp)_{p_1})C(\mathbf{t}heta((\sigma_1\mathbf{t}imes\sigma_2)^\sharp)_{p_2})C(\pi) = C'(\mathbf{t}heta((\sigma_1\mathbf{t}imes\sigma_2)^\sharp)_{p_1})C'(\mathbf{t}heta((\sigma_1\mathbf{t}imes\sigma_2)^\sharp)_{p_2})C'(\pi).\]
On the other hand, by {\bf Step\,2},
\[C(\mathbf{t}heta((\sigma_1\mathbf{t}imes\sigma_2)^\sharp)_{p_1})C(\mathbf{t}heta((\sigma_1\mathbf{t}imes\sigma_2)^\sharp)_{p_2}) = C'(\mathbf{t}heta((\sigma_1\mathbf{t}imes\sigma_2)^\sharp)_{p_1})C'(\mathbf{t}heta((\sigma_1\mathbf{t}imes\sigma_2)^\sharp)_{p_2}).\]
Therefore (\ref{E:main ide}) holds for $\pi$.

{\bf Step\,4.} First we assume $\pi$ is of type (IIa). There exist a totally real number field $k$ and a finite place $v_0$ of $k$ such that $k_{v_0}=F$. To prove (\ref{E:main ide}), we proceed as in {\bf Step 2}. By Corollary \ref{C:analytic family} and the identity theorem for holomorphic functions, we may assume ${\rm Re}(\lambda)=0$. By \frak{c}ite[Theorem 5.8]{Shin2012} (see also \frak{c}ite[Theorem 1.1]{Weinstein2009}), there exists an irreducible cuspidal automorphic representation $\sigma_1$ of $\frak{o}peratorname{GL}_2({\mathbb A}_k)$ with trivial central character satisfying the following conditions:
\begin{itemize}
\item $\sigma_{1,v}$ is unramified for all finite places $v \neq v_0$.
\item $\sigma_{1,v_0} = {\rm St}\frak{o}times \mathbf{t}imesi^\varepsilon$.
\item $\sigma_{1,v}$ is a discrete series representation for all real places $v$.
\end{itemize}
Let $U$ be an open neighborhood of $0$ in ${\mathbb R}$. By \frak{c}ite[Theorem 5.8]{Shin2012}, there exists an irreducible cuspidal automorphic representation $\sigma_2$ of $\frak{o}peratorname{GL}_2({\mathbb A}_k)$ with trivial central character such that
\begin{itemize}
\item $\sigma_{2,v}$ is unramified for all finite places $v \neq v_0$.
\item $\sigma_{2,v_0} = {\rm Ind}_{B(F)}^{\frak{o}peratorname{GL}_2(F)}(|\mbox{ }|^{\lambda+\sqrt{-1}t}\mathbf{t}imesi^\varepsilon\boxtimes|\mbox{ }|^{-\lambda-\sqrt{-1}t}\mathbf{t}imesi^\varepsilon)$ for some $t \in U$.
\item $\sigma_{2,v}$ is a discrete series representation for all real places $v$.
\end{itemize}
Then $\mathbf{t}heta((\sigma_1\mathbf{t}imes\sigma_2)^\sharp)$ is an irreducible globally generic cuspidal automorphic representation of $G({\mathbb A}_k)$ with trivial central character satisfying the following conditions:
\begin{itemize}
\item $\mathbf{t}heta((\sigma_1\mathbf{t}imes\sigma_2)^\sharp)_v$ is unramified for all finite places $v \neq v_0$.
\item $\mathbf{t}heta((\sigma_1\mathbf{t}imes\sigma_2)^\sharp)_{v_0}$ is of type (IIa) with parameter $\lambda+t\sqrt{-1}$ for some $t \in U$ and sign $\varepsilon$.
\item $\mathbf{t}heta((\sigma_1\mathbf{t}imes\sigma_2)^\sharp)_v$ is of type (DS) for all real places $v$.
\end{itemize}
By Corollary \ref{C:endoscopic case}, 
\[C(\mathbf{t}heta((\sigma_1\mathbf{t}imes\sigma_2)^\sharp)_{v_0})\operatorname{pr}od_{v \mid \infty}C(\mathbf{t}heta((\sigma_1\mathbf{t}imes\sigma_2)^\sharp)_v) = C'(\mathbf{t}heta((\sigma_1\mathbf{t}imes\sigma_2)^\sharp)_{v_0})\operatorname{pr}od_{v \mid \infty}C'(\mathbf{t}heta((\sigma_1\mathbf{t}imes\sigma_2)^\sharp)_v).\]
On the other hand, by {\bf Step\,3},
\[\operatorname{pr}od_{v \mid \infty}C(\mathbf{t}heta((\sigma_1\mathbf{t}imes\sigma_2)^\sharp)_v) = \operatorname{pr}od_{v \mid \infty}C'(\mathbf{t}heta((\sigma_1\mathbf{t}imes\sigma_2)^\sharp)_v).\]
We conclude that
\[C(\mathbf{t}heta((\sigma_1\mathbf{t}imes\sigma_2)^\sharp)_{v_0}) = C'(\mathbf{t}heta((\sigma_1\mathbf{t}imes\sigma_2)^\sharp)_{v_0}).\]
Therefore, (\ref{E:main ide}) follows from Corollary \ref{C:analytic family}. 

Finally we assume $\pi$ is of type (PS). By Corollary \ref{C:analytic family} and the identity theorem for holomorphic functions, we may assume $\pi$ is tempered, that is, ${\rm Re}(\lambda_1)={\rm Re}(\lambda_2)=0$. Let $k$ be a totally real cubic field. Let $\{\infty_1,\infty_2,\infty_3\}$ be the set of real places of $k$. Let $U$ be an open neighborhood of $0$ in ${\mathbb R}$. By Proposition \ref{P:existence}, there exist irreducible cuspidal automorphic representations $\sigma_1$ and $\sigma_2$ of $\frak{o}peratorname{GL}_2({\mathbb A}_k)$ with trivial central character satisfying the following conditions:
\begin{itemize}
\item $\sigma_{i,v}$ is unramified for all finite places $v$ and $i=1,2$.
\item $\sigma_{i,\infty_1}$ and $\sigma_{i,\infty_2}$ are discrete series representations for $i=1,2$.
\item $\sigma_{1,\infty_3} = {\rm Ind}_{B({\mathbb R})}^{\frak{o}peratorname{GL}_2({\mathbb R})}(|\mbox{ }|^{(\lambda_1+\lambda_2)/2+\sqrt{-1}t_1}{\rm sgn}^\varepsilon\boxtimes|\mbox{ }|^{(-\lambda_1-\lambda_2)/2-\sqrt{-1}t_1}{\rm sgn}^\varepsilon)$ for some $t_1 \in U$.
\item $\sigma_{2,\infty_3} = {\rm Ind}_{B({\mathbb R})}^{\frak{o}peratorname{GL}_2({\mathbb R})}(|\mbox{ }|^{(\lambda_1-\lambda_2)/2+\sqrt{-1}t_2}{\rm sgn}^\varepsilon\boxtimes|\mbox{ }|^{(-\lambda_1+\lambda_2)/2-\sqrt{-1}t_2}{\rm sgn}^\varepsilon)$ for some $t_2 \in U$.
\end{itemize}
Then $\mathbf{t}heta((\sigma_1\mathbf{t}imes\sigma_2)^\sharp)$ is an irreducible globally generic cuspidal automorphic representation of $G({\mathbb A}_k)$ with trivial central character satisfying the following conditions:
\begin{itemize}
\item $\mathbf{t}heta((\sigma_1\mathbf{t}imes\sigma_2)^\sharp)_v$ is unramified for all finite places $v$.
\item $\mathbf{t}heta((\sigma_1\mathbf{t}imes\sigma_2)^\sharp)_{\infty_i}$ is of type (DS) for $i=1,2$.
\item $\mathbf{t}heta((\sigma_1\mathbf{t}imes\sigma_2)^\sharp)_{\infty_3}$ is of type (PS) with parameter $(\lambda_1+\sqrt{-1}(t_1+t_2), \lambda_2+\sqrt{-1}(t_1-t_2))$ and sign $\varepsilon$.
\end{itemize}
By Corollary \ref{C:endoscopic case}, 
\[\operatorname{pr}od_{i=1}^3C(\mathbf{t}heta((\sigma_1\mathbf{t}imes\sigma_2)^\sharp)_{\infty_i}) = \operatorname{pr}od_{i=1}^3C'(\mathbf{t}heta((\sigma_1\mathbf{t}imes\sigma_2)^\sharp)_{\infty_i}).\]
On the other hand, by {\bf Step\,3},
\[C(\mathbf{t}heta((\sigma_1\mathbf{t}imes\sigma_2)^\sharp)_{\infty_1})C(\mathbf{t}heta((\sigma_1\mathbf{t}imes\sigma_2)^\sharp)_{\infty_2}) = C'(\mathbf{t}heta((\sigma_1\mathbf{t}imes\sigma_2)^\sharp)_{\infty_1})C'(\mathbf{t}heta((\sigma_1\mathbf{t}imes\sigma_2)^\sharp)_{\infty_2}).\]
We conclude that
\[C(\mathbf{t}heta((\sigma_1\mathbf{t}imes\sigma_2)^\sharp)_{\infty_3}) = C'(\mathbf{t}heta((\sigma_1\mathbf{t}imes\sigma_2)^\sharp)_{\infty_3}).\]
Therefore, (\ref{E:main ide}) follows from Corollary \ref{C:analytic family}. This completes the proof of Proposition \ref{P:main ide}.

\section{Endoscopic lifts}\label{S:Yoshida lifts}
Let $\pi$ be an irreducible globally generic cuspidal automorphic representation of $G({\mathbb A})$ with trivial central character and paramodular conductor $\frak{n}$ satisfying the conditions in \S\,\ref{SS:main thm}. In this section, we assume $\pi$ is endoscopic. Then we state
the key ingredients (Propositions \ref{P:W(1)} and \ref{P:Rallis inner product}) of the explicit Rallis inner product formula (Proposition
\ref{P:main identity2}).

\subsection{Theta lifts}\label{SS:theta lifts}
Let $(V,Q)$ be the quadratic space over $k$ defined by $V={\rm M}_{2 , 2}$ and $Q[x]=\det(x)$. Let $\iota$ be the main involution on ${\rm M}_{2 , 2}$ defined by
\[\begin{pmatrix} x_1&x_2\\mathbf{t}imes_3&x_4\end{pmatrix}^{\iota}=\begin{pmatrix} x_4 & -x_2 \\ -x_3 & x_1\end{pmatrix}.\] The associated symmetric bilinear form is given by $(x,y) = {\rm tr}(xy^{\iota})$. 
Put
\begin{align*}
H&={\rm GO}(V), \quad H_1 = {\rm O}(V),\\
H^{\frak{c}irc} &= {\rm GSO}(V), \quad H_1^{\frak{c}irc} = {\rm SO}(V).
\end{align*}
Let $\nu : H \rightarrow \mathbb{G}_m$ be the similitude character. Let ${\bf t}$ be the involution on $\frak{o}peratorname{GL}_2\mathbf{t}imes\frak{o}peratorname{GL}_2$ defined by 
\[{\rm Ad}({\bf t})(h_1,h_2) = \left((h_2^{\iota})^{-1},(h_1^{\iota})^{-1}\right).\]
Put ${\pmb \mu}_2 = \langle{\bf t}\rangle$. We have an exact sequence
\[1 \longrightarrow   {\mathbb G}_m \stackrel{\Delta}{\longrightarrow} (\frak{o}peratorname{GL}_2\mathbf{t}imes \frak{o}peratorname{GL}_2)\rtimes {\pmb \mu}_2 \stackrel{\rho}{\longrightarrow} H \longrightarrow 1,\]
where $\Delta(a)=(a{\bf 1}_2,a{\bf 1}_2)$, $\rho(h_1,h_2){x}=h_1{ x}h_2^{-1}$, and $\rho({\bf t})x=x^{\iota}$ for $a \in {\mathbb G}_m, h_1, h_2 \in \frak{o}peratorname{GL}_2$, and $x \in V$. For $h_1,h_2 \in \frak{o}peratorname{GL}_2$, we write $\rho(h_1,h_2) = [h_1,h_2]$. Note that $\nu([h_1,h_2])=\det(h_1h_2^{-1})$. We denote by ${\bf t}$ the image of $\bf t$ in $H$ by abuse of notation, and by ${\bf t}_v$ the image of $\bf t$ in $H(k_v)$ for each place $v$ of $k$.

Let $\frak{o}mega=\frak{o}mega_{\psi,V,2}$ be the Weil representation of $\frak{o}peratorname{Sp}_4({\mathbb A})\mathbf{t}imes H_1({\mathbb A})$ on $\frak{c}alS(V^2({\mathbb A}))$ with respect to $\psi$. Let $S(V^2({\mathbb A}))$ be the subspace of $\frak{c}alS(V^2({\mathbb A}A))$
consisting of functions which correspond to polynomials in the Fock model
at the archimedean places. We extend $\frak{o}mega$ to a representation of ${\rm G}(\frak{o}peratorname{Sp}_4 \mathbf{t}imes H_1)({\mathbb A})$ as in (\ref{Weil rep on R}).

Let $\varphi \in S(V^2({\mathbb A}))$. The theta function associated to $\varphi$ is defined by
\[\Theta(g,h;\varphi) = \sum_{x \in V^2(k)}\frak{o}mega(g,h)\varphi(x)\]
for $(g,h) \in {\rm G}(\frak{o}peratorname{Sp}_4 \mathbf{t}imes H_1)({\mathbb A})$. Let $f$ be a cusp form on $H({\mathbb A})$ and let $\varphi \in S(V^2({\mathbb A}))$. For $g \in G({\mathbb A})$, choose $h \in H({\mathbb A})$ such that $\nu(h)=\nu(g)$, and put
\[\mathbf{t}heta(f,\varphi)(g) = \int_{H_1(k)\backslash H_1({\mathbb A})}f(h_1h)\Theta(g,h_1h;\varphi)\,dh_1.\]
Then $\mathbf{t}heta(f,\varphi)$ is an automorphic form on $G({\mathbb A})$. For any irreducible cuspidal automorphic representation $\sigma^{\sharp}$ of $H({\mathbb A})$ on the space $\mathcal{V}_{\sigma^\sharp}$, we define $\mathbf{t}heta(\sigma^{\sharp})$ as the automorphic representation of $G({\mathbb A})$ on the space $\mathcal{V}_{\mathbf{t}heta(\sigma^{\sharp})}$ generated by $\mathbf{t}heta(f,\varphi)$ for all $f \in \mathcal{V}_{\sigma^{\sharp}}$ and $\varphi \in S(V^2({\mathbb A}))$. 

Since we assume $\pi$ is endoscopic, there exists an irreducible unitary cuspidal automorphic representation $\sigma^{\sharp}$ of $H({\mathbb A})$ such that
\[\mathbf{t}heta(\sigma^{\sharp}) = \pi.\]
By \frak{c}ite[Lemma 2]{HST1993}, the tower property, and the cuspidality of $\pi$, we have
\begin{align}\label{E:restriction}
\mathcal{V}_{\sigma^{\sharp}}\vert_{H^\frak{c}irc({\mathbb A})} = \mathcal{V}_\sigma \frak{o}plus \mathcal{V}_{\sigma\frak{c}irc{\rm Ad}({\bf t})}
\end{align}
as spaces of functions on $H^\frak{c}irc({\mathbb A})$ for some irreducible unitary cuspidal automorphic representation $\sigma$ of $H^\frak{c}irc({\mathbb A})$ on the space $\mathcal{V}_\sigma$ with $\sigma \neq \sigma\frak{c}irc{\rm Ad}({\bf t})$. Via the isomorphism
\[H^\frak{c}irc \simeq \Delta\mathbb{G}_m\backslash(\frak{o}peratorname{GL}_2\mathbf{t}imes\frak{o}peratorname{GL}_2)\]
induced by $\rho$, we have
\[\sigma = \sigma_1 \mathbf{t}imes \sigma_2,\quad \mathcal{V}_\sigma = \mathcal{V}_{\sigma_1}\frak{o}times \mathcal{V}_{\sigma_2}\]
for some irreducible unitary cuspidal automorphic representations $\sigma_1$ and $\sigma_2$ of $\frak{o}peratorname{GL}_2({\mathbb A})$ on the spaces $\mathcal{V}_{\sigma_1}$ and $\mathcal{V}_{\sigma_2}$, respectively, with equal central characters. Let $\frak{n}_1$ and $\frak{n}_2$ be the conductors of $\sigma_1$ and $\sigma_2$, respectively. By our assumptions on $\pi$ in \S\,\ref{SS:main thm} and the condition $\sigma \neq \sigma\frak{c}irc{\rm Ad}({\bf t})$, $\sigma_{1}$ and $\sigma_2$ satisfy the following properties:
\begin{itemize}
\item $\sigma_1 \neq \sigma_2^\vee$.
\item $\sigma_1$ and $\sigma_2$ have trivial central characters.
\item $\frak{n}_1$ and $\frak{n}_2$ are square-free and coprime, and $\frak{n}_1\frak{n}_2=\frak{n}$.
\item For $v \in S({\rm DS})$, $\sigma_{1,v}$ and $\sigma_{2,v}$ are discrete series representations.
\item For $v \in S({\rm PS})$, $\sigma_{1,v}$ and $\sigma_{2,v}$ are unitary principal series representations with non-zero ${\rm SO}(2)$-invariant vectors.
\end{itemize}
For $v \in S({\rm DS})$, let $\kappa_{1,v} \in {\mathbb Z}_{\geq 1}$ and $\kappa_{2,v}\in {\mathbb Z}_{\geq 1}$ be the minimal weights of $\sigma_{1,v}$ and $\sigma_{2,v}$, respectively. Then
\[
\lambda_{1,v} = \frac{\kappa_{1,v}+\kappa_{2,v}}{2}, \quad \lambda_{2,v} =  -\frac{|\kappa_{1,v}-\kappa_{2,v}|}{2}.
\]
For $v \in S({\rm PS})$, we have 
\[\sigma_{i,v} = {\rm Ind}_{B(k_v)}^{\frak{o}peratorname{GL}_2(k_v)}(|\mbox{ }|_v^{\mu_{i,v}}{\rm sgn}^\varepsilon\boxtimes |\mbox{ }|_v^{-\mu_{i,v}}{\rm sgn}^\varepsilon)\]
for some $\varepsilon \in \{0,1\}$ and $\mu_{i,v}\in {\mathbb C}$ with $|{\rm Re}(\mu_{i,v})| < 1/2$ for $i=1,2$. Then
\[
\{ \lambda_{1,v} ,\,\lambda_{2,v}\}= \{ \mu_{1,v} + \mu_{2,v},\,\mu_{1,v} - \mu_{2,v}\},

\]
after replacing $\lambda_{i,v}$ with $-\lambda_{i,v}$ or $\mu_{i,v}$ with $-\mu_{i,v}$ if necessary.

\subsection{Automorphic forms on ${\rm GO}(V)$}

Consider non-zero automorphic forms ${\bf f}_1 \in \mathcal{V}_{\sigma_1}$ and ${\bf f}_2 \in \mathcal{V}_{\sigma_2}$ satisfying the following conditions:
\begin{itemize}
\item If $v$ is a finite place and $v \nmid \frak{n}$, then $$\sigma_{1,v}(k_1){\bf f}_1 = {\bf f}_1,\quad \sigma_{2,v}(k_2){\bf f}_2 = {\bf f}_2$$
 for $(k_1,k_2) \in \frak{o}peratorname{GL}_2(\frak{o}_v)\mathbf{t}imes \frak{o}peratorname{GL}_2(\frak{o}_v)$.
\item If $v \mid \frak{n}_1$, then
$$\sigma_{1,v}(k_1){\bf f}_1 = {\bf f}_1,\quad \sigma_{2,v}(k_2){\bf f}_2 = {\bf f}_2$$
for $(k_1,k_2) \in K_0(\varpi_v)\mathbf{t}imes \frak{o}peratorname{GL}_2(\frak{o}_v)$.
\item If $v \mid \frak{n}_2$, then
$$\sigma_{1,v}(k_1){\bf f}_1 = {\bf f}_1,\quad \sigma_{2,v}(k_2){\bf f}_2 = {\bf f}_2$$
for $(k_1,k_2) \in \frak{o}peratorname{GL}_2(\frak{o}_v)\mathbf{t}imes K_0(\varpi_v)$.
\item If $v \in S({\rm DS})$, then
$$\sigma_{1,v}(k_{\mathbf{t}heta}){\bf f}_1 = e^{\sqrt{-1}\kappa_{1,v} \mathbf{t}heta} {\bf f}_1,\quad \sigma_{2,v}(k_{\mathbf{t}heta}){\bf f}_2 = e^{\sqrt{-1}\kappa_{2,v} \mathbf{t}heta} {\bf f}_2$$
for $k_{\mathbf{t}heta} \in {\rm SO}(2)$.
\item If $v \in S({\rm PS})$, then
$$\sigma_{1,v}(k){\bf f}_1 = {\bf f}_1,\quad \sigma_{2,v}(k){\bf f}_2 = {\bf f}_2$$
for $k \in {\rm SO}(2)$.
\end{itemize} 
The conditions above characterize ${\bf f}_1$ and ${\bf f}_2$ up to scalars. We normalize ${\bf f}_1$ and ${\bf f}_2$ so that
\[
W_{{\bf f}_i}\left( \operatorname{pr}od_{v \nmid \infty}{\bf a}(\varpi_v^{-\frak{c}_v})\right)  = e^{-2\pi|S({\rm DS})|}\operatorname{pr}od_{v \in S({\rm PS})}K_{\mu_{i,v}}(2\pi),
\]
where $W_{{\bf f}_i}$ is the Whittaker function of ${\bf f}_i$ defined by 
\[W_{{\bf f}_i}(g) = \int_{k \backslash {\mathbb A}}{\bf f}_i({\bf n}(x)g)\frak{o}verline{\psi(x)}\,dx.\]
Here $dx$ is the Tamagawa measure on ${\mathbb A}$. Let ${\bf f}\in \mathcal{V}_{\sigma}$ be the automorphic form defined by
\[
{\bf f}(h)={\bf f}_1(h_1){\bf f}_2(h_2)
\]
for $h=[h_1,h_2] \in H^{\frak{c}irc}({\mathbb A})$.

Consider a non-zero automorphic form ${\bf f}^{\sharp} \in \mathcal{V}_{\sigma^{\sharp}}$ satisfying the following conditions:
\begin{itemize}
\item If $v$ is a finite place and $v\nmid \frak{n}$, then
$$\sigma^{\sharp}_v(k'){\bf f}^{\sharp}={\bf f}^{\sharp}$$
for $k' \in H(\frak{o}_v)$. 

\item If $v \mid \frak{n}_1$, then 
$$\sigma_v^{\sharp}([k_1,k_2]){\bf f}^{\sharp}={\bf f}^{\sharp}$$ 
for $(k_1,k_2) \in K_0(\varpi_v)\mathbf{t}imes \frak{o}peratorname{GL}_2(\frak{o}_v)$.
\item If $v \mid \frak{n}_2$, then
$$\sigma^{\sharp}_v([k_1,k_2]){\bf f}^{\sharp}={\bf f}^{\sharp}$$ for $(k_1,k_2) \in \frak{o}peratorname{GL}_2(\frak{o}_v)\mathbf{t}imes K_0(\varpi_v)$.
\item If $v \in S({\rm DS})$, then 
$$\sigma^{\sharp}_v([k_{\mathbf{t}heta_1},k_{\mathbf{t}heta_2}]){\bf f}^{\sharp} = e^{\sqrt{-1}(\kappa_{1,v}\mathbf{t}heta_1+\kappa_{2,v}\mathbf{t}heta_2)}{\bf f}^{\sharp}$$
for $k_{\mathbf{t}heta_1},k_{\mathbf{t}heta_2} \in {\rm SO}(2)$.
\item If $v \in S({\rm PS})$, then
$$\sigma^{\sharp}_v([k_1,k_2]){\bf f}^{\sharp}={\bf f}^{\sharp}, \quad \sigma^{\sharp}_v({\bf t}_v){\bf f}^{\sharp}={\bf f}^{\sharp}$$
for $k_1,k_2 \in {\rm SO}(2)$.
\end{itemize}
The conditions above characterize ${\bf f}^{\sharp}$ up to scalars. We normalize ${\bf f}^\sharp$ so that
$${\bf f}^{\sharp}\vert_{H^\frak{c}irc({\mathbb A})} = {\bf f}.$$

Let $L$ be the lattice of $V^2(k)$ defined by
\[L=\begin{pmatrix} \frak{n}_2 & \frak{o} \\ \frak{n} & \frak{n}_1 \end{pmatrix} \frak{o}plus \begin{pmatrix} \frak{o} & \frak{o} \\ \frak{o} & \frak{o} \end{pmatrix}.\]
Define $\varphi  = \bigotimes_v \varphi_v \in S(V^2({\mathbb A}))$ as follows:
If $v$ is a finite place, then 
\begin{align}\label{E:non-archi Schwartz fun}
\varphi_v = \mathbb{I}_{L\frak{o}times_\frak{o} \frak{o}_v}.
\end{align}
If $v \in S({\rm DS})$ and $\kappa_{1,v}\geq \kappa_{2,v}$, then
\begin{align}\label{E:archi Schwartz fun DS1}
\varphi_v(x,y) =(-\sqrt{-1}x_1-x_2-x_3+\sqrt{-1}x_4)^{\lambda_{1,v}}(y_1+\sqrt{-1}y_2-\sqrt{-1}y_3+y_4)^{-\lambda_{2,v}}e^{-\pi\,{\rm tr}(x{}^tx+y{}^ty)}.
\end{align}
If $v \in S({\rm DS})$ and $\kappa_{1,v}\leq \kappa_{2,v}$, then
\begin{align}\label{E:archi Schwartz fun DS2}
\varphi_v(x,y) =(-\sqrt{-1}x_1-x_2-x_3+\sqrt{-1}x_4)^{\lambda_{1,v}}(y_1-\sqrt{-1}y_2+\sqrt{-1}y_3+y_4)^{-\lambda_{2,v}}e^{-\pi\,{\rm tr}(x{}^tx+y{}^ty)}.
\end{align}
If $v \in S({\rm PS})$, then
\begin{align}\label{E:archi Schwartz fun PS}
\varphi_v(x,y) = e^{-\pi\,{\rm tr}(x{}^tx+y{}^ty)}.
\end{align}
Let $\frak{S}$ be the subset of places of $k$ defined by
\[\frak{S} = \{v \mbox{ }\vert\mbox{ }\sigma_v \not\simeq \sigma_v\frak{c}irc{\rm Ad}({\bf t}_v)\}.\]
Since $\sigma \neq \sigma \frak{c}irc {\rm Ad}(\bf t)$, $\frak{S}$ contains infinitely many places of $k$ by the strong multiplicity one theorem for $H^\frak{c}irc$. Recall $S({\rm DS})$ is the set of real places of type (DS). Let $S(\frak{n}) = \{v \mid \frak{n}\}$. Note that $S(\frak{n})\subseteq \frak{S}$.

\begin{prop}\label{P:W(1)}
Let $f \in \pi$ be the cusp form satisfying the conditions (\ref{E:K-type2}) and (\ref{E:normalization}).
We have
\[\mathbf{t}heta({\bf f}^{\sharp},\varphi)(g) = 2^{-|(S({\rm DS})\frak{c}up S(\frak{n}))\frak{c}ap \frak{S}|}\frak{c}dot\operatorname{pr}od_{v \in S({\rm DS})}2^{-\lambda_{1,v}- 4}\pi^{(-3\lambda_{1,v}+\lambda_{2,v}-5)/2}\frak{c}dot\operatorname{pr}od_{v \mid \frak{n}}(1+q_v)^{-1}\frak{c}dot\frak{D}^{-3/2}\frak{c}dot{\zeta(2)^{-2}}\frak{c}dot f(gg_0)\]
for $g \in G({\mathbb A})$. Here $g_0 \in G({\mathbb A})$ is defined by
\[
g_{0,v} = \begin{cases}
\operatorname{diag}( 1, 1, \varpi_v^{\frak{c}_v}, \varpi_v^{\frak{c}_v} ) & \mbox{ if $v \nmid \infty$},\\
1 & \mbox{ if $v \mid \infty$}.
\end{cases}
\]
\end{prop}

\begin{proof}
The proof will be given in $\S\,\ref{S:proof 1}$ below.
\end{proof}

\begin{prop}\label{P:Rallis inner product}
We have
\begin{align*}
\left\langle\mathbf{t}heta({\bf f}^{\sharp},\varphi),\mathbf{t}heta({\bf f}^{\sharp},\varphi)\right\rangle &= 2^{-2|(S({\rm DS})\frak{c}up S(\frak{n}))\frak{c}ap \frak{S}|}\frak{c}dot\frak{D}^{-8}\frak{c}dot\frac{4}{\zeta(2)^4}\frak{c}dot\frac{L(1,\pi,{\rm Ad})}{\Delta_{{\rm PGSp}_4}}\frak{c}dot \operatorname{pr}od_{v\mid \frak{n}}q_v^{-3}\zeta_v(1)^{-2}\zeta_v(2)\zeta_v(4)\\
&\mathbf{t}imes \operatorname{pr}od_{v \in S({\rm DS})} 2^{-\lambda_{1,v}-\lambda_{2,v}-3}(1+\lambda_{1,v}-\lambda_{2,v})^{-1}\frak{c}dot \operatorname{pr}od_{v \in S({\rm PS})} 2^{-4}.
\end{align*}
\end{prop}

\begin{proof}
The proof will be given in $\S\,\ref{S:proof 2}$ below.
\end{proof}

\section{Calculation of Whittaker functions}\label{S:cal1}
We keep the notation of $\S\,\ref{S:Yoshida lifts}$. The aim of this section is to prove Proposition \ref{P:W(1)}. We prove  it by comparing the Whittaker function of $\mathbf{t}heta({\bf f}^\sharp,\varphi)$ and the normalization of $f$ in (\ref{E:normalization}). It boils down to the calculation of certain local Whittaker functions of $\pi_v$ in terms of local integrals involving Whittaker functions of $\sigma_v$ and the Weil representation $\frak{o}mega_v$ for each place $v$.

\subsection{Measures}\label{SS:measure} Let $v$ be a place of $k$. Let $K_v$ be the maximal compact subgroup of $H_1^{\frak{c}irc}(k_v)$ defined by
\[
K_v = \begin{cases}
[{\bf d}(\varpi_v^\frak{c}),{\bf d}(\varpi_v^\frak{c})]H_1^{\frak{c}irc}(\frak{o}_v)[{\bf d}(\varpi_v^{-\frak{c}}),{\bf d}(\varpi_v^{-\frak{c}})]   & \mbox{ if $v$ is finite},\\
H_1^{\frak{c}irc}(k_v) \frak{c}ap ({\rm O}(2) \mathbf{t}imes {\rm O}(2))/\{\pm 1\} & \mbox{ if $v$ is real}.
\end{cases}
\]
We fix a Haar measure $dh_{1,v}$ on $H_1^{\frak{c}irc}(k_v)$ as follows:
\begin{itemize}
\item If $v$ is finite, the measure is normalized so that 
\begin{align}\label{E:non-archi. integration1}
{\rm vol}(K_v,dh_{1,v})=1.
\end{align} For $\phi \in L^1(H_1^{\frak{c}irc}(k_v))$, we have
\begin{align}\label{E:non-archi. integration2}
\begin{split}
&\int_{H_1^{\frak{c}irc}(k_v)}\phi(h_{1,v})\,dh_{1,v}\\
& = q_v^{-2\frak{c}_v}\int_{k_v}\int_{k_v}\int_{k_v^{\mathbf{t}imes}}\int_{k_v^{\mathbf{t}imes}}\int_{K_v}\phi([{\bf n}(x_1),{\bf n}(x_2)][{\bf m}(y_1),{\bf m}(y_2)]k)|y_1|_{v}^{-2}|y_2|_{v}^{-2}\,dk\,d^{\mathbf{t}imes}y_1\,d^{\mathbf{t}imes}y_2\,dx_1\,dx_2\\
&+ q_v^{-2\frak{c}_v}\int_{k_v}\int_{k_v}\int_{k_v^{\mathbf{t}imes}}\int_{k_v^{\mathbf{t}imes}}\int_{K_v}\phi([{\bf a}(\varpi_v),{\bf a}(\varpi_v)][{\bf n}(x_1),{\bf n}(x_2)][{\bf m}(y_1),{\bf m}(y_2)]k)|y_1|_{v}^{-2}|y_2|_{v}^{-2}\,dk\,d^{\mathbf{t}imes}y_1\,d^{\mathbf{t}imes}y_2\,dx_1\,dx_2.
\end{split}
\end{align}
\item If $v$ is real, the measure is defined so that for all $\phi\in L^1(H_1^{\frak{c}irc}({\mathbb R}))$, we have
\begin{align}\label{E:archi. integration}
\begin{split}
\int_{H_1^{\frak{c}irc}({\mathbb R})}\phi(h_{1,\infty})\,dh_{1,\infty}&=\int_{H_1^{\frak{c}irc}({\mathbb R})^0}\phi(h_{1,\infty})\,dh_{1,\infty}+\int_{H_1^{\frak{c}irc}({\mathbb R})^0}\phi([{\bf a}(-1),{\bf a}(-1)]h_{1,\infty})\,dh_{1,\infty},\\
\int_{H_1^{\frak{c}irc}({\mathbb R})^0}\phi(h_{1,\infty})\,dh_{1,\infty} &=4\int_{{\mathbb R}}\int_{{\mathbb R}}\int_{0}^{\infty}\int_{0}^{\infty}\int_{K_{\infty}^0}\phi([{\bf n}(x_1),{\bf n}(x_2)][{\bf m}(y_1),{\bf m}(y_2)]k)y_1^{-2}y_2^{-2}\,dk\,d^{\mathbf{t}imes}y_1\,d^{\mathbf{t}imes}y_2\,dx_1\,dx_2
\\
&= 16 \pi^2 \int_{K_{\infty}^0}\int_{0}^{\infty}\int_{0}^{\infty}\int_{K_{\infty}^0}\phi(k[{\bf m}(e^{t_1}),{\bf m}(e^{t_2})]k')\sinh(2t_1)\sinh(2t_2)\,dk\,dt_1\,dt_2\,dk'.
\end{split}
\end{align} 
Here $K_{\infty}^0$ and $H_1^{\frak{c}irc}({\mathbb R})^0$ are the topological identity components of $K_{\infty}$ and $H_1^{\frak{c}irc}({\mathbb R})$, respectively, and ${\rm vol}(K_{\infty}^0,dk)={\rm vol}(K_{\infty}^0,dk')=1$. We refer to \frak{c}ite[\S\,12]{IchinoIkeda2010} for the measure with respect to the Cartan decomposition.
\end{itemize}
Let $d\end{pmatrix}silon_v$ be the Haar measure on ${\pmb \mu}_2(k_v)$ such that ${\rm vol}({\pmb \mu}_2(k_v),d\end{pmatrix}silon_v)=1$. We extend the measure on $H_1^{\frak{c}irc}(k_v)$ to a measure on $H_1(k_v)$ by
\[
\int_{H_1(k_v)}\phi(h_{1,v})\,dh_{1,v}  =  \int_{{\pmb \mu}_2(k_v)}\int_{H_1^{\frak{c}irc}(k_v)}\phi(h_{1,v}\end{pmatrix}silon_v)\,dh_{1,v}\,d\end{pmatrix}silon_v
\]
for $\phi \in L^1(H_1(k_v))$.

Let $dh_1$ be the Tamagawa measure on $H_1({\mathbb A})$. Note that ${\rm vol}(H_1(k)\backslash H_1({\mathbb A}))=1$ and 
\begin{align}\label{E:ratio of measures}
dh_1 = \frak{D}^{-3}\frak{c}dot\zeta(2)^{-2}\frak{c}dot\operatorname{pr}od_{v}dh_{1,v}.
\end{align}
Let $d\end{pmatrix}silon =\operatorname{pr}od_v d\end{pmatrix}silon_v$ be the Tamagawa measure on ${\pmb \mu}_2({\mathbb A})$.

\subsection{Whittaker functions}
Recall $\frak{S}$ is the subset of places of $k$ defined by
\[\frak{S} = \{v \mbox{ }\vert\mbox{ }\sigma_v \not\simeq \sigma_v\frak{c}irc{\rm Ad}({\bf t}_v)\}.\]
Let $v$ be a place of $k$. Let $\mathcal{V}_{1,v}$ and $\mathcal{V}_{2,v}$ be the spaces of $\sigma_{1,v}$ and $\sigma_{2,v}$, respectively. Then $\mathcal{V}_v = \mathcal{V}_{1,v}\frak{o}times\mathcal{V}_{2,v}$ is the space of $\sigma_v$. We define an irreducible admissible representation $\sigma_v^{\sharp}$ of $H(k_v)$ as follows:
\begin{itemize}
\item $v \notin \frak{S}$: In this case, $\sigma_{1,v} \simeq \sigma_{2,v}$. We take $\mathcal{V}_{1,v} = \mathcal{V}_{2,v}$ and define $\mathcal{V}_v^{\sharp} = \mathcal{V}_v$. The representation $\sigma_v^{\sharp}$ of $H(k_v)$ on $\mathcal{V}_v^{\sharp}$ is defined by
\begin{align*}
\begin{split}
\sigma_v^{\sharp}([h_1,h_2])(v_1\frak{o}times v_2) &= \sigma_{1,v}(h_1)v_1\frak{o}times \sigma_{2,v}(h_2)v_2,\\
\sigma_v^{\sharp}({\bf t}_v)(v_1\frak{o}times v_2) & = v_2\frak{o}times v_1
\end{split}
\end{align*}
for $h_1,h_2 \in \frak{o}peratorname{GL}_2(k_v)$ and $v_1\frak{o}times v_2 \in \mathcal{V}_v^{\sharp}$.
\item $v \in \frak{S}$: In this case, define $\sigma_v^{\sharp}= {\rm Ind}_{H^{\frak{c}irc}(k_v)}^{H(k_v)}\sigma_v$. The induced representation is realized on $\mathcal{V}_v^{\sharp} = \mathcal{V}_v \frak{o}plus \mathcal{V}_v$, where the action is defined by
\begin{align*}
\begin{split}
\sigma_v^{\sharp}(h)(v_1, v_2) &= (\sigma_v(h)v_1 ,\sigma_v({\rm Ad}({\bf t}_v)h)v_2),\\
\sigma_v^{\sharp}({\bf t}_v)(v_1, v_2) &= (v_2, v_1)
\end{split}
\end{align*}
for $h \in H^{\frak{c}irc}(k_v)$ and $(v_1, v_2) \in \mathcal{V}_v^{\sharp}.$
\end{itemize}
 
\subsubsection{Local models} 
Let $v$ be place of $k$. For $i=1,2$, let $\mathcal{V}_{i,v}=\mathcal{W}(\sigma_{i,v},\psi_v)$ be the space of Whittaker functions of $\sigma_{i,v}$ with respect to $\psi_v$. Consider a non-zero Whittaker function $W_{1,v} \in \mathcal{V}_{1,v}$ and $W_{2,v} \in \mathcal{V}_{2,v}$ satisfying the following conditions:
\begin{itemize}
\item If $v$ is a finite place and $v \nmid \frak{n}$, then $$\sigma_{1,v}(k_1){W}_{1,v} = {W}_{1,v},\quad \sigma_{2,v}(k_2){W}_{2,v} = {W}_{2,v}$$
 for $(k_1,k_2) \in \frak{o}peratorname{GL}_2(\frak{o}_v)\mathbf{t}imes \frak{o}peratorname{GL}_2(\frak{o}_v)$.
\item If $v \mid \frak{n}_1$, then
$$\sigma_{1,v}(k_1){W}_{1,v} = {W}_{1,v},\quad \sigma_{2,v}(k_2){W}_{2,v} = {W}_{2,v}$$
for $(k_1,k_2) \in K_0(\varpi_v)\mathbf{t}imes \frak{o}peratorname{GL}_2(\frak{o}_v)$.
\item If $v \mid \frak{n}_2$, then
$$\sigma_{1,v}(k_1){W}_{1,v} = {W}_{1,v},\quad \sigma_{2,v}(k_2){W}_{2,v} = {W}_{2,v}$$
for $(k_1,k_2) \in \frak{o}peratorname{GL}_2(\frak{o}_v)\mathbf{t}imes K_0(\varpi_v)$.
\item If $v \in S({\rm DS})$, then
$$\sigma_{1,v}(k_{\mathbf{t}heta}){W}_{1,v} = e^{\sqrt{-1}\kappa_{1,v} \mathbf{t}heta} {W}_{1,v},\quad \sigma_{2,v}(k_{\mathbf{t}heta}){W}_{2,v} = e^{\sqrt{-1}\kappa_{2,v} \mathbf{t}heta} {W}_{2,v}$$
for $k_{\mathbf{t}heta} \in {\rm SO}(2)$.
\item If $v \in S({\rm PS})$, then
$$\sigma_{1,v}(k){W}_{1,v} = {W}_{1,v},\quad \sigma_{2,v}(k){W}_{2,v} = {W}_{2,v}$$
for $k \in {\rm SO}(2)$.
\end{itemize}
The conditions above characterize $W_{1,v}$ and $W_{2,v}$ up to scalars. We normalize $W_{1,v}$ and $W_{2,v}$ as follows:
\begin{itemize}
\item If $v$ is a finite place, then
$$W_{1,v}({\bf a}(\varpi_v^{-\frak{c}_v}))=W_{2,v}({\bf a}(\varpi_v^{-\frak{c}_v}))=1.$$
\item If $v \in S({\rm DS})$, then
$$W_{1,v}(1)=W_{2,v}(1)=e^{-2\pi}.$$
\item If $v \in S({\rm PS})$, then
$$W_{1,v}(1)=K_{\mu_{1,v}}(2\pi),\quad W_{2,v}(1)=K_{\mu_{2,v}}(2\pi).$$
\end{itemize}
Let $W_v$ be the Whittaker function on $H^{\frak{c}irc}(k_v)$ defined by 
\begin{align}\label{E:Whittaker newform}
W_v([h_1,h_2])=W_{1,v}(h_1)W_{2,v}(h_2)
\end{align}
for $h_1,h_2 \in \frak{o}peratorname{GL}_2(k_v)$.

Fix isomorphisms $\sigma \simeq \bigotimes_v \sigma_{v}$ and $\sigma^{\sharp}\simeq \bigotimes_v \sigma_v^{\sharp}$ such that
\begin{align}\label{E:iso}
\begin{split}
{\bf f} &\longmapsto \bigotimes_vW_v,\\
{\bf f}^{\sharp} & \longmapsto \left(\bigotimes_{\scriptstyle{v \in S({\rm DS})\frak{c}up S(\frak{n})} \atop \scriptstyle{v\in\frak{S}} }(W_v,0)\right)\frak{o}times \left(\bigotimes_{\scriptstyle{v \notin S({\rm DS})\frak{c}up S(\frak{n})}\atop\scriptstyle{ v \in \frak{S}} }(W_v,W_v)\right) \frak{o}times \left(\bigotimes_{v \notin \frak{S}} W_v\right).
\end{split}
\end{align}
\subsubsection{Global Whittaker functions}
If $R$ is a set of places of $k$, denote by ${\bf t}_R \in {\pmb \mu}_2({\mathbb A})$ the element such that
\[
 {\bf t}_{R,v}=
 \begin{cases}  
{\bf t}_v   & \mbox{ if $v \in R$},\\
1 & \mbox{ if $v \notin R$}.
 \end{cases} 
\]
For an automorphic form $f$ on $H({\mathbb A})$ and a set $R$ of places of $k$, let $f_R$ be the automorphic form on $H^\frak{c}irc({\mathbb A})$ defined by
\[f_R(h)=f(h{\bf t}_R)\]
for $h \in H^\frak{c}irc({\mathbb A})$.

Let $f$ be a cusp form on $H^\frak{c}irc({\mathbb A})$ and let $\varphi \in S(V^2({\mathbb A}))$. Define Whittaker functions $W_f$ and $W_{\mathbf{t}heta(f,\varphi)}$ by
\begin{align*}
W_{f}(h) &= \int_{(k\backslash {\mathbb A})^2}f([{\bf n}(x),{\bf n}(y)]h)\frak{o}verline{\psi(x+y)}\,dx\,dy,\\
 W_{\mathbf{t}heta(f, \varphi)}(g) &= \int_{U(k) \backslash U({\mathbb A})} \mathbf{t}heta(f, \varphi)(ug)
 \frak{o}verline{\psi_U(u)} \, du
\end{align*}
for $g \in G({\mathbb A})$ and $h \in H^\frak{c}irc({\mathbb A})$.
Here $dx,dy,du$ are the Tamagawa measures.

Let
\[\Delta N = \{ [{\bf n}(x),{\bf n}(-x)] \in H_1^{\frak{c}irc} \mbox{ }\vert\mbox{ }x \in \mathbb{G}_a\}.\]

\begin{lemma}\label{L:Whittaker function} Let $\varphi \in S(V^2({\mathbb A}))$ and let $f$ be a cusp form on $H({\mathbb A})$. For $(g,h) \in {\rm G}(\frak{o}peratorname{Sp}_4 \mathbf{t}imes H_1)({\mathbb A})$ with $h \in H^{\frak{c}irc}({\mathbb A})$, we have
\[
 W_{\mathbf{t}heta(f, \varphi)}(g) = 2^{-1-|T|}\sum_{R\subseteq T}
 \int_{\Delta N({\mathbb A}) \backslash H_1^{\frak{c}irc}({\mathbb A})} W_{f_R}(h_1\frak{c}dot{\rm Ad}({\bf t}_R)h)
 \frak{o}mega(g, h_1{\bf t}_R h) \varphi ({\bf x}_0,{\bf y}_0) \, dh_1,
\]
where $T$ is a sufficiently large finite set of places of $k$, and
\[
 {\bf x}_0 =
 \begin{pmatrix}
  0 & -1 \\
  0 & 0
 \end{pmatrix},\quad {\bf y}_0={\bf a}(-1).
\]
\end{lemma}

\begin{proof}
Note that
\[
 \mathbf{t}heta(f, \varphi)(g) = 2^{-1} 
 \int_{{\pmb \mu}_2({\mathbb A})}\int_{H_1^{\frak{c}irc}(k) \backslash H_1^{\frak{c}irc}({\mathbb A})} f(h_1\end{pmatrix}silon h) \Theta(g, h_1\end{pmatrix}silon h; \varphi) \, dh_1\,d\end{pmatrix}silon.
\]
Since 
\[
 \frak{o}mega(u, 1) \varphi(x, y) = \varphi(x, xu_0 + y)
 \psi(\det(x) u_1 + (x, y) u_2 + \det(y) u_3)
\]
for 
\[
u = \begin{pmatrix}
 1 & 0 & u_1 & u_2 \\
 0 & 1 & u_2 & u_3 \\
 0 & 0 & 1 & 0 \\
 0 & 0 & 0 & 1
\end{pmatrix}
\begin{pmatrix}
 1 & u_0 & 0 & 0 \\
 0 & 1 & 0 & 0 \\
 0 & 0 & 1 & 0 \\
 0 & 0 & -u_0 & 1
\end{pmatrix},
\]
we have
\begin{align*}
W_{\mathbf{t}heta(f, \varphi)}(g) &= 2^{-1} \int_{{\pmb \mu}_2({\mathbb A})}\int_{H_1^{\frak{c}irc}(k) \backslash H_1^{\frak{c}irc}({\mathbb A})} \int_{(k \backslash {\mathbb A})^4}
 f(h_1\end{pmatrix}silon h ) \sum_{x, y \in V(k)} \frak{o}mega(g, h_1\end{pmatrix}silon h) \varphi(x, x u_0 + y) \\
 & \quad\quad\quad\quad\quad\quad\quad\mathbf{t}imes \psi(\det(x) u_1 + (x, y) u_2 + (\det(y) + 1) u_3 + u_0) \, du \, dh_1\,d\end{pmatrix}silon.
\end{align*}
Hence, putting
\begin{align*}
 X_0 & = \left\{ (0, y) \in V^2 \, | \, \det(y) = -1 \right\}, \\
 X_1 & = \left\{ (x, y) \in V^2 \, | \, \det(x) = 0, x \ne 0, 
 (x, y) = 0, \det(y) = -1 \right\},
\end{align*}
and
\[
 I_i = \int_{{\pmb \mu}_2({\mathbb A})}\int_{H_1^{\frak{c}irc}(k) \backslash H_1^{\frak{c}irc}({\mathbb A})} \int_{k \backslash {\mathbb A}}
 f(h_1\end{pmatrix}silon h) \sum_{(x, y) \in X_i(k)} \frak{o}mega(g, h_1\end{pmatrix}silon h) \varphi(x, x u_0 + y) \psi(u_0)
 \, du_0 \, dh_1\,d\end{pmatrix}silon,
\]
we have
\[
 W_{\mathbf{t}heta(f, \varphi)}(g) = 2^{-1}(I_0+I_1).
\]
In fact, it follows from the cuspidality of $f$ that
\[
 I_0 = \int_{{\pmb \mu}_2({\mathbb A})}\int_{H_1^{\frak{c}irc}(k) \backslash H_1^{\frak{c}irc}({\mathbb A})} \int_{k \backslash {\mathbb A}}
 f(h_1\end{pmatrix}silon h) \sum_{y \in \frak{o}peratorname{SL}_2(k)} \frak{o}mega(g, h_1\end{pmatrix}silon h) \varphi(0, y{\bf a}(-1)) \psi(u_0)
 \, du_0 \, dh_1\,d\end{pmatrix}silon = 0.
\]
It remains to compute $I_1$.

We claim that the map $h_1 \mapsto h_1 ({\bf x}_0, {\bf y}_0)$ induces an isomorphism
\[
 \Delta N \backslash H_1^{\frak{c}irc} \longrightarrow X_1.
\]
Obviously, $H_1^{\frak{c}irc}$ acts on $X_1$.
We first show that this action is transitive.
Let $(x, y) \in X_1$ and write \[y = \begin{pmatrix} y_1 & y_2 \\ y_3 & y_4\end{pmatrix}.\]
Since the rank of $x$ is $1$, there exists $h_1 \in H_1^{\frak{c}irc}$ such that 
$h_1x = {\bf x}_0$.
Hence we may assume that $x = {\bf x}_0$.
Then $(x, y) = y_3 = 0$.
Thus we have
\[
 y =
 \begin{pmatrix}
  y_1 & y_2 \\
  0 & -y_1^{-1}
 \end{pmatrix}.
\]
Put 
\[
 h_1 = \left[
 \begin{pmatrix}
  1 &  y_1 y_2 \\
  0 & -y_1
 \end{pmatrix},
 \begin{pmatrix}
  -y_1 & 0 \\
  0 & 1
 \end{pmatrix}
 \right].
\]
Then we have $h_1({\bf x}_0, y) = ({\bf x}_0,{\bf y}_0)$.
We next show that the stabilizer of this action is 
$ \Delta N$ in $H_1^{\frak{c}irc}$.
Obviously, $\Delta N$ fixes $({\bf x}_0,{\bf y}_0)$.
Assume that $h_1({\bf x}_0,{\bf y}_0) = ({\bf x}_0,{\bf y}_0)$ with $h_1 = [g_1, g_2] \in H_1^{\frak{c}irc}$.
Then $(g_1 {\bf x}_0 g_2^{-1}, g_1 {\bf y}_0g_2^{-1}) = ({\bf x}_0,{\bf y}_0)$.
Write
\[
 g_1 =
 \begin{pmatrix}
  a & b \\
  c & d
 \end{pmatrix}.
\]
It follows from $g_1 \mathbf{y}_0 = \mathbf{y}_0 g_2$ that \[g_2 = \begin{pmatrix} a & -b \\ -c & d \end{pmatrix},\] which combined with $g_1 \mathbf{x}_0 = \mathbf{x}_0 g_2$ implies that $a=d$, $c=0$.
Hence $h_1 \in \Delta N$.
This completes the proof of the claim.

If follows from the claim that
\[
 I_1 = \int_{{\pmb \mu}_2({\mathbb A})}\int_{\Delta N({\mathbb A}) \backslash H_1^{\frak{c}irc}({\mathbb A})}
 \int_{\Delta N(k) \backslash \Delta N({\mathbb A})} \int_{k \backslash {\mathbb A}}
 f(n h_1\end{pmatrix}silon h) \frak{o}mega(g, h_1\end{pmatrix}silon h) \varphi({\bf x}_0, {\bf x}_0 u_0 + {\bf y}_0) \psi(u_0)
 \, du_0 \, dn \, dh_1\,d\end{pmatrix}silon. 
\]
Since 
\[
 {\bf x}_0 u_0 + {\bf y}_0 = 
 {\bf n}(-u_0){\bf y}_0,
\]
we have
\begin{align*}
 & \int_{\Delta N(k) \backslash \Delta N({\mathbb A})} \int_{k \backslash {\mathbb A}}
 f(n h_1\end{pmatrix}silon h) \frak{o}mega(g, h_1\end{pmatrix}silon h) \varphi({\bf x}_0, {\bf x}_0 u_0 + {\bf y}_0) \psi(u_0)
 \, du_0 \, dn \\
 & = \int_{(k \backslash {\mathbb A})^2}
 f([{\bf n}(x), {\bf n}(-x)] h_1\end{pmatrix}silon h) \frak{o}mega(g, h_1\end{pmatrix}silon h) \varphi({\bf x}_0, {\bf n}(-u_0){\bf y}_0) \psi(u_0) \, du_0 \, dx.
\end{align*}
Note that
\[
 \frak{o}mega(g, h_1\end{pmatrix}silon h) \varphi({\bf x}_0, {\bf n}(-u_0){\bf y}_0)
 = \frak{o}mega(g, [{\bf n}(u_0), 1] h_1\end{pmatrix}silon h) \varphi({\bf x}_0,{\bf y}_0).
\]
Hence $I_1$ is equal to 
\begin{align*}
 & \int_{{\pmb \mu}_2({\mathbb A})}\int_{\Delta N({\mathbb A}) \backslash H_1^{\frak{c}irc}({\mathbb A})} \int_{(k \backslash {\mathbb A})^2}
 f([{\bf n}(x-u_0), {\bf n}(-x)] h_1\end{pmatrix}silon h) \frak{o}mega(g, h_1\end{pmatrix}silon h) \varphi({\bf x}_0,{\bf y}_0) \psi(u_0)
 \, du_0 \, dx  \, dh_1\,d\end{pmatrix}silon \\
 &= \int_{{\pmb \mu}_2({\mathbb A})}\int_{\Delta N({\mathbb A}) \backslash H_1^{\frak{c}irc}({\mathbb A})} \int_{(k \backslash {\mathbb A})^2}
 f([{\bf n}(-u_0), {\bf n}(-x)] h_1\end{pmatrix}silon h) \frak{o}mega(g, h_1\end{pmatrix}silon h) \varphi({\bf x}_0,{\bf y}_0) \psi(u_0 + x)
 \, du_0 \, dx  \, dh_1\,d\end{pmatrix}silon \\
 &= \int_{{\pmb \mu}_2({\mathbb A})}\int_{\Delta N({\mathbb A}) \backslash H_1^{\frak{c}irc}({\mathbb A})} \int_{(k\backslash {\mathbb A})^2}f([{\bf n}(x),{\bf n}(y)]h_1\end{pmatrix}silon h)\frak{o}verline{\psi(x+y)} \frak{o}mega(g, h_1\end{pmatrix}silon h) \varphi({\bf x}_0,{\bf y}_0) 
 \,dx\,dy\, dh_1\, d\end{pmatrix}silon.
\end{align*}
This completes the proof.
\end{proof}

\begin{lemma}\label{L:global Whittaker}
Let $\varphi=\bigotimes_v\varphi_v \in S(V^2({\mathbb A}))$ be the Schwartz function defined in (\ref{E:non-archi Schwartz fun})-(\ref{E:archi Schwartz fun PS}). Let $g \in \frak{o}peratorname{Sp}_4({\mathbb A})$. We have
\[
W_{\mathbf{t}heta({\bf f}^{\sharp},\varphi)}(g) = 2^{-1-|(S({\rm DS})\frak{c}up S(\frak{n}))\frak{c}ap \frak{S}|}\frak{c}dot \frak{D}^{-5/2}\frak{c}dot \zeta(2)^{-2}\frak{c}dot\left[\operatorname{pr}od_v \mathcal{W}_v^+(g_v) + \operatorname{pr}od_v \mathcal{W}_v^-(g_v) \right],
\]
where  
\begin{align}\label{E:local Whi.}
\begin{split}
\mathcal{W}_v^+(g_v) &= \int_{\Delta N(k_v)\backslash H_1^{\frak{c}irc}(k_v)}W_v(h_{1,v})\frak{o}mega_v(g_v,h_{1,v})\varphi_v({\bf x}_0,{\bf y}_0)\,d\bar{h}_{1,v},\\
 \mathcal{W}_v^-(g_v) &= \int_{\Delta N(k_v)\backslash H_1^{\frak{c}irc}(k_v)}W_v({\rm Ad}({\bf t}_v)h_{1,v})\frak{o}mega_v(g_v,h_{1,v}{\bf t}_{v})\varphi_v({\bf x}_0,{\bf y}_0)\,d\bar{h}_{1,v}.
\end{split}
\end{align}
Here $d\bar{h}_{1,v}$ is the quotient measure defined by the measures on $\Delta N(k_v)$ and $H_1^\frak{c}irc(k_v)$ in \S\,\ref{SS:measures} and \S\,\ref{SS:measure}, respectively.
\end{lemma}

\begin{proof}
Put $S' = (S({\rm DS})\frak{c}up S(\frak{n}))\frak{c}ap \frak{S}$. Let $R$ be a set of places of $k$. By (\ref{E:restriction}) and the normalization of isomorphisms in (\ref{E:iso}), 

\[
{\bf f}_R^\sharp = \begin{cases}
{\bf f} & \mbox{ if $S' \frak{c}ap R= \varnothing$},\\
{\bf f}\frak{c}irc{\rm Ad}({\bf t}) & \mbox{ if $S' \subseteq R$},\\
0 & \mbox{ otherwise}.
\end{cases}
\]

It follows that
\begin{align}\label{E:restriction of Whi.}
W_{{\bf f}_R^\sharp} = 
\begin{cases}
\displaystyle{\operatorname{pr}od_v W_v} & \mbox{ if $S' \frak{c}ap R =   \varnothing$},\\
\displaystyle{\operatorname{pr}od_v W_v\frak{c}irc{\rm Ad}({\bf t}_v)} & \mbox{ if $S' \subseteq R$},\\
0 & \mbox{ otherwise}.
\end{cases}

\end{align}
Note that $\frak{o}mega_v(1,{\bf t}_v)\varphi_v = \varphi_v$ for $v \notin S'$. Hence we conclude from (\ref{E:restriction of Whi.}) that for $g \in \frak{o}peratorname{Sp}_4({\mathbb A})$, we have
\[
\int_{\Delta N({\mathbb A}) \backslash H_1^\frak{c}irc({\mathbb A})}W_{{\bf f}_R^\sharp}(h_1)\frak{o}mega(g,h_1{\bf t}_R)\varphi({\bf x}_0,{\bf y}_0)\,dh_1 = \frak{D}^{-5/2}\zeta(2)^{-2}\frak{c}dot\begin{cases}
\displaystyle{\operatorname{pr}od_v \mathcal{W}_v^+(g_v)}  & \mbox{ if $S'\frak{c}ap R = \varnothing$},\\
\displaystyle{\operatorname{pr}od_v \mathcal{W}_v^-(g_v)} & \mbox{ if $S' \subseteq R$},\\
0 & \mbox{ otherwise}.
\end{cases} 
\]

Here the extra factor $\frak{D}^{-5/2}\zeta(2)^{-2}$ is due to the ratio of the Tamagawa measures on $\Delta N({\mathbb A})$ and $H_1^\frak{c}irc({\mathbb A})$ to the corresponding standard measures defined in \S\,\ref{SS:measures} and \S\,\ref{SS:measure}, respectively.
The assertion then follows from Lemma \ref{L:Whittaker function}. This completes the proof.
\end{proof}

\subsection{Calculation of local Whittaker functions}

\subsubsection{Non-archimedean cases}
Let $v$ be a finite place of $k$ and $\varphi_v \in S(V^2(k_v))$ the Schwartz function defined in (\ref{E:non-archi Schwartz fun}). 
If $v \nmid \frak{n}$, then 
\begin{align}\label{E:equivariant property of test vector case v=p not divide N_1N_2}
\frak{o}mega_v(k',[k_1,k_2])\varphi_v=\varphi_v
\end{align}
for $k' \in {\rm diag}(1,1,\varpi_v^{\frak{c}_v},\varpi_v^{\frak{c}_v})G(\frak{o}_v){\rm diag}(1,1,\varpi_v^{-\frak{c}_v},\varpi_v^{-\frak{c}_v})$ and $(k_1,k_2) \in \frak{o}peratorname{GL}_2(\frak{o}_v)\mathbf{t}imes \frak{o}peratorname{GL}_2(\frak{o}_v)$ such that $\nu(k')=\det(k_1k_2^{-1})$. If $v \mid \frak{n}_1$, then
\begin{align}\label{E:equivariant property of test vector case v=p divide N_1}
\frak{o}mega_v(k',[k_1,k_2])\varphi_v = \varphi_v
\end{align}
for $k' \in {\rm diag}(1,1,\varpi_v^{\frak{c}_v},\varpi_v^{\frak{c}_v}){\rm K}(\varpi_v){\rm diag}(1,1,\varpi_v^{-\frak{c}_v},\varpi_v^{-\frak{c}_v})$ and $(k_1,k_2) \in K_0(\varpi_v)\mathbf{t}imes \frak{o}peratorname{GL}_2(\frak{o}_v)$ such that $\nu(k')=\det(k_1k_2^{-1})$. If $v\mid \frak{n}_2$, then 
\begin{align}\label{E:equivariant property of test vector case v=p divide N_2}
\frak{o}mega_v(k',[k_1,k_2])\varphi_v = \varphi_v
\end{align}
for $k' \in {\rm diag}(1,1,\varpi_v^{\frak{c}_v},\varpi_v^{\frak{c}_v}){\rm K}(\varpi_v){\rm diag}(1,1,\varpi_v^{-\frak{c}_v},\varpi_v^{-\frak{c}_v})$ and $(k_1,k_2) \in \frak{o}peratorname{GL}_2(\frak{o}_v)\mathbf{t}imes K_0(\varpi_v)$ such that $\nu(k')=\det(k_1k_2^{-1})$.

Let $\mathcal{W}^{\pm}_v$ be the local Whittaker functions defined in (\ref{E:local Whi.}).
\begin{lemma}\label{L:local Whittaker finite 1}
Assume $v$ is a finite place of $k$ and $ v \nmid \frak{n}$. We have
\[\mathcal{W}_v^+(\operatorname{diag}( \varpi_v^{-\frak{c}_v}, 1, \varpi_v^{\frak{c}_v}, 1 ))=\mathcal{W}_v^-(\operatorname{diag}( \varpi_v^{-\frak{c}_v}, 1, \varpi_v^{\frak{c}_v}, 1 ))=q_v^{\frak{c}_v}.\]
\end{lemma}

\begin{proof}
We drop the subscript $v$ for brevity. Let 
\[g = \operatorname{diag}( \varpi^{-\frak{c}}, 1, \varpi^{\frak{c}}, 1 ) \in \frak{o}peratorname{Sp}_4(k_v),\quad h = [{\bf d}(\varpi^{\frak{c}}),{\bf d}(\varpi^{\frak{c}})] \in H_1^\frak{c}irc(k_v).\]
By (\ref{E:equivariant property of test vector case v=p not divide N_1N_2}) and our normalization of the Haar measure on $H_1^{\frak{c}irc}(k_v)$ in (\ref{E:non-archi. integration2}), we have
\[
\mathcal{W}^+(g) = q^{-2\frak{c}}\left(Z^{(1)}+ q\frak{c}dot Z^{(2)}\right),

\]
where
\begin{align*}
Z^{(1)} &= \int_{k_v}\int_{k_v^\mathbf{t}imes}\int_{k_v^\mathbf{t}imes}W([1,{\bf n}(x)][{\bf m}(y_1),{\bf m}(y_2)]h)\\
&\mathbf{t}imes\frak{o}mega(g,[1,{\bf n}(x)][{\bf m}(y_1),{\bf m}(y_2)]h)\varphi({\bf x}_0,{\bf y}_0)|y_1|^{-2}|y_2|^{-2}\,d^{\mathbf{t}imes}y_1\,d^\mathbf{t}imes y_2\,dx,\\
Z^{(2)} &= \int_{k_v}\int_{k_v^\mathbf{t}imes}\int_{k_v^\mathbf{t}imes}W([{\bf a}(\varpi),{\bf a}(\varpi)][1,{\bf n}(x)][{\bf m}(y_1),{\bf m}(y_2)]h)\\
&\mathbf{t}imes\frak{o}mega(g,[{\bf a}(\varpi),{\bf a}(\varpi)][1,{\bf n}(x)][{\bf m}(y_1),{\bf m}(y_2)]h)\varphi({\bf x}_0,{\bf y}_0)|y_1|^{-2}|y_2|^{-2}\,d^{\mathbf{t}imes}y_1\,d^\mathbf{t}imes y_2\,dx.\\

\end{align*} 
For $h_1 \in H_1(k_v)$, we have
\[
\frak{o}mega(g,h_1)\varphi({\bf x}_0,{\bf y}_0) = q^{2\frak{c}}\frak{c}dot\varphi(h_1^{-1}\frak{c}dot (\varpi^{-\frak{c}} {\bf x}_0,{\bf y}_0)).
\]

Let $h_1 = [1,{\bf n}(x)][{\bf m}(y_1),{\bf m}(y_2)]h$ with $x \in k_v$, $y_1,y_2 \in k_v^{\mathbf{t}imes}$. Then
\begin{align*}
\frak{o}mega(g,h_1)\varphi({\bf x}_0,{\bf y}_0)&=q^{2\frak{c}}\frak{c}dot\varphi\left(\begin{pmatrix} 0 & -y_1^{-1}y_2^{-1}\\ 0 & 0 \end{pmatrix}, \begin{pmatrix} -y_1^{-1}y_2 & -y_1^{-1}y_2^{-1}x\varpi^{\frak{c}} \\ 0 & y_1y_2^{-1}\end{pmatrix} \right),\\
\frak{o}mega(g,[{\bf a}(\varpi),{\bf a}(\varpi)]h_1)\varphi({\bf x}_0,{\bf y}_0)&=q^{2\frak{c}}\frak{c}dot\varphi\left(\begin{pmatrix} 0 & -y_1^{-1}y_2^{-1}\varpi^{-1}\\ 0 & 0 \end{pmatrix}, \begin{pmatrix} -y_1^{-1}y_2 & -y_1^{-1}y_2^{-1}x\varpi^{\frak{c}} \\ 0 & y_1y_2^{-1}\end{pmatrix} \right).
\end{align*}
Therefore, 
\begin{align*}
\frak{o}mega(g,h_1)\varphi({\bf x}_0,{\bf y}_0) \neq 0 & \mbox{ if and only if }y_1y_2^{-1} \in \frak{o}^{\mathbf{t}imes}, y_1^{-1} \in \frak{o} ,\mbox{ and }x \in y_1y_2\varpi^{-\frak{c}}\frak{o},\\
\frak{o}mega(g,[{\bf a}(\varpi),{\bf a}(\varpi)]h_1)\varphi({\bf x}_0,{\bf y}_0) \neq 0 &\mbox{ if and only if }y_1y_2^{-1} \in \frak{o}^{\mathbf{t}imes},
 y_1^{-1} \in \varpi\frak{o},\mbox{ and }x \in y_1y_2\varpi^{-\frak{c}}\frak{o}.
\end{align*}
On the other hand, the functions $W_{1}({\bf a}(y))$ and $W_{2}({\bf a}(y))$ are both supported in $\varpi^{-\frak{c}}\frak{o}$. We conclude that 
\begin{align*}
&W(h_1)\frak{o}mega(g,h_1)\varphi({\bf x}_0,{\bf y}_0) \neq 0 \mbox{ if and only if }y_1,y_2\in\frak{o}^{\mathbf{t}imes}\mbox{ and }x\in \varpi^{-\frak{c}}\frak{o},\\
&W([{\bf a}(\varpi),{\bf a}(\varpi)]h_1)\frak{o}mega(g,[{\bf a}(\varpi),{\bf a}(\varpi)]h_1)\varphi({\bf x}_0,{\bf y}_0)=0.
\end{align*}
Hence 
\begin{align*}
Z^{(1)} &= q^{2\frak{c}}\frak{c}dot W([{\bf a}(\varpi^{-\frak{c}}),{\bf a}(\varpi^{-\frak{c}})])\frak{c}dot{\rm vol}(\varpi^{-\frak{c}}\frak{o}){\rm vol}(\frak{o}^\mathbf{t}imes)^2 = q^{3\frak{c}},\\ Z^{(2)} &=0.
\end{align*}
A similar calculation shows that $\mathcal{W}^-(g)=\mathcal{W}^+(g).$ This completes the proof.

\end{proof}

\begin{lemma}\label{L:local Whittaker finite 2}
Assume $v \mid \frak{n}$. We have 
\[\mathcal{W}_v^+(\operatorname{diag}( \varpi_v^{-\frak{c}_v}, 1, \varpi_v^{\frak{c}_v}, 1 ))=\mathcal{W}_v^-(\operatorname{diag}( \varpi_v^{-\frak{c}_v}, 1, \varpi_v^{\frak{c}_v}, 1 ))=q_v^{\frak{c}_v}(1+q_v)^{-1}.\]
\end{lemma}

\begin{proof}
The calculations for $v \mid \frak{n}_1$ and $v\mid \frak{n}_2$ are similar and we assume $v \mid \frak{n}_1$. We drop the subscript $v$ for brevity. Let $\mathcal{U}$ be the open compact subgroup of $H_1^{\frak{c}irc}(k_v)$ defined by
\[\mathcal{U}=H_1^{\frak{c}irc}(k_v)\frak{c}ap (K_0(\varpi)\mathbf{t}imes \frak{o}peratorname{GL}_2(\frak{o}))/\frak{o}^{\mathbf{t}imes}.\]
Note that
\[\mathcal{C}=\left\{[k(a),1],[w,1] \mbox{ }\vert\mbox{ }a \in \frak{o} / \varpi\frak{o}           \right\}\]
is a complete set of coset representatives for $H_1^\frak{c}irc(\frak{o})/\mathcal{U}$, where
\[k(a) = \begin{pmatrix} 1 & 0 \\ a & 1 \end{pmatrix}.\]
Let
\[g = \operatorname{diag}( \varpi^{-\frak{c}}, 1, \varpi^{\frak{c}}, 1 ) \in \frak{o}peratorname{Sp}_4(k_v),\quad h = [{\bf d}(\varpi^{\frak{c}}),{\bf d}(\varpi^{\frak{c}})] \in H_1^\frak{c}irc(k_v).\]
By (\ref{E:equivariant property of test vector case v=p divide N_1}) and our normalization of the Haar measure on $H_1^{\frak{c}irc}(k_v)$ in (\ref{E:non-archi. integration2}), we have
\[
\mathcal{W}^+(g) = q^{-2\frak{c}}(1+q)^{-1}\left( Z^{(1)}+ q\frak{c}dot Z^{(2)}\right),

\]
where
\begin{align*}
Z^{(1)} &= \sum_{k \in \mathcal{C}}\int_{k_v}\int_{k_v^\mathbf{t}imes}\int_{k_v^\mathbf{t}imes}W([1,{\bf n}(x)][{\bf m}(y_1),{\bf m}(y_2)]hk)\\
&\mathbf{t}imes\frak{o}mega(g,[1,{\bf n}(x)][{\bf m}(y_1),{\bf m}(y_2)]hk)\varphi({\bf x}_0,{\bf y}_0)|y_1|^{-2}|y_2|^{-2}\,d^{\mathbf{t}imes}y_1\,d^\mathbf{t}imes y_2\,dx,\\
Z^{(2)} &= \sum_{k \in \mathcal{C}}\int_{k_v}\int_{k_v^\mathbf{t}imes}\int_{k_v^\mathbf{t}imes}W([{\bf a}(\varpi),{\bf a}(\varpi)][1,{\bf n}(x)][{\bf m}(y_1),{\bf m}(y_2)]hk)\\
&\mathbf{t}imes\frak{o}mega(g,[{\bf a}(\varpi),{\bf a}(\varpi)][1,{\bf n}(x)][{\bf m}(y_1),{\bf m}(y_2)]hk)\varphi({\bf x}_0,{\bf y}_0)|y_1|^{-2}|y_2|^{-2}\,d^{\mathbf{t}imes}y_1\,d^\mathbf{t}imes y_2\,dx.\\

\end{align*}
For $h_1 \in H_1(k_v)$, we have
\[
\frak{o}mega(g,h_1)\varphi({\bf x}_0,{\bf y}_0) = q^{2\frak{c}}\frak{c}dot\varphi(h_1^{-1}\frak{c}dot (\varpi^{-\frak{c}} {\bf x}_0,{\bf y}_0)).
\]
Let $h_1 = [1,{\bf n}(x)][{\bf m}(y_1),{\bf m}(y_2)]hk$ with $x \in k_v$, $y_1,y_2 \in k_v^{\mathbf{t}imes}$, and $k \in \mathcal{C}$. If $k=[k(a),1]$, then
\begin{align*}
\frak{o}mega(g,h_1)\varphi({\bf x}_0,{\bf y}_0)&=q^{2\frak{c}}\frak{c}dot\varphi\left(\begin{pmatrix} 0 & -y_1^{-1}y_2^{-1}\\ 0 & ay_1^{-1}y_2^{-1} \end{pmatrix}, \begin{pmatrix} -y_1^{-1}y_2 & -y_1^{-1}y_2^{-1}x\varpi^\frak{c} \\ ay_1^{-1}y_2 & y_1y_2^{-1}+ay_1^{-1}y_2^{-1}x\varpi^\frak{c}\end{pmatrix} \right),\\
\frak{o}mega(g,[{\bf a}(\varpi),{\bf a}(\varpi)]h_1)\varphi({\bf x}_0,{\bf y}_0)&=q^{2\frak{c}}\frak{c}dot\varphi\left(\begin{pmatrix} 0 & -y_1^{-1}y_2^{-1}\varpi^{-1}\\ 0 & ay_1^{-1}y_2^{-1}\varpi^{-1} \end{pmatrix}, \begin{pmatrix} -y_1^{-1}y_2 & -y_1^{-1}y_2^{-1}x\varpi^\frak{c} \\ ay_1^{-1}y_2 & y_1y_2^{-1}+ay_1^{-1}y_2^{-1}x\varpi^\frak{c}\end{pmatrix} \right).
\end{align*}
If $k=[{w},1]$, then
\begin{align*}
\frak{o}mega(g,h_1)\varphi({\bf x}_0,{\bf y}_0) &= q^{2\frak{c}}\frak{c}dot\varphi \left( \begin{pmatrix} 0 & 0 \\ 0 & -y_1^{-1}y_2^{-1} \end{pmatrix},\begin{pmatrix} 0 & -y_1y_2^{-1} \\ -y_1^{-1}y_2 & -y_1^{-1}y_2^{-1}x\varpi^\frak{c}  \end{pmatrix} \right),\\
 \frak{o}mega(g,[{\bf a}(\varpi),{\bf a}(\varpi)]h_1)\varphi({\bf x}_0,{\bf y}_0) &= q^{2\frak{c}}\frak{c}dot\varphi \left( \begin{pmatrix} 0 & 0 \\ 0 & -y_1^{-1}y_2^{-1}\varpi^{-1} \end{pmatrix},\begin{pmatrix} 0 & -y_1y_2^{-1} \\ -y_1^{-1}y_2 & -y_1^{-1}y_2^{-1}x\varpi^\frak{c}  \end{pmatrix} \right).
\end{align*}
Therefore, if $k=1$, then
\begin{align*}
\frak{o}mega(g,h_1)\varphi({\bf x}_0,{\bf y}_0) \neq 0 & \mbox{ if and only if }y_1y_2^{-1} \in \frak{o}^{\mathbf{t}imes}, y_1^{-1} \in \frak{o} ,\mbox{ and }x \in y_1y_2\varpi^{-\frak{c}}\frak{o},\\
\frak{o}mega(g,[{\bf a}(\varpi),{\bf a}(\varpi)]h_1)\varphi({\bf x}_0,{\bf y}_0) \neq 0 &\mbox{ if and only if }y_1y_2^{-1} \in \frak{o}^{\mathbf{t}imes},
 y_1^{-1} \in \varpi\frak{o},\mbox{ and }x \in y_1y_2\varpi^{-\frak{c}}\frak{o},
\end{align*}
and if $k \neq 1$, then
\begin{align*}
\frak{o}mega(g,h_1)\varphi({\bf x}_0,{\bf y}_0) \neq 0 & \mbox{ if and only if }y_1y_2^{-1} \in \frak{o}^{\mathbf{t}imes}, y_1^{-1} \in \varpi\frak{o} ,\mbox{ and }x \in y_1y_2\varpi^{-\frak{c}}\frak{o},\\
\frak{o}mega(g,[{\bf a}(\varpi),{\bf a}(\varpi)]h_1)\varphi({\bf x}_0,{\bf y}_0) \neq 0 &\mbox{ if and only if }y_1y_2^{-1} \in \frak{o}^{\mathbf{t}imes},
 y_1^{-1} \in \varpi\frak{o},\mbox{ and }x \in y_1y_2\varpi^{-\frak{c}}\frak{o}.
\end{align*}
On the other hand, the functions $W_{1}({\bf a}(y))$ and $W_{2}({\bf a}(y))$ are both supported in $\varpi^{-\frak{c}}\frak{o}$, whereas the functions $W_{1}({\bf a}(y)k(a))$ with $a \in \frak{o}^\mathbf{t}imes$ and $W_{1}({\bf a}(y)w)$ are both supported in $\varpi^{-\frak{c}-1}\frak{o}$. We conclude that if $k=1$, then
\begin{align*}
&W(h_1)\frak{o}mega(g,h_1)\varphi({\bf x}_0,{\bf y}_0) \neq 0 \mbox{ if and only if }y_1,y_2\in\frak{o}^{\mathbf{t}imes}\mbox{ and }x\in \varpi^{-\frak{c}}\frak{o},\\
&W([{\bf a}(\varpi),{\bf a}(\varpi)]h_1)\frak{o}mega(g,[{\bf a}(\varpi),{\bf a}(\varpi)]h_1)\varphi({\bf x}_0,{\bf y}_0)=0,
\end{align*}
and if $k \neq 1$, then
\begin{align*}
W(h_1)\frak{o}mega(g,h_1)\varphi({\bf x}_0,{\bf y}_0) &= 0 ,\\
W([{\bf a}(\varpi),{\bf a}(\varpi)]h_1)\frak{o}mega(g,[{\bf a}(\varpi),{\bf a}(\varpi)]h_1)\varphi({\bf x}_0,{\bf y}_0)&=0.
\end{align*}
Hence 
\begin{align*}
Z^{(1)} &= q^{2\frak{c}}\frak{c}dot W([{\bf a}(\varpi^{-\frak{c}}),{\bf a}(\varpi^{-\frak{c}})])\frak{c}dot{\rm vol}(\varpi^{-\frak{c}}\frak{o}){\rm vol}(\frak{o}^\mathbf{t}imes)^2 = q^{3\frak{c}},\\ Z^{(2)} &=0.
\end{align*}
A similar calculation shows that $\mathcal{W}^-(g)=\mathcal{W}^+(g).$ This completes the proof.

\end{proof}

\subsubsection{Archimedean cases}
Let $v$ be a real place of $k$. We identify $k_v$ with ${\mathbb R}$. Let $\varphi_v \in S(V^2({\mathbb R}))$ be the Schwartz function defined in (\ref{E:archi Schwartz fun DS1})-(\ref{E:archi Schwartz fun PS}). 
If $v \in S({\rm DS})$, then
\begin{align}\label{E:equivariant property d.s.}
\frak{o}mega_{v}(1,[k_{\mathbf{t}heta_1},k_{\mathbf{t}heta_2}])\varphi_{v} = e^{-\sqrt{-1}(\kappa_{1,v}\mathbf{t}heta_1+\kappa_{2,v}\mathbf{t}heta_2)}\varphi_{v}
\end{align}
for $k_{\mathbf{t}heta_1},k_{\mathbf{t}heta_2} \in {\rm SO}(2)$, and
\begin{align}\label{E:lowest weight condition}
Z\frak{c}dot \varphi_{v} = -\lambda_1\frak{c}dot\varphi_{v},\quad Z'\frak{c}dot \varphi_{v} = -\lambda_2\frak{c}dot\varphi_{v},\quad N_{-}\frak{c}dot\varphi_{v} =0. 
\end{align}
Here $Z, Z', N_-$ are elements in $\frak{sp}_4({\mathbb R})\frak{o}times_{\mathbb R}{\mathbb C}$ defined by
\[
Z=-\sqrt{-1} \begin{pmatrix} 0&0&1&0 \\ 0&0&0&0 \\ -1&0&0&0\\ 0&0&0&0 \end{pmatrix},\quad Z' = -\sqrt{-1} \begin{pmatrix} 0&0&0&0 \\ 0&0&0&1 \\ 0&0&0&0\\ 0&-1&0&0 \end{pmatrix},\quad N_- = \frac{1}{2} \begin{pmatrix} 0&1&0&\sqrt{-1} \\ -1&0&\sqrt{-1}&0 \\ 0&-\sqrt{-1}&0&1 \\ -\sqrt{-1}& 0 & -1 & 0\end{pmatrix}.
\]
If $v \in S({\rm PS})$, then
\begin{align}\label{E:equivariant property PS}
\frak{o}mega_v(k,[k_1,k_2])\varphi_v = \varphi_v
\end{align}
for $k \in G({\mathbb R})\frak{c}ap {\rm O}(4)$ and $k_1,k_2 \in {\rm O}(2)$ with $\nu(k) = \det(k_1k_2^{-1})$.

For $n \in {\mathbb Z}_{\geq 0}$, let
\[H_n(x) = (-1)^n e^{x^2}\frac{d^n}{dx^n}\left(e^{-x^2}\right)\]
denote the Hermite polynomial.

\begin{lemma}\label{L:4.5}
Let $r_1,r_2,r_3 \in {\mathbb R}$ with $r_1>0$ and $r_2^2+r_3>0$. For $n \in {\mathbb Z}_{\geq 0}$, put
\[J_n(r_1,r_2,r_3) = \int_{0}^{\infty}y^{n-2}H_n(\sqrt{\pi}(r_1y+r_2y^{-1}))e^{-\pi(r_1y+r_2y^{-1})^2-\pi r_3y^{-2}}\,dy.\]
Then
\[
J_n(r_1,r_2,r_3) = 2^{n-1}\pi^{n/2}\left((r_2^2+r_3)^{1/2}+r_2\right)^n(r_2^2+r_3)^{-1/2}e^{-2\pi r_1\left((r_2^2+r_3)^{1/2}+r_2\right)}.
\]
\end{lemma}

\begin{proof}
The assertion is a variant of \frak{c}ite[Lemma 7.5]{Ichino2005}. In a small enough neighborhood of $x=0$, we have
\begin{align*}
\sum_{n=0}^{\infty}\frac{1}{n!}(-\sqrt{\pi}x)^nJ_n(r_1,r_2,r_3) &= \int_{0}^{\infty}y^{-2}e^{-\pi(xy+r_1y+r_2y^{-1})^2-\pi r_3y^{-2}}\,dy\\
&=2^{-1}(r_2^2+r_3)^{-1/2}e^{-2\pi r_2(x+r_1)}e^{-2\pi (r_2^2+r_3)^{1/2}|x+r_1|}\\
&=2^{-1}(r_2^2+r_3)^{-1/2}e^{-2\pi \left((r_2^2+r_3)^{1/2}+r_2\right)(x+r_1)}.
\end{align*}
This completes the proof.
\end{proof}

\begin{lemma}\label{L:Mellin transform}
Let $n \in {\mathbb Z}_{\geq0}$. Put
\begin{align*}
h_{n}(a_1,a_2) &= a_1a_2^{n+1}\int_{0}^{\infty}y^{-n-2}\left((a_1^2y^{-2}+a_2^2y^2)^{1/2}-a_2y\right)^{n}(a_1^2y^{-2}+a_2^2y^2)^{-1/2}\\
&\quad\quad\quad\quad\quad\quad\quad\quad\quad\quad\quad\mathbf{t}imes e^{-2\pi\left(y^2-a_2^2+(a_2y^{-1}+a_2^{-1}y)(a_1^2y^{-2}+a_2^2y^2)^{1/2}\right)}\,dy
\end{align*}
for $a_1,a_2>0.$ Let $s_1,s_2 \in {\mathbb C}$ satisfy
${\rm Re}(s_1+s_2+1)>0$ and ${\rm Re}(s_1)>0>{\rm Re}(s_2).$
Then 
\begin{align*}
&\int_{0}^{\infty}\int_{0}^{\infty}x_1^{s_1-1}x_2^{s_2-1}h_n(x_1,x_2)\,dx_1\,dx_2 \\
& = 2^{-n-4}\pi^{-n-1}(4\pi^{3})^{-s_1/2}(4\pi)^{-s_2/2}{G}amma\left(\frac{s_1+s_2+2n+1}{2}\right){G}amma\left(\frac{s_1+s_2+1}{2}\right){G}amma\left(\frac{s_1}{2}\right){G}amma\left(\frac{-s_2}{2}\right).
\end{align*}
\end{lemma}

\begin{proof}
We make a change of variable from $x_2$ to $x_1y^{-2}x_2$. Then
\begin{align*}
&\int_{0}^{\infty}\int_{0}^{\infty}x_1^{s_1-1}x_2^{s_2-1}h_{n}(x_1,x_2)\,dx_1\,dx_2 \\
&=\int_{0}^{\infty}\int_{0}^{\infty}\int_{0}^{\infty}x_1^{s_1+s_2+2n}x_2^{s_2+n}y^{-2s_2-4n-3}\left((1+x_2^2)^{1/2}-x_2\right)^{n}(1+x_2^2)^{-1/2}\\
&\quad\quad\quad\quad\quad\quad\quad\mathbf{t}imes e^{-2\pi x_1^2x_2y^{-4}\left((1+x_2^2)^{1/2}-x_2\right)}e^{-2\pi y^2x_2^{-1}\left((1+x_2^2)^{1/2}+x_2\right)}\,dx_1\,dy\,dx_2\\
&=2^{-1}(2\pi)^{-(s_1+s_2+2n+1)/2}{G}amma\left(\frac{s_1+s_2+2n+1}{2}\right)\\
&\mathbf{t}imes\int_{0}^{\infty}\int_{0}^{\infty}x_2^{(-s_1+s_2-1)/2}y^{2s_1-1}\left((1+x_2^2)^{1/2}-x_2\right)^{-(s_1+s_2+1)/2}(1+x_2^2)^{-1/2}\\
&\quad\quad\quad\quad\quad\quad\quad\quad\quad\quad\quad\quad\quad\quad\quad\quad\quad\quad\quad\mathbf{t}imes e^{-2\pi y^2x_2^{-1}\left((1+x_2^2)^{1/2}+x_2\right)}\,dy\,dx_2\\
&=2^{-2}(2\pi)^{(-3s_1-s_2-2n-1)/2}{G}amma\left(\frac{s_1+s_2+2n+1}{2}\right){G}amma\left(s_1\right)\\
&\mathbf{t}imes \int_{0}^{\infty}x_2^{(s_1+s_2-1)/2}\left((1+x_2^2)^{1/2}+x_2\right)^{(-s_1+s_2+1)/2}(1+x_2^2)^{-1/2}\,dx_2\\
&=2^{-n-4}\pi^{-n-1}(4\pi^{3})^{-s_1/2}(4\pi)^{-s_2/2}{G}amma\left(\frac{s_1+s_2+2n+1}{2}\right){G}amma\left(\frac{s_1+s_2+1}{2}\right){G}amma\left(\frac{s_1}{2}\right){G}amma\left(\frac{-s_2}{2}\right).
\end{align*}
Here the last equality follows from \frak{c}ite[p.\,311, (28)]{BE1954} and the duplication formula
\[{G}amma\left(\frac{s_1}{2}\right){G}amma\left(\frac{s_1+1}{2}\right)= 2^{1-s_1}\sqrt{\pi}\,{G}amma\left(s_1\right).\] This completes the proof.
\end{proof}

\begin{lemma}\label{L:local Whittaker archi. 1}
Let $v \in S({\rm DS})$. For $a_1,a_2>0$, we have 
\begin{align*}
&\mathcal{W}_{v}^+({\rm diag}(a_1,a_2,a_1^{-1},a_2^{-1}))\\
 &= \mathcal{W}_{v}^-({\rm diag}(a_1,a_2,a_1^{-1},a_2^{-1})) \\
&= 2^{-\lambda_{1,v}- 4}\pi^{(-3\lambda_{1,v}+\lambda_{2,v}-5)/2}\\
&\mathbf{t}imes e^{-2\pi a_2^2}\int_{c_1-\sqrt{-1}\infty}^{c_1+\sqrt{-1}\infty}\frac{ds_1}{2\pi \sqrt{-1}}\,\int_{c_2-\sqrt{-1}\infty}^{c_2+\sqrt{-1}\infty}\frac{ds_2}{2\pi \sqrt{-1}}\,(4\pi^{3}a_1^2)^{(-s_1+\lambda_{1,v}+1)/2}(4\pi a_2^2)^{(-s_2+\lambda_{2,v})/2}\\
&\quad\quad\quad\quad\quad\quad\quad\quad\quad\quad\quad\quad\mathbf{t}imes {G}amma\left(\frac{s_1+s_2-2\lambda_{2,v}+1}{2}\right){G}amma\left(\frac{s_1+s_2+1}{2}\right){G}amma\left(\frac{s_1}{2}\right){G}amma\left(\frac{-s_2}{2}\right).
\end{align*}
Here $c_1,c_2 \in {\mathbb R}$ satisfy 
\[
c_1+c_2+1>0,\quad c_1>0>c_2.
\]
\end{lemma}

\begin{proof}
We identify $k_v={\mathbb R}$ and drop the subscript $v$ for brevity. Without loss of generality, we assume $\kappa_1 \geq \kappa_2$. Let $g = {\rm diag}(a_1,a_2,a_1^{-1},a_2^{-1})$. Note that $W\vert_{H_1^\frak{c}irc({\mathbb R})}$ is supported in $H_1^{\frak{c}irc}({\mathbb R})^0$ and 
\[W([{\bf a}(y_1),{\bf a}(y_2)]) = y_1^{\kappa_1/2}y_2^{\kappa_2/2}e^{-2\pi y_1-2\pi y_2}\]
for $y_1,y_2 >0$. By (\ref{E:archi. integration}) and (\ref{E:equivariant property d.s.}), we have
\begin{align*}
&\mathcal{W}^+(g)= 4a_1^{\lambda_1+2}a_2^{-\lambda_2+2}\int_{0}^{\infty}\int_{0}^{\infty} y_1^{-\lambda_2-2}y_2^{\lambda_2-2}e^{-\pi(a_1^2y_1^{-2}y_2^{-2}+a_2^2y_1^{-2}y_2^2+a_2^{2}y_1^2y_2^{-2}+2y_1^2+2y_2^2)}\\
&\quad\quad\quad\quad\quad\quad\quad\quad\quad\mathbf{t}imes \int_{{\mathbb R}}(y_1y_2^{-1}-y_1^{-1}y_2-\sqrt{-1}x)^{-\lambda_2}e^{-\pi a_2^2 x^2}e^{2\pi \sqrt{-1}xy_1y_2}\,dx\,dy_1\,dy_2.
\end{align*}
By \frak{c}ite[Lemma 7.4]{Ichino2005}, we have
\begin{align*}
&\int_{{\mathbb R}}(y_1y_2^{-1}-y_1^{-1}y_2-\sqrt{-1}x)^{-\lambda_2}e^{-\pi a_2^2 x^2}e^{2\pi \sqrt{-1}xy_1y_2}\,dx\\
&=(2\sqrt{\pi})^{\lambda_2}a_2^{\lambda_2-1}H_{-\lambda_2}(\sqrt{\pi} ( a_2 y_1 y_2^{-1}-a_2 y_1^{-1}y_2+a_2^{-1}y_1y_2))e^{-\pi a_2^{-2}y_1^2y_2^2}.
\end{align*}
Therefore, by Lemma \ref{L:4.5},
\begin{align*}
\mathcal{W}^+(g)&= 4(2\sqrt{\pi})^{\lambda_2}a_1^{\lambda_1+2}a_2\int_{0}^{\infty}\int_{0}^{\infty}y_1^{-\lambda_2-2}y_2^{\lambda_2-2}e^{-\pi(a_1^2y_1^{-2}y_2^{-2}+a_2^2y_1^{-2}y_2^2+a_2^{2}y_1^2y_2^{-2}+a_2^{-2}y_1^2y_2^2+2y_1^2+2y_2^2)}\\
&\quad\quad\quad\quad\quad\quad\quad\quad\quad\quad\quad\quad\quad\quad\quad\quad\mathbf{t}imes H_{-\lambda_2}(\sqrt{\pi} ( a_2 y_1 y_2^{-1}-a_2 y_1^{-1}y_2+a_2^{-1}y_1y_2)) \,dy_1\,dy_2\\
&=4(2\sqrt{\pi})^{\lambda_2}a_1^{\lambda_1+2}a_2\int_{0}^{\infty}y^{\lambda_2-2}e^{-4\pi y^2-2\pi a_2^2}J_{-\lambda_2}(a_2y^{-1}+a_2^{-1}y,\,-a_2y,\,a_1^2y^{-2})\,dy\\
&= 2a_1^{\lambda_1+1}a_2^{\lambda_2}e^{-2\pi a_2^2}h_{-\lambda_2}(a_1,a_2).
\end{align*}
A similar calculation shows that $\mathcal{W}^-(g)=\mathcal{W}^+(g).$ The assertion then follows from Lemma \ref{L:Mellin transform} and the Mellin inversion formula. This completes the proof.
\end{proof}

\begin{lemma}\label{L:local Whittaker archi. 2}
Let $v \in S({\rm PS})$. For $a_1,a_2>0$, we have
\begin{align*}
&\mathcal{W}_v^+({\rm diag}(a_1,a_2,a_1^{-1},a_2^{-1})) \\
&= \mathcal{W}_v^-({\rm diag}(a_1,a_2,a_1^{-1},a_2^{-1})) \\&= 2^{-4}a_1^2a_2\\
&\mathbf{t}imes\int_{c_1-\sqrt{-1}\infty}^{c_1+\sqrt{-1}\infty}\frac{ds_1}{2\pi \sqrt{-1}}\,\int_{c_2-\sqrt{-1}\infty}^{c_2+\sqrt{-1}\infty}\frac{ds_2}{2\pi \sqrt{-1}}\,\left(\pi a_1a_2^{-1}\right)^{-s_1}\left(\pi a_2^{2}\right)^{-s_2}\\
&\mathbf{t}imes{G}amma\left(\frac{s_1+\lambda_{1,v}}{2}\right){G}amma\left(\frac{s_1-\lambda_{1,v}}{2}\right){G}amma\left(\frac{s_1+\lambda_{2,v}}{2}\right){G}amma\left(\frac{s_1-\lambda_{2,v}}{2}\right)\\
&\mathbf{t}imes{G}amma\left(\frac{s_2}{2}+\frac{\lambda_{1,v}+\lambda_{2,v}}{4}\right){G}amma\left(\frac{s_2}{2}-\frac{\lambda_{1,v}+\lambda_{2,v}}{4}\right){G}amma\left(\frac{s_2}{2}+\frac{\lambda_{1,v}-\lambda_{2,v}}{4}\right){G}amma\left(\frac{s_2}{2}-\frac{\lambda_{1,v}-\lambda_{2,v}}{4}\right)\\
&\mathbf{t}imes{G}amma\left(\frac{s_1+s_2}{2}+\frac{\lambda_{1,v}+\lambda_{2,v}}{4}\right)^{-1}{G}amma\left(\frac{s_1+s_2}{2}-\frac{\lambda_{1,v}+\lambda_{2,v}}{4}\right)^{-1}\\
&\mathbf{t}imes {}_3F_2\left(\frac{s_1}{2},\frac{s_2}{2}+\frac{\lambda_{1,v}-\lambda_{2,v}}{4}, \frac{s_2}{2}-\frac{\lambda_{1,v}-\lambda_{2,v}}{4} ;\, \frac{s_1+s_2}{2}+\frac{\lambda_{1,v}+\lambda_{2,v}}{4},\frac{s_1+s_2}{2}-\frac{\lambda_{1,v}+\lambda_{2,v}}{4};\,1           \right).
\end{align*}
Here $c_1,c_2 \in {\mathbb R}$ satisfy 
\[
c_1>\max\left\{ |{\rm Re}(\lambda_{1,v})|,\,|{\rm Re}(\lambda_{2,v})|\right\},\quad c_2>\max\left\{\left\vert{\rm Re}\left(\frac{\lambda_{1,v}+\lambda_{2,v}}{2}\right)\right\vert,\,\left\vert{\rm Re}\left(\frac{\lambda_{1,v}-\lambda_{2,v}}{2}\right)\right\vert\right\}.
\]
\end{lemma}

\begin{proof}
We identify $k_v={\mathbb R}$ and drop the subscript $v$ for brevity. Let $g = {\rm diag}(a_1,a_2,a_1^{-1},a_2^{-1})$. Note that 
\[W([{\bf a}(y_1),{\bf a}(y_2)]) = {\rm sgn}^\varepsilon(y_1y_2)|y_1y_2|^{1/2}K_{\mu_1}(2\pi |y_1|)K_{\mu_2}(2\pi |y_2|)\]
for $y_1,y_2 \in {\mathbb R}^{\mathbf{t}imes}$. By (\ref{E:archi. integration}) and (\ref{E:equivariant property PS}), we have
\begin{align*}
\mathcal{W}^+(g)& =8 a_1^2a_2^2 \int_{0}^{\infty}\int_{0}^{\infty}y_1^{-2}y_2^{-2}K_{\mu_1}(2\pi y_1^2)K_{\mu_2}(2\pi y_2^2)e^{-\pi(a_1^2y_1^{-2}y_2^{-2}+a_2^2y_1^{-2}y_2^2+a_2^2y_1^2y_2^{-2})}\\
&\quad\quad\quad\quad\quad\quad\quad\quad\quad\quad\quad\quad\quad\quad\quad\quad\quad\mathbf{t}imes\int_{{\mathbb R}}e^{-\pi a_2^2y_1^{-2}y_2^{-2}x^2}e^{2\pi \sqrt{-1}x}\,dx\,dy_1\,dy_2\\
&=8a_1^2a_2\int_{0}^{\infty}\int_{0}^{\infty}y_1^{-1}y_2^{-1}K_{\mu_1}(2\pi y_1^2)K_{\mu_2}(2\pi y_2^2)e^{-\pi(a_1^2y_1^{-2}y_2^{-2}+a_2^2y_1^{-2}y_2^2+a_2^2y_1^2y_2^{-2}+a_2^{-2}y_1^2y_2^2)}\,dy_1\,dy_2.
\end{align*}
Therefore, in the notation of \frak{c}ite[Theorem 3.2]{Ishii2005}, we have
\[
\mathcal{W}^+(g)=W_{(\lambda_1,\lambda_2)}^{(0,0)}((a_1a_2^{-1},a_2^2)).
\]
A similar calculation shows that $\mathcal{W}^-(g)=\mathcal{W}^+(g).$ The assertion then follows from \frak{c}ite[Proposition 3.5]{Ishii2005}.
\end{proof}

\subsection{Proof of Proposition \ref{P:W(1)}}\label{S:proof 1}
Let $g_0, g_1 \in G({\mathbb A})$ be the elements defined by
\begin{align*}
g_{0,v} &= \begin{cases}
\operatorname{diag}( 1, 1, \varpi_v^{\frak{c}_v}, \varpi_v^{\frak{c}_v} ) & \mbox{ if $v \nmid \infty$},\\
1 & \mbox{ if $v \mid \infty$},
\end{cases}\\
g_{1,v} &= \begin{cases}
\operatorname{diag}( \varpi_v^{-\frak{c}_v}, 1, \varpi_v^{\frak{c}_v}, 1 ) & \mbox{ if $v \nmid \infty$},\\
1 & \mbox{ if $v \mid \infty$}.
\end{cases}
\end{align*}
Let $\varphi = \bigotimes_v \varphi_v \in S(V^2({\mathbb A}))$ be the Schwartz function defined in (\ref{E:non-archi Schwartz fun})-(\ref{E:archi Schwartz fun PS}). By (\ref{E:equivariant property of test vector case v=p not divide N_1N_2})-(\ref{E:equivariant property PS}), there exists a constant $C$ such that
\[\mathbf{t}heta({\bf f}^\sharp,\varphi)(g) = C\frak{c}dot f(gg_0)\]
for $g \in G({\mathbb A})$.

To determine $C$, by the normalization of $f$ in (\ref{E:normalization}), it suffices to compute $W_{\mathbf{t}heta({\bf f}^\sharp,\varphi)}(g_1).$ The assertion then follows from Lemmas \ref{L:global Whittaker}-\ref{L:local Whittaker finite 2}, \ref{L:local Whittaker archi. 1} and \ref{L:local Whittaker archi. 2}. This completes the proof of Proposition \ref{P:W(1)}.

\section{Explicit Rallis inner product formula}\label{S:cal2}
We keep the notation of $\S\,\ref{S:Yoshida lifts}$ and $\S\,\ref{S:cal1}$. The aim of this section is to prove Proposition \ref{P:Rallis inner product}. We prove it by specializing the Rallis inner product formula in \frak{c}ite{GQT2014} to the theta lift $\mathbf{t}heta({\bf f}^\sharp,\varphi)$. It boils down to the calculation of certain doubling local zeta integrals involving matrix coefficients of $\sigma_v^\sharp$ and the Weil representation $\frak{o}mega_v$ for each place $v$.

\subsection{Matrix coefficients}

\subsubsection{Hermitian pairings on $\sigma_v$ and $\sigma_v^\sharp$}\label{SS:local pairing}

Let $v$ be a place of $k$. Let $\langle \ ,\ \rangle_{i,v} : \mathcal{V}_{i,v}\frak{o}times\frak{o}verline{\mathcal{V}}_{i,v} \rightarrow {\mathbb C}$ be the $\frak{o}peratorname{GL}_2(k_v)$-invariant Hermitian pairing defined by
\[
\langleW_1,W_2\rangle_{i,v}=\int_{k_v^{\mathbf{t}imes}}W_1({\bf a}(t))\frak{o}verline{W_2({\bf a}(t))}\,d^{\mathbf{t}imes}t
\]
for $W_1,W_2 \in \mathcal{V}_{i,v}$. 
Let $\mathcal{B}_v : \mathcal{V}_v\frak{o}times \frak{o}verline{\mathcal{V}}_v\rightarrow {\mathbb C}$ be the $H^{\frak{c}irc}(k_v)$-invariant Hermitian pairing defined by
\[
\mathcal{B}_v(W_1\frak{o}times W_2,W_3\frak{o}times W_4) = \frac{\zeta_{v}(2)^2}{\zeta_{v}(1)^2}\frak{c}dot\frac{\langleW_1,W_3\rangle_{1,v}\langleW_2,W_4\rangle_{2,v}}{L(1,\sigma_{1,v},{\rm Ad})L(1,\sigma_{2,v},{\rm Ad})}
\]
for $W_1,W_3 \in \mathcal{V}_{1,v}$ and $W_2,W_4 \in \mathcal{V}_{2,v}$.
Let $\mathcal{B}_v^{\sharp} : \mathcal{V}_v^{\sharp}\frak{o}times\frak{o}verline{\mathcal{V}}_v^{\sharp}\rightarrow {\mathbb C}$ be the $H(k_v)$-invariant Hermitian pairing defined as follows:
\begin{itemize}
\item If $v \notin \frak{S}$, then $\mathcal{B}_v^{\sharp}=\mathcal{B}_v$.
\item If $v \in \frak{S}$, then
$$\mathcal{B}_v^{\sharp}((W_1,W_2),(W_3,W_4))=\frac{1}{2}\left[\mathcal{B}_v(W_1,W_3)+\mathcal{B}_v(W_2,W_4)\right]$$
for $(W_1,W_2),\,(W_3,W_4) \in \mathcal{V}_{v}^{\sharp}$.
\end{itemize}

\subsubsection{Matrix coefficients of $\sigma_v$}
Let $v$ be a place of $k$.
Let $W_v$ be the Whittaker function on $H^{\frak{c}irc}(k_v)$ defined in (\ref{E:Whittaker newform}).

\begin{lemma}\label{E:matrix coefficients unram}
Let $v \nmid \infty\frak{n}$. We have
\[
\mathcal{B}_v(W_v,W_v)=1.
\]
\end{lemma}

\begin{proof}
The calculation was carried out in \frak{c}ite[Lemmas 6.9]{IP2018}.
\end{proof}

\begin{lemma}\label{E:matrix coefficients}
Let $v \mid \frak{n}_1$. Write
\[\sigma_{1,v} = {\rm St}\frak{o}times \mu,\quad \sigma_{2,v}  = {\rm Ind}_{B(k_v)}^{\frak{o}peratorname{GL}_2(k_v)}(\frak{c}hi\boxtimes\frak{c}hi^{-1}),\]
where ${\rm St}$ is the Steinberg representation of $\frak{o}peratorname{GL}_2(k_v)$, and $\frak{c}hi$  and $\mu$ are unramified characters of $k_v^{\mathbf{t}imes}$ such that $\frak{c}hi= |\mbox{ }|_v^s $ with $|{\rm Re}(s)|<1/2$ and $\mu^2=1$. For
\[h_{n,m} = [{\bf a}(\varpi_v^n){\bf d}(\varpi_v^m),{\bf a}(\varpi_v^{n+m})],\quad h_{n,m}' = [w{\bf a}(\varpi_v^n){\bf d}(\varpi_v^m),{\bf a}(\varpi_v^{n+m})]\]
with $m,n \in {\mathbb Z}$ such that $m+n \geq 0$, we have
\begin{align*}

\mathcal{B}_{ v}(\sigma_{ v}(h_{n,m})W_{v },W_{ v}) &= \frac{\zeta_v(2)}{\zeta_v(1)}\frak{c}dot\varepsilon^{n-m}\frak{c}dot\frac{q_v^{-|n-m|-(n+m)/2}}{1+q_v^{-1}}\frak{c}dot\left(\alpha^{n+m}\frak{c}dot\frac{1-\alpha^{-2}q_v^{-1}}{1-\alpha^{-2}}+\alpha^{-(n+m)}\frak{c}dot\frac{1-\alpha^2q_v^{-1}}{1-\alpha^2}\right),\\
\mathcal{B}_{ v}(\sigma_{v }(h_{n,m}')W_{v },W_{ v}) &= -\frac{\zeta_v(2)}{\zeta_v(1)}\frak{c}dot\varepsilon^{n-m}\frak{c}dot\frac{q_v^{-|n-m-1|-(n+m)/2}}{1+q_v^{-1}}\frak{c}dot\left(\alpha^{n+m}\frak{c}dot\frac{1-\alpha^{-2}q_v^{-1}}{1-\alpha^{-2}}+\alpha^{-(n+m)}\frak{c}dot\frac{1-\alpha^2q_v^{-1}}{1-\alpha^2}\right),

\end{align*}
where
\[\alpha = \frak{c}hi(\varpi_v),\quad \varepsilon = \mu(\varpi_v).\]
\end{lemma}

\begin{proof}
By \frak{c}ite[Lemmas 6.9 and 6.11]{IP2018},
\[\mathcal{B}_{ v}(W_{v },W_{ v}) = \frac{\zeta_v(2)}{\zeta_v(1)}.\]
The assertion then follows from the formulae for matrix coefficients in \frak{c}ite{Macdonald1971} and \frak{c}ite[\S 7]{GJ1972}.
\end{proof}

\begin{lemma}\label{E:coefficient}
Let $v \in S({\rm DS})$. For $h = [k_{\mathbf{t}heta_1},k_{\mathbf{t}heta_2}][{\bf m}(e^{t_1}),{\bf m}(e^{t_2})][k_{\mathbf{t}heta_3},k_{\mathbf{t}heta_4}] \in H_1^\frak{c}irc({\mathbb R})^0$ with $k_{\mathbf{t}heta_1},k_{\mathbf{t}heta_2},k_{\mathbf{t}heta_3},k_{\mathbf{t}heta_4} \in {\rm SO}(2)$ and $t_1, t_2 \in {\mathbb R}$, we have
\[
\mathcal{B}_{ v}(\sigma_{v }(h)W_{ v},W_{v })  = 2^{-2\lambda_{1,v}-2}e^{\sqrt{-1}(\kappa_{1,v}\mathbf{t}heta_1+\kappa_{1,v}\mathbf{t}heta_3+\kappa_{2,v}\mathbf{t}heta_2+\kappa_{2,v}\mathbf{t}heta_4)}\frak{c}osh(t_1)^{-\kappa_{1,v}}\frak{c}osh(t_2)^{-\kappa_{2,v}}.
\]
For $h \in H^\frak{c}irc({\mathbb R}) \setminus H^\frak{c}irc({\mathbb R})^0$, we have $\mathcal{B}_{ v}(\sigma_{v }(h)W_{ v},W_{v }) =0$.
\end{lemma}

\begin{proof}
The assertion follows from the formulae for the Whittaker functions that
\[
W_{i,v}({\bf a}(y)k_{\mathbf{t}heta})=\begin{cases} e^{\sqrt{-1}\kappa_{i,v}\mathbf{t}heta}y^{\kappa_{i,v}/2}e^{-2\pi y}&\mbox{ if }y>0,\\
0&\mbox{ if }y<0,\end{cases}
\]
for $i=1,2$, $y \in {\mathbb R}^{\mathbf{t}imes}$ and $ k_{\mathbf{t}heta} \in {\rm SO}(2)$. 
\end{proof}

\begin{lemma}\label{E:coefficient PS}
Let $v \in S({\rm PS})$. We have
\[
\mathcal{B}_v(W_v,W_v) = 2^{-4}.
\]
\end{lemma}

\begin{proof}
By \frak{c}ite[6.576.4]{Table2000}, we have
\[
\langleW_{i,v},W_{i,v}\rangle_{i,v} = \int_{\mathbb R} K_{\mu_{i,v}}(2 \pi |t|)^2 \, dt = 2^{-2} {G}amma \left( \frac{1}{2} + \mu_{i,v} \right) {G}amma \left( \frac{1}{2} - \mu_{i,v} \right)
\]
for $i=1,2$. Therefore
\[
\mathcal{B}_v(W_v,W_v) = \frac{\zeta_v(2)^2}{\zeta_v(1)^2}\frak{c}dot\frac{\langleW_{1,v},W_{1,v}\rangle\langleW_{2,v},W_{2,v}\rangle}{L(1,\sigma_{1,v},{\rm Ad})L(1,\sigma_{2,v},{\rm Ad})}=2^{-4}.
\]

\end{proof}

\subsubsection{Matrix coefficients of the Weil representations}
Let $v$ be a place of $k$ and $\varphi_v \in S(V^2(k_v))$ the Schwartz function defined in (\ref{E:non-archi Schwartz fun})-(\ref{E:archi Schwartz fun PS}). Let ${\bf P}hi_v$ be the matrix coefficient of the Weil representation $\frak{o}mega_v$ defined by
\[
{\bf P}hi_v(h_{1,v}) = \int_{V^2(k_v)}\frak{o}mega_v(1,h_{1,v})\varphi_v(x_v)\frak{o}verline{\varphi_v(x_v)}\,dx_v
\]
for $h_{1,v} \in H_1(k_v)$. 
\begin{lemma}\label{L:matrix coefficient nonarchimedean case}
Let $v$ be a finite place of $k$. Let $n,m \in {\mathbb Z}$. If $v \nmid \frak{n}$, then 
$${\bf P}hi_{v}([{\bf a}(\varpi_v^n){\bf d}(\varpi_v^m),{\bf a}(\varpi_v^{n+m})])= q_v^{-2|n|-2|m|}.$$
If $v \mid \frak{n}_1$, then
\begin{align*}
{\bf P}hi_{v}([{\bf a}(\varpi_v^n){\bf d}(\varpi_v^m),{\bf a}(\varpi_v^{n+m})]) & =  q_v^{-2|n|-2|m|-2},\\
{\bf P}hi_{v}([w{\bf a}(\varpi_v^n){\bf d}(\varpi_v^m),{\bf a}(\varpi_v^{n+m})]) & =  q_v^{-|n|-|n-1|-|m|-|m+1|-2}.
\end{align*}
If $v\mid \frak{n}_2$, then
\begin{align*}
{\bf P}hi_{v}([{\bf a}(\varpi_v^{n+m}),{\bf a}(\varpi_v^n){\bf d}(\varpi_v^m)]) & =  q_v^{-2|n|-2|m|-2},\\
{\bf P}hi_{v}([{\bf a}(\varpi_v^{n+m}),w{\bf a}(\varpi_v^n){\bf d}(\varpi_v^m)]) & = q_v^{-|n|-|n-1|-|m|-|m+1|-2}.

\end{align*}
\end{lemma}

\begin{proof}
The verification is straightforward and we leave it to the readers.
\end{proof}
 
\begin{lemma}\label{L:matrix coeff. of Weil rep d.s}
Let $v \in S({\rm DS})$. For $a,b>0$, we have
\begin{align*}
{\bf P}hi_{v}([{\bf m}(a),{\bf m}(b)]) &= \pi^{-\lambda_{1,v}+\lambda_{2,v}}{G}amma(\lambda_{1,v}+1){G}amma(-\lambda_{2,v}+1)(ab+a^{-1}b^{-1})^{-2}(ab^{-1}+a^{-1}b)^{-2}\\
&\mathbf{t}imes\left[(ab+a^{-1}b^{-1})^{-1}+(ab^{-1}+a^{-1}b)^{-1}\right]^{\lambda_{1,v}-\lambda_{2,v}}.
\end{align*}
\end{lemma}

\begin{proof}
We identify $k_v={\mathbb R}$ and drop the subscript $v$ for brevity. Without loss of generality, we assume $\kappa_1 \geq \kappa_2$. For $n \in {\mathbb Z}_{\geq 0}$ and $z=(z_1,z_2,z_3,z_4) \in {\mathbb C}^4$, let 
\begin{align*}
f_n(z) &= \int_{{\mathbb R}^4}(a^{-1}x_1-a^{-1}\sqrt{-1}x_2-a\sqrt{-1}x_3-ax_4)^n(b^{-1}x_1+b\sqrt{-1}x_2+b^{-1}\sqrt{-1}x_3-bx_4)^{n}\\
&\quad\mathbf{t}imes e^{-\pi\left[ (a^{-2}+b^{-2})x_1^2+ (a^{-2}+b^{2})x_2^2+(a^{2}+b^{-2})x_3^2+(a^{2}+b^{2})x_4^2        \right]}e^{2\pi \sqrt{-1}(z_1x_1+z_2x_2+z_3x_3+z_4x_4)}\,dx_1\,dx_2\,dx_3\,dx_4.
\end{align*}
Then \[f_{0}(z) = (ab+a^{-1}b^{-1})^{-1}(ab^{-1}+a^{-1}b)^{-1}e^{-\pi\left[ (a^{-2}+b^{-2})^{-1}z_1^2+ (a^{-2}+b^{2})^{-1}z_2^2+(a^{2}+b^{-2})^{-1}z_3^2+(a^{2}+b^{2})^{-1}z_4^2        \right]}\]
and $f_n(z) = \nabla^n f_{0}(z)$, where  
\begin{align*}
\nabla = \frac{1}{(2\pi\sqrt{-1})^2}&\left(a^{-1}\frac{\partial}{\partial z_1}-a^{-1}\sqrt{-1}\frac{\partial}{\partial z_2}-a\sqrt{-1}\frac{\partial}{\partial z_3}-a\frac{\partial}{\partial z_4}\right)\\
\mathbf{t}imes&\left(b^{-1}\frac{\partial}{\partial z_1}+b\sqrt{-1}\frac{\partial}{\partial z_2}+b^{-1}\sqrt{-1}\frac{\partial}{\partial z_3}-b\frac{\partial}{\partial z_4}\right).
\end{align*}
We claim that
\begin{align}\label{E:1}
f_n(0) = \pi^{-n}{G}amma(n+1)(ab+a^{-1}b^{-1})^{-1}(ab^{-1}+a^{-1}b)^{-1}\left[(ab+a^{-1}b^{-1})^{-1}+(ab^{-1}+a^{-1}b)^{-1}\right]^n.
\end{align}

Assume the claim holds. We have
\[
{\bf P}hi ([{\bf m}(a),{\bf m}(b)])= \int_{V^2({\mathbb R})}\varphi\left({\bf m}(a)^{-1}x,{\bf m}(a)^{-1}y\right)\frak{o}verline{\varphi(x{\bf m}(b)^{-1},y{\bf m}(b)^{-1})}\,dx\,dy.
\]
Making a change of variables from $(y_1,y_3)$ to $(-y_1,-y_3)$, we see that
\begin{align*}
{\bf P}hi([{\bf m}(a),{\bf m}(b)]) &= f_{\lambda_1}(0)f_{-\lambda_2}(0)\\
&=\pi^{-\kappa_1}{G}amma(\lambda_1+1){G}amma(-\lambda_2+1)(ab+a^{-1}b^{-1})^{-2}(ab^{-1}+a^{-1}b)^{-2}\\
&\mathbf{t}imes\left[(ab+a^{-1}b^{-1})^{-1}+(ab^{-1}+a^{-1}b)^{-1}\right]^{\kappa_1}.
\end{align*}
Here the last equality follows from (\ref{E:1}).

It remains to prove the claim (\ref{E:1}). Let
\[
D= \{(a,b) \in {\mathbb C}^2 \mbox{ }\vert\mbox{ }ab(ab+a^{-1}b^{-1})(ab^{-1}+a^{-1}b) \neq 0 \}.
\]
Let $(a,b) \in D$ be such that $(1+ab^{-1})(1+a^{-1}b^{-1})(1-a^{-1}b)(1-ab) \neq 0$.
We make the following change of variables:
\begin{align*}
&\begin{cases}
z_1 = a^{-1}u_1+b^{-1}u_4,\\
z_4 = -bu_1+au_4,
\end{cases}
\quad 
\begin{cases}
z_2 = a^{-1}u_2+bu_3,\\
z_3 =  -b^{-1}u_2+au_3,
\end{cases}\\
&\begin{cases}
Z = (1+ab^{-1})^{-1}u_1 + (1+a^{-1}b^{-1})^{-1}\sqrt{-1}u_3 ,\\
\frak{o}verline{Z} = (1+ab^{-1})^{-1}u_1 - (1+a^{-1}b^{-1})^{-1}\sqrt{-1}u_3,
\end{cases}
\quad
\begin{cases}
Z' = (1-a^{-1}b)^{-1}u_4 + (1-ab)^{-1}\sqrt{-1}u_2,\\
\frak{o}verline{Z'} = (1-a^{-1}b)^{-1}u_4 - (1-ab)^{-1}\sqrt{-1}u_2,
\end{cases}\\
&\begin{cases}
Z = u+ u',\\
\frak{o}verline{Z'} = -u+u',
\end{cases}
\quad
\begin{cases}
\frak{o}verline{Z} = v+v',\\
Z' = v-v'.
\end{cases}
\end{align*}
Then
\begin{align*}
f_0(z) &= (ab+a^{-1}b^{-1})^{-1}(ab^{-1}+a^{-1}b)^{-1} e^{-4\pi\left[(ab+a^{-1}b^{-1})^{-1}+(ab^{-1}+a^{-1}b)^{-1}\right](uv+u'v')}\\
&\mathbf{t}imes e^{-4\pi\left[(ab^{-1}+a^{-1}b)^{-1}-(ab+a^{-1}b^{-1})^{-1}\right](uu'+vv') - 4\pi(uv'+u'v)},\\
\nabla &= \frac{1}{(2\pi \sqrt{-1})^2}\frak{c}dot\frac{\partial^2}{\partial u \partial v}.
\end{align*}
It follows that 
\begin{align*}
f_n(0) &= (-4\pi^2)^{-n}(n!)^2(ab+a^{-1}b^{-1})^{-1}(ab^{-1}+a^{-1}b)^{-1}\\
&\mathbf{t}imes \left(\mbox{the coefficient of $u^nv^n$ in the Taylor expansion of $e^{-4\pi\left[(ab+a^{-1}b^{-1})^{-1}+(ab^{-1}+a^{-1}b)^{-1}\right]uv}$ at (0,0)}\right)\\
&=\pi^{-n}{G}amma(n+1)(ab+a^{-1}b^{-1})^{-1}(ab^{-1}+a^{-1}b)^{-1}\left[(ab+a^{-1}b^{-1})^{-1}+(ab^{-1}+a^{-1}b)^{-1}\right]^n.
\end{align*}
Therefore (\ref{E:1}) holds in this case.
Since both sides of (\ref{E:1}) are holomorphic functions on $D$, we conclude that they are equal on $D$. In particular, (\ref{E:1}) holds for $a,b>0$. This completes the proof.
\end{proof}

\begin{lemma}\label{L:matrix coeff. of Weil rep PS}
Let $v \in S({\rm PS})$. For $a,b>0$, we have
\[
{\bf P}hi_v([{\bf m}(a),{\bf m}(b)]) = (ab+a^{-1}b^{-1})^{-2}(ab^{-1}+a^{-1}b)^{-2}.
\]
\end{lemma}

\begin{proof}
The calculation is similar to the one in Lemma \ref{L:matrix coeff. of Weil rep d.s}. We leave the details to the readers.
\end{proof}

\subsection{Rallis inner product formula}
Let $\mathcal{B}_{\sigma} : \mathcal{V}_{\sigma}\frak{o}times \frak{o}verline{\mathcal{V}}_{\sigma} \rightarrow {\mathbb C}$ and $\mathcal{B}_{\sigma^{\sharp}} : \mathcal{V}_{\sigma^{\sharp}}\frak{o}times \frak{o}verline{\mathcal V}_{\sigma^{\sharp}} \rightarrow {\mathbb C}$ be the Petersson pairings defined by
\begin{align*}
\mathcal{B}_{\sigma}(f_1,f_2) &= \int_{Z_{H}({\mathbb A})H^{\frak{c}irc}(k)\backslash H^{\frak{c}irc}({\mathbb A})}f_1(h_0)\frak{o}verline{f_2(h_0)}\,dh_0,\\
\mathcal{B}_{\sigma^{\sharp}}(f_3,f_4) &= \int_{Z_{H}({\mathbb A})H(k)\backslash H({\mathbb A})}f_3(h)\frak{o}verline{f_4(h)}\,dh
\end{align*}
for $f_1,f_2 \in \mathcal{V}_{\sigma}$ and $f_3,f_4 \in \mathcal{V}_{\sigma^{\sharp}}$. Here $Z_H$ is the center of $H$, and $dh_0$ and $dh$ are the Tamagawa measures on $Z_H({\mathbb A})\backslash H^{\frak{c}irc}({\mathbb A})$ and $Z_H({\mathbb A})\backslash H({\mathbb A})$, respectively. Note that ${\rm vol}(Z_H({\mathbb A})H^{\frak{c}irc}(k)\backslash H^{\frak{c}irc}({\mathbb A}))=4$ and ${\rm vol}(Z_H({\mathbb A})H(k)\backslash H({\mathbb A}))=2$. 
By \frak{c}ite[Proposition 6]{Wald1985} and \frak{c}ite[Lemma 2.3]{GI2011}, we have
\begin{align}
\mathcal{B}_{\sigma} &= \frak{D}^{-1}\frak{c}dot\frac{4}{\zeta(2)^2}\frak{c}dot L(1,\sigma,{\rm Ad})\frak{c}dot \operatorname{pr}od_v\mathcal{B}_v,\\
\mathcal{B}_{\sigma^{\sharp}} & = \frak{D}^{-1}\frak{c}dot\frac{4}{\zeta(2)^2}\frak{c}dot L(1,\sigma,{\rm Ad})\frak{c}dot \operatorname{pr}od_v\mathcal{B}_v^{\sharp}\label{E:ratio of measures2}.
\end{align}
Here $\mathcal{B}_v$ and $\mathcal{B}_v^{\sharp}$ are the local Hermitian pairings defined in \S\,\ref{SS:local pairing}. 

Let $\mathcal{B}_{\frak{o}mega} : \mathcal{S}(V^2({\mathbb A}))\frak{o}times \frak{o}verline{\mathcal{S}(V^2({\mathbb A}))} \rightarrow {\mathbb C}$ be the canonical pairing defined by
\[\mathcal{B}_{\frak{o}mega}(\varphi_1,\varphi_2) = \int_{V^2({\mathbb A})}\varphi_1(x)\frak{o}verline{\varphi_2(x)}\,dx,\]
where $dx$ is the Tamagawa measure on $V^2({\mathbb A})$. For each place $v$ of $k$, let $\mathcal{B}_{\frak{o}mega_v} : \mathcal{S}(V^2(k_v))\frak{o}times \frak{o}verline{\mathcal{S}(V^2(k_v))} \rightarrow {\mathbb C}$ be the canonical pairing defined by
\[\mathcal{B}_{\frak{o}mega_v}(\varphi_1,\varphi_2) = \int_{V^2(k_v)}\varphi_1(x_v)\frak{o}verline{\varphi_2(x_v)}\,dx_v,\]
where $dx_v$ is defined by the Haar measure on $k_v$ in \S\,\ref{SS:measures}. Then we have
\begin{align}\label{E:ratio of measures3}
\mathcal{B}_\frak{o}mega(\varphi_1,\varphi_2) = \frak{D}^{-4}\frak{c}dot \operatorname{pr}od_v \mathcal{B}_{\frak{o}mega_v}(\varphi_{1,v},\varphi_{2,v})
\end{align}
for $\varphi_1= \bigotimes_v \varphi_{1,v}$, $\varphi_2= \bigotimes_v \varphi_{2,v} \in \mathcal{S}(V^2({\mathbb A}))$.

\begin{thm}(Rallis inner product formula)\label{T:RIF}
Let $f = \bigotimes_v f_v \in \sigma^\sharp$ and $\varphi=\bigotimes_v\varphi_v \in \frak{c}alS(V^2({\mathbb A}))$. We have
\[
\left\langle\mathbf{t}heta({f},\varphi),\mathbf{t}heta({f},\varphi) \right\rangle = \frak{D}^{-8}\frak{c}dot\frac{4}{\zeta(2)^4}\frak{c}dot\frac{L(1,\pi,{\rm Ad})}{\Delta_{{\rm PGSp}_4}}\frak{c}dot \operatorname{pr}od_{v}Z_v(f_v,\varphi_v),
\]
where 
\[
Z_v(f_v,\varphi_v) = \frac{\zeta_{v}(2)\zeta_{v}(4)}{L(1,\sigma_v,{\rm std})}\frak{c}dot \int_{H_1(k_v)}\mathcal{B}_{\frak{o}mega_v}(\frak{o}mega_v(1,h_{1,v})\varphi_v,\varphi_v)\mathcal{B}_v^{\sharp}(\sigma_v^{\sharp}(h_{1,v}){f}_v,{f}_v)\,dh_{1,v}.
\]
\end{thm}

\begin{proof}
Since 
\[
 L(s, \pi, {\mathbb A}d) = L(s, \sigma, {\rm std}) \frak{c}dot L(s, \sigma, {\rm Ad}), 
\]
the assertion is a special case of the Rallis inner product formula proved in \frak{c}ite[Theorem 11.3]{GQT2014} (see also \frak{c}ite[\S\,7]{GI2011}).
Here the extra factor $4 \mathfrak{D}^{-8} \zeta(2)^{-4} L(1, \sigma, {\rm Ad})$ is due to the ratio of the Haar measures in (\ref{E:ratio of measures}), (\ref{E:ratio of measures2}), and (\ref{E:ratio of measures3}).
\end{proof}

\subsection{Calculation of local integrals}
Let $v$ be a place of $k$.
Let ${\bf f}_v^\sharp \in \mathcal{V}_v^\sharp$ be the local component of ${\bf f}^\sharp$ with respect to the isomorphism in (\ref{E:iso}), and 
$\varphi_v \in S(V^2(k_v))$ the Schwartz function defined in (\ref{E:non-archi Schwartz fun})-(\ref{E:archi Schwartz fun PS}).
Let ${\bf P}si_v$ and ${\bf P}hi_v$ be the matrix coefficients of $\sigma_v^{\sharp}$ and $\frak{o}mega_v$, respectively, defined by
\begin{align*}
{\bf P}si_v(h_v) &= \mathcal{B}_v^{\sharp}(\sigma_v^{\sharp}(h_v){\bf f}_v^{\sharp},{\bf f}_v^{\sharp}),\\
{\bf P}hi_v(h_{1,v}) &= \mathcal{B}_{\frak{o}mega_v}(\frak{o}mega_v(1,h_{1,v})\varphi_v,\varphi_v)
\end{align*}
for $h_v \in H(k_v)$ and $h_{1,v} \in H_1(k_v)$.  Let $Z_v$ be the local integral defined by
\[
Z_v = \frac{\zeta_{v}(2)\zeta_{v}(4)}{L(1,\sigma_v,{\rm std})}\frak{c}dot \int_{H_1(k_v)}{\bf P}hi_v(h_{1,v}){\bf P}si_v(h_{1,v})\,dh_{1,v}.
\]

\begin{lemma}\label{L:zeta integral1}
Let $v$ be a finite place of $k$. If $v \nmid \frak{n}$, then
\[Z_v = 1.\]

If $v \mid \frak{n}$, then 
\[Z_v  = 2^{-2}\frak{c}dot q_v^{-3}\frac{\zeta_v(2)\zeta_v(4)}{\zeta_v(1)^2}.\]
\end{lemma}

\begin{proof}
We drop the subscript $v$ for brevity. First we assume $v\nmid \frak{n}$. By Lemmas \ref{E:matrix coefficients unram}, \ref{L:matrix coefficient nonarchimedean case}, (\ref{E:equivariant property of test vector case v=p not divide N_1N_2}), and \frak{c}ite[Proposition 6.2]{LNM1254} (see also \frak{c}ite[Proposition 3]{LR2005}, \frak{c}ite[Proposition 6.3]{HN2017}), we have
\[
\int_{H_1(k_v)}{\bf P}hi(h_1){\bf P}si(h_1)\,dh_1 = \frac{L(1,\sigma,{\rm std})}{\zeta(2)\zeta(4)}.
\]

Now we assume $v \mid \frak{n}$. The calculations for $v\mid \frak{n}_1$ and $v\mid \frak{n}_2$ are similar and we assume $v \mid \frak{n}_1$. Since $v \in \frak{S}$ and ${\bf f}^\sharp = (W,0) \in \mathcal{V}^{\sharp}$, we have \begin{align*}
{\bf P}si(h) &= 2^{-1}\mathcal{B}(\sigma(h)W,W),\\
{\bf P}si_{ }(h{\bf t}_{ }) &= \mathcal{B}_{ }^{\sharp}((0,\sigma_{ }({\rm Ad}({\bf t}_{ })h)W_{ }),(W_{ },0))=0
\end{align*}
for $h \in H^{\frak{c}irc}(k_v)$. Therefore
\[
Z = 2^{-2}\frak{c}dot\frac{\zeta(2)\zeta(4)}{L(1,\sigma,{\rm std})}\frak{c}dot\int_{H_1^\frak{c}irc(k_v)}{\bf P}hi(h_1)\mathcal{B}(\sigma(h_1)W,W)\,dh_1.
\]

Let $\mathcal{U}$ be the open compact subgroup of $H_1^{\frak{c}irc}(k_v)$ defined by
\[\mathcal{U}=H_1^{\frak{c}irc}(k_v)\frak{c}ap (K_0(\varpi)\mathbf{t}imes \frak{o}peratorname{GL}_2(\frak{o}))/\frak{o}^{\mathbf{t}imes}.\]
For $n,m \in {\mathbb Z}$, let \[h_{n,m} = [{\bf a}(\varpi^n){\bf d}(\varpi^m),{\bf a}(\varpi^{n+m})],\quad h_{n,m}' = [w{\bf a}(\varpi^n){\bf d}(\varpi^m),{\bf a}(\varpi^{n+m})].\] Note that
\[\left\{h_{n,m},h_{n,m}' \mbox{ }\vert\mbox{ }n,m \in {\mathbb Z},\, n+m \geq 0\right\}\]
is a complete set of coset representatives for $\mathcal{U} \backslash H_1^{\frak{c}irc}(k_v) / \mathcal{U}$, and we have
\begin{align}\label{E:cardinalities for double cosets}
\begin{split}
|\,\mathcal{U}h_{n,m}\mathcal{U} / \mathcal{U}\,| &=  \begin{cases} q^{|n-m|} & \mbox{ if }n+m=0,\\  q^{n+m+|n-m|}(1+q^{-1}) & \mbox{ if }n+m \geq 1,   \end{cases}\\
|\,\mathcal{U}h_{n,m}'\mathcal{U} / \mathcal{U}\,| &=\begin{cases} q^{|n-m-1|} & \mbox{ if }n+m=0,\\  q^{n+m+|n-m-1|}(1+q^{-1}) & \mbox{ if }n+m \geq 1.   \end{cases}
\end{split}
\end{align}

By Lemmas \ref{E:matrix coefficients}, \ref{L:matrix coefficient nonarchimedean case}, (\ref{E:equivariant property of test vector case v=p divide N_1}), and (\ref{E:cardinalities for double cosets}), we have
\begin{align*}
{\rm vol}(\mathcal{U},dh_1)^{-1} \int_{H_1^{\frak{c}irc}(k_v)}{\bf P}hi_{ }(h_{1})\mathcal{B}_{ }(\sigma_{ }(h_{1})W_{ },W_{ })\,dh_{1} & = \sum_{n,m \in {\mathbb Z}, \, n+m\geq 0}{\bf P}hi(h_{n,m})\mathcal{B}_{ }(\sigma_{ }(h_{n,m})W_{ },W_{ }) \frak{c}dot|\,\mathcal{U}h_{n,m}\mathcal{U} / \mathcal{U}\,|\\
& + \sum_{n,m \in {\mathbb Z}, \, n+m\geq 0}{\bf P}hi(h_{n,m}')\mathcal{B}_{ }(\sigma_{ }(h_{n,m}')W_{ },W_{ }) \frak{c}dot|\,\mathcal{U}h_{n,m}'\mathcal{U} / \mathcal{U}\,|\\
&=\frac{\zeta(2)}{\zeta(1)}\frak{c}dot(Z^{(1)}+Z^{(2)}+Z^{(3)}+Z^{(4)}),
\end{align*}
where
\begin{align*}
Z^{(1)} &= \sum_{n\in{\mathbb Z}}\left(q^{-4|n|-2}-q^{-2|n|-2|n-1|-2}\right),\\
Z^{(2)} &= (q^{-2}-q^{-4})\sum_{m=1}^{\infty}\varepsilon^mq^{-3m/2}\left(\alpha^{m}\frak{c}dot\frac{1-\alpha^{-2}q^{-1}}{1-\alpha^{-2}}+\alpha^{-m}\frak{c}dot\frac{1-\alpha^2q^{-1}}{1-\alpha^2}\right),\\
Z^{(3)}& = ({q^{-2}-q^{-4}})\sum_{n=1}^{\infty}\sum_{m=n+1}^{\infty}\varepsilon^{-n-m}q^{-5n/2-3m/2}\left(\alpha^{-n+m}\frak{c}dot\frac{1-\alpha^{-2}q^{-1}}{1-\alpha^{-2}}+\alpha^{n-m}\frak{c}dot\frac{1-\alpha^2q^{-1}}{1-\alpha^2}\right),\\
Z^{(4)}& = (q^{-2}-1)\sum_{m=1}^{\infty}\sum_{n=m+1}^{\infty}\varepsilon^{n+m}q^{-3n/2-5m/2}\left(\alpha^{n-m}\frak{c}dot\frac{1-\alpha^{-2}q^{-1}}{1-\alpha^{-2}}+\alpha^{-n+m}\frak{c}dot\frac{1-\alpha^2q^{-1}}{1-\alpha^2}\right).
\end{align*}
By direct calculations, we have
\begin{align*}
Z^{(1)} & = \frac{(q-q^{-1})^2}{q^4-1},\\
Z^{(2)} & = (q^{-2}-q^{-4})\left[\varepsilon q^{-3/2}(\alpha+\alpha^{-1})-q^{-3}-q^{-4}\right](1-\varepsilon\alpha q^{-3/2})^{-1}(1-\varepsilon\alpha^{-1} q^{-3/2})^{-1},\\
Z^{(3)} & = \frac{q^{-2}-q^{-4}}{q^4-1}\frak{c}dot\left[\varepsilon q^{-3/2}(\alpha+\alpha^{-1})-q^{-3}-q^{-4}\right](1-\varepsilon\alpha q^{-3/2})^{-1}(1-\varepsilon\alpha^{-1} q^{-3/2})^{-1},\\
Z^{(4)} & = \frac{q^{-2}-1}{q^4-1}\frak{c}dot\left[\varepsilon q^{-3/2}(\alpha+\alpha^{-1})-q^{-3}-q^{-4}\right](1-\varepsilon\alpha q^{-3/2})^{-1}(1-\varepsilon\alpha^{-1} q^{-3/2})^{-1}.
\end{align*}
Therefore, noting that ${\rm vol}(\mathcal{U},dh_1) = (1+q)^{-1}$ by the normalization (\ref{E:non-archi. integration1}) and that
\[
 L(s,\sigma,{\rm std}) = (1 - \varepsilon \alpha q^{-s-1/2})^{-1} (1 - \varepsilon \alpha^{-1} q^{-s-1/2})^{-1},
\]
we have
\begin{align*}
\int_{H_1^{\frak{c}irc}(k_v)}{\bf P}hi_{ }(h_{1})\mathcal{B}_{ }(\sigma_{ }(h_{1})W_{ },W_{ })\,dh_{1} & = q^{-3} (1-q^{-1})^2  (1 - \varepsilon \alpha q^{-3/2})^{-1} (1 - \varepsilon \alpha^{-1} q^{-3/2})^{-1}\\
& = \frac{L(1,\sigma,{\rm std})}{\zeta(2)\zeta(4)}\frak{c}dot q^{-3}\frac{\zeta(2)\zeta(4)}{\zeta(1)^2} .
\end{align*}
This completes the proof.
\end{proof}

\begin{lemma}\label{L:archi. d.s local zeta integral}
Let $v \in S({\rm DS})$. We have
\[Z_{v} = 2^{-\lambda_{1,v}-\lambda_{2,v}-3}(1+\lambda_{1,v}-\lambda_{2,v})^{-1}\frak{c}dot\begin{cases} 1 & \mbox{ if }v \notin \frak{S},
\\2^{-2} & \mbox{ if }v \in \frak{S}. \end{cases}\]
\end{lemma}

\begin{proof}
We identify $k_v={\mathbb R}$ and drop the subscript $v$ for brevity. Without loss of generality, we assume $\kappa_1 \ge \kappa_2$. 
If $v \notin \frak{S}$, then $\kappa_1=\kappa_2$ and we have  
$\frak{o}mega_{ }(1,{\bf t}_{ })\varphi_{ }=(-1)^{\lambda_1}\varphi_{ }=\varphi_{ }$, $\sigma_{ }^{\sharp}({\bf t}_{ })W=W$, and ${\bf P}si(h) = \mathcal{B}(\sigma(h)W, W)$ for $h \in H^\frak{c}irc({\mathbb R})$. If $v \in \frak{S}$, then  
\begin{align*}
{\bf P}si(h) &= 2^{-1}\mathcal{B}(\sigma(h)W,W),\\
{\bf P}si_{ }(h{\bf t}_{ }) &= \mathcal{B}_{ }^{\sharp}((0,\sigma_{ }({\rm Ad}({\bf t}_{ })h)W_{ }),(W_{ },0))=0
\end{align*}
for $h \in H^{\frak{c}irc}({\mathbb R})$. Therefore, we have
\[
Z_{ } = \frac{\zeta(2)\zeta(4)}{L(1,\sigma,{\rm std})}\frak{c}dot\int_{H_1^{\frak{c}irc}({\mathbb R})}{\bf P}hi_{ }(h_{1})\mathcal{B}_{ }(\sigma_{ }(h_{1})W_{ },W_{ })\,dh_{1}\frak{c}dot \begin{cases} 1 & \mbox{ if }v \notin \frak{S},
\\2^{-2} & \mbox{ if }v \in \frak{S}. \end{cases}
\]

By (\ref{E:archi. integration}), (\ref{E:equivariant property d.s.}), and Lemmas \ref{E:coefficient}, \ref{L:matrix coeff. of Weil rep d.s}, we have
\begin{align*}
&\int_{H_1^{\frak{c}irc}({\mathbb R})}{\bf P}hi_{ }(h_{1})\mathcal{B}_{ }(\sigma_{ }(h_{1})W_{ },W_{ })\,dh_{1} \\
&= 2^{-2-2\kappa_1-\kappa_2}\pi^{2-\kappa_1}{G}amma(\lambda_1+1){G}amma(-\lambda_2+1)\\
&\mathbf{t}imes \int_{0}^{ \infty}\int_{0}^{\infty } \frak{c}osh(t_1+t_2)^{-2}\frak{c}osh(t_1-t_2)^{-2}\left(\frak{c}osh(t_1+t_2)^{-1}+\frak{c}osh(t_1-t_2)^{-1}\right)^{\kappa_1}\\
&\quad\quad\quad\quad\quad\quad\quad\quad\quad\quad\quad\quad\mathbf{t}imes\frak{c}osh(t_1)^{-\kappa_1}\frak{c}osh(t_2)^{-\kappa_2}\sinh(2t_1)\sinh(2t_2)\,dt_1\,dt_2\\
&=2^{-\kappa_2+1}\pi^{2-\kappa_1}{G}amma(\lambda_1+1){G}amma(-\lambda_2+1)\\
&\mathbf{t}imes \int_{0}^{\infty }\int_{0}^{\infty } \frac{\frak{c}osh(t_2)^{-2\lambda_2+1}\sinh(2t_1)\sinh(t_2)}{(\frak{c}osh(2t_1)+\frak{c}osh(2t_2))^{2+\kappa_1}}\,dt_1\,dt_2.
\end{align*}
Here the last equality follows from the formulae
\begin{align*}
\frak{c}osh(t_1+t_2)\frak{c}osh(t_1-t_2) & = 2^{-1}(\frak{c}osh(2t_1)+\frak{c}osh(2t_2)),\\
\frak{c}osh(t_1+t_2)+\frak{c}osh(t_1-t_2) & = 2\frak{c}osh(t_1)\frak{c}osh(t_2),\\
\sinh(2 t_2) &= 2 \sinh(t_2) \frak{c}osh(t_2).
\end{align*}
Moreover, the above integral is equal to 
\begin{align*}
&\int_{0}^{\infty }\frak{c}osh(t_2)^{-2\lambda_2+1}\sinh(t_2)\left(\int_{0}^{ \infty} \frac{\sinh(2t_1)}{(\frak{c}osh(2t_1)+\frak{c}osh(2t_2))^{2+\kappa_1}}\,dt_1\right)\,dt_2\\
&=2^{-1}(1+\kappa_1)^{-1}\int_{0}^{\infty }\frac{\frak{c}osh(t_2)^{-2\lambda_2+1}\sinh(t_2)}{(1+\frak{c}osh(2t_2))^{1+\kappa_1}}\,dt_2\\
&=2^{-2-\kappa_1}(1+\kappa_1)^{-1}\int_{0}^{ \infty}\frak{c}osh(t_2)^{-2\lambda_1-1}\sinh(t_2)\,dt_2\\
&=2^{-3-\kappa_1}\lambda_1^{-1}(1+\kappa_1)^{-1}.
\end{align*}
Noting that 
\[
 L(s,\sigma,{\rm std}) = 2^2 (2 \pi)^{-2s-\lambda_1+\lambda_2+1} {G}amma(s+\lambda_1-1) {G}amma(s-\lambda_2), 
\]
we conclude that
\begin{align*}
\int_{H_1^{\frak{c}irc}({\mathbb R})}{\bf P}hi_{ }(h_{1})\mathcal{B}_{ }(\sigma_{ }(h_{1})W_{ },W_{ })\,dh_{1} &= 2^{-2-2\lambda_1}(1+\kappa_1)^{-1}\pi^{2-\kappa_1}{G}amma(\lambda_1){G}amma(-\lambda_2+1)\\
&=\frac{L(1,\,\sigma,\,{\rm std})}{\zeta_{ }(2)\zeta_{ }(4)}\frak{c}dot 2^{-\lambda_1-\lambda_2-3}(1+\kappa_1)^{-1}.
\end{align*}
This completes the proof.
\end{proof}

\begin{lemma}\label{L:archi. spherical local zeta integral}
Let $v \in S({\rm PS})$. We have
\begin{align*}
Z_v &= 2^{-4}.
\end{align*}
\end{lemma}

\begin{proof}
We identify $k_v={\mathbb R}$ and drop the subscript $v$ for brevity. We follow the doubling method in \frak{c}ite[\S\,6]{LNM1254} and \frak{c}ite{LR2005}. 
Let
$${\rm O}_{2,2} = \left\{ h \in \frak{o}peratorname{GL}_4 \mbox{ }\left\vert\mbox{ } h \begin{pmatrix} 0 & {\bf 1}_2 \\ {\bf 1}_2 & 0\end{pmatrix}  {}^th = \begin{pmatrix} 0 & {\bf 1}_2 \\ {\bf 1}_2 & 0\end{pmatrix} \right. \right\} .$$
We identify $H_1({\mathbb R})$ with ${\rm O}_{2,2}({\mathbb R})$ with respect to the following basis of $V$:
\begin{align*}
	\left\{\begin{pmatrix} 0 & 1 \\ 0 & 0 \end{pmatrix},\, \begin{pmatrix} 1 & 0 \\ 0 & 0 \end{pmatrix},\,  \begin{pmatrix} 0 & 0 \\ -1 & 0 \end{pmatrix},\, \begin{pmatrix} 0 & 0 \\ 0 & 1\end{pmatrix}\right\}.
\end{align*}

Let $Q$ be the standard Siegel parabolic subgroup of ${\rm O}_{2,2}$, $N$ its unipotent radical, and $K_{2,2} = {\rm O}_{2,2}({\mathbb R})\frak{c}ap{\rm O}(4)$ a maximal compact subgroup of ${\rm O}_{2,2}({\mathbb R})$. We regard $\frak{o}peratorname{GL}_2$ as a Levi subgroup of $Q$ via the embedding 
\begin{align*}
\frak{o}peratorname{GL}_2 \longrightarrow Q,\quad
g  \longmapsto \underline{g}=\begin{pmatrix} g& 0 \\ 0 &{}^tg^{-1}\end{pmatrix}.
\end{align*}
Then we have
$$\sigma^{\sharp}\vert_{{\rm O}_{2,2}({\mathbb R})} = {\rm Ind}_{Q({\mathbb R})}^{{\rm O}_{2,2}({\mathbb R})}(\mathbf{t}au),$$
where
\[\mathbf{t}au = {\rm Ind}_{B({\mathbb R})}^{\frak{o}peratorname{GL}_2({\mathbb R})}(|\mbox{ }|^{\mu_1+\mu_2}\boxtimes |\mbox{ }|^{\mu_1-\mu_2}).\]
Denote by $\frak{o}mega_\mathbf{t}au$ and $\frak{o}mega_{\mathbf{t}au^{\vee}}$ the bi-${\rm O}(2)$-invariant matrix coefficients of $\mathbf{t}au$ and $\mathbf{t}au^{\vee}$, respectively, normalized so that $\frak{o}mega_\mathbf{t}au(1)=\frak{o}mega_{\mathbf{t}au^{\vee}}(1)=1$.
We identify ${\rm O}_{2,2}\mathbf{t}imes{\rm O}_{2,2}$ with its image under the embedding 
\[
{\rm O}_{2,2} \mathbf{t}imes{\rm O}_{2,2}\longrightarrow {\rm O}_{4,4},\quad	\left(\begin{pmatrix} a & b \\ c & d \end{pmatrix} , \begin{pmatrix}  a' & b' \\ c' & d' \end{pmatrix} \right) \longrightarrow \begin{pmatrix} a & 0 & b & 0 \\ 0 & a' & 0 & -b' \\ c & 0 & d & 0 \\ 0 & -c' & 0 & d'  \end{pmatrix}.
\]
Let $P$ be the standard Siegel parabolic subgroup of ${\rm O}_{4,4}$ and $K_{4,4} = {\rm O}_{4,4}({\mathbb R}) \frak{c}ap {\rm O}(8)$ a maximal compact subgroup of ${\rm O}_{4,4}({\mathbb R})$. We regard $\frak{o}peratorname{GL}_4$ as a Levi subgroup of $P$ via the embedding 
\[
\frak{o}peratorname{GL}_4 \longrightarrow P,\quad
g  \longmapsto \underline{g}=\begin{pmatrix} g& 0 \\ 0 &{}^tg^{-1}\end{pmatrix}.
\]
Let $f^o$ be the right $K_{4,4}$-invariant section of the degenerate principal series representation ${\rm Ind}_{P({\mathbb R})}^{{\rm O}_{4,4}({\mathbb R})}(\delta_P^{s/3})$ normalized so that $f^o(\delta,s)=1$, where
\[
 \delta =
 \begin{pmatrix}
  0 & 0 & \frac{1}{2} \mathbf{1}_2 & \frac{1}{2} \mathbf{1}_2 \\
  \frac{1}{2} \mathbf{1}_2 & -\frac{1}{2} \mathbf{1}_2 & 0 & 0 \\
  \mathbf{1}_2 & \mathbf{1}_2 & 0 & 0 \\
  0 & 0 & \mathbf{1}_2 & -\mathbf{1}_2
 \end{pmatrix}.
\]

Consider the integral
\[\frak{c}alZ(s) = \int_{{\rm O}_{2,2}({\mathbb R})}f^o(\delta(h,1),s){\bf P}si(h)\,dh.\]
By \frak{c}ite[Lemma 7.7]{GI2011}, the integral $\frak{c}alZ(s)$ is absolutely convergent at $s=1/2$.
By Lemma \ref{L:matrix coeff. of Weil rep PS} and \frak{c}ite[Proposition 6.4]{LNM1254}, we have
\[{\bf P}hi(h) = 2^{-4}\frak{c}dot f^o\left(\delta(h,1),\frac{1}{2}\right)\]
for $h \in {\rm O}_{2,2}({\mathbb R})$. Therefore
\[Z = 2^{-4}\frak{c}dot\frac{\zeta(2)\zeta(4)}{L(1,\sigma,{\rm std})}\frak{c}dot\frak{c}alZ\left(\frac{1}{2}\right).\]
Let $\langle\ ,\ \rangle_{\mathbf{t}au} : \mathbf{t}au \mathbf{t}imes \mathbf{t}au^\vee \rightarrow {\mathbb C}$ be a non-zero invariant pairing. Let
$\phi \in {\rm Ind}_{Q({\mathbb R})}^{{\rm O}_{2,2}({\mathbb R})}(\mathbf{t}au)$ and $\phi^\vee \in {\rm Ind}_{Q({\mathbb R})}^{{\rm O}_{2,2}({\mathbb R})}(\mathbf{t}au^\vee)$ be non-zero $K_{2,2}$-invariant sections. Then
\[
{\bf P}si(h) = {\bf P}si(1)\frak{c}dot\int_{K_{2,2}}\frac{\langle\phi(kh),\phi^\vee(k)\rangle_{\mathbf{t}au}}{\langle\phi(1),\phi^\vee(1)\rangle_\mathbf{t}au}\,dk
\]
for $h \in {\rm O}_{2,2}({\mathbb R})$. Note that ${\bf P}si(1) = 2^{-4}$ by Lemma \ref{E:coefficient PS}. Therefore, we have
\begin{align*}
\frak{c}alZ(s) & = 2^{-4}\int_{{\rm O}_{2,2}({\mathbb R})}f^o(\delta(h,1),s)\int_{K_{2,2}} \frac{\langle\phi(kh),\phi^\vee(k)\rangle_{\mathbf{t}au}}{\langle\phi(1),\phi^\vee(1)\rangle_\mathbf{t}au} \,dk\,dh\\
& = 2^{-4}\int_{K_{2,2}}\int_{{\rm O}_{2,2}({\mathbb R})}f^o(\delta(h,k),s) \frac{\langle\phi(h),\phi^\vee(k)\rangle_{\mathbf{t}au}}{\langle\phi(1),\phi^\vee(1)\rangle_\mathbf{t}au} \,dh\,dk \\
& = 2^{-4}\int_{K_{2,2}\mathbf{t}imes K_{2,2}} \int_{\frak{o}peratorname{GL}_2({\mathbb R})} \int_{N({\mathbb R})} \delta_Q(\underline{g})^{-1/2} f^o(\delta(u\underline{g}k_1,k_2),s)\frak{o}mega_{\mathbf{t}au}(g) \,du\,dg\,dk_1\,dk_2\\
& = 2^{-4}\int_{\frak{o}peratorname{GL}_2({\mathbb R})} \int_{N({\mathbb R})} \delta_Q(\underline{g})^{-1/2} f^o(\delta(u\underline{g},1),s)\frak{o}mega_{\mathbf{t}au}(g) \,du\,dg.
\end{align*}
Let 

\[A = \begin{pmatrix} 0 & {\bf 1}_2 \\ {\bf 1}_2 & {\bf 1}_2\end{pmatrix}.\]
Then the  function 

\[F_1^o(g,s) = |\det(g)|^{-1/2}\int_{N({\mathbb R})}f^o(\delta (u,1)\underline{A}^{-1}\underline{g},s) \,du\]
for $g \in \frak{o}peratorname{GL}_4({\mathbb R})$ defines an ${\rm O}(4)$-invariant section of ${\rm Ind}_{P'({\mathbb R})}^{\frak{o}peratorname{GL}_4({\mathbb R})}(\delta_{P'}^{s/2})$, where
\[P' = \left\{\left. \begin{pmatrix} a & * \\ 0 & d \end{pmatrix}\mbox{ }\right\vert \mbox{ }a,d \in \frak{o}peratorname{GL}_2 \right\}.\]
On the other hand, an ${\rm O}(4)$-invariant section of ${\rm Ind}_{P'({\mathbb R})}^{\frak{o}peratorname{GL}_4({\mathbb R})}(\delta_{P'}^{s/2})$ is also given by
\[F_2^o(g,s) = |\det(g)|^{s+1}\int_{\frak{o}peratorname{GL}_2({\mathbb R})}{\bf P}hi^o((0,x)g)|\det(x)|^{2s+2}\,dx\]
for $g \in \frak{o}peratorname{GL}_4({\mathbb R})$, where ${\bf P}hi^o \in \mathcal{S}({\rm M}_{2,4}({\mathbb R}))$ is defined by
\[{\bf P}hi^o(x) = e^{-\pi\,{\rm tr}(x{}^tx)}.\]
Therefore, 
\[F_1^o = \frac{F_1^o({A},s)}{F_2^o({A},s)}\frak{c}dot F_2^o.\]
By direct calculations, we have
\[F_1^o({A},s) = 2\frak{c}dot\frac{\zeta(2s+2)}{\zeta(2s+3)},\quad F_2^o({A},s) = 2^{-2s-2}\zeta(2s+1)\zeta(2s+2).\]

Hence
\[
\frac{F_1^o({A},s)}{F_2^o({A},s)} = 2^{2s+3}\zeta(2s+1)^{-1}\zeta(2s+3)^{-1}.\]
We conclude that
\begin{align*}
& \int_{\frak{o}peratorname{GL}_2({\mathbb R})} \int_{N({\mathbb R})} \delta_Q(\underline{g})^{-1/2} f^o(\delta(u\underline{g},1),s)\frak{o}mega_{\mathbf{t}au}(g) \,du\,dg\\
& = \int_{\frak{o}peratorname{GL}_2({\mathbb R})} F_1^o\left({A}\begin{pmatrix} g & 0 \\ 0 & {\bf 1}_2\end{pmatrix},s \right)\frak{o}mega_{\mathbf{t}au}(g) \,dg\\
& = 2^{2s+3}\zeta(2s+1)^{-1}\zeta(2s+3)^{-1}\int_{\frak{o}peratorname{GL}_2({\mathbb R})}|\det(g_1)|^{s+1}\left(\int_{\frak{o}peratorname{GL}_2({\mathbb R})}{\bf P}hi^o(g_2g_1,g_2)|\det(g_2)|^{2s+2}\,dg_2\right)\frak{o}mega_{\mathbf{t}au}(g_1)\,dg_1.
\end{align*}
Noting that $\frak{o}mega_\mathbf{t}au$ is a zonal spherical function on $\frak{o}peratorname{GL}_2({\mathbb R})$ with respect to ${\rm O}(2)$ 
and following the argument in the proof of \frak{c}ite[Proposition (1.2.5)]{Macdonald1971}, we have
\[
\int_{{\rm O}(2)}\frak{o}mega_{\mathbf{t}au}(g_1kg_2)\,dk = \frak{o}mega_{\mathbf{t}au}(g_1)\frak{o}mega_{\mathbf{t}au}(g_2)
\]
for $g_1,g_2 \in \frak{o}peratorname{GL}_2({\mathbb R})$. Therefore, proceeding as in the proof of \frak{c}ite[Proposition 6.1]{LNM1254}, we have
\begin{align*}
&\int_{\frak{o}peratorname{GL}_2({\mathbb R})}|\det(g_1)|^{s+1}\left(\int_{\frak{o}peratorname{GL}_2({\mathbb R})}{\bf P}hi^o(g_2g_1,g_2)|\det(g_2)|^{2s+2}\,dg_2\right)\frak{o}mega_{\mathbf{t}au}(g_1)\,dg_1\\
&=\int_{\frak{o}peratorname{GL}_2({\mathbb R})}e^{-\pi\,{\rm tr}(g{}^tg)}\frak{o}mega_\mathbf{t}au(g)|\det(g)|^{s+1}\,dg \int_{\frak{o}peratorname{GL}_2({\mathbb R})}e^{-\pi\,{\rm tr}(g{}^tg)}\frak{o}mega_{\mathbf{t}au^{\vee}}(g)|\det(g)|^{s+1}\,dg\\
&=L\left(s+\frac{1}{2},\sigma,{\rm std}\right).
\end{align*}
Here the last equality follows from a calculation analogous to \frak{c}ite[Lemma 6.10]{GJ1972}.

It follows that
\[
\frak{c}alZ(s) = 2^{2s-1}\frak{c}dot\frac{L(s+1/2,\sigma,{\rm std})}{\zeta(2s+1)\zeta(2s+3)}.
\]
This completes the proof.

\end{proof}

\subsection{Proof of Proposition \ref{P:Rallis inner product}}\label{S:proof 2}
The assertion follows from Theorem \ref{T:RIF} and Lemmas \ref{L:zeta integral1}-\ref{L:archi. spherical local zeta integral}.

\section{Convergence lemmas}

We keep the notation of \S\,\ref{SS:analytic family}. In this section, we study the convergence of the doubling local zeta integrals and the Rankin-Selberg local zeta integrals defined in (\ref{E:local zeta1}) and (\ref{E:local zeta2}), respectively. 

Except in Lemma \ref{L:local zeta Ur}, let $\pi$ be a representation of $G(F)$ in one of the three types in \S\,\ref{SS:analytic family}. In Case (IIa) and Case (PS), we fix a sign of representations and write $\pi=\pi_\lambda$ for the representation with parameter $\lambda$. Let ${\boldsymbol \omega}ega$ be the domain defined by excluding the points of reducibility of the induced representations (\ref{E:induced repre IIa}) and (\ref{E:induced repre PS}) in Case (IIa) and Case (PS), respectively. Recall the domain 
\[
\mathcal{D} = 
\begin{cases}
\left\{\lambda \in {\mathbb C} \mbox{ }\vert\mbox{ } |{\rm Re}(\lambda) |<1/2 \right\} & \mbox{ in Case (IIa)},\\
\left\{\lambda=(\lambda_1,\lambda_2) \in {\mathbb C}^2 \mbox{ }\vert\mbox{ }|{\rm Re}(\lambda_1)|+|{\rm Re}(\lambda_2)|<1 \right\} & \mbox{ in Case (PS)},
\end{cases}
\]
defined in (\ref{E:domain}).
Let 
\[
K= \begin{cases}
G(\frak{o}) & \mbox{ if $F$ is non-archimedean},\\
G({\mathbb R}) \frak{c}ap {\rm O}(4) & \mbox{ if $F={\mathbb R}$}.
\end{cases}
\]

\subsection{Doubling local zeta integrals}\label{SS:Doubling local zeta integrals}
Recall $P=P_{4,4}$ and $I(s)=I_{4,4}(s)$ in the notation of \S\,\ref{ss:eisenstein}. Denote by $\mathcal{C}(\pi)$ the space of matrix coefficients of $\pi$. If $\phi \in \mathcal{C}(\pi)$  and $F\in I(s)$ is a holomorphic section, let $Z(s,\phi,F)$ be the local zeta integal defined as in (\ref{E:local zeta1}). 

\begin{lemma}\label{L:local zeta Ur}
Assume $\pi$ is an irreducible generic admissible unramified representation of $G(F)$ with trivial central character. Write 
\begin{align*}
\pi \vert_{\frak{o}peratorname{Sp}_4(F)} = {\rm Ind}_{\frak{o}peratorname{Sp}_4(F)\frak{c}ap {\bf B}(F)}^{\frak{o}peratorname{Sp}_4(F)}(|\mbox{ }|^{\lambda_{1}}\boxtimes|\mbox{ }|^{\lambda_{2}})
\end{align*}
for some $\lambda_1$, $\lambda_2 \in {\mathbb C}$. 
Let $\phi\in\mathcal{C}(\pi)$ and let $F \in I(s)$ be a holomorphic section. 
The integral $Z(s,\phi,F)$ is absolutely convergent for ${\rm Re}(s)>-1/2+\max\{|{\rm Re}(\lambda_1)|,|{\rm Re}(\lambda_2)|\}$.
\end{lemma}

\begin{proof}
Let $s \in {\mathbb R}R$.
Let $K_1 = \frak{o}peratorname{Sp}_4(\mathfrak{o})$ and
\[
 A^{+} =
 \{ \operatorname{diag}( \varpi^{n_1}, \varpi^{n_2}, \varpi^{-n_1}, \varpi^{-n_2} )
 \, | \, n_1 \ge n_2 \ge 0 \}.
\]
Then $\frak{o}peratorname{Sp}_4(F) = K_1 A^{+} K_1$.
We may assume that $\phi$ is bi-$G(\frak{o})$-invariant, $F$ is $\frak{o}peratorname{GSp}_8(\mathfrak{o})$-invariant, and $F(1,s) = 1$.
In particular,
\[
 F(\delta (k_1 g k_2, 1), s) = F(\delta (g, 1), s)
\]
for all $k_1, k_2 \in K_1$.
Let
\[
 a = 
 \operatorname{diag}( \varpi^{n_1}, \varpi^{n_2}, \varpi^{-n_1}, \varpi^{-n_2} )
 \in A^{+}.
\]
By \frak{c}ite[p.~241]{Wald2003},
there exists a constant $C > 0$ such that
\[
 \operatorname{vol}(K_1aK_1) \le C q^{4n_1 + 2n_2}.
\]
By \frak{c}ite[Proposition 6.4]{LNM1254},
\[
 F(\delta (a, 1), s) = q^{- (s + {5}/{2})(n_1 + n_2)}.
\]
By Macdonald's formula \frak{c}ite{Macdonald1971}, \frak{c}ite{Casselman1980},
there exists a polynomial ${\bf P}si$ such that
\[
 |\phi(a)| \le {\bf P}si(n_1) q^{-2n_1 - n_2 + \eta(n_1 + n_2)},
\]
where $\eta = \max\{|{\rm Re}(\lambda_{1})|,|{\rm Re}(\lambda_{2})|\}$. 
Hence $|Z(s, \phi, F)|$ is majorized by
\begin{align*}
 & \sum_{a \in A^{+}} \operatorname{vol}(K_1aK_1) F(\delta (a,1), s) |\phi(a)| \\
 & \le C \sum_{n_2 = 0}^{\infty}\sum_{n_1 = n_2}^{\infty}
 {\bf P}si(n_1)
 q^{- (s + {1}/{2} - \eta) n_1} q^{- (s + {3}/{2} - \eta) n_2}.
\end{align*}
This completes the proof.
\end{proof}

\begin{lemma}\label{L:local zeta DS}
Assume $\pi$ is of type (DS). Let $\phi\in\mathcal{C}(\pi)$  and let $F \in I(s)$ be a holomorphic section.  The integral $Z(s, \phi, F)$ is 
absolutely convergent for ${\mathbb R}e(s) > -{1}/{2}$.
\end{lemma}

\begin{proof}
Fix $s > - {1}/{2}$.
By H\"older's inequality,
it suffices to show that the integral
\begin{equation} \label{eq:doubling_infty}
 \int_{\frak{o}peratorname{Sp}_4({\mathbb R})} |F(\delta (g,1), s)|^{2(1-\end{pmatrix}silon)} \,dg  
\end{equation}
is convergent for some $\end{pmatrix}silon>0$.
Let $K_1 = \frak{o}peratorname{Sp}_4({\mathbb R}) \frak{c}ap \operatorname{O}(4)$ and
\[
 \mathfrak{a}^{+} = \{ \operatorname{diag}(X_1, X_2, -X_1, -X_2) \, | \, X_1 \ge X_2 \ge 0 \}.
\]
Then $\frak{o}peratorname{Sp}_4({\mathbb R}) = K_1 \exp(\mathfrak{a}^{+}) K_1$.
We may assume that $F$ is $(\frak{o}peratorname{GSp}_8({\mathbb R}) \frak{c}ap \operatorname{O}(8))$-invariant and
$F(1,s) = 1$.
In particular,
\[
 F(\delta (k_1 g k_2, 1), s) = F(\delta (g, 1), s)
\]
for all $k_1, k_2 \in K_1$.
Let $\Delta^{+}$ be the set of positive roots
determined by the chamber $\mathfrak{a}^{+}$.
Let
\[
 X = \operatorname{diag}(X_1, X_2, -X_1, -X_2) \in \mathfrak{a}^{+}
\]
and $a_i = \exp(X_i)$.
By \frak{c}ite[Proposition 6.4]{LNM1254},
\[
 F(\delta (\exp(X), 1), s) =
 \left( \operatorname{pr}od_{i=1}^2 \sqrt{(1+a_i^2)(1+a_i^{-2})} \right)^{-s -{5}/{2}}
 \le (a_1 a_2)^{-s-{5}/{2}}.
\]
Obviously,
\[
 \left| \operatorname{pr}od_{\alpha \in \Delta^{+}} \sinh(\alpha(X)) \right|
 \le a_1^4 a_2^2.
\]
Hence the integral \eqref{eq:doubling_infty} is majorized by
\begin{align*}
 & \int_{\mathfrak{a}^{+}} \int_{K_1 \mathbf{t}imes K_1}
 \left\vert F(\delta (k_1 \exp(X) k_2, 1), s)\right\vert^{2(1-\end{pmatrix}silon)}
 \left| \operatorname{pr}od_{\alpha \in \Delta^{+}} \sinh(\alpha(X)) \right| 
 \, dk_1 \, dk_2 \, dX \\
 & \le \int_{1}^{\infty}\int_{a_2}^{\infty} 
 a_1^{-2s-1+2\end{pmatrix}silon s +5 \end{pmatrix}silon} 
 a_2^{-2s-3+2\end{pmatrix}silon s +5 \end{pmatrix}silon}
 \, d^{\mathbf{t}imes} a_1 \, d^{\mathbf{t}imes} a_2.
\end{align*}
This completes the proof.
\end{proof}

Assume $\pi=\pi_\lambda$ is of type (IIa) or (PS) with parameter $\lambda$. Recall that $P_{2,2}$ is the standard Siegel parabolic subgroup of $G$. We may write
\[
\pi_\lambda = \begin{cases}
\displaystyle{{\rm Ind}_{P_{2,2}(F)}^{G(F)}(\mathbf{t}au_\lambda \boxtimes \mathbf{t}imesi^\varepsilon|\mbox{ }|^{-\lambda})} & \mbox{ in Case (IIa)},\\
\displaystyle{{\rm Ind}_{P_{2,2}({\mathbb R})}^{G({\mathbb R})}(\mathbf{t}au_\lambda \boxtimes {\rm sgn}^\varepsilon|\mbox{ }|^{(-\lambda_1-\lambda_2)/2})} & \mbox{ in Case (PS)},
\end{cases}
\]
where $\mathbf{t}au_\lambda$ is the representation of $\frak{o}peratorname{GL}_2(F)$ defined by
\[
\mathbf{t}au_\lambda = \begin{cases}
\displaystyle{{\rm St}\frak{o}times |\mbox{ }|^\lambda} & \mbox{ in Case (IIa)},\\
\displaystyle{{\rm Ind}_{B({\mathbb R})}^{\frak{o}peratorname{GL}_2({\mathbb R})}(|\mbox{ }|^{\lambda_1}\boxtimes|\mbox{ }|^{\lambda_2})} & \mbox{ in Case (PS)}.
\end{cases}
\]
Let \[
{\bf K} = \begin{cases}
\frak{o}peratorname{GL}_2(\frak{o}) & \mbox{ in Case (IIa)},\\
{\rm O}(2) & \mbox{ in Case (PS)}.
\end{cases}
\]
Note that the restrictions of $\pi_\lambda$ and $\mathbf{t}au_\lambda$ to $K$ and ${\bf K}$, respectively, do not depend on $\lambda$. We may realize the representation $\mathbf{t}au_\lambda$ (resp. $\mathbf{t}au_\lambda^\vee$) on a space $\mathcal{V}$ (resp. $\mathcal{V}^\vee$) which dose not depend on $\lambda$ and on which the action of $\mathbf{t}au_\lambda \vert_{\bf K}$ (resp. $\mathbf{t}au_\lambda^\vee \vert_{\bf K}$) does not depend on $\lambda$, and fix a bilinear pairing
$\langle \ , \ \rangle : \mathcal{V} \mathbf{t}imes \mathcal{V}^\vee \rightarrow {\mathbb C}$ which is invariant with respect to the actions of $\mathbf{t}au_\lambda$ and $\mathbf{t}au^\vee_\lambda$ for all $\lambda$.
We call a map
\[
{\boldsymbol \omega}ega \longrightarrow C^\infty(G(F)),\quad \lambda \longmapsto \phi_\lambda
\]
a $K$-finite analytic family of matrix coefficients if it 
satisfies the following conditions:
\begin{itemize}
\item The map $(\lambda,g) \mapsto \phi_\lambda(g)$ is continuous.
\item For each $g \in G(F)$, the map $\lambda \mapsto \phi_\lambda(g)$ is analytic.
\item For each $\lambda \in {\boldsymbol \omega}ega$, the function $g \mapsto \phi_\lambda(g)$ belongs to $\mathcal{C}(\pi_\lambda)$.
\item There exist finitely many irreducible representations $\rho_i$ of $K\mathbf{t}imes K$ such that $\phi_\lambda$ is contained in the direct sum of the $\rho_i$-isotypic subspaces of $\mathcal{C}(\pi_\lambda)$ for all $\lambda \in {\boldsymbol \omega}ega$.
\end{itemize}
We call a map
\[
{\boldsymbol \omega}ega \mathbf{t}imes G(F)  \longrightarrow \mathcal{V},\quad (\lambda,g) \longmapsto h_\lambda(g)
\]
a $K$-finite analytic section of $\pi_\lambda$ if it satisfies the following conditions:
\begin{itemize}
\item For each $v^\vee \in \mathcal{V}^\vee$, the map $(\lambda,g)\mapsto \langleh_\lambda(g),v^\vee\rangle$ is continuous.
\item For each $g \in G(F)$ and $v \in \mathcal{V}^\vee$, the map $\lambda \mapsto \langleh_\lambda(g),v^\vee\rangle$ is analytic.
\item For each $\lambda \in {\boldsymbol \omega}ega$, the map $g \mapsto h_\lambda(g)$ belongs to $\pi_\lambda$.
\item There exist finitely many irreducible representations $\rho_i$ of $K$ such that $h_\lambda$ is contained in the direct sum of the $\rho_i$-isotypic subspaces of $\pi_\lambda$ for all $\lambda \in {\boldsymbol \omega}ega$.

\end{itemize}
Similarly, we define the notion of $K$-finite analytic sections of $\pi^\vee_\lambda$. Given $K$-finite analytic sections $h_\lambda$ and $h^\vee_\lambda$ of $\pi_\lambda$ and $\pi^\vee_\lambda$, respectively, it is easy to show that the map
\begin{align}\label{E:explicit analytic family for mc}
\lambda \longmapsto \left[g \mapsto\int_{K\frak{c}ap \frak{o}peratorname{Sp}_4(F)}\langleh_\lambda(kg),h_\lambda^\vee(k)\rangle\,dk\right]
\end{align}
defines a $K$-finite analytic family of matrix coefficients. Moreover, for any fixed $\lambda_0 \in {\boldsymbol \omega}ega$, any $K$-finite analytic family of matrix coefficients can be written as a linear combination, with analytic functions of $\lambda$ as coefficients, of $K$-finite analytic families of the form (\ref{E:explicit analytic family for mc}) in a neighborhood of $\lambda_0$.

\begin{lemma}\label{L:ab1}

Let $\phi_\lambda$ be a $K$-finite analytic family of matrix coefficients and $F \in I(s)$ a holomorphic section.  The integral $Z(s,\phi_\lambda,F)$ is absolutely convergent for 
\begin{align*}
\begin{cases}
{\rm Re}(s)>-1/2+\max\{0,|{\rm Re}(\lambda)|-1/2\} & \mbox{ in Case (IIa)},\\ 
{\rm Re}(s)>-1/2+\max\{|{\rm Re}(\lambda_{1})|,|{\rm Re}(\lambda_{2})|\} & \mbox{ in Case (PS)}, 
\end{cases}
\end{align*}
uniformly for $\lambda$ varying in a compact set. In particular, the integral is absolutely convergent for ${\rm Re}(s) \geq 1/2$ if $\lambda \in \mathcal D$.
\end{lemma}

\begin{proof}
Since we only consider the convergence for $\lambda$ varying in a compact set, we may assume $\phi_\lambda$ is of the form (\ref{E:explicit analytic family for mc}) for some $K$-finite analytic sections $h_\lambda$ and $h_\lambda^\vee$ of $\pi_\lambda$ and $\pi^\vee_\lambda$, respectively. Let $Q$ be the standard Siegel parabolic subgroup of $\frak{o}peratorname{Sp}_4$ and $N$ its unipotent radical. We identify $\frak{o}peratorname{GL}_2$ with a Levi subgroup of $Q$ via the embedding
\[\frak{o}peratorname{GL}_2 \longrightarrow Q,\quad g \longmapsto \underline{g} = \begin{pmatrix} g & 0 \\ 0 & {}^tg^{-1}\end{pmatrix}.\]
Then
\begin{align*}
Z(s,\phi_\lambda,F) & = \int_{\frak{o}peratorname{Sp}_4(F)}F(\delta(g,1),s)\int_{K\frak{c}ap \frak{o}peratorname{Sp}_4(F)} \langleh_\lambda(kg),h_\lambda^\vee(k)\rangle \,dk\,dg\\
& = \int_{K\frak{c}ap \frak{o}peratorname{Sp}_4(F)}\int_{\frak{o}peratorname{Sp}_4(F)}F(\delta(g,k),s) \langleh_\lambda(g),h_\lambda^\vee(k)\rangle \,dg\,dk \\
& = \int_{(K\frak{c}ap \frak{o}peratorname{Sp}_4(F))^2} \int_{\frak{o}peratorname{GL}_2(F)} \int_{N(F)} \delta_Q(\underline{g})^{-1/2} F(\delta(u\underline{g}k_1,k_2),s)\langle\mathbf{t}au_\lambda(g)h_\lambda(k_1),h_\lambda^\vee(k_2)\rangle \,du\,dg\,dk_1\,dk_2.
\end{align*}
Recall that $P\frak{c}ap \frak{o}peratorname{Sp}_8$ is the standard Siegel parabolic subgroup of $\frak{o}peratorname{Sp}_8$. We identify $\frak{o}peratorname{GL}_4$ with a Levi subgroup of $P\frak{c}ap \frak{o}peratorname{Sp}_8$ via the embedding
\[\frak{o}peratorname{GL}_4 \longrightarrow P\frak{c}ap \frak{o}peratorname{Sp}_8,\quad a \longmapsto \underline{a} = \begin{pmatrix} a & 0 \\ 0 & {}^ta^{-1}\end{pmatrix}.\] Let $P'$ be the parabolic subgroup of $\frak{o}peratorname{GL}_4$ defined by
\[P' = \left\{\left. \begin{pmatrix} a & * \\ 0 & d \end{pmatrix}\mbox{ }\right\vert \mbox{ }a,d \in \frak{o}peratorname{GL}_2 \right\}.\]

For $g \in \frak{o}peratorname{Sp}_8(F)$, define ${\bf P}si(g,s) \in {\rm Ind}_{P'(F)}^{\frak{o}peratorname{GL}_4(F)}(\delta_{P'}^{s/2})$ by
\[{\bf P}si(g,s)(a) = |\det(a)|^{-3/2}\int_{N(F)}F(\delta (u,1)\underline{A}^{-1}\underline{a}\,g,s) \,du\]
for $a \in \frak{o}peratorname{GL}_4(F).$ Here 
\[A= \begin{pmatrix} 0 & {\bf 1}_2 \\ {\bf 1}_2 & -{\bf 1}_2\end{pmatrix}. \]
Note that ${\bf P}si(g,s)$ is an intertwining integral (cf.\,\frak{c}ite[Lemma 6.2]{LNM1254} and \frak{c}ite[Proposition 1]{LR2005}) and absolutely convergent for ${\rm Re}(s)>-1/2$.
Then
\[
Z(s,\phi_\lambda,F)  = \int_{(K\frak{c}ap \frak{o}peratorname{Sp}_4(F))^2} \int_{\frak{o}peratorname{GL}_2(F)} {\bf P}si((k_1,k_2),s)\left(A \begin{pmatrix} g & 0 \\ 0 & {\bf 1}_2  \end{pmatrix}  \right)\langle\mathbf{t}au_\lambda(g)h_\lambda(k_1),h_\lambda^\vee(k_2)\rangle \,dg\,dk_1\,dk_2.
\]

Let $\eta = \max\{|{\rm Re}(\lambda_{1})|,|{\rm Re}(\lambda_{2})|\}$  and $\mu = \min\{{\rm Re}(\lambda_1),{\rm Re}(\lambda_2)\}$ in Case (PS). Fix $s \in {\mathbb R}$ such that 
\[
\begin{cases}
s>-1/2+\max\{0,|{\rm Re}(\lambda)|-1/2\} & \mbox{ in Case (IIa)},\\
s>-1/2+\eta & \mbox{ In Case (PS)}.
\end{cases}
\]
It suffices to show that the integral
\begin{align}\label{eq:doubling_PS}
\int_{(K\frak{c}ap \frak{o}peratorname{Sp}_4(F))^2} \int_{\frak{o}peratorname{GL}_2(F)} \left\vert{\bf P}si((k_1,k_2),s)\left(A \begin{pmatrix} g & 0 \\ 0 & {\bf 1}_2  \end{pmatrix}  \right)\langle\mathbf{t}au_\lambda(g)h_\lambda(k_1),h_\lambda^\vee(k_2)\rangle \right\vert \,dg\,dk_1\,dk_2
\end{align}
is uniformly convergent for $\lambda$ varying in a compact set. We may assume the section $F$ is $\frak{o}peratorname{GSp}_8(\frak{o})$-invariant (resp.~$(\frak{o}peratorname{GSp}_8({\mathbb R})\frak{c}ap {\rm O}(8))$-invariant) in Case (IIa) (resp.~Case (PS)). Let $f^o \in {\rm Ind}_{P'(F)}^{\frak{o}peratorname{GL}_4(F)}(\delta_{P'}^{s/2})$ be the $\frak{o}peratorname{GL}_4(\frak{o})$-invariant section (resp.~${\rm O}(4)$-invariant section) in Case (IIa) (resp.~Case (PS)) defined by
\[f^o(a,s) = |\det(a)|^{s+1}\int_{\frak{o}peratorname{GL}_2(F)}{\bf P}hi^o((0,x)a)|\det(x)|^{2s+2}\,dx\]
for $a \in \frak{o}peratorname{GL}_4(F)$. Here ${\bf P}hi^o \in \mathcal{S}({\rm M}_{2,4}(F))$ is given by
\[
{\bf P}hi^o(x) = \begin{cases}
{\mathbb I}_{{\rm M}_{2,4}(\frak{o})}(x) & \mbox{ in Case (IIa)},\\
e^{-\pi\,{\rm tr}(x{}^tx)} & \mbox{ in Case (PS)}.
\end{cases}
\]
Note that the above integral is absolutely convergent since $s>-1/2$. Then
\[{\bf P}si(1,s) = \frac{{\bf P}si(1,s)({A})}{f^o({A},s)}\frak{c}dot f^o.\]

Put $F^+ = \{ \nu \in F^{\mathbf{t}imes}\mbox{ }\vert\mbox{ }|\nu| \leq 1\}$. 

There is a function $\mathbf{t}imesi$ on $F^+$ such that $0 \leq \mathbf{t}imesi(\nu) \leq C\frak{c}dot |\nu|^{-1}$ for some constant $C$ and such that 
\[\int_{\frak{o}peratorname{GL}_2(F)}f(g)\,dg = \int_{F^{\mathbf{t}imes}}\int_{F^+}\int_{{\bf K}\mathbf{t}imes {\bf K}}f(tk_1{\bf a}(\nu)k_2)\mathbf{t}imesi(\nu) \,dk_1\,dk_2\,d^{\mathbf{t}imes}\nu\,d^{\mathbf{t}imes}t \]
for all $f \in L^1(\frak{o}peratorname{GL}_2(F))$.
Let $0<\end{pmatrix}silon<s+1/2-\eta$ in Case (PS). 

There exists a constant $C_\lambda>0$ in Case (IIa) (resp.~$C_{\lambda,\end{pmatrix}silon}>0$ in Case (PS)) bounded uniformly as $\lambda$ varies in a compact set such that
\[
\left\vert\langle\mathbf{t}au_\lambda(k_1 {\bf a}(\nu) k_2)h_\lambda(k_3),h_\lambda^\vee(k_4)\rangle\right\vert \leq \begin{cases}
C_{\lambda}\frak{c}dot|\nu|^{{\rm Re}(\lambda)+1} & \mbox{ in Case (IIa)},\\
C_{\lambda,\end{pmatrix}silon}\frak{c}dot|\nu|^{\mu+1/2-\end{pmatrix}silon} & \mbox{ in Case (PS)},
\end{cases}
\]
for all $\nu \in F^+$, $k_1,k_2 \in {\bf K}$, and $k_3,k_4 \in K$. 
In Case (IIa), we have
\[
f^o\left(A\begin{pmatrix} \varpi^m{\bf a}(\varpi^n) & 0 \\ 0 & {\bf 1}_2\end{pmatrix} \right) = \zeta(2s+1)\zeta(2s+2)q^{(-n-2m)(s+1)}\frak{c}dot\begin{cases}
1 & \mbox{ if $m \geq 0$},\\
q^{m(2s+2)} & \mbox{ if $0 \geq m \geq -n$},\\
q^{(n+2m)(2s+2)} & \mbox{ if $-n\geq m$},
\end{cases}
\]
for $m \in {\mathbb Z}$ and  $n \in {\mathbb Z}_{\geq 0}$.
In Case (PS), we have
\[
f^o\left({A}\begin{pmatrix} {t{\bf a}(\nu)} & 0 \\ 0 & {\bf 1}_2 \end{pmatrix} \right) = \zeta(2s+1)\zeta(2s+2)|\nu t^2|^{s+1}(1+\nu^2 t^2)^{-s-1}(1+t^2)^{-s-1}
\]
for $t \in {\mathbb R}^{\mathbf{t}imes}$ and $\nu \in {\mathbb R}^+$.
By \frak{c}ite[Lemma 6.1]{LNM1254},  
\[f^o\left({A}\begin{pmatrix} {k_1gk_2} & 0 \\ 0  & {\bf 1}_2 \end{pmatrix}\right) = f^o\left(A \begin{pmatrix} g & 0 \\ 0 & {\bf 1}_2\end{pmatrix} \right)\]
for all $k_1, k_2 \in {\bf K}$ and $g \in \frak{o}peratorname{GL}_2(F)$.
Therefore, the integral (\ref{eq:doubling_PS}) is majorized by
\[
\frac{{\bf P}si(1,s)({A})}{f^o({A},s)}\frak{c}dot\zeta(2s+1)\zeta(2s+2)C \frak{c}dot\begin{cases}
C_{\lambda}\frak{c}dot \left(I_{\lambda}^{(1)}+I_{\lambda}^{(2)}+I_{\lambda}^{(3)}\right) & \mbox{ in Case (IIa)},\\
C_{\lambda,\end{pmatrix}silon}\frak{c}dot I_{\lambda,\end{pmatrix}silon} & \mbox{ in Case (PS)},
\end{cases}
\]
where
\begin{align*}
I_{\lambda}^{(1)} &= \sum_{n=0}^{\infty}\sum_{m=0}^\infty q^{-n(s+{\rm Re}(\lambda)+1)}q^{-m(2s+2+2{\rm Re}(\lambda))},\\
I_{\lambda}^{(2)} &= \sum_{n=0}^{\infty}\sum_{m=1}^nq^{-n(s+{\rm Re}(\lambda)+1)}q^{2m{\rm Re}(\lambda)},\\
I_{\lambda}^{(3)} &= \sum_{n=0}^{\infty}\sum_{m=n+1}^\infty q^{-n(-s+{\rm Re}(\lambda)-1)}q^{-m(2s+2-2{\rm Re}(\lambda))}
\end{align*}
in Case (IIa), and
\[
I_{\lambda,\end{pmatrix}silon} =  \int_{{\mathbb R}^\mathbf{t}imes}\left(\frac{t^2}{1+t^2}\right)^{s+1}|t|^{-s+{\rm Re}(\lambda_{1})+{\rm Re}(\lambda_{2})-\mu-1/2+\end{pmatrix}silon}\int_{-|t|}^{|t|}\frac{|\nu|^{s+\mu+1/2-\end{pmatrix}silon}}{(1+\nu^2)^{s+1}} \,d^\mathbf{t}imes\nu\,d^{\mathbf{t}imes}t
\]
in Case (PS).
This shows the absolute convergence of $Z(s, \phi_\lambda,F)$. It is clear that the integrals $I_{\lambda}^{(1)}, I_{\lambda}^{(2)}, I_{\lambda}^{(3)}, I_{\lambda,\end{pmatrix}silon}$ are bounded uniformly as $\lambda$ varies in a compact set. This completes the proof. 
\end{proof}

\subsection{Local zeta integrals for $\frak{o}peratorname{GSp}_4 \mathbf{t}imes \frak{o}peratorname{GSp}_4$}\label{SS:local zeta for Rankin-Selberg}
Recall $\mathcal{P}=P_{4,3}$ and $\frak{c}alI(s)=I_{4,3}(s)$ in the notation of \S\,\ref{ss:eisenstein}. Denote by $C^{\infty}(U(F)\backslash G(F),\psi_U)$ the space of smooth Whittaker functions on $G(F)$ with respect to $\psi_U$ and by $\mathcal{W}(\pi,\psi_U)$ the space of smooth Whittaker functions of $\pi$ with respect to $\psi_U$.  If $W \in \mathcal{W}(\pi,\psi_U)$ and $\frak{c}alF \in \frak{c}alI(s)$ is a holomorphic section, let $\frak{c}alZ(s,W,\frak{c}alF)$ be the local zeta integal defined as in (\ref{E:local zeta2}) with $\frak{o}verline{W}$ replaced by the left translation of $W$ by $\operatorname{diag}(-1,1,1,-1)$ when $\pi$ is of type (IIa) or (PS). 

We follow the notation in \S\,\ref{SS:theta lifts}. In particular, $V = {\rm M}_{2,2}$ is a quadratic space over $F$ with the norm form.
Let $\frak{o}mega$ be the Weil representation of $\frak{o}peratorname{Sp}_4(F)\mathbf{t}imes H_1(F)$ on $\mathcal{S}(V^2(F))$.
We extend $\frak{o}mega$ to a representation of ${\rm G}(\frak{o}peratorname{Sp}_4 \mathbf{t}imes H_1)(F)$ as in (\ref{Weil rep on R}).  
Let $\sigma_1$ and $\sigma_2$ be the irreducible admissible representations of $\frak{o}peratorname{GL}_2(F)$ defined as follows:
\begin{itemize}
\item If $\pi$ is of type (IIa), then
$$\sigma_1= {\rm Ind}_{B(F)}^{\frak{o}peratorname{GL}_2(F)}(|\mbox{ }|^{\lambda}\mathbf{t}imesi^\varepsilon\boxtimes|\mbox{ }|^{-\lambda}\mathbf{t}imesi^\varepsilon),\quad \sigma_2={\rm St}\frak{o}times \mathbf{t}imesi^\varepsilon.$$
\item If $\pi$ is of type (DS), then
$$\sigma_1 = {\rm DS}(\lambda_1-\lambda_2),\quad \sigma_2 = {\rm DS}(\lambda_1+\lambda_2).$$
\item If $\pi$ is of type (PS), then 
$$\sigma_1 = {\rm Ind}_{B({\mathbb R})}^{\frak{o}peratorname{GL}_2({\mathbb R})}(|\mbox{ }|^{(\lambda_1+\lambda_2)/2}{\rm sgn}^\varepsilon\boxtimes|\mbox{ }|^{(-\lambda_1-\lambda_2)/2}{\rm sgn}^\varepsilon),\quad \sigma_2 =  {\rm Ind}_{B({\mathbb R})}^{\frak{o}peratorname{GL}_2({\mathbb R})}(|\mbox{ }|^{(\lambda_1-\lambda_2)/2}{\rm sgn}^\varepsilon\boxtimes |\mbox{ }|^{(-\lambda_1+\lambda_2)/2}{\rm sgn}^\varepsilon).$$
\end{itemize}
Via the isomorphism
\[H^\frak{c}irc \simeq \Delta\mathbb{G}_m\backslash(\frak{o}peratorname{GL}_2\mathbf{t}imes\frak{o}peratorname{GL}_2),\]
we have a representation $\sigma = \sigma_1 \mathbf{t}imes \sigma_2$ of $H^\frak{c}irc(F)$. Let $N^\square$ be the unipotent subgroup of $H^\frak{c}irc$ defined by
\[
N^\square = \{ [{\bf n}(x),{\bf n}(y)] \mbox{ }\vert\mbox{ }x,y \in \mathbb{G}_a \},
\]
and $\psi_{N^\square}$ the additive character of $N^\square(F)$ defined by 
\[
\psi_{N^\square}([{\bf n}(x),{\bf n}(y)]) = \psi(x+y).
\]
Denote by $\mathcal{W}(\sigma,\psi_{N^\square})$ the space of smooth Whittaker functions of $\sigma$ with respect to $\psi_{N^\square}$. We have a surjective equivariant map
\[
S(V^2(F)) \frak{o}times  \mathcal{W}(\sigma,\psi_{N^\square}) \longrightarrow \mathcal{W}(\pi,\psi_U), \quad \varphi \frak{o}times W \longmapsto \mathcal{W}(\varphi,W),
\]
where
\begin{align}\label{E:explicit Whittaker}
\mathcal{W}(\varphi,W)(g) = \int_{\Delta N(F)\backslash H_1^{\frak{c}irc}(F)}W(h_{1}h)\frak{o}mega(g,h_{1}h)\varphi({\bf x}_0,{\bf y}_0)\,d\bar{h}_{1}
\end{align}
for $(g,h) \in {\rm G}(\frak{o}peratorname{Sp}_4 \mathbf{t}imes H_1)(F)$. 
Here 
\[
{\bf x}_0 = \begin{pmatrix} 0 & -1 \\ 0 & 0\end{pmatrix},\quad {\bf y}_0 = {\bf a}(-1).
\]

In Case (IIa) and Case (PS), we write $\pi=\pi_\lambda$ for the representation of $G(F)$ with parameter $\lambda$ and $\sigma=\sigma_\lambda$ for the representation of $H^\frak{c}irc(F)$ defined as above with respect to $\lambda$.
We call a map
\[
{\boldsymbol \omega}ega \longrightarrow C^{\infty}(U(F)\backslash G(F),\psi_U),\quad \lambda \longmapsto {W}_\lambda
\]
a $K$-finite analytic family of Whittaker functions if it satisfies the following conditions:
\begin{itemize}
\item The map $(\lambda,g) \mapsto {W}_\lambda(g)$ is continuous.
\item For each $g \in G(F)$, the map $\lambda \mapsto {W}_\lambda(g)$ is analytic.
\item For each $\lambda \in {\boldsymbol \omega}ega$, the function $g \mapsto {W}_\lambda(g)$ belongs to $\mathcal{W}(\pi_\lambda,\psi_U)$.
\item There exist finitely many irreducible representations $\rho_i$ of $K$ such that ${W}_\lambda$ is contained in the direct sum of the $\rho_i$-isotypic subspaces of $\mathcal{W}(\pi_\lambda,\psi_U)$ for all $\lambda \in {\boldsymbol \omega}ega$.
\end{itemize}
Let 
\[
{\bf K}^\square = \begin{cases}
H^\frak{c}irc(\frak{o}) & \mbox{ if $F$ is non-archimedean},\\
({\rm O}(2) \mathbf{t}imes {\rm O}(2))/\{\pm 1\} & \mbox{ if $F={\mathbb R}$}.
\end{cases}
\]
Similarly, we define the notion of ${\bf K}^\square$-finite analytic families valued in $\mathcal{W}(\sigma_\lambda,\psi_{N^\square})$.

Let $\end{pmatrix}silon>0$. If $\pi$ is of type (IIa), let $\frak{X}(\pi,\end{pmatrix}silon)$ be the set consisting of the following characters of ${\bf T}(F)$:
\begin{align}\label{E:charaIIa}
\begin{split}
{\rm diag}(a,b,ca^{-1},cb^{-1})&\longmapsto 1,\\
{\rm diag}(a,b,ca^{-1},cb^{-1})&\longmapsto |a|^{1/2}\frak{c}dot |b|^{1/2} \frak{c}dot |c|^{-1/2},\\
{\rm diag}(a,b,ca^{-1},cb^{-1})&\longmapsto |a|^{-|{\rm Re}(\lambda)|-\end{pmatrix}silon}\frak{c}dot |b|^{-|{\rm Re}(\lambda)|-\end{pmatrix}silon} \frak{c}dot |c|^{|{\rm Re}(\lambda)|+\end{pmatrix}silon},\\
{\rm diag}(a,b,ca^{-1},cb^{-1})&\longmapsto |a|^{-|{\rm Re}(\lambda)|-\end{pmatrix}silon+1/2}\frak{c}dot |b|^{-|{\rm Re}(\lambda)|-\end{pmatrix}silon+1/2} \frak{c}dot |c|^{|{\rm Re}(\lambda)|+\end{pmatrix}silon-1/2}.

\end{split}
\end{align} 
If $\pi$ is of type (DS), let $\frak{X}(\pi,\end{pmatrix}silon)$ be the set consisting of the following character of ${\bf T}({\mathbb R})$:
\begin{align}\label{E:charaDS}
{\rm diag}(a,b,ca^{-1},cb^{-1})&\longmapsto |a|^{-\end{pmatrix}silon}|b|^{-\end{pmatrix}silon}|c|^\end{pmatrix}silon.
\end{align}
 If $\pi$ is of type (PS), let $\frak{X}(\pi,\end{pmatrix}silon)$ be the set consisting of the following character of ${\bf T}({\mathbb R})$:
\begin{align}\label{E:charaPS}
{\rm diag}(a,b,ca^{-1},cb^{-1})&\longmapsto |a|^{-|{\rm Re}(\lambda_1)|-|{\rm Re}(\lambda_2)|-2\end{pmatrix}silon} |c|^{(|{\rm Re}(\lambda_1)|+|{\rm Re}(\lambda_2)|)/2+\end{pmatrix}silon}.
\end{align}

We have the following uniform asymptotic estimate for Whittaker functions and an explicit construction of $K$-finite analytic families by (\ref{E:explicit Whittaker}).
\begin{lemma}\label{L:Whittaker fun}
(1) Let ${\bf W}_\lambda$ be a ${\bf K}^\square$-finite analytic family valued in $\mathcal{W}(\sigma_\lambda,\psi_{N^\square})$ and let $\varphi \in S(V^2(F))$. Then the map 
\begin{align}\label{E:explicit analytic family}
\lambda \longmapsto \mathcal{W}(\varphi,{\bf W}_\lambda)
\end{align}
defines a $K$-finite analytic family of Whittaker functions. 

(2) Let $W \in \mathcal{W}(\pi,\psi_U)$. For any $\end{pmatrix}silon>0$, there exist a non-negative function $\phi_{\end{pmatrix}silon}$ on $(F^\mathbf{t}imes)^2$ and a constant $C_\end{pmatrix}silon>0$ which satisfy the following conditions: 
\begin{itemize}
\item
\[
\left\vert W(utk) \right\vert \leq  \delta_{\bf B}(t)^{1/2}\phi_{\end{pmatrix}silon}(b^2c^{-1},ab^{-1})\sum_{\frak{c}hi \in \frak{X}(\pi,\end{pmatrix}silon)}\frak{c}hi(t)
\]
for $t={\rm diag}(a,b,ca^{-1},cb^{-1}) \in {\bf T}(F)$, $u \in U(F)$ and $k \in K$.
\item When $\pi$ is of type (IIa), we can extend $\phi_{\end{pmatrix}silon}$ to a Schwartz function in $\mathcal{S}(F^2)$ of the form
\[
\phi_\end{pmatrix}silon = C_{\end{pmatrix}silon}\frak{c}dot \mathbb{I}_{\varpi^{-n}\frak{o}}\frak{o}times\mathbb{I}_{\varpi^{-n}\frak{o}}
\]
for some $n \in {\mathbb Z}$.
\item When $\pi$ is of type (DS) or (PS), we have
\[\phi_\end{pmatrix}silon(a,b) \leq C_\end{pmatrix}silon\frak{c}dot e^{-\pi(|a|+|b|)/4}\]
for $a,b \in {\mathbb R}^\mathbf{t}imes$. 

\end{itemize}

(3) Let ${W}_\lambda$ be a $K$-finite analytic family of Whittaker functions. Then in (2), we can choose a function $\phi_\end{pmatrix}silon = \phi_{\lambda,\end{pmatrix}silon}$ for ${W}_\lambda$ so that the constant $C_\end{pmatrix}silon = C_{\lambda,\end{pmatrix}silon}$ is bounded uniformly as $\lambda$ varies in a compact set and the integer $n$ is independent of $\lambda$ in Case (IIa).

\end{lemma}

\begin{proof}

To prove (2) for Case (DS), we may assume $W = \mathcal{W}(\varphi,{\bf W})$ for some ${\bf W} \in \mathcal{W}(\sigma,\psi_{N^\square})$ and $\varphi \in S(V^2(F))$. For Case (IIa) and Case (PS), we prove (1) and (2) simultaneously. Let ${\bf W}_\lambda$ be a ${\bf K}^\square$-finite analytic family valued in $\mathcal{W}(\sigma_\lambda,\psi_{N^\square})$ and let $\varphi \in S(V^2(F))$. We write $W_\lambda = \mathcal{W}(\varphi,{\bf W}_\lambda)$.

First we consider Case (IIa). Let $t={\rm diag}(ab,a,b^{-1},1) \in {\bf T}(F)$ and $k \in K$. Choose $h_k \in H^\frak{c}irc(\frak{o})$ such that $\nu(h_k)=\nu(k)$. Then
\[
W_\lambda(tk) = \int_{H_1^\frak{c}irc(\frak{o})}Z_\lambda^{(1)}(k_1;t,k)\,dk_1 + \int_{H_1^\frak{c}irc(\frak{o})}Z^{(2)}_\lambda(k_1;t,k)\,dk_1,
\]
where
\begin{align*}
Z_\lambda^{(1)}(k_1;t,k) & = |a|\int_F\int_{F^\mathbf{t}imes}\int_{F^\mathbf{t}imes} {\bf W}_\lambda([{\bf d}(a){\bf m}(y_1),{\bf u}(x){\bf m}(y_2)]k_1h_k) \\
& \quad\quad\mathbf{t}imes\frak{o}mega(tk,[{\bf d}(a){\bf m}(y_1),{\bf u}(x){\bf m}(y_2)]k_1h_k)\varphi({\bf x}_0,{\bf y}_0)|y_1|^{-2}|y_2|^{-2}\,d^\mathbf{t}imes y_1 \, d^\mathbf{t}imes y_2\,dx,\\
Z_\lambda^{(2)}(k_1;t,k) & = |a\varpi^{-1}|\int_F\int_{F^\mathbf{t}imes}\int_{F^\mathbf{t}imes}{\bf W}_\lambda([{\bf a}(\varpi),{\bf a}(\varpi)][{\bf d}(a){\bf m}(y_1),{\bf u}(x){\bf m}(y_2)]k_1h_k) \\
& \quad\quad\quad\quad\mathbf{t}imes\frak{o}mega(tk,[{\bf a}(\varpi),{\bf a}(\varpi)][{\bf d}(a){\bf m}(y_1),{\bf u}(x){\bf m}(y_2)]k_1h_k)\varphi({\bf x}_0,{\bf y}_0)|y_1|^{-2}|y_2|^{-2}\,d^\mathbf{t}imes y_1 \, d^\mathbf{t}imes y_2\,dx.
\end{align*}
Let $k_1 \in H_1^\frak{c}irc(\frak{o})$. We have
\begin{align*}
Z_\lambda^{(1)}(k_1;t,k) & = |a^3b^2|\int_{F^\mathbf{t}imes}\int_{F^\mathbf{t}imes}    {\bf W}_\lambda([{\bf d}(a){\bf m}(y_1),{\bf m}(y_2)]k_1h_k) |y_1|^{-2}|y_2|^{-2}\\
&\quad\quad\quad\quad\mathbf{t}imes \int_F\psi(x)\frak{o}mega(k,k_1h_k)\varphi\left( \begin{pmatrix} 0 & -aby_1^{-1}y_2^{-1} \\ 0 & 0 \end{pmatrix} , \begin{pmatrix} -ay_1^{-1}y_2 & -ay_1^{-1}y_2^{-1}x\\ 0 & y_1y_2^{-1} \end{pmatrix} \right) \,dx\,d^\mathbf{t}imes y_1 \, d^\mathbf{t}imes y_2.
\end{align*}
Write 
\[
\frak{o}mega(k,k_1h_k)\varphi(x,y) = \sum_{i}\varphi_0^{(i)}(x)\varphi_{11}^{(i)}(y_{11})\varphi_{12}^{(i)}(y_{12})\varphi_{21}^{(i)}(y_{21})\varphi_{22}^{(i)}(y_{22})
\]
for some $\varphi_0^{(i)} \in \mathcal{S}(V(F))$, $\varphi_{11}^{(i)}, \varphi_{12}^{(i)}, \varphi_{21}^{(i)},\varphi_{22}^{(i)} \in \mathcal{S}(F)$.

Then
\begin{align*}
Z_\lambda^{(1)}(k_1;t,k) & = |a^2b^2|\sum_i \varphi_{21}^{(i)}(0)\int_{F^\mathbf{t}imes}\int_{F^\mathbf{t}imes}  {\bf W}_\lambda([{\bf d}(a){\bf m}(y_1),{\bf m}(y_2)]k_1h_k) |y_1|^{-1}|y_2|^{-1}\\
&\quad\quad\quad\quad\quad\quad\quad\mathbf{t}imes \varphi_0^{(i)}\left( \begin{pmatrix} 0 & -aby_1^{-1}y_2^{-1} \\ 0 & 0 \end{pmatrix} \right) \varphi_{11}^{(i)}(-ay_1^{-1}y_2) \hat{\varphi}_{12}^{(i)}(-a^{-1}y_1y_2) \varphi_{22}^{(i)}(y_1y_2^{-1}) \,d^\mathbf{t}imes y_1 \, d^\mathbf{t}imes y_2,
\end{align*}
where $\hat{\varphi}_{12}^{(i)}$ is the Fourier transform of ${\varphi}_{12}^{(i)}$ with respect to $\psi$.
Choose a constant $C>0$ and a sufficiently large integer $n$ independent of $k,k_1$, and $\lambda$ such that $\sum_i|\varphi_{21}^{(i)}(0)| \leq C$ and 
\[
| \varphi_0^{(i)} | \leq C\frak{c}dot \mathbb{I}_{V(\varpi^{-n}\frak{o})},\quad |\varphi_{11}^{(i)}|\leq C\frak{c}dot \mathbb{I}_{\varpi^{-n}\frak{o}},\quad |\hat{\varphi}_{12}^{(i)}|\leq C\frak{c}dot \mathbb{I}_{\varpi^{-n}\frak{o}}, \quad |\varphi_{22}^{(i)}|\leq C\frak{c}dot \mathbb{I}_{\varpi^{-n}\frak{o}}
\]
for all $i$. Then
\begin{align*}
|Z_\lambda^{(1)}(k_1;t,k)| &\leq C^5\frak{c}dot\delta_{\bf B}(t)^{1/2} \int_{F^\mathbf{t}imes} \int_{F^\mathbf{t}imes} |{\bf W}_\lambda([{\bf d}(a){\bf m}(y_1),{\bf m}(y_2)]k_1h_k)| |a|^{1/2}|y_1|^{-1}|y_2|^{-1}\\
&\quad\quad\quad\quad\quad\quad\quad\quad\mathbf{t}imes\mathbb{I}_{\varpi^{-n}\frak{o}}(aby_1^{-1}y_2^{-1})\mathbb{I}_{\varpi^{-n}\frak{o}}(ay_1^{-1}y_2)\mathbb{I}_{\varpi^{-n}\frak{o}}(a^{-1}y_1y_2)\mathbb{I}_{\varpi^{-n}\frak{o}}(y_1y_2^{-1})\, d^\mathbf{t}imes y_1 \, d^\mathbf{t}imes y_2.
\end{align*}
Let $\end{pmatrix}silon>0$. There exists ${\bf P}hi_{\lambda,\end{pmatrix}silon} \in \mathcal{S}(F^2)$ such that
\[
|{\bf W}_\lambda([{\bf a}(t_1),{\bf a}(t_2)]k')| \leq |t_1|^{-|{\rm Re}(\lambda)|+1/2-\end{pmatrix}silon}|t_2|{\bf P}hi_{\lambda,\end{pmatrix}silon}(t_1,t_2)
\]
for $t_1,t_2 \in F^\mathbf{t}imes$ and $k' \in H^\frak{c}irc(\frak{o})$. Moreover, we can find such ${\bf P}hi_{\lambda,\end{pmatrix}silon}$ which is bounded uniformly as $\lambda$ varies in a compact set and whose support is contained in $\varpi^{-2n}\frak{o} \mathbf{t}imes \varpi^{-2n}\frak{o}$ for some integer $n$ independent of $\lambda$. Hence it suffices to consider the integral
\begin{align}\label{E:local zeta Whittaker}
\begin{split}
&\int_{F^\mathbf{t}imes}\int_{F^\mathbf{t}imes} \frak{c}hi_{\lambda,\end{pmatrix}silon}(a^{-1}y_1^2)|y_2| \mathbb{I}_{\varpi^{-2n}\frak{o}}(a^{-1}y_1^2)\mathbb{I}_{\varpi^{-n}\frak{o}}(y_2)\\
&\mathbf{t}imes\mathbb{I}_{\varpi^{-n}\frak{o}}(aby_1^{-1}y_2^{-1})\mathbb{I}_{\varpi^{-n}\frak{o}}(ay_1^{-1}y_2)\mathbb{I}_{\varpi^{-n}\frak{o}}(a^{-1}y_1y_2)\mathbb{I}_{\varpi^{-n}\frak{o}}(y_1y_2^{-1})\, d^\mathbf{t}imes y_1 \, d^\mathbf{t}imes y_2,
\end{split}
\end{align}
where $\frak{c}hi_{\lambda,\end{pmatrix}silon} = |\mbox{ }|^{-|{\rm Re}(\lambda)|-\end{pmatrix}silon}$. 
The integral is majorized by 
\[
\left [C_{\lambda,\end{pmatrix}silon}^{(1)}  +C_{\lambda,\end{pmatrix}silon}^{(2)}\frak{c}dot |ab|^{1/2} +  C_{\lambda,\end{pmatrix}silon}^{(3)}\frak{c}dot \frak{c}hi_{\lambda,\end{pmatrix}silon}(ab)+ C_{\lambda,\end{pmatrix}silon}^{(4)}\frak{c}dot \frak{c}hi_{\lambda,\end{pmatrix}silon}(ab)|ab|^{1/2}\right] \frak{c}dot \mathbb{I}_{\varpi^{-2n}\frak{o}}(a)\mathbb{I}_{\varpi^{-2n}\frak{o}}(b)
\]
for some constants $C_{\lambda,\end{pmatrix}silon}^{(1)}, C_{\lambda,\end{pmatrix}silon}^{(2)}, C_{\lambda,\end{pmatrix}silon}^{(3)}, C_{\lambda,\end{pmatrix}silon}^{(4)}$ which are bounded uniformly as $\lambda$ varies in a compact set. Indeed, it is clear that (\ref{E:local zeta Whittaker}) is majorized by
\begin{align*}
&\int_{F^\mathbf{t}imes} \frak{c}hi_{\lambda,\end{pmatrix}silon}(a^{-1}y_1^2) \mathbb{I}_{\varpi^{-2n}\frak{o}}(a^{-1}y_1^2) \mathbb{I}_{\varpi^{-2n}\frak{o}}(a^2by_1^{-2})\,d^\mathbf{t}imes y_1\frak{c}dot\int_{F^\mathbf{t}imes}|y_2|\mathbb{I}_{\varpi^{-2n}\frak{o}}(y_2^2) \mathbb{I}_{\varpi^{-2n}\frak{o}}(aby_2^{-2})\,d^\mathbf{t}imes y_2\\
&\mathbf{t}imes\mathbb{I}_{\varpi^{-2n}\frak{o}}(a)\mathbb{I}_{\varpi^{-2n}\frak{o}}(b).
\end{align*} 
Assume that both $\log_q|a|$ and $\log_q|b|$ are even integers. The other cases can be treated in a similar way. Then the above integral is equal to 
\[
(\frak{c}hi_{\lambda,\end{pmatrix}silon}(\varpi^2)-1)^{-1}\left(\frak{c}hi_{\lambda,\end{pmatrix}silon}(ab\varpi^{2n+2})-\frak{c}hi_{\lambda,\end{pmatrix}silon}(\varpi^{-2n})\right)\frak{c}dot(q^{-1}-1)^{-1}(q^{-n-1}|ab|^{1/2}-q^n)\frak{c}dot\mathbb{I}_{\varpi^{-2n}\frak{o}}(a)\mathbb{I}_{\varpi^{-2n}\frak{o}}(b).
\]

Therefore we obtain a uniform estimate for $Z_\lambda^{(1)}(k_1;t,k)$. We have a similar estimate for $Z_\lambda^{(2)}(k_1;t,k)$. Moreover, it follows from the above estimate that the map $\lambda \mapsto W_\lambda(g)$ is analytic for each $g \in G(F)$. The continuity of the map $(\lambda,g)\mapsto W_\lambda(g)$ can be proved in a similar way. Therefore the map $\lambda \mapsto W_\lambda$ defines a $K$-finite analytic family. This completes the proof of (1) and (2) for Case (IIa).

Next we consider Case (PS). Let $t={\rm diag}(ab,a,b^{-1},1) \in {\bf T}({\mathbb R})$ and $k \in K$. Choose $h_k \in {\bf K}^\square$ such that $\nu(h_k) = \nu(k)$. Then
\[
W_{\lambda}(tk) = \int_{ {\bf K}^\square \frak{c}ap H_1^\frak{c}irc({\mathbb R})}Z_{\lambda}(k_1;t,k)\,dk_1,
\]

where
\begin{align*}
Z_{\lambda}(k_1;t,k) &= |a|\int_{\mathbb R}\int_{0}^\infty\int_{0}^\infty {\bf W}_\lambda([{\bf d}(a){\bf m}(y_1),{\bf u}(x){\bf m}(y_2)]k_1h_k) \\
& \quad\quad\mathbf{t}imes\frak{o}mega(tk,[{\bf d}(a){\bf m}(y_1),{\bf u}(x){\bf m}(y_2)]k_1h_k)\varphi({\bf x}_0,{\bf y}_0)y_1^{-2}y_2^{-2}\,d^\mathbf{t}imes y_1 \, d^\mathbf{t}imes y_2\,dx\\
&= \delta_{\bf B}(t)^{1/2}\int_{0}^\infty\int_{0}^\infty  {\bf W}_\lambda([{\bf d}(a){\bf m}(y_1),{\bf m}(y_2)]k_1h_k) |a|^{1/2}y_1^{-1}y_2^{-1}\\
&\quad\quad\quad\quad\mathbf{t}imes \int_{\mathbb R}\psi(-a^{-1}y_1y_2x)\frak{o}mega(k,k_1h_k)\varphi\left( \begin{pmatrix} 0 & -aby_1^{-1}y_2^{-1} \\ 0 & 0 \end{pmatrix} , \begin{pmatrix} -ay_1^{-1}y_2 & x\\ 0 & y_1y_2^{-1} \end{pmatrix} \right) \,dx\,d^\mathbf{t}imes y_1 \, d^\mathbf{t}imes y_2.
\end{align*}
The inner integral over ${\mathbb R}$ is equal to the product of $e^{-\pi(y_1^2y_2^{-2}+a^2y_1^{-2}y_2^2+a^2b^2y_1^{-2}y_2^{-2}+a^{-2}y_1^2y_2^2)}$ and a polynomial in four variables $y_1y_2^{-1}$, $ay_1^{-1}y_2$, $ab y_1^{-1}y_2^{-1}$, and $a^{-1}y_1y_2$. Note that this polynomial is independent of $\lambda$. We conclude that
\begin{align*}
|Z_\lambda(k_1;t,k)| &\ll_{k,k_1} \delta_{\bf B}(t)^{1/2} \int_0^\infty\int_0^\infty |{\bf W}_\lambda([{\bf d}(a){\bf m}(y_1),{\bf m}(y_2)]k_1h_k)| |a|^{1/2}y_1^{-1}y_2^{-1}\\
&\quad\quad\quad\quad\quad\quad\quad\mathbf{t}imes  e^{-\pi(y_1^2y_2^{-2}+a^2y_1^{-2}y_2^2+a^2b^2y_1^{-2}y_2^{-2}+a^{-2}y_1^2y_2^2)/2}\,d^\mathbf{t}imes y_1\,d^\mathbf{t}imes y_2.
\end{align*} 

For $\end{pmatrix}silon_1,\end{pmatrix}silon_2>0$, we have
\[
|{\bf W}_\lambda([{\bf a}(t_1),{\bf a}(t_2)]k')| \ll_{\lambda_1,\lambda_2,\end{pmatrix}silon_1,\end{pmatrix}silon_2} |t_1|^{-\mu_1+1/2-\end{pmatrix}silon_1}|t_2|^{-\mu_2+1/2-\end{pmatrix}silon_2}e^{-\pi(|t_1|+|t_2|)}
\]
for $t_1,t_2 \in {\mathbb R}^\mathbf{t}imes$ and $k' \in {\bf K}^\square$.
Here
\[
\mu_1 = \frac{|{\rm Re}(\lambda_1)+{\rm Re}(\lambda_2)|}{2},\quad \mu_2 = \frac{|{\rm Re}(\lambda_1)-{\rm Re}(\lambda_2)|}{2}.
\]
Assume $\mu_1 \geq \mu_2$. The case $\mu_1\leq\mu_2$ can be proved in a similar way and we omit it. Let $\end{pmatrix}silon_1=2\end{pmatrix}silon_2=\end{pmatrix}silon>0$. Then
\begin{align*}
&\int_0^\infty\int_0^\infty |{\bf W}_\lambda([{\bf d}(a){\bf m}(y_1),{\bf m}(y_2)]k_1h_k)| |a|^{1/2}y_1^{-1}y_2^{-1}e^{-\pi(y_1^2y_2^{-2}+a^2y_1^{-2}y_2^2+a^2b^2y_1^{-2}y_2^{-2}+a^{-2}y_1^2y_2^2)/2}\,d^\mathbf{t}imes y_1\,d^\mathbf{t}imes y_2\\
& \ll_{\lambda_1,\lambda_2,\end{pmatrix}silon} |a|^{\mu_1+\end{pmatrix}silon} \int_{0}^{\infty}\int_{0}^{\infty} y_1^{-2\mu_1-2\end{pmatrix}silon}y_2^{-2\mu_2-\end{pmatrix}silon}e^{-\pi y_1^2(a^{-2}y_2^2+y_2^{-2})/2 -\pi y_1^{-2}(a^2y_2^2+a^2b^2y_2^{-2})/2}\,d^\mathbf{t}imes y_1\, d^\mathbf{t}imes y_2 \\
&\ll_{\lambda_1,\lambda_2,\end{pmatrix}silon}  |a|^{\mu_1+\end{pmatrix}silon} \int_{0}^{\infty} y^{-2\mu_2-\end{pmatrix}silon}\left(a^{-2}y^2+y^{-2}\right)^{(\mu_1+\end{pmatrix}silon)/2}\left(a^2y^2+a^2b^2y^{-2}\right)^{-(\mu_1+\end{pmatrix}silon)/2}\\
&\quad\quad\quad\quad\quad\quad\quad\quad\quad\quad\mathbf{t}imes K_{\mu_1+\end{pmatrix}silon}\left(\pi (a^{-2}y^2+y^{-2})^{1/2}(a^2y^2+a^2b^2y^{-2})^{1/2}\right)\,d^\mathbf{t}imes y\\
&\ll_{\lambda_1,\lambda_2,\end{pmatrix}silon} |a|^{\mu_1+\end{pmatrix}silon} \int_{0}^{\infty} y^{-2\mu_2-\end{pmatrix}silon}\left(a^2y^2+a^2b^2y^{-2}\right)^{-(\mu_1+\end{pmatrix}silon)} e^{-\pi(a^{-2}y^2+y^{-2})^{1/2}(a^2y^2+a^2b^2y^{-2})^{1/2}/2}\,d^\mathbf{t}imes y.
\end{align*}
Here, in the last two inequalities, we use the integral representation (\ref{E:K Bessel}) of $K_{\mu_1+\end{pmatrix}silon}$ and the estimate 
\begin{align}\label{E:estimate K Bessel}
|K_{\mathbf{t}imesi_1}(y)| \ll_{\mathbf{t}imesi_1,\mathbf{t}imesi_2} 
 y^{-\mathbf{t}imesi_2}e^{-y/2}
\end{align}
for $0 < \mathbf{t}imesi_1 \leq \mathbf{t}imesi_2$ and $y>0$. By the inequality
\[
\sqrt{x}+\sqrt{y} \leq \sqrt{2(x+y)}
\]
for $x,y \geq 0$, we have
\begin{align*}
&\int_{0}^{\infty} y^{-2\mu_2-\end{pmatrix}silon}\left(a^2y^2+a^2b^2y^{-2}\right)^{-(\mu_1+\end{pmatrix}silon)} e^{-\pi(a^{-2}y^2+y^{-2})^{1/2}(a^2y^2+a^2b^2y^{-2})^{1/2}/2}\,d^\mathbf{t}imes y\\
& \ll_{\lambda_1,\lambda_2,\end{pmatrix}silon} |a|^{-2\mu_1-2\end{pmatrix}silon}|b|^{-2\mu_1-2\end{pmatrix}silon} \int_{0}^\infty y^{\mu_1-\mu_2+\end{pmatrix}silon/2} e^{-\pi(|a|+|b|+y+|ab|y^{-1})/4}\,d^\mathbf{t}imes y.
\end{align*}
By the integral representation (\ref{E:K Bessel}) of $K_{\mu_1-\mu_2+\end{pmatrix}silon/2}$, the estimate (\ref{E:estimate K Bessel}), and the assumption that $\mu_1\geq\mu_2$, we have
\begin{align*}
&\int_{0}^\infty y^{\mu_1-\mu_2+\end{pmatrix}silon/2} e^{-\pi(|a|+|b|+y+|ab|y^{-1})/4}\,d^\mathbf{t}imes y\\
&\ll_{\lambda_1,\lambda_2,\end{pmatrix}silon}e^{-\pi(|a|+|b|)/4}|ab|^{\mu_1/2-\mu_2/2+\end{pmatrix}silon/4} K_{\mu_1-\mu_2+\end{pmatrix}silon/2}(2^{-1}\pi |ab|^{1/2})\\
& \ll_{\lambda_1,\lambda_2,\end{pmatrix}silon} e^{-\pi(|a|+|b|)/4}.
\end{align*}
Moreover, we can choose
constants in the above inequalities so that they are bounded uniformly as $\lambda$ varies in a compact set. Therefore we obtain a uniform estimate for $Z_\lambda(k_1;t,k)$. A similar estimate shows that the map $\lambda \mapsto W_\lambda$ is a $K$-finite analytic family. This completes the proof of (1) and (2) for Case (PS). 

Finally we assume $\pi$ is of type (DS). There exists a polynomial $P \in {\mathbb C}[X,Y]$ divisible by $XY$ such that
$$|W([{\bf a}(t_1),{\bf a}(t_2)]k')| \leq P(|t_1|,|t_2|) e^{-2\pi(|t_1|+|t_2|)}$$
for $t_1,t_2 \in {\mathbb R}^\mathbf{t}imes$ and $k' \in {\bf K}^\square$. Similarly as in Case (PS), we only need to consider the integral 
\[
\int_{0}^{\infty}\int_{0}^{\infty}P(|a^{-1}y_1^2|,|y_2|^2) |a|^{1/2}y_1^{-1}y_2^{-1}e^{-\pi(y_1^2y_2^{-2}+a^2y_1^{-2}y_2^2+a^2b^2y_1^{-2}y_2^{-2}+a^{-2}y_1^2y_2^2)/2}\,d^\mathbf{t}imes y_1\,d^\mathbf{t}imes y_2.
\]
We may assume $P(X,Y) = X^mY^n$ for some $m,n \in {\mathbb Z}_{\geq 1}$. By an estimate similar to the one in Case (PS), we have
\begin{align*}
&\int_{0}^{\infty}\int_{0}^{\infty}P(|a^{-1}y_1^2|,|y_2|^2) |a|^{1/2}y_1^{-1}y_2^{-1}e^{-\pi(y_1^2y_2^{-2}+a^2y_1^{-2}y_2^2+a^2b^2y_1^{-2}y_2^{-2}+a^{-2}y_1^2y_2^2)/2}\,d^\mathbf{t}imes y_1\,d^\mathbf{t}imes y_2\\
&\ll_{m,n}|a|^{-m+1/2}\int_{0}^{\infty}y^{2n-1}\left(a^2y^2+a^2b^2y^{-2}\right)^{(2m-1)/4}\left(a^{-2}y^2+y^{-2}\right)^{-(2m-1)/4}\\
&\quad\quad\quad\quad\quad\quad\quad\quad\quad\mathbf{t}imes K_{m-1/2}\left(\pi(a^{-2}y^2+y^{-2})^{1/2}(a^2y^2+a^2b^2y^{-2})^{1/2}\right) \,d^\mathbf{t}imes y\\
&\ll_{m,n}|a|^{-m+1/2}\int_{0}^{\infty}y^{2n-1}\left(a^{-2}y^2+y^{-2}\right)^{-(2m-1)/2}e^{-\pi(a^{-2}y^2+y^{-2})^{1/2}(a^2y^2+a^2b^2y^{-2})^{1/2}/2}\,d^\mathbf{t}imes y\\
&\ll_{m,n}\int_{0}^{\infty}y^{n-1/2} e^{-\pi(|a|+|b|+y+|ab|y^{-1})/4}\,d^\mathbf{t}imes y\\
&\ll_{m,n}e^{-\pi(|a|+|b|)/4}|ab|^{(2n-1)/4}K_{n-1/2}(2^{-1}\pi|ab|^{1/2})\\
&\ll_{m,n,\end{pmatrix}silon} |ab|^{-\end{pmatrix}silon}e^{-\pi(|a|+|b|)/4}.
\end{align*}
Here the last inequality follows from (\ref{E:estimate K Bessel}) with $\mathbf{t}imesi_1 = n-1/2$ and $\mathbf{t}imesi_2 = n-1/2+2\end{pmatrix}silon$.
This completes the proof of (2) for Case (DS).

It remains to prove (3). Note that for any fixed $\lambda_0 \in {\boldsymbol \omega}ega$, any $K$-finite analytic family of Whittaker functions can be written as a linear combination, with analytic functions of $\lambda$ as coefficients, of $K$-finite analytic families of the form (\ref{E:explicit analytic family}) in a neighborhood of $\lambda_0$. Since we only consider the convergence for $\lambda$ varying in a compact set, it suffices to consider $K$-analytic families of the form (\ref{E:explicit analytic family}). It follows from the above estimate for Case (IIa) and Case (PS) that (3) holds for $K$-analytic families of the form (\ref{E:explicit analytic family}). This completes the proof.
\end{proof}

\begin{lemma}\label{L:uniform2}
Let $\frak{c}alF \in \frak{c}alI(s)$ be a holomorphic section.

(1) Let $W \in \mathcal{W}(\pi,\psi_U)$. The integral $\frak{c}alZ(s,W,\frak{c}alF)$ is absolutely convergent for 
\begin{align*}
\begin{cases}
{\rm Re}(s) >  -1 + 4|{\rm Re}(\lambda)|  & \mbox{ if $\pi$ is of type (IIa)},\\ 
{\rm Re}(s) > -1 & \mbox{ if $\pi$ is of type (DS)},\\
{\rm Re}(s) > -1 + 2(|{\rm Re}(\lambda_1)|+|{\rm Re}(\lambda_2)|) & \mbox{ if $\pi$ is of type (PS)}.
\end{cases}
\end{align*}
In particular, the integral is absolutely convergent for ${\rm Re}(s) \geq 1$ if $\pi$ is of type (IIa) or (PS) with parameter in $\mathcal D$.

(2) Let ${W}_\lambda$ be a $K$-finite analytic family of Whittaker functions. The integral $\frak{c}alZ(s,{W}_\lambda,\frak{c}alF)$ is uniformly convergent as $\lambda$ varies in a compact set.
\end{lemma}

\begin{proof}
We prove (1) and (2) simultaneously.
Let 
\[(K\mathbf{t}imes K)^\frak{c}irc = \left\{ (k_1,k_2) \in K\mathbf{t}imes K \mbox{ }\vert\mbox{ } \nu(k_1)=\nu(k_2)\right\}.\]
We define $({\bf B}\mathbf{t}imes {\bf B})^\frak{c}irc$ and $({\bf T} \mathbf{t}imes {\bf T})^\frak{c}irc$ in a similar way. Let \[U' = \left\{ \left.\begin{pmatrix}
   1 & 0 & x & 0 \\
   0 & 1 & 0 & 0 \\
   0 & 0 & 1 & 0 \\
   0 & 0 & 0 & 1
 \end{pmatrix}\mbox{ } \right\vert\mbox{ }x \in {\mathbb G}_a\right\}\]
be a unipotent subgroup of $G$. For $W \in \mathcal{W}(\pi,\psi_U)$, let
\[
W'(g) = \begin{cases}
W({\rm diag}(-1,1,1,-1)g) & \mbox{ if $\pi$ is of type (IIa) or (PS)},\\
\frak{o}verline{W(g)} & \mbox{ if $\pi$ is of type (DS)}.
\end{cases}
\]
Then
\begin{align*}
\frak{c}alZ(s, W, \frak{c}alF) &= 
 \int_{Z_{\frak{o}peratorname{GSp}_8}(F) \mathbf{t}ilde{U}(F) \backslash {\bf G}(F)}
 \frak{c}alF(\eta g, s) (W\frak{o}times W')(g) \, dg\\
 &=\int_{(K\mathbf{t}imes K)^\frak{c}irc}\int_{Z_{\frak{o}peratorname{GSp}_8}(F)\backslash({\bf T} \mathbf{t}imes {\bf T})^\frak{c}irc(F)} \delta_{({\bf B}\mathbf{t}imes {\bf B})^\frak{c}irc}(t)^{-1} (W\frak{o}times W')(tk)\\
 &\quad\quad\quad\quad\quad\quad\quad\quad\mathbf{t}imes \int_{U'(F)\backslash U(F)} \frak{c}alF(\eta(u,1)tk)\psi_U(u) \,du\,dt\,dk.
\end{align*}
Let $s \in {\mathbb R}$ and $\end{pmatrix}silon>0$.
Since
\[
\left\{ \left({\rm diag}(ab,a,b^{-1},1), {\rm diag}(cd,c,c^{-1}d^{-1}a,c^{-1}a)\right) \mbox{ }\vert\mbox{ }a,b,c,d \in F^\mathbf{t}imes\right\}
\]
is a set of representatives for $Z_{\frak{o}peratorname{GSp}_8}(F)\backslash({\bf T} \mathbf{t}imes {\bf T})^\frak{c}irc(F)$, by Lemma \ref{L:Whittaker fun}, it suffices to consider the integral
\begin{align*}
&\int_{(F^\mathbf{t}imes)^4}\delta_{({\bf B}\mathbf{t}imes {\bf B})^\frak{c}irc}((t_1,t_2))^{-1/2}\phi_{\end{pmatrix}silon}(a,b)\phi_{\end{pmatrix}silon}(c^2a^{-1},d)\frak{c}hi_1(t_1)\frak{c}hi_2(t_2)\\
&\quad\quad\quad\quad\quad\quad\mathbf{t}imes \int_{U'(F)\backslash U(F)} \frak{c}alF(\eta(u,1)(t_1,t_2)) \,du\,d(a,b,c,d)
\end{align*}
for $\frak{c}hi_1,\frak{c}hi_2 \in \frak{X}(\pi,\end{pmatrix}silon)$. Here $\phi_\end{pmatrix}silon$ is a function on $(F^\mathbf{t}imes)^2$ satisfying the conditions in Lemma \ref{L:Whittaker fun}-(2), $d(a,b,c,d)$ is a Haar measure on $(F^\mathbf{t}imes)^4$, and 
\[t_1={\rm diag}(ab,a,b^{-1},1),\quad t_2={\rm diag}(cd,c,c^{-1}d^{-1}a,c^{-1}a).\]
We may assume $\frak{c}alF$ is $\frak{o}peratorname{GSp}_8(\frak{o})$-invariant (resp. $\frak{o}peratorname{GSp}_8({\mathbb R}) \frak{c}ap {\rm O}(8)$-invariant) when $F$ is non-archimedean (resp. $F={\mathbb R}$) and $\frak{c}alF(1,s)=1$. By \frak{c}ite[p.~173, (198) and p.~177, (214)]{Jiang1996}, we have
\begin{align*}
&\int_{U'(F)\backslash U(F)} \frak{c}alF(\eta(u,1)(t_1,t_2)) \,du\\
&=\delta_{({\bf B}\mathbf{t}imes {\bf B})^\frak{c}irc}((t_1,t_2))^{1/2}|a^{3/2}bc^{-1}|^{s+1}\frac{\zeta(s+1)^2}{\zeta(s+2)\zeta(s+3)}f^o(u,v,s),
\end{align*}
where
\[
 u = abc^{-1}d^{-1}, \qquad
 v = ac^{-1},
\]
and
\[
f^o(u,v,s)=
\begin{cases}
\max\{1,|u|\}^{-s-1}\max\{1,|v|\}^{-2s-2} & \mbox{ if $F$ is non-archimedean},\\
(1+u^2)^{-(s+1)/2}(1+v^2)^{-s-1} & \mbox{ if $F={\mathbb R}$}.
\end{cases}
\]
Fix $\frak{c}hi_1,\frak{c}hi_2 \in \frak{X}(\pi,\end{pmatrix}silon)$.  Let $k_1,k_2,k_3,k_1',k_2',k_3' \in {\mathbb R}$ be such that  
\[
\frak{c}hi_1(t) = |a|^{k_1}|b|^{k_2}|c|^{k_3},\quad \frak{c}hi_2(t) = |a|^{k_1'}|b|^{k_2'}|c|^{k_3'}
\]
for $t = {\rm diga}(a,b,ca^{-1},cb^{-1})$. Then 
\[\frak{c}hi_1(t_1)\frak{c}hi_2(t_2) = |a|^{k_a} |b|^{k_b} |c|^{k_c} |d|^{k_d},\]
where
\[
 k_a = k_1+k_2+k_3+k_3', \qquad
 k_b = k_1, \qquad
 k_c = k_1'+k_2', \qquad
 k_d = k_1'.
\]
Hence it suffices to consider the integral 
\[
 \int_{(F^\mathbf{t}imes)^4} \phi_{\end{pmatrix}silon}(a,b)\phi_{\end{pmatrix}silon}(c^2a^{-1},d) \frak{c}dot |a|^{{3}s/{2}  + k_a + {3}/{2}} |b|^{s + k_b + 1} |c|^{-s + k_c - 1} |d|^{k_d} f^o(u,v,s)\, d(a,b,c,d).
\]
We change variables $(a,b,c,d) \mapsto (a,b,u,v)$ to get
\begin{align}\label{E:Jiang's integral}
 \int_{(F^\mathbf{t}imes)^4} \phi_{\end{pmatrix}silon}(a,b)\phi_{\end{pmatrix}silon}(av^{-2},bu^{-1}v) \frak{c}dot |a|^{{s}/{2}  + l_a + {1}/{2}} |b|^{s + l_b + 1} |u|^{l_u} |v|^{s + l_v + 1} f^o(u,v,s) \, d(a,b,u,v), 
\end{align}
where 
\begin{align*}
 l_a & = k_a + k_c = k_1 + k_2 + k_3 + k_1' + k_2' + k_3' , \\
 l_b & = k_b + k_d = k_1 + k_1', \\
 l_u & = -k_d = -k_1', \\
 l_v & = -k_c + k_d = - k_2'. 
\end{align*}

First we consider Case (IIa). 

By Lemma \ref{L:Whittaker fun}-(3), we can choose a Schwartz function $\phi_\end{pmatrix}silon = \phi_{\lambda,\end{pmatrix}silon}$ for $W_\lambda$ of the form
\[
\phi_{\lambda,\end{pmatrix}silon}(a,b) = C_{\lambda,\end{pmatrix}silon} \frak{c}dot \mathbb{I}_{\varpi^{-n}\frak{o}}(a)\mathbb{I}_{\varpi^{-n}\frak{o}}(b)
\]
so that the constant $C_{\lambda,\end{pmatrix}silon}>0$ is bounded uniformly as $\lambda$ varies in a compact set and the integer $n$ is independent of $\lambda$. 
Put $r = q^n > 1$ and $\phi = \mathbb{I}_{\varpi^{-n}\frak{o}}$.
We write the integral (\ref{E:Jiang's integral}) as 
\[
C_{\lambda,\end{pmatrix}silon}^2\frak{c}dot (I_1 + I_2 + I_3 + I_4), 
\]
where 
\begin{align*}
 I_1 & = \int_{F^\mathbf{t}imes} \int_{F^\mathbf{t}imes} \int_{|u| \le 1} \int_{|v| \le 1}
 \phi(a) \phi(b) \phi(a v^{-2}) \phi(b u^{-1} v) \frak{c}dot |a|^{{s}/{2}  + l_a + {1}/{2}} |b|^{s + l_b + 1} |u|^{l_u} |v|^{s + l_v + 1} \, d(a,b,u,v) \\
 & = \int_{|a| \le r} \int_{|b| \le r} \int_{|u| \le 1} \int_{|v| \le 1}
 \phi(a v^{-2}) \phi(b u^{-1} v) \frak{c}dot |a|^{{s}/{2}  + l_a + {1}/{2}} |b|^{s + l_b + 1} |u|^{l_u} |v|^{s + l_v + 1} \, d(a,b,u,v), \\
 I_2 & = \int_{F^\mathbf{t}imes} \int_{F^\mathbf{t}imes} \int_{|u| \le 1} \int_{|v| > 1}
 \phi(a) \phi(b) \phi(a v^{-2}) \phi(b u^{-1} v) \frak{c}dot |a|^{{s}/{2}  + l_a + {1}/{2}} |b|^{s + l_b + 1} |u|^{l_u} |v|^{-s + l_v - 1} \, d(a,b,u,v) \\
 & = \int_{|a| \le r} \int_{|b| \le r} \int_{|u| \le 1} \int_{|v| < 1}
 \phi(a v^2) \phi(b u^{-1} v^{-1}) \frak{c}dot |a|^{{s}/{2}  + l_a + {1}/{2}} |b|^{s + l_b + 1} |u|^{l_u} |v|^{s - l_v + 1} \, d(a,b,u,v), \\
 I_3 & = \int_{F^\mathbf{t}imes} \int_{F^\mathbf{t}imes} \int_{|u| > 1} \int_{|v| \le 1}
 \phi(a) \phi(b) \phi(a v^{-2}) \phi(b u^{-1} v) \frak{c}dot |a|^{{s}/{2}  + l_a + {1}/{2}} |b|^{s + l_b + 1} |u|^{-s + l_u - 1} |v|^{s + l_v + 1} \, d(a,b,u,v) \\
 & = \int_{|a| \le r} \int_{|b| \le r} \int_{|u| < 1} \int_{|v| \le 1}
 \phi(a v^{-2}) \phi(b u v) \frak{c}dot |a|^{{s}/{2}  + l_a + {1}/{2}} |b|^{s + l_b + 1} |u|^{s - l_u + 1} |v|^{s + l_v + 1} \, d(a,b,u,v), \\
 I_4 & = \int_{F^\mathbf{t}imes} \int_{F^\mathbf{t}imes} \int_{|u| > 1} \int_{|v| > 1}
 \phi(a) \phi(b) \phi(a v^{-2}) \phi(b u^{-1} v) \frak{c}dot |a|^{{s}/{2}  + l_a + {1}/{2}} |b|^{s + l_b + 1} |u|^{-s + l_u - 1} |v|^{-s + l_v - 1} \, d(a,b,u,v) \\
 & = \int_{|a| \le r} \int_{|b| \le r} \int_{|u| < 1} \int_{|v| < 1}
 \phi(a v^2) \phi(b u v^{-1}) \frak{c}dot |a|^{{s}/{2}  + l_a + {1}/{2}} |b|^{s + l_b + 1} |u|^{s - l_u + 1} |v|^{s - l_v + 1} \, d(a,b,u,v). \\
\end{align*}
We assume $l_u \neq 0$. The case $l_u=0$ can be proved in a similar way and we omit it.
For $|b| \leq r$ and $|v|\leq 1$, we have 
\[
 \int_{|u| \le 1} \phi(b u^{-1} v) |u|^{l_u} \, du
 = \int_{r^{-1} |bv| \le |u| \le 1} |u|^{l_u} \, du
 =\frac{1- (q^{-1} r^{-1} |bv|)^{l_u}}{1-q^{-l_u}}.

\]
Then
\begin{align*}
 |1-q^{-l_u}| \frak{c}dot I_1 & \le  
 \int_{|a| \le r} \int_{|b| \le r} \int_{|v| \le 1}
\phi(av^{-2}) |a|^{{s}/{2}  + l_a + {1}/{2}} |b|^{s + l_b + 1} |v|^{s + l_v + 1} \, d(a,b,v) \\
 & + q^{-l_u} r^{-l_u} \int_{|a| \le r} \int_{|b| \le r} \int_{|v| \le 1}
\phi(av^{-2}) |a|^{{s}/{2}  + l_a + {1}/{2}} |b|^{s + l_b + l_u + 1} |v|^{s + l_u + l_v + 1} \, d(a,b,v). 
\end{align*}
Similarly, we have
\[
 \int_{|u| \le 1} \phi(b u^{-1} v^{-1}) |u|^{l_u} \, du

 = \frac{1- (q^{-1} r^{-1} |bv^{-1}|)^{l_u}}{1-q^{-l_u}}
\]
if $r^{-1}|bv^{-1}| \le 1$ and 
\[
 \int_{|u| \le 1} \phi(b u^{-1} v^{-1}) |u|^{l_u} \, du = 0
\]
otherwise.
Hence we have
\begin{align*}
 |1-q^{-l_u}| \frak{c}dot I_2 & \le  
 \int_{|a| \le r} \int_{|b| \le r} \int_{|v| < 1}
 |a|^{{s}/{2}  + l_a + {1}/{2}} |b|^{s + l_b + 1} |v|^{s - l_v + 1} \, d(a,b,v) \\
 & + q^{-l_u} r^{-l_u} \int_{|a| \le r} \int_{|b| \le r} \int_{|v| < 1}
 |a|^{{s}/{2}  + l_a + {1}/{2}} |b|^{s + l_b + l_u + 1} |v|^{s - l_u - l_v + 1} \, d(a,b,v).
\end{align*}
We also have
\begin{align*}
 I_3 & \le \int_{|a| \le r} \int_{|b| \le r} \int_{|u| < 1} \int_{|v| \le 1}
\phi(av^{-2}) |a|^{{s}/{2}  + l_a + {1}/{2}} |b|^{s + l_b + 1} |u|^{s - l_u + 1} |v|^{s + l_v + 1} \, d(a,b,u,v), \\
 I_4 & \le \int_{|a| \le r} \int_{|b| \le r} \int_{|u| < 1} \int_{|v| < 1}
 |a|^{{s}/{2}  + l_a + {1}/{2}} |b|^{s + l_b + 1} |u|^{s - l_u + 1} |v|^{s - l_v + 1} \, d(a,b,u,v).
\end{align*}
Note that the integrals
\[
\int_{|a|\leq r}\int_{|v|\leq 1}\phi(av^{-2})|a|^{s/2+l_a+1/2}|v|^{s+l_v+1}\,d(a,v),\quad \int_{|a|\leq r}\int_{|v|\leq 1}\phi(av^{-2})|a|^{s/2+l_a+1/2}|v|^{s+l_u+l_v+1}\,d(a,v)
\]
are absolutely convergent for
\[
s > \max\{-2l_a-1,-l_a-l_v/2-1\}, \quad
s > \max\{-2l_a-1,-l_a-l_u/2-l_v/2-1\},
\]
respectively.
We conclude that the integrals $I_1$, $I_2$, $I_3$, and $I_4$ are absolutely convergent for 
\[
s> \max\left\{ -2l_a-1,-l_b-1, l_u-1, l_v-1, -l_b-l_u-1,  l_u+l_v-1, -l_a-l_v/2-1,  -l_a-l_u/2-l_v/2-1    \right\}.
\]
From (\ref{E:charaIIa}), one can verify that the above inequality holds if 
$
s >  4|{\rm Re}(\lambda)|+4\end{pmatrix}silon-1.
$
Moreover, the above integrals are uniformly convergent as $\lambda$ varies in a compact set. This completes the proof for Case (IIa).

Next we consider Case (PS). Put 
\[\mu = \frac{|{\rm Re}(\lambda_1)|+|{\rm Re}(\lambda_2)|}{2}.\] By (\ref{E:charaPS}), 
$$l_a=-2\mu-2\end{pmatrix}silon,\quad l_b=-4\mu-4\end{pmatrix}silon,\quad l_u=2\mu+2\end{pmatrix}silon,\quad l_v=0.$$  
Assume $s> 4\mu+4\end{pmatrix}silon-1$. By Lemma \ref{L:Whittaker fun}-(3), we can choose a function $\phi_\end{pmatrix}silon = \phi_{\lambda,\end{pmatrix}silon}$ for $W_\lambda$ satisfying 
\[ \phi_{\lambda,\end{pmatrix}silon}(a,b) \leq C_{\lambda,\end{pmatrix}silon} \frak{c}dot e^{-\pi(|a|+|b|)/4}\]
for $a,b \in {\mathbb R}^\mathbf{t}imes$ so that the constant $C_{\lambda,\end{pmatrix}silon}>0$ is bounded uniformly as $\lambda$ varies in a compact set.
Then the integral (\ref{E:Jiang's integral}) is bounded by
\[
C_{\lambda,\end{pmatrix}silon}^2\int_{({\mathbb R}^\mathbf{t}imes)^4}  |a|^{{s}/{2}  + {1}/{2} - 2 (\mu+\end{pmatrix}silon) } |b|^{s + 1 - 4 (\mu+\end{pmatrix}silon)}e^{-\pi(|a|+|b|)/4} \frac{|u|^{2(\mu+\end{pmatrix}silon)}}{(1+u^2)^{(s+1)/2}} \frac{|v|^{s + 1 }}{(1+v^2)^{s+1}} \, d(a,b,u,v),
\]
which is absolutely convergent.
Moreover, it is clear that the above integral is uniformly convergent as $\lambda$ varies in a compact set. This completes the proof for Case (PS).

Finally we assume $\pi$ is of type (DS). 
By (\ref{E:charaDS}), 
\[l_a=-2\end{pmatrix}silon,\quad l_b=-2\end{pmatrix}silon,\quad l_u=\end{pmatrix}silon,\quad l_v=\end{pmatrix}silon.\]
Assume $s > 4\end{pmatrix}silon-1$. By Lemma \ref{L:Whittaker fun}-(2), there exists a constant $C_\end{pmatrix}silon>0$ such that 
\[\phi_\end{pmatrix}silon(a,b) \leq C_\end{pmatrix}silon \frak{c}dot e^{-\pi(|a|+|b|)/4}\]
for $a,b \in {\mathbb R}^\mathbf{t}imes$.
Then the integral (\ref{E:Jiang's integral}) is bounded by
\[
C_\end{pmatrix}silon^2\int_{({\mathbb R}^\mathbf{t}imes)^4}  |a|^{{s}/{2}  + {1}/{2} - 2 \end{pmatrix}silon } |b|^{s + 1 - 2 \end{pmatrix}silon}e^{-\pi(|a|+|b|)/4} \frac{|u|^{\end{pmatrix}silon}}{(1+u^2)^{(s+1)/2}} \frac{|v|^{s + 1 +\end{pmatrix}silon}}{(1+v^2)^{s+1}} \, d(a,b,u,v),
\]
which is absolutely convergent.
This completes the proof.
\end{proof}

		

\end{document}