1 Introduction
1.1 Picard rank jumps for K3 surfaces
 Let X be a K3 surface over a number field K. Let 
 $\mathcal {X}\xrightarrow {\pi } S$
 be a smooth and projective model of X over an open subscheme S of
$\mathcal {X}\xrightarrow {\pi } S$
 be a smooth and projective model of X over an open subscheme S of 
 $\mathrm {Spec}(\mathcal {O}_K)$
, the spectrum of the ring of integers
$\mathrm {Spec}(\mathcal {O}_K)$
, the spectrum of the ring of integers 
 $\mathcal {O}_K$
 of K. For every place
$\mathcal {O}_K$
 of K. For every place 
 $\mathfrak {P}$
 of K in S, let
$\mathfrak {P}$
 of K in S, let 
 $\mathcal {X}_{\overline {\mathfrak {P}}}$
 be the geometric fibre of
$\mathcal {X}_{\overline {\mathfrak {P}}}$
 be the geometric fibre of 
 $\pi $
 at
$\pi $
 at 
 $\mathfrak {P}$
. There is an injective specialisation map between Picard groups (see [Reference HuybrechtsHuy16, Chap.17 Prop.2.10]):
$\mathfrak {P}$
. There is an injective specialisation map between Picard groups (see [Reference HuybrechtsHuy16, Chap.17 Prop.2.10]): 
 $$ \begin{align*}\mathrm{sp}_{\mathfrak{P}}:\mathrm{Pic}(X_{\overline{K}})\hookrightarrow \mathrm{Pic}(\mathcal{X}_{\overline{\mathfrak{P}}}),\end{align*} $$
$$ \begin{align*}\mathrm{sp}_{\mathfrak{P}}:\mathrm{Pic}(X_{\overline{K}})\hookrightarrow \mathrm{Pic}(\mathcal{X}_{\overline{\mathfrak{P}}}),\end{align*} $$
which implies the inequality between Picard ranks
 $$ \begin{align*}\rho(\mathcal{X}_{\overline{\mathfrak{P}}}):=\operatorname{\mathrm{rank}}_{\mathbb{Z}}\operatorname{\mathrm{Pic}}(\mathcal{X}_{\overline{\mathfrak{P}}})\geq\rho(X_{\overline{K}}):=\operatorname{\mathrm{rank}}_{\mathbb{Z}}\operatorname{\mathrm{Pic}}(X_{\overline{K}}).\end{align*} $$
$$ \begin{align*}\rho(\mathcal{X}_{\overline{\mathfrak{P}}}):=\operatorname{\mathrm{rank}}_{\mathbb{Z}}\operatorname{\mathrm{Pic}}(\mathcal{X}_{\overline{\mathfrak{P}}})\geq\rho(X_{\overline{K}}):=\operatorname{\mathrm{rank}}_{\mathbb{Z}}\operatorname{\mathrm{Pic}}(X_{\overline{K}}).\end{align*} $$
In this paper, our main result implies the following theorem.
Theorem 1.1. Let X be a K3 surface over a number field K, and assume that X admits, up to a finite extension of K, a projective smooth model 
 $\mathcal {X}\rightarrow \mathrm {Spec}(\mathcal {O}_K)$
. Then there are infinitely many finite places
$\mathcal {X}\rightarrow \mathrm {Spec}(\mathcal {O}_K)$
. Then there are infinitely many finite places 
 $\mathfrak {P}$
 of K such that
$\mathfrak {P}$
 of K such that 
 $\rho (\mathcal {X}_{\overline {\mathfrak {P}}})> \rho (X_{\overline {K}})$
.
$\rho (\mathcal {X}_{\overline {\mathfrak {P}}})> \rho (X_{\overline {K}})$
.
 This question has been raised by Charles [Reference CharlesCha14], inspired by the work of Bogomolov–Hassett–Tschinkel [Reference Bogomolov, Hassett and TschinkelBHT11] and Li–Liedtke [Reference Li and LiedtkeLL12] (see also [Reference Costa and TschinkelCT14], [Reference Costa, Elsenhans and JahnelCEJ16]). By [Reference CharlesCha14, Theorem 1], up to a finite extension of K, the Picard rank 
 $\rho (\mathcal {X}_{\overline {\mathfrak {P}}})$
 for a density one set of primes
$\rho (\mathcal {X}_{\overline {\mathfrak {P}}})$
 for a density one set of primes 
 $\mathfrak {P}$
 is completely determined by
$\mathfrak {P}$
 is completely determined by 
 $\rho ({X}_{\overline {K}})$
 and the endomorphism field E of the sub-Hodge structure
$\rho ({X}_{\overline {K}})$
 and the endomorphism field E of the sub-Hodge structure 
 $T(X_\sigma )$
 of
$T(X_\sigma )$
 of 
 $H^2(X_\sigma ^{an}(\mathbb {C}),\mathbb {Q}))$
 given by the orthogonal complement of
$H^2(X_\sigma ^{an}(\mathbb {C}),\mathbb {Q}))$
 given by the orthogonal complement of 
 $\operatorname {\mathrm {Pic}}(X_{\overline {K}})$
 with respect to the intersection form, for any embedding
$\operatorname {\mathrm {Pic}}(X_{\overline {K}})$
 with respect to the intersection form, for any embedding 
 $\sigma $
 of K in
$\sigma $
 of K in 
 $\mathbb {C}$
. For instance, if E is CM or
$\mathbb {C}$
. For instance, if E is CM or 
 $\dim _E T(X_\sigma )$
 is even, then
$\dim _E T(X_\sigma )$
 is even, then 
 $\rho (\mathcal {X}_{\overline {\mathfrak {P}}})=\rho (X_{\overline {K}})$
 for a density one set of primes
$\rho (\mathcal {X}_{\overline {\mathfrak {P}}})=\rho (X_{\overline {K}})$
 for a density one set of primes 
 $\mathfrak {P}$
. In this situation, our theorem proves that the density zero set, where
$\mathfrak {P}$
. In this situation, our theorem proves that the density zero set, where 
 $\rho (\mathcal {X}_{\overline {\mathfrak {P}}})>\rho (X_{\overline {K}})$
 is in fact infinite.
$\rho (\mathcal {X}_{\overline {\mathfrak {P}}})>\rho (X_{\overline {K}})$
 is in fact infinite.
1.2 Rational curves on K3 surfaces
As an application of the above theorem, let us first recall the following conjecture.
Conjecture 1.2. Let X be a K3 surface over an algebraically closed field k. Then X contains infinitely many rational curves.
 The first result towards this conjecture is the one attributed to Bogomolov and Mumford and appearing in [Reference Mori and MukaiMM83, Appendix], which states that every K3 surface over 
 $\mathbb {C}$
 contains a rational curve. This conjecture has been settled in recent years in many cases thanks to the work of many people [Reference Bogomolov, Hassett and TschinkelBHT11, Reference Li and LiedtkeLL12, Reference CharlesCha14, Reference Bogomolov and TschinkelBT05, Reference TayouTay20b, Reference ChenChe99, Reference Chen and LewisCL13]. In characteristic zero, this conjecture has been solved in full generality in [Reference Chen, Gounelas and LiedtkeCGL19, Theorem A]. Our theorem implies the following alternative for K3 surfaces over number fields admitting everywhere potentially good reduction.
$\mathbb {C}$
 contains a rational curve. This conjecture has been settled in recent years in many cases thanks to the work of many people [Reference Bogomolov, Hassett and TschinkelBHT11, Reference Li and LiedtkeLL12, Reference CharlesCha14, Reference Bogomolov and TschinkelBT05, Reference TayouTay20b, Reference ChenChe99, Reference Chen and LewisCL13]. In characteristic zero, this conjecture has been solved in full generality in [Reference Chen, Gounelas and LiedtkeCGL19, Theorem A]. Our theorem implies the following alternative for K3 surfaces over number fields admitting everywhere potentially good reduction.
Corollary 1.3. Let X be a K3 surface over a number field K, and assume that X has potentially good reduction everywhere. Then either
- 
1.  $X_{\overline {K}}$
 contains infinitely many rational curves, or $X_{\overline {K}}$
 contains infinitely many rational curves, or
- 
2. X has infinitely many unirational and hence supersingular specialisations. 
1.3 Exceptional splitting of abelian varieties
 Let A denote a geometrically simple abelian variety over a number field K. Assuming the Mumford–Tate conjecture for A, Zwyina [Reference ZywinaZyw14, Corollary 1.3] proved that the mod 
 $\mathfrak {P}$
 reduction
$\mathfrak {P}$
 reduction 
 $A_{\mathfrak {P}}$
 is geometrically simple for a density one set of primes of K (up to replacing K by a finite extension) if and only if
$A_{\mathfrak {P}}$
 is geometrically simple for a density one set of primes of K (up to replacing K by a finite extension) if and only if 
 $\operatorname {\mathrm {End}}(A_{\overline {K}})$
 is commutative. As an application of the proof of Theorem 1.1 (more precisely, Theorem 2.4), we prove that the density zero set of primes with
$\operatorname {\mathrm {End}}(A_{\overline {K}})$
 is commutative. As an application of the proof of Theorem 1.1 (more precisely, Theorem 2.4), we prove that the density zero set of primes with 
 $A_{\mathfrak {P}}$
 geometrically nonsimple is infinite for certain classes of abelian varieties A, which are closely related to Kuga–Satake abelian varieties. We note that the Mumford–Tate conjecture is known (by work of Tankeev [Reference TankeevTan90, Reference TankeevTan95] and Vasiu [Reference VasiuVas08]) for the classes of abelian varieties that we treat.
$A_{\mathfrak {P}}$
 geometrically nonsimple is infinite for certain classes of abelian varieties A, which are closely related to Kuga–Satake abelian varieties. We note that the Mumford–Tate conjecture is known (by work of Tankeev [Reference TankeevTan90, Reference TankeevTan95] and Vasiu [Reference VasiuVas08]) for the classes of abelian varieties that we treat.
 As a first example, we observe that the moduli space of principally polarised abelian surfaces can be realised as a GSpin Shimura variety of dimension 
 $3$
 and, in this case, the associated Kuga–Satake abelian varieties are isogenous to powers of abelian surfaces. We therefore obtain:
$3$
 and, in this case, the associated Kuga–Satake abelian varieties are isogenous to powers of abelian surfaces. We therefore obtain:
Theorem 1.4. Every 
 $2$
-dimensional abelian scheme over
$2$
-dimensional abelian scheme over 
 $\mathcal {O}_K$
 admits infinitely many places of geometrically nonsimple reduction.
$\mathcal {O}_K$
 admits infinitely many places of geometrically nonsimple reduction.
 More generally, consider the setting of 
 $(V,Q)$
, a
$(V,Q)$
, a 
 $(b+2)$
-dimensional quadratic space over
$(b+2)$
-dimensional quadratic space over 
 $\mathbb {Q}$
 with signature
$\mathbb {Q}$
 with signature 
 $(b,2)$
.
$(b,2)$
.
Assumption 1.5. Suppose that 
 $b\geq 3$
,
$b\geq 3$
, 
 $b\equiv 3 \bmod 4$
 and the even Clifford algebra
$b\equiv 3 \bmod 4$
 and the even Clifford algebra 
 $C^+(V,Q)$
 is isomorphic to the matrix algebra
$C^+(V,Q)$
 is isomorphic to the matrix algebra 
 $M_{2^{n}}(\mathbb {Q})$
 with
$M_{2^{n}}(\mathbb {Q})$
 with 
 $n=\frac {b+1}{2}$
.
$n=\frac {b+1}{2}$
.
 Such a quadratic space (and its Clifford algebra) corresponds to a family of abelian varieties called Kuga–Satake abelian varieties (see Section 2.2). Every such abelian variety A has a splitting of the form 
 $A = A^+\times A^-$
 induced by the grading of the Clifford algebra. By the Kuga–Satake construction, it follows that
$A = A^+\times A^-$
 induced by the grading of the Clifford algebra. By the Kuga–Satake construction, it follows that 
 $A^+$
 is isogenous to
$A^+$
 is isogenous to 
 $B^{2^{n}}$
 for some lower-dimensional abelian variety B. Our next result concerns places of split reduction of B when A is defined over some number field K. Generically,
$B^{2^{n}}$
 for some lower-dimensional abelian variety B. Our next result concerns places of split reduction of B when A is defined over some number field K. Generically, 
 $\operatorname {\mathrm {End}}(B_{\bar {K}})=\mathbb {Z}$
 (see Section 9.2), and hence the set of places of geometrically split reductions has density zero by [Reference ZywinaZyw14], as the Mumford–Tate conjecture is known for A and therefore for B. We then prove the following result:
$\operatorname {\mathrm {End}}(B_{\bar {K}})=\mathbb {Z}$
 (see Section 9.2), and hence the set of places of geometrically split reductions has density zero by [Reference ZywinaZyw14], as the Mumford–Tate conjecture is known for A and therefore for B. We then prove the following result:
Theorem 1.6. Consider the above setting, with the assumption that B extends to an abelian scheme 
 $\mathcal {B}\rightarrow \mathrm {Spec}(\mathcal {O}_K)$
 (and, therefore, A also extends to an abelian scheme
$\mathcal {B}\rightarrow \mathrm {Spec}(\mathcal {O}_K)$
 (and, therefore, A also extends to an abelian scheme 
 $\mathcal {A} \rightarrow \mathrm {Spec}(\mathcal {O}_K)$
). Then there are infinitely many finite places
$\mathcal {A} \rightarrow \mathrm {Spec}(\mathcal {O}_K)$
). Then there are infinitely many finite places 
 $\mathfrak {P}$
 of K such that
$\mathfrak {P}$
 of K such that 
 $\mathcal {B}_{\mathfrak {P}}$
 is geometrically nonsimple.
$\mathcal {B}_{\mathfrak {P}}$
 is geometrically nonsimple.
 We also have similar results for abelian varieties parametrised by Shimura varieties associated to the unitary similitude group 
 $\mathrm {GU}(r,1)$
,
$\mathrm {GU}(r,1)$
, 
 $r\geq 1$
; see Section 9.3 for the precise definitions.
$r\geq 1$
; see Section 9.3 for the precise definitions.
Corollary 1.7. Let E be an imaginary quadratic field, and let 
 $\mathcal {A}$
 be a principally polarised abelian scheme over
$\mathcal {A}$
 be a principally polarised abelian scheme over 
 $\mathcal {O}_K$
. Suppose that there is an embedding
$\mathcal {O}_K$
. Suppose that there is an embedding 
 $\mathcal {O}_E\subset \operatorname {\mathrm {End}}(\mathcal {A})$
 compatible with the polarisation on
$\mathcal {O}_E\subset \operatorname {\mathrm {End}}(\mathcal {A})$
 compatible with the polarisation on 
 $\mathcal {A}$
 and that the action of
$\mathcal {A}$
 and that the action of 
 $\mathcal {O}_E$
 on
$\mathcal {O}_E$
 on 
 $\operatorname {\mathrm {Lie}} \mathcal {A}_K$
 has signature
$\operatorname {\mathrm {Lie}} \mathcal {A}_K$
 has signature 
 $(r,1)$
. Then there are infinitely many finite places
$(r,1)$
. Then there are infinitely many finite places 
 $\mathfrak {P}$
 of K such that
$\mathfrak {P}$
 of K such that 
 $\mathcal {A}_{\mathfrak {P}}$
 admits a geometric isogeny factor, which is an elliptic curve CM by E.
$\mathcal {A}_{\mathfrak {P}}$
 admits a geometric isogeny factor, which is an elliptic curve CM by E.
We should mention that the assumption of potentially good reduction in the above statements has been removed recently by one of the authors in [Reference TayouTay22] so that all the above results hold unconditionally.
1.4 GSpin Shimura varieties
 The above theorems can be reformulated within the more general framework of intersections of a (nonspecial) arithmetic 
 $1$
-cycle and special divisors in GSpin Shimura varieties as follows. Let
$1$
-cycle and special divisors in GSpin Shimura varieties as follows. Let 
 $(L,Q)$
 be an integral quadratic even lattice of signature
$(L,Q)$
 be an integral quadratic even lattice of signature 
 $(b,2)$
 with
$(b,2)$
 with 
 $b\geq 3$
.Footnote 1 Assume that L is a maximal lattice in
$b\geq 3$
.Footnote 1 Assume that L is a maximal lattice in 
 $V:=L\otimes _{\mathbb {Z}}\mathbb {Q}$
 over which Q is
$V:=L\otimes _{\mathbb {Z}}\mathbb {Q}$
 over which Q is 
 $\mathbb {Z}$
-valued. Associated to this data is a GSpin Shimura variety M, which is a Deligne–Mumford stack over
$\mathbb {Z}$
-valued. Associated to this data is a GSpin Shimura variety M, which is a Deligne–Mumford stack over 
 $\mathbb {Q}$
; see Section 2.1. It is a Shimura variety of Hodge type, which (by the work of Andreatta–Goren–Howard–Madapusi-Pera [Reference Andreatta, Goren, Howard and PeraAGHMP18]) admits a normal flat integral model
$\mathbb {Q}$
; see Section 2.1. It is a Shimura variety of Hodge type, which (by the work of Andreatta–Goren–Howard–Madapusi-Pera [Reference Andreatta, Goren, Howard and PeraAGHMP18]) admits a normal flat integral model 
 $\mathcal {M}$
 over
$\mathcal {M}$
 over 
 $\mathbb {Z}$
. This model is smooth at primes p that do not divide
$\mathbb {Z}$
. This model is smooth at primes p that do not divide 
 $\operatorname {\mathrm {Disc}}(Q)$
. Moreover, there is a family of the so-called Kuga–Satake abelian scheme
$\operatorname {\mathrm {Disc}}(Q)$
. Moreover, there is a family of the so-called Kuga–Satake abelian scheme 
 $\mathcal {A}^{\mathrm {univ}}\rightarrow \mathcal {M}$
; see Section Section 2.2,2.4. For every
$\mathcal {A}^{\mathrm {univ}}\rightarrow \mathcal {M}$
; see Section Section 2.2,2.4. For every 
 $m\in \mathbb {Z}_{>0}$
, a special divisor
$m\in \mathbb {Z}_{>0}$
, a special divisor 
 $\mathcal {Z}(m)\rightarrow \mathcal {M}$
 is constructed in [Reference Andreatta, Goren, Howard and PeraAGHMP18]Footnote 2 parametrising Kuga-Satake abelian varieties that admit special endomorphisms s such that
$\mathcal {Z}(m)\rightarrow \mathcal {M}$
 is constructed in [Reference Andreatta, Goren, Howard and PeraAGHMP18]Footnote 2 parametrising Kuga-Satake abelian varieties that admit special endomorphisms s such that 
 $s\circ s = [m]$
 (see Section 2.5). In particular, the moduli space of polarised K3 surfaces can be embedded in a GSpin Shimura variety (see Section 9.1), and special divisors parametrise K3 surfaces with Picard rank greater than that of the generic K3 surface. Our main theorem is the following.
$s\circ s = [m]$
 (see Section 2.5). In particular, the moduli space of polarised K3 surfaces can be embedded in a GSpin Shimura variety (see Section 9.1), and special divisors parametrise K3 surfaces with Picard rank greater than that of the generic K3 surface. Our main theorem is the following.
Theorem 1.8. Let K be a number field, and let 
 $\mathcal {Y}\in \mathcal {M}(\mathcal {O}_K)$
. Assume that
$\mathcal {Y}\in \mathcal {M}(\mathcal {O}_K)$
. Assume that 
 $\mathcal {Y}_K\in M(K)$
 is Hodge-generic. Then there exist infinitely many finite places
$\mathcal {Y}_K\in M(K)$
 is Hodge-generic. Then there exist infinitely many finite places 
 $\mathfrak {P}$
 of K modulo, for which
$\mathfrak {P}$
 of K modulo, for which 
 $\mathcal {Y}$
 lies in the image of
$\mathcal {Y}$
 lies in the image of 
 $\mathcal {Z}(m)\rightarrow \mathcal {M}$
 for some
$\mathcal {Z}(m)\rightarrow \mathcal {M}$
 for some 
 $m\in \mathbb {Z}_{>0}$
 (here m depends on
$m\in \mathbb {Z}_{>0}$
 (here m depends on 
 $\mathfrak {P}$
).
$\mathfrak {P}$
).
 Here we say that 
 $x\in M(K)$
 is Hodge-generic if for one embedding (equivalently any)
$x\in M(K)$
 is Hodge-generic if for one embedding (equivalently any) 
 $\sigma :K\hookrightarrow \mathbb {C}$
, the point
$\sigma :K\hookrightarrow \mathbb {C}$
, the point 
 $x^\sigma \in M(\mathbb {C})$
 does not lie on any divisor
$x^\sigma \in M(\mathbb {C})$
 does not lie on any divisor 
 $\mathcal {Z}(m)(\mathbb {C})$
. This is a harmless assumption since all
$\mathcal {Z}(m)(\mathbb {C})$
. This is a harmless assumption since all 
 $\mathcal {Z}(m)_K$
 are unions of GSpin Shimura varieties associated to rational quadratic spaces having signature
$\mathcal {Z}(m)_K$
 are unions of GSpin Shimura varieties associated to rational quadratic spaces having signature 
 $(b-1,2)$
. Hence, we may and will always work with the smallest GSpin sub-Shimura variety of M containing
$(b-1,2)$
. Hence, we may and will always work with the smallest GSpin sub-Shimura variety of M containing 
 $\mathcal {Y}_K$
.Footnote 3
$\mathcal {Y}_K$
.Footnote 3
 Theorem 1.8 is a generalisation of the main results of [Reference CharlesCha18, Reference Shankar and TangST19]. In the complex setting, the analogous results are well understood. More precisely, the Noether-Lefschetz locus of a nontrivial variation of Hodge structures of weight 
 $2$
 with
$2$
 with 
 $h^{2,0}=1$
 over a complex quasi-projective curve is dense for the analytic topology by a well-known result of Green [Reference VoisinVoi02, Prop. 17.20]. When this variation is of K3 type, the main result of [Reference TayouTay20a] shows in fact that this locus is equidistributed with respect to a natural measure. In the global function field setting, the main result of [Reference Maulik, Shankar and TangMST18] shows that given a nonisotrivial ordinary abelian surface over a projective curve C over
$h^{2,0}=1$
 over a complex quasi-projective curve is dense for the analytic topology by a well-known result of Green [Reference VoisinVoi02, Prop. 17.20]. When this variation is of K3 type, the main result of [Reference TayouTay20a] shows in fact that this locus is equidistributed with respect to a natural measure. In the global function field setting, the main result of [Reference Maulik, Shankar and TangMST18] shows that given a nonisotrivial ordinary abelian surface over a projective curve C over 
 $\overline {\mathbb {F}}_p$
, there are infinitely many
$\overline {\mathbb {F}}_p$
, there are infinitely many 
 $\overline {\mathbb {F}}_p$
-points in C such that the corresponding abelian surface is not simple. This result is analogous to Theorem 1.8 in the function field setting when
$\overline {\mathbb {F}}_p$
-points in C such that the corresponding abelian surface is not simple. This result is analogous to Theorem 1.8 in the function field setting when 
 $b=2,3$
.
$b=2,3$
.
 We now say a word about the potentially good reduction hypothesis (i.e., the fact that we require 
 $\mathcal {Y}$
 to be an
$\mathcal {Y}$
 to be an 
 $\mathcal {O}_K$
-point of
$\mathcal {O}_K$
-point of 
 $\mathcal {M}$
, up to a finite extension of the base field, as opposed to a
$\mathcal {M}$
, up to a finite extension of the base field, as opposed to a 
 $\mathcal {O}_K[1/N]$
-point). The boundary components in the Satake compactificationFootnote 4 of M have dimension either
$\mathcal {O}_K[1/N]$
-point). The boundary components in the Satake compactificationFootnote 4 of M have dimension either 
 $0$
 or
$0$
 or 
 $1$
, whereas the Shimura variety itself is b-dimensional. As the boundary has large codimension in the ambient Shimura variety, it follows that ‘most’ points have potentially good reduction, so our good-reduction hypothesis is not an especially stringent condition. A large family of points with potentially good reduction everywhere (in the case
$1$
, whereas the Shimura variety itself is b-dimensional. As the boundary has large codimension in the ambient Shimura variety, it follows that ‘most’ points have potentially good reduction, so our good-reduction hypothesis is not an especially stringent condition. A large family of points with potentially good reduction everywhere (in the case 
 $b = 2c$
) can be obtained as follows: consider a real quadratic field
$b = 2c$
) can be obtained as follows: consider a real quadratic field 
 $F/\mathbb {Q}$
 and a
$F/\mathbb {Q}$
 and a 
 $(c+1)$
-dimensional orthogonal space
$(c+1)$
-dimensional orthogonal space 
 $(V',Q')$
 over F with real signatures
$(V',Q')$
 over F with real signatures 
 $(c+1,0)$
 at one archimedean place and
$(c+1,0)$
 at one archimedean place and 
 $(c-1,2)$
 at the other. Then the associated
$(c-1,2)$
 at the other. Then the associated 
 $(c-1)$
-dimensional Shimura variety of Hodge type is compact and embeds inside the b-dimensional Shimura variety associated to the
$(c-1)$
-dimensional Shimura variety of Hodge type is compact and embeds inside the b-dimensional Shimura variety associated to the 
 $\mathbb {Q}$
-rational
$\mathbb {Q}$
-rational 
 $(b+2)$
-dimensional quadratic space obtained by treating
$(b+2)$
-dimensional quadratic space obtained by treating 
 $V'$
 as a
$V'$
 as a 
 $\mathbb {Q}$
-vector space equipped with the quadratic form
$\mathbb {Q}$
-vector space equipped with the quadratic form 
 $\operatorname {\mathrm {tr}}_{F/\mathbb {Q}}(Q')$
.
$\operatorname {\mathrm {tr}}_{F/\mathbb {Q}}(Q')$
.
1.5 Strategy of the proof
 The proof of Theorem 1.8 follows the lines of [Reference CharlesCha18] and relies on Arakelov intersection theory on the integral model 
 $\mathcal {M}$
 of the GSpin Shimura variety M. For every positive integer m, the special divisor
$\mathcal {M}$
 of the GSpin Shimura variety M. For every positive integer m, the special divisor 
 $\mathcal {Z}(m)$
 parametrises points of
$\mathcal {Z}(m)$
 parametrises points of 
 $\mathcal {M}$
 for which the associated Kuga–Satake abelian variety admits an extra special endomorphism s that satisfies
$\mathcal {M}$
 for which the associated Kuga–Satake abelian variety admits an extra special endomorphism s that satisfies 
 $s\circ s=[m]$
; see Section 2.3. By the work of Bruinier [Reference BruinierBru02], this divisor can be endowed with a Green function
$s\circ s=[m]$
; see Section 2.3. By the work of Bruinier [Reference BruinierBru02], this divisor can be endowed with a Green function 
 $\Phi _{m}$
, which is constructed using theta lift of nonholomorphic Eisenstein series of negative weight and thus yields an arithmetic divisor
$\Phi _{m}$
, which is constructed using theta lift of nonholomorphic Eisenstein series of negative weight and thus yields an arithmetic divisor 
 $\widehat {\mathcal {Z}}(m)=(\mathcal {Z}(m),\Phi _{m})$
 in the first arithmetic Chow group
$\widehat {\mathcal {Z}}(m)=(\mathcal {Z}(m),\Phi _{m})$
 in the first arithmetic Chow group 
 $\widehat {\operatorname {\mathrm {CH}}^1}(\mathcal {M})$
 of
$\widehat {\operatorname {\mathrm {CH}}^1}(\mathcal {M})$
 of 
 $\mathcal {M}$
. By assumption, we have an abelian scheme
$\mathcal {M}$
. By assumption, we have an abelian scheme 
 $\mathcal {A}_{\mathcal {Y}}\rightarrow \mathcal {Y}=\mathrm {Spec}(\mathcal {O}_K)$
 and a map
$\mathcal {A}_{\mathcal {Y}}\rightarrow \mathcal {Y}=\mathrm {Spec}(\mathcal {O}_K)$
 and a map 
 $\iota :\mathcal {Y}\rightarrow \mathcal {M}$
. We can express the height
$\iota :\mathcal {Y}\rightarrow \mathcal {M}$
. We can express the height 
 $h_{\widehat {\mathcal {Z}}(m)}(\mathcal {Y})$
 of
$h_{\widehat {\mathcal {Z}}(m)}(\mathcal {Y})$
 of 
 $\mathcal {Y}$
 with respect to the arithmetic divisor
$\mathcal {Y}$
 with respect to the arithmetic divisor 
 $\widehat {\mathcal {Z}}(m)$
 as follows (see Section 3.1):
$\widehat {\mathcal {Z}}(m)$
 as follows (see Section 3.1): 
 $$ \begin{align} h_{\widehat{\mathcal{Z}}(m)}(\mathcal{Y})=\sum_{\sigma:K\hookrightarrow \mathbb{C}}\Phi_m(\mathcal{Y}^\sigma)+\sum_{\mathfrak{P} \text{ finite place}} (\mathcal{Y}. \mathcal{Z}(m))_{\mathfrak{P}} \log |\mathcal{O}_K/\mathfrak{P}|. \end{align} $$
$$ \begin{align} h_{\widehat{\mathcal{Z}}(m)}(\mathcal{Y})=\sum_{\sigma:K\hookrightarrow \mathbb{C}}\Phi_m(\mathcal{Y}^\sigma)+\sum_{\mathfrak{P} \text{ finite place}} (\mathcal{Y}. \mathcal{Z}(m))_{\mathfrak{P}} \log |\mathcal{O}_K/\mathfrak{P}|. \end{align} $$
 By definition, 
 $(\mathcal {Y},\mathcal {Z}(m))_{\mathfrak {P}}\neq 0$
 if and only if the Kuga–Satake abelian variety at
$(\mathcal {Y},\mathcal {Z}(m))_{\mathfrak {P}}\neq 0$
 if and only if the Kuga–Satake abelian variety at 
 $\mathcal {Y}_{\overline {\mathfrak {P}}}$
 admits a special endomorphism s with
$\mathcal {Y}_{\overline {\mathfrak {P}}}$
 admits a special endomorphism s with 
 $s\circ s=[m]$
. Therefore, to prove Theorem 1.8, it suffices to show that for a fixed finite place
$s\circ s=[m]$
. Therefore, to prove Theorem 1.8, it suffices to show that for a fixed finite place 
 $\mathfrak {P}$
, for most positive integers m, we have
$\mathfrak {P}$
, for most positive integers m, we have 
 $$ \begin{align} (\mathcal{Y}. \mathcal{Z}(m))_{\mathfrak{P}}=o\left(h_{\widehat{\mathcal{Z}}(m)}(\mathcal{Y})-\sum_{\sigma:K\rightarrow \mathbb{C}}\Phi_m(\mathcal{Y}^\sigma)\right). \end{align} $$
$$ \begin{align} (\mathcal{Y}. \mathcal{Z}(m))_{\mathfrak{P}}=o\left(h_{\widehat{\mathcal{Z}}(m)}(\mathcal{Y})-\sum_{\sigma:K\rightarrow \mathbb{C}}\Phi_m(\mathcal{Y}^\sigma)\right). \end{align} $$
 Here are the ingredients of the proof. Let m be a positive integer represented by the lattice 
 $(L,Q)$
:
$(L,Q)$
: 
- 
1. Starting from an explicit expression of  $\Phi _m$
 given by Bruinier in [Reference BruinierBru02, §2.2], we pick the main term out of the archimedean part of equation (1.1), which is a scalar multiple of $\Phi _m$
 given by Bruinier in [Reference BruinierBru02, §2.2], we pick the main term out of the archimedean part of equation (1.1), which is a scalar multiple of $m^{\frac {b}{2}}\log m$
; see Proposition 5.2. $m^{\frac {b}{2}}\log m$
; see Proposition 5.2.
- 
2. To treat the term  $h_{\widehat {\mathcal {Z}}(m)}(\mathcal {Y})$
, we use a theorem of Howard and Madapusi-Pera [Reference Howard and Madapusi PeraHM17, Theorem 9.4.1], which asserts that the generating series of $h_{\widehat {\mathcal {Z}}(m)}(\mathcal {Y})$
, we use a theorem of Howard and Madapusi-Pera [Reference Howard and Madapusi PeraHM17, Theorem 9.4.1], which asserts that the generating series of $\widehat {\mathcal {Z}}(m)$
 is a component of a vector-valued modular form of weight $\widehat {\mathcal {Z}}(m)$
 is a component of a vector-valued modular form of weight $1+\frac {b}{2}$
 with respect to the Weil representation associated to the lattice $1+\frac {b}{2}$
 with respect to the Weil representation associated to the lattice $(L,Q)$
. As a consequence, we get $(L,Q)$
. As a consequence, we get $h_{\widehat {\mathcal {Z}}(m)}(\mathcal {Y})=O(m^{\frac {b}{2}})$
. This modularity result was previously known over the complex fibre by the work of Borcherds [Reference BorcherdsBor99], and a cohomological version was given by Kudla–Millson [Reference Kudla and MillsonKM90]. $h_{\widehat {\mathcal {Z}}(m)}(\mathcal {Y})=O(m^{\frac {b}{2}})$
. This modularity result was previously known over the complex fibre by the work of Borcherds [Reference BorcherdsBor99], and a cohomological version was given by Kudla–Millson [Reference Kudla and MillsonKM90].
- 
3. Based on Bruinier’s explicit formula, we reduce the estimate of the remaining part of the archimedean term into a problem of counting lattice points with weight functions admitting logarithmic singularities; see Proposition 5.4. 
- 
4. The treatment of this lattice-counting problem in Section 6 is one of the key novelties here compared to the treatment of the archimedean places in the previous works [Reference CharlesCha18, Reference Shankar and TangST19]. We break the sum into two parts; the first part, which consists of lattice points that are not very close to the singularity of the weight function, is treated using the circle method, and the rest is controlled by the so-called diophantine bound. More precisely, the geometrical meaning of controlling the second part is to show that (away from a small set of m)  $\mathcal {Y}(\mathbb {C})$
 is not very close to $\mathcal {Y}(\mathbb {C})$
 is not very close to $\mathcal {Z}(m)(\mathbb {C})$
. Roughly speaking, we prove that if $\mathcal {Z}(m)(\mathbb {C})$
. Roughly speaking, we prove that if $\mathcal {Y}(\mathbb {C})$
 is too close to too many special divisors with m in a certain range, then $\mathcal {Y}(\mathbb {C})$
 is too close to too many special divisors with m in a certain range, then $\mathcal {Y}(\mathbb {C})$
 must be close to a special divisor with much smaller m. This would violate the diophantine bound deduced from the height formula and the estimates in (1)–(3) above; see Theorem 5.8. $\mathcal {Y}(\mathbb {C})$
 must be close to a special divisor with much smaller m. This would violate the diophantine bound deduced from the height formula and the estimates in (1)–(3) above; see Theorem 5.8.
- 
5. Now it remains to treat the finite contribution. This part can be translated into a lattice-counting problem on a sequence of lattices  $L_n, n\in \mathbb {Z}_{\geq 1}$
, where $L_n, n\in \mathbb {Z}_{\geq 1}$
, where $L_n$
 is the lattice of special endomorphisms of the Kuga–Satake abelian variety over $L_n$
 is the lattice of special endomorphisms of the Kuga–Satake abelian variety over $\mathcal {Y} \bmod \mathfrak {P}^n$
; see Lemma 7.2. As in [Reference Shankar and TangST19], we use Grothendieck–Messing theory and Serre–Tate theory to describe the asymptotic behaviour of $\mathcal {Y} \bmod \mathfrak {P}^n$
; see Lemma 7.2. As in [Reference Shankar and TangST19], we use Grothendieck–Messing theory and Serre–Tate theory to describe the asymptotic behaviour of $L_n$
. These results give adequate bounds for the main terms. To deal with the error terms, we use the diophantine bound (see Theorem 5.8) for individual m to obtain better bounds on average. This step is crucial for our proof. Indeed, we illustrate the necessity of using the height bound with an example of a transcendental point of $L_n$
. These results give adequate bounds for the main terms. To deal with the error terms, we use the diophantine bound (see Theorem 5.8) for individual m to obtain better bounds on average. This step is crucial for our proof. Indeed, we illustrate the necessity of using the height bound with an example of a transcendental point of $\mathcal {M}$
 in Section 7.3, where the finite contribution can be arbitrarily large for an infinite sequence of m. We also remark that our idea of using the global height bound has other applications. Indeed, our idea is a crucial ingredient in proving intersection-theoretic results in characteristic p, as well as in proving the ordinary Hecke-orbit conjecture for GSpin Shimura varieties (see [Reference Maulik, Shankar and TangMST22]). It has also been used to extend the main theorem to the bad reduction situation; see [Reference TayouTay22]. We note, however, that our theorem applies to K3 surfaces with potentially good reduction everywhere. There are very few K3 surfaces with good reduction everywhere, but the condition of potentially good reduction is far less restrictive. Indeed, the moduli spaces of polarised K3 surfaces contain several compact Shimura varieties whose points parametrise K3 surfaces with potentially good reduction everywhere, and our result applies to them. $\mathcal {M}$
 in Section 7.3, where the finite contribution can be arbitrarily large for an infinite sequence of m. We also remark that our idea of using the global height bound has other applications. Indeed, our idea is a crucial ingredient in proving intersection-theoretic results in characteristic p, as well as in proving the ordinary Hecke-orbit conjecture for GSpin Shimura varieties (see [Reference Maulik, Shankar and TangMST22]). It has also been used to extend the main theorem to the bad reduction situation; see [Reference TayouTay22]. We note, however, that our theorem applies to K3 surfaces with potentially good reduction everywhere. There are very few K3 surfaces with good reduction everywhere, but the condition of potentially good reduction is far less restrictive. Indeed, the moduli spaces of polarised K3 surfaces contain several compact Shimura varieties whose points parametrise K3 surfaces with potentially good reduction everywhere, and our result applies to them.
- 
6. We briefly describe how we use the diophantine bound for each m to obtain stronger bounds on the local contribution from finite places on average. The arguments in (1)–(3) actually prove that the quantity inside the little o in the right-hand side of equation (1.2) is bounded by  $m^{\frac {b}{2}}\log m$
, as $m^{\frac {b}{2}}\log m$
, as $m\rightarrow \infty $
 (although we prove that it is also $m\rightarrow \infty $
 (although we prove that it is also $\gg m^{\frac {b}{2}}\log m$
 in (4) for most m). Since each term $\gg m^{\frac {b}{2}}\log m$
 in (4) for most m). Since each term $(\mathcal {Y}. \mathcal {Z}(m))_{\mathfrak {P}}$
 is nonnegative, we have that for any $(\mathcal {Y}. \mathcal {Z}(m))_{\mathfrak {P}}$
 is nonnegative, we have that for any $\mathfrak {P}$
, the local contribution $\mathfrak {P}$
, the local contribution $(\mathcal {Y}. \mathcal {Z}(m))_{\mathfrak {P}}=O(m^{\frac {b}{2}}\log m)$
 – this is the diophantine bound that we refer to. By Lemma 7.2, this diophantine bound implies that for $(\mathcal {Y}. \mathcal {Z}(m))_{\mathfrak {P}}=O(m^{\frac {b}{2}}\log m)$
 – this is the diophantine bound that we refer to. By Lemma 7.2, this diophantine bound implies that for $n\gg m^{\frac {b}{2} +\epsilon }, \epsilon>0$
, any nonzero special endomorphism s in the lattice $n\gg m^{\frac {b}{2} +\epsilon }, \epsilon>0$
, any nonzero special endomorphism s in the lattice $L_n$
 must satisfy $L_n$
 must satisfy $s\circ s=[m']$
 with $s\circ s=[m']$
 with $m'\geq m$
. Then a geometry-of-numbers argument suffices to conclude the proof of our theorem. $m'\geq m$
. Then a geometry-of-numbers argument suffices to conclude the proof of our theorem.
1.6 Organisation of the paper
 In Section 2, we recall the construction of the GSpin Shimura variety associated to the lattice 
 $(L,Q)$
 following [Reference Andreatta, Goren, Howard and PeraAGHMP17, Reference Andreatta, Goren, Howard and PeraAGHMP18, Reference Howard and Madapusi PeraHM17], as well as the construction of its integral model and the construction of the special divisors using the notion of special endomorphisms; then we give a reformulation of Theorem 1.8. In Section 3, we recall how to associate Green functions to the special divisors on
$(L,Q)$
 following [Reference Andreatta, Goren, Howard and PeraAGHMP17, Reference Andreatta, Goren, Howard and PeraAGHMP18, Reference Howard and Madapusi PeraHM17], as well as the construction of its integral model and the construction of the special divisors using the notion of special endomorphisms; then we give a reformulation of Theorem 1.8. In Section 3, we recall how to associate Green functions to the special divisors on 
 $\mathcal {M}$
, and we state Borcherds–Howard–Madapusi-Pera’s modularity result from [Reference Howard and Madapusi PeraHM17]; then we derive consequences on the growth of the global height of an
$\mathcal {M}$
, and we state Borcherds–Howard–Madapusi-Pera’s modularity result from [Reference Howard and Madapusi PeraHM17]; then we derive consequences on the growth of the global height of an 
 $\mathcal {O}_K$
-point on
$\mathcal {O}_K$
-point on 
 $\mathcal {M}$
. In Section 4, we collect some general results on quadratic forms that will be used in the following sections. In Section 5, we give a first-step estimate on the growth of the archimedean terms, and we derive the diophantine bounds on archimedean and nonarchimedean contributions. The second step in estimating the archimedean contributions is performed in Section 6, while the nonarchimedean contributions are treated in Section 7. In Section 8, we put together all the ingredients to prove Theorem 2.4 and hence Theorem 1.8. Finally, in Section 9, we prove the applications to K3 surfaces. Subsequently, we prove the applications to Kuga–Satake abelian varieties and abelian varieties parametrised by unitary Shimura varieties.
$\mathcal {M}$
. In Section 4, we collect some general results on quadratic forms that will be used in the following sections. In Section 5, we give a first-step estimate on the growth of the archimedean terms, and we derive the diophantine bounds on archimedean and nonarchimedean contributions. The second step in estimating the archimedean contributions is performed in Section 6, while the nonarchimedean contributions are treated in Section 7. In Section 8, we put together all the ingredients to prove Theorem 2.4 and hence Theorem 1.8. Finally, in Section 9, we prove the applications to K3 surfaces. Subsequently, we prove the applications to Kuga–Satake abelian varieties and abelian varieties parametrised by unitary Shimura varieties.
1.7 Notations
 If 
 $f,g:\mathbb {N}\rightarrow \mathbb {R}$
 are real functions and g does not vanish, then
$f,g:\mathbb {N}\rightarrow \mathbb {R}$
 are real functions and g does not vanish, then 
- 
1.  $f=O(g)$
, or $f=O(g)$
, or $f\ll g$
, if there exists an integer $f\ll g$
, if there exists an integer $n_0\in \mathbb {N}$
, a positive constant $n_0\in \mathbb {N}$
, a positive constant $C_{0}>0$
 such that $C_{0}>0$
 such that $$ \begin{align*}\forall n\geq n_0,\, |f(n)|\leq C_{0}|g_{}(n)|.\end{align*} $$ $$ \begin{align*}\forall n\geq n_0,\, |f(n)|\leq C_{0}|g_{}(n)|.\end{align*} $$
- 
2.  $f\asymp h$
 if $f\asymp h$
 if $f=O(h)$
 and $f=O(h)$
 and $h=O(f)$
. $h=O(f)$
.
- 
3.  $f=o(g)$
 if for every $f=o(g)$
 if for every $\epsilon>0$
, there exists $\epsilon>0$
, there exists $n_\epsilon $
 such that for every $n_\epsilon $
 such that for every $n\geq n_\epsilon $ $n\geq n_\epsilon $ $$ \begin{align*}|f(n)|\leq \epsilon |g(n)|.\end{align*} $$ $$ \begin{align*}|f(n)|\leq \epsilon |g(n)|.\end{align*} $$
- 
4. For p a prime number,  $\operatorname {\mathrm {val}}_p$
 denotes the p-adic valuation on $\operatorname {\mathrm {val}}_p$
 denotes the p-adic valuation on $\mathbb {Q}$
. $\mathbb {Q}$
.
- 
5. For  $s\in \mathbb {C}$
, $s\in \mathbb {C}$
, $\mathrm {Re}(s)$
 is the real part of s. $\mathrm {Re}(s)$
 is the real part of s.
2 The GSpin Shimura varieties and their special divisors
 Let 
 $(L,Q)$
 be an integral quadratic even lattice of signature
$(L,Q)$
 be an integral quadratic even lattice of signature 
 $(b,2)$
,
$(b,2)$
, 
 $b\geq 1$
, with associated bilinear form defined by
$b\geq 1$
, with associated bilinear form defined by 
 $$ \begin{align*}(x.y)=Q(x+y)-Q(x)-Q(y),\end{align*} $$
$$ \begin{align*}(x.y)=Q(x+y)-Q(x)-Q(y),\end{align*} $$
for 
 $x,y\in L$
. Let
$x,y\in L$
. Let 
 $V:=L\otimes _{\mathbb {Z}}\mathbb {Q}$
, and assume that L is a maximal lattice in V over which Q is
$V:=L\otimes _{\mathbb {Z}}\mathbb {Q}$
, and assume that L is a maximal lattice in V over which Q is 
 $\mathbb {Z}$
-valued. We recall in this section the theory of GSpin Shimura varieties associated with
$\mathbb {Z}$
-valued. We recall in this section the theory of GSpin Shimura varieties associated with 
 $(L,Q)$
. Our main references are [Reference Andreatta, Goren, Howard and PeraAGHMP17, Section 2], [Reference Andreatta, Goren, Howard and PeraAGHMP18, Section 4] and [Reference PeraMP16, Section 3].
$(L,Q)$
. Our main references are [Reference Andreatta, Goren, Howard and PeraAGHMP17, Section 2], [Reference Andreatta, Goren, Howard and PeraAGHMP18, Section 4] and [Reference PeraMP16, Section 3].
2.1 The GSpin Shimura variety
 For a commutative ring R, let 
 $L_{R}$
 denote
$L_{R}$
 denote 
 $L\otimes _{\mathbb {Z}}R$
, and the quadratic form Q on L induces a quadratic form Q on
$L\otimes _{\mathbb {Z}}R$
, and the quadratic form Q on L induces a quadratic form Q on 
 $L_R$
. The Clifford algebra
$L_R$
. The Clifford algebra 
 $C(L_R)$
 of
$C(L_R)$
 of 
 $(L_R, Q)$
 is the R-algebra defined as the quotient of the tensor algebra
$(L_R, Q)$
 is the R-algebra defined as the quotient of the tensor algebra 
 $\bigotimes L_R$
 by the ideal generated by
$\bigotimes L_R$
 by the ideal generated by 
 $\{(x\otimes x)-Q(x),\, x\in L_R\}$
. It has a
$\{(x\otimes x)-Q(x),\, x\in L_R\}$
. It has a 
 $\mathbb {Z}/2\mathbb {Z}$
 grading
$\mathbb {Z}/2\mathbb {Z}$
 grading 
 $C(L_R)=C(L_R)^+\oplus C(L_R)^-$
 induced by the grading on
$C(L_R)=C(L_R)^+\oplus C(L_R)^-$
 induced by the grading on 
 $\bigotimes L_R$
. When R is a
$\bigotimes L_R$
. When R is a 
 $\mathbb {Q}$
-algebra, we also denote
$\mathbb {Q}$
-algebra, we also denote 
 $C(L_R)$
 (respectively,
$C(L_R)$
 (respectively, 
 $C^\pm (L_R)$
) by
$C^\pm (L_R)$
) by 
 $C(V_R)$
 (respectively,
$C(V_R)$
 (respectively, 
 $C^\pm (V_R)$
) and note that
$C^\pm (V_R)$
) and note that 
 $C(L)$
 is a lattice in
$C(L)$
 is a lattice in 
 $C(V)$
.
$C(V)$
.
 Let 
 $G:=\mathrm {GSpin}(V)$
 be the group of spinor similitudes of V. It is the reductive algebraic group over
$G:=\mathrm {GSpin}(V)$
 be the group of spinor similitudes of V. It is the reductive algebraic group over 
 $\mathbb {Q}$
 such that
$\mathbb {Q}$
 such that 
 $$ \begin{align*}G(R)=\{g\in C^{+}(V_R)^\times,\, gV_R g^{-1}=V_{R}\}\end{align*} $$
$$ \begin{align*}G(R)=\{g\in C^{+}(V_R)^\times,\, gV_R g^{-1}=V_{R}\}\end{align*} $$
for any 
 $\mathbb {Q}$
-algebra R. We denote by
$\mathbb {Q}$
-algebra R. We denote by 
 $\nu :G\rightarrow \mathbb {G}_m$
 the spinor similitude factor as defined in [Reference BassBas74, Section 3]. The group G acts on V via
$\nu :G\rightarrow \mathbb {G}_m$
 the spinor similitude factor as defined in [Reference BassBas74, Section 3]. The group G acts on V via 
 $g\bullet v=gvg^{-1}$
 for
$g\bullet v=gvg^{-1}$
 for 
 $v\in V_R$
 and
$v\in V_R$
 and 
 $g\in G(R)$
. Moreover, there is an exact sequence of algebraic groups
$g\in G(R)$
. Moreover, there is an exact sequence of algebraic groups 
 $$ \begin{align*}1\rightarrow \mathbb{G}_{m}\rightarrow G\xrightarrow{g\mapsto g\bullet}\mathrm{SO}(V)\rightarrow 1.\end{align*} $$
$$ \begin{align*}1\rightarrow \mathbb{G}_{m}\rightarrow G\xrightarrow{g\mapsto g\bullet}\mathrm{SO}(V)\rightarrow 1.\end{align*} $$
 Let 
 $D_L$
 be the period domain associated to
$D_L$
 be the period domain associated to 
 $(L,Q)$
 defined byFootnote 5
$(L,Q)$
 defined byFootnote 5 
 $$ \begin{align*}D_L=\{x \in \mathbb{P}(V_{\mathbb{C}})\mid (\overline{x}.x)<0,(x.x)=0\}.\end{align*} $$
$$ \begin{align*}D_L=\{x \in \mathbb{P}(V_{\mathbb{C}})\mid (\overline{x}.x)<0,(x.x)=0\}.\end{align*} $$
It is a hermitian symmetric domain, and the group 
 $G(\mathbb {R})$
 acts transitively on
$G(\mathbb {R})$
 acts transitively on 
 $D_L$
. As in [Reference Andreatta, Goren, Howard and PeraAGHMP18, §4.1],
$D_L$
. As in [Reference Andreatta, Goren, Howard and PeraAGHMP18, §4.1], 
 $(G,D_L)$
 defines a Shimura datum as follows: for any class
$(G,D_L)$
 defines a Shimura datum as follows: for any class 
 $[z]\in D_{L}$
 with
$[z]\in D_{L}$
 with 
 $z\in V_{\mathbb {C}}$
, there is a morphism of algebraic groups over
$z\in V_{\mathbb {C}}$
, there is a morphism of algebraic groups over 
 $\mathbb {R}$
$\mathbb {R}$
 
 $$ \begin{align*}h_{[z]}:\mathbb{S}=\mathrm{Res}_{\mathbb{C}/\mathbb{R}}\mathbb{G}_m\rightarrow G_{\mathbb{R}}\end{align*} $$
$$ \begin{align*}h_{[z]}:\mathbb{S}=\mathrm{Res}_{\mathbb{C}/\mathbb{R}}\mathbb{G}_m\rightarrow G_{\mathbb{R}}\end{align*} $$
such that the induced Hodge decomposition on 
 $V_{\mathbb {C}}$
 is given by
$V_{\mathbb {C}}$
 is given by 
 $$ \begin{align*}V^{1,-1}=\mathbb{C} z, V^{-1,1}=\mathbb{C} \overline{z}, V_{\mathbb{C}}^{0,0}=(\mathbb{C} z\oplus \mathbb{C} \overline{z})^{\bot}.\end{align*} $$
$$ \begin{align*}V^{1,-1}=\mathbb{C} z, V^{-1,1}=\mathbb{C} \overline{z}, V_{\mathbb{C}}^{0,0}=(\mathbb{C} z\oplus \mathbb{C} \overline{z})^{\bot}.\end{align*} $$
Indeed, choose a representative 
 $z=u+iw$
, where
$z=u+iw$
, where 
 $u,w\in V_{\mathbb {R}}$
 are orthogonal and
$u,w\in V_{\mathbb {R}}$
 are orthogonal and 
 $Q(u)=Q(w)=-1$
, then
$Q(u)=Q(w)=-1$
, then 
 $h_{[z]}$
 is the morphism such that
$h_{[z]}$
 is the morphism such that 
 $h_{[z]}(i)=uw\in G(\mathbb {R})\subset C^{+}(V_{\mathbb {R}})^{\times }$
. Hence
$h_{[z]}(i)=uw\in G(\mathbb {R})\subset C^{+}(V_{\mathbb {R}})^{\times }$
. Hence 
 $D_L$
 is identified with a
$D_L$
 is identified with a 
 $G(\mathbb {R})$
-conjugacy class in
$G(\mathbb {R})$
-conjugacy class in 
 $\mathrm {Hom}(\mathrm {Res}_{\mathbb {C}/\mathbb {R}}\mathbb {G}_m,G_{\mathbb {R}})$
. The reflex field of
$\mathrm {Hom}(\mathrm {Res}_{\mathbb {C}/\mathbb {R}}\mathbb {G}_m,G_{\mathbb {R}})$
. The reflex field of 
 $(G,D_L)$
 is equal to
$(G,D_L)$
 is equal to 
 $\mathbb {Q}$
 by [Reference AndréAnd96, Appendix 1].
$\mathbb {Q}$
 by [Reference AndréAnd96, Appendix 1].
 Let 
 $\mathbb {K}\subset G(\mathbb {A}_{f})$
 be the compact open subgroup
$\mathbb {K}\subset G(\mathbb {A}_{f})$
 be the compact open subgroup 
 $$ \begin{align*}\mathbb{K}=\mathrm{G}(\mathbb{A}_f)\cap C(\widehat{L})^{\times},\end{align*} $$
$$ \begin{align*}\mathbb{K}=\mathrm{G}(\mathbb{A}_f)\cap C(\widehat{L})^{\times},\end{align*} $$
where 
 $\widehat {L}=L\otimes _{\mathbb {Z}} \widehat {\mathbb {Z}}$
. By [Reference PeraMP16, Lemma 2.6], the image of
$\widehat {L}=L\otimes _{\mathbb {Z}} \widehat {\mathbb {Z}}$
. By [Reference PeraMP16, Lemma 2.6], the image of 
 $\mathbb {K}$
 in
$\mathbb {K}$
 in 
 $\mathrm {SO}(\widehat {L})$
 is the subgroup of elements acting trivially on
$\mathrm {SO}(\widehat {L})$
 is the subgroup of elements acting trivially on 
 $L^{\vee }/L$
, where
$L^{\vee }/L$
, where 
 $L^{\vee }$
 is the dual lattice of L defined by
$L^{\vee }$
 is the dual lattice of L defined by 
 $$ \begin{align*}L^{\vee}:=\{x\in V\mid \forall y\in L,\, (x.y)\in \mathbb{Z}\}.\end{align*} $$
$$ \begin{align*}L^{\vee}:=\{x\in V\mid \forall y\in L,\, (x.y)\in \mathbb{Z}\}.\end{align*} $$
By the theory of canonical models, we get a b-dimensional Deligne–Mumford stack M over 
 $\mathbb {Q}$
, the GSpin Shimura variety associated with L, such that
$\mathbb {Q}$
, the GSpin Shimura variety associated with L, such that 
 $$ \begin{align*}M(\mathbb{C})=G(\mathbb{Q})\backslash D_L\times G(\mathbb{A}_f)/\mathbb{K}.\end{align*} $$
$$ \begin{align*}M(\mathbb{C})=G(\mathbb{Q})\backslash D_L\times G(\mathbb{A}_f)/\mathbb{K}.\end{align*} $$
2.2 The Kuga–Satake construction and K3 type motives in characteristic 
 $0$
$0$
The Kuga–Satake construction was first considered in [Reference Kuga and SatakeKS67] and later in [Reference DeligneDel72] and [Reference DeligneDel79]. We follow here the exposition of [Reference PeraMP16, Section 3].
 Let 
 $G\rightarrow \mathrm {Aut}(N)$
 be an algebraic representation of G on a
$G\rightarrow \mathrm {Aut}(N)$
 be an algebraic representation of G on a 
 $\mathbb {Q}$
-vector space N, and let
$\mathbb {Q}$
-vector space N, and let 
 $N_{\widehat {\mathbb {Z}}}\subset N_{\mathbb {A}_f}$
 be a
$N_{\widehat {\mathbb {Z}}}\subset N_{\mathbb {A}_f}$
 be a 
 $\mathbb {K}$
-stable lattice. Then one can construct a local system
$\mathbb {K}$
-stable lattice. Then one can construct a local system 
 $\mathbf {N}_{B}$
 on
$\mathbf {N}_{B}$
 on 
 $M(\mathbb {C})$
 whose fibre at a point
$M(\mathbb {C})$
 whose fibre at a point 
 $[[z],g]$
 is identified with
$[[z],g]$
 is identified with 
 $N\cap g(N_{\widehat {\mathbb {Z}}})$
. The corresponding vector bundle
$N\cap g(N_{\widehat {\mathbb {Z}}})$
. The corresponding vector bundle 
 $\mathbf {N}_{dR,M(\mathbb {C})}=\mathcal {O}_{M(\mathbb {C})}\otimes \mathbf {N}_{B}$
 is equipped with a holomorphic filtration
$\mathbf {N}_{dR,M(\mathbb {C})}=\mathcal {O}_{M(\mathbb {C})}\otimes \mathbf {N}_{B}$
 is equipped with a holomorphic filtration 
 $\mathcal {F}^{\bullet }\mathbf {N}_{dR,M(\mathbb {C})}$
, which at every point
$\mathcal {F}^{\bullet }\mathbf {N}_{dR,M(\mathbb {C})}$
, which at every point 
 $[[z],g]$
 equips the fibre with the Hodge structure determined by the cocharacter
$[[z],g]$
 equips the fibre with the Hodge structure determined by the cocharacter 
 $h_{[z]}$
. Hence we obtain a functor
$h_{[z]}$
. Hence we obtain a functor 
 $$ \begin{align} (N,N_{\widehat{\mathbb{Z}}})\mapsto \left(\mathbf{N}_{B},\mathcal{F}^{\bullet}\mathbf{N}_{dR,M(\mathbb{C}))}\right) \end{align} $$
$$ \begin{align} (N,N_{\widehat{\mathbb{Z}}})\mapsto \left(\mathbf{N}_{B},\mathcal{F}^{\bullet}\mathbf{N}_{dR,M(\mathbb{C}))}\right) \end{align} $$
from the category of algebraic 
 $\mathbb {Q}$
-representations of G with a
$\mathbb {Q}$
-representations of G with a 
 $\mathbb {K}$
-stable lattice to variations of
$\mathbb {K}$
-stable lattice to variations of 
 $\mathbb {Z}$
-Hodge structures over
$\mathbb {Z}$
-Hodge structures over 
 $M(\mathbb {C})$
. Applying this functor to
$M(\mathbb {C})$
. Applying this functor to 
 $(V,\widehat {L})$
, we obtain a variation of
$(V,\widehat {L})$
, we obtain a variation of 
 $\mathbb {Z}$
-Hodge structures
$\mathbb {Z}$
-Hodge structures 
 $\{\mathbf {V}_{B},\mathcal {F}^{\bullet }\mathbf {V}_{dR,M(\mathbb {C})}\}$
 of weight
$\{\mathbf {V}_{B},\mathcal {F}^{\bullet }\mathbf {V}_{dR,M(\mathbb {C})}\}$
 of weight 
 $0$
 over
$0$
 over 
 $M(\mathbb {C})$
. The quadratic form Q gives a polarisation on
$M(\mathbb {C})$
. The quadratic form Q gives a polarisation on 
 $(\mathbf {V}_{B},\mathcal {F}^{\bullet }\mathbf {V}_{dR,M(\mathbb {C})})$
 and hence by [Reference DeligneDel79, 1.1.15], all
$(\mathbf {V}_{B},\mathcal {F}^{\bullet }\mathbf {V}_{dR,M(\mathbb {C})})$
 and hence by [Reference DeligneDel79, 1.1.15], all 
 $(\mathbf {N}_{B},\mathcal {F}^{\bullet }\mathbf {N}_{dR,M(\mathbb {C}))})$
 are polarisable.
$(\mathbf {N}_{B},\mathcal {F}^{\bullet }\mathbf {N}_{dR,M(\mathbb {C}))})$
 are polarisable.
 Also, if we denote by H the representation of the group G on 
 $C(V)$
 by left multiplication and
$C(V)$
 by left multiplication and 
 $H_{\widehat {\mathbb {Z}}}=C(L)_{\widehat {\mathbb {Z}}}$
, then applying the functor (2.1) to the pair
$H_{\widehat {\mathbb {Z}}}=C(L)_{\widehat {\mathbb {Z}}}$
, then applying the functor (2.1) to the pair 
 $(H,H_{\widehat {\mathbb {Z}}})$
, we obtain a polarisable variation of
$(H,H_{\widehat {\mathbb {Z}}})$
, we obtain a polarisable variation of 
 $\mathbb {Z}$
-Hodge structures
$\mathbb {Z}$
-Hodge structures 
 $(\mathbf {H}_{B},\mathbf {H}_{dR,M(\mathbb {C})})$
 of type
$(\mathbf {H}_{B},\mathbf {H}_{dR,M(\mathbb {C})})$
 of type 
 $(-1,0),(0,-1)$
 with a right
$(-1,0),(0,-1)$
 with a right 
 $C(V)$
-action. Therefore, there is a family of abelian schemes
$C(V)$
-action. Therefore, there is a family of abelian schemes 
 $A^{\mathrm {univ}}\rightarrow M$
 of relative dimension
$A^{\mathrm {univ}}\rightarrow M$
 of relative dimension 
 $2^{b+1}$
, the Kuga–Satake abelian scheme, such that the homology of the family
$2^{b+1}$
, the Kuga–Satake abelian scheme, such that the homology of the family 
 $A^{\mathrm {univ},an}(\mathbb {C})\rightarrow M^{an}(\mathbb {C})$
 is precisely
$A^{\mathrm {univ},an}(\mathbb {C})\rightarrow M^{an}(\mathbb {C})$
 is precisely 
 $(\mathbf {H}_{B},\mathbf {H}_{dR,M(\mathbb {C})})$
. It is equipped with a right
$(\mathbf {H}_{B},\mathbf {H}_{dR,M(\mathbb {C})})$
. It is equipped with a right 
 $C(L)$
-action and a compatible
$C(L)$
-action and a compatible 
 $\mathbb {Z}/2\mathbb {Z}$
-grading:
$\mathbb {Z}/2\mathbb {Z}$
-grading: 
 $A^{\mathrm {univ}}=A^{\mathrm {univ},+}\times A^{\mathrm {univ},-}$
; see [Reference PeraMP16, 3.5–3,7, 3.10].Footnote 6
$A^{\mathrm {univ}}=A^{\mathrm {univ},+}\times A^{\mathrm {univ},-}$
; see [Reference PeraMP16, 3.5–3,7, 3.10].Footnote 6
 Using 
 $A^{\mathrm {univ}}$
, one descends
$A^{\mathrm {univ}}$
, one descends 
 $\mathbf {H}_{dR,M(\mathbb {C})}$
 to a filtered vector bundle with an integrable connection
$\mathbf {H}_{dR,M(\mathbb {C})}$
 to a filtered vector bundle with an integrable connection 
 $(\mathbf {H}_{dR},\mathcal {F}^{\bullet }\mathbf {H}_{dR})$
 over M as the first relative de Rham homology with the Gauss–Manin connection ([Reference PeraMP16, 3.10]). For any prime
$(\mathbf {H}_{dR},\mathcal {F}^{\bullet }\mathbf {H}_{dR})$
 over M as the first relative de Rham homology with the Gauss–Manin connection ([Reference PeraMP16, 3.10]). For any prime 
 $\ell $
, the
$\ell $
, the 
 $\ell $
-adic sheaf
$\ell $
-adic sheaf 
 $\mathbb {Z}_\ell \otimes \mathbf {H}_B$
 over
$\mathbb {Z}_\ell \otimes \mathbf {H}_B$
 over 
 $M(\mathbb {C})$
 descends also canonically to an
$M(\mathbb {C})$
 descends also canonically to an 
 $\ell $
-adic étale sheaf
$\ell $
-adic étale sheaf 
 $\mathbf {H}_{\ell ,\mathrm {\acute{e}t}}$
 over M, which is canonically isomorphic to the
$\mathbf {H}_{\ell ,\mathrm {\acute{e}t}}$
 over M, which is canonically isomorphic to the 
 $\ell $
-adic Tate module of
$\ell $
-adic Tate module of 
 $A^{\mathrm {univ}}$
 ([Reference PeraMP16, 3.13]). Moreover, by Deligne’s theory of absolute Hodge cycles, one descends
$A^{\mathrm {univ}}$
 ([Reference PeraMP16, 3.13]). Moreover, by Deligne’s theory of absolute Hodge cycles, one descends 
 $\mathbf {V}_{dR,M(\mathbb {C})}$
 and
$\mathbf {V}_{dR,M(\mathbb {C})}$
 and 
 $\mathbb {Z}_\ell \otimes \mathbf {V}_B$
 to
$\mathbb {Z}_\ell \otimes \mathbf {V}_B$
 to 
 $(\mathbf {V}_{dR},\mathcal {F}^{\bullet }\mathbf {V}_{dR})$
 and
$(\mathbf {V}_{dR},\mathcal {F}^{\bullet }\mathbf {V}_{dR})$
 and 
 $\mathbf {V}_{\ell ,\mathrm{\acute{e}t}}$
 over M ([Reference PeraMP16, 3.4, 3.10–3.12]). More precisely, an idempotent
$\mathbf {V}_{\ell ,\mathrm{\acute{e}t}}$
 over M ([Reference PeraMP16, 3.4, 3.10–3.12]). More precisely, an idempotent 
 $$ \begin{align*}\pi=(\pi_{B,\mathbb{Q}}, \pi_{dR, \mathbb{Q}}, \pi_{\ell,\mathbb{Q}})\in \operatorname{\mathrm{End}}(\operatorname{\mathrm{End}}(\mathbf{H}_{B}\otimes \mathbb{Q}))\times \operatorname{\mathrm{End}}(\operatorname{\mathrm{End}}(\mathbf{H}_{dR})) \times \operatorname{\mathrm{End}}(\operatorname{\mathrm{End}}(\mathbf{H}_{\ell, \acute{\mathrm{e}}\mathrm{t}}\otimes \mathbb{Q}_\ell))\end{align*} $$
$$ \begin{align*}\pi=(\pi_{B,\mathbb{Q}}, \pi_{dR, \mathbb{Q}}, \pi_{\ell,\mathbb{Q}})\in \operatorname{\mathrm{End}}(\operatorname{\mathrm{End}}(\mathbf{H}_{B}\otimes \mathbb{Q}))\times \operatorname{\mathrm{End}}(\operatorname{\mathrm{End}}(\mathbf{H}_{dR})) \times \operatorname{\mathrm{End}}(\operatorname{\mathrm{End}}(\mathbf{H}_{\ell, \acute{\mathrm{e}}\mathrm{t}}\otimes \mathbb{Q}_\ell))\end{align*} $$
is constructed in ([Reference PeraMP16, 3.4, 3.10–3.12]) such that the fibre of 
 $\pi $
 at each closed point in M is an absolute Hodge cycle and
$\pi $
 at each closed point in M is an absolute Hodge cycle and 
 $(\mathbf {V}_{B}\otimes \mathbb {Q}, \mathbf {V}_{dR}, \mathbf {V}_{\ell , \mathrm{\acute{e}t}}\otimes \mathbb {Q}_\ell )$
 is the image of
$(\mathbf {V}_{B}\otimes \mathbb {Q}, \mathbf {V}_{dR}, \mathbf {V}_{\ell , \mathrm{\acute{e}t}}\otimes \mathbb {Q}_\ell )$
 is the image of 
 $\pi $
. In particular,
$\pi $
. In particular, 
 $(\mathbf {V}_{B}\otimes \mathbb {Q}, \mathbf {V}_{dR}, \mathbf {V}_{\ell , \mathrm{\acute{e}t}}\otimes \mathbb {Q}_\ell )$
 is a family of absolute Hodge motives over M, and we call each fibre a K3 type motive. (For a reference on absolute Hodge motives, we refer to [Reference Deligne, Milne, Ogus and ShihDMOS82, IV].)
$(\mathbf {V}_{B}\otimes \mathbb {Q}, \mathbf {V}_{dR}, \mathbf {V}_{\ell , \mathrm{\acute{e}t}}\otimes \mathbb {Q}_\ell )$
 is a family of absolute Hodge motives over M, and we call each fibre a K3 type motive. (For a reference on absolute Hodge motives, we refer to [Reference Deligne, Milne, Ogus and ShihDMOS82, IV].)
 On the other hand, let 
 $\operatorname {\mathrm {End}}_{C(V)}(H)$
 denote the endomorphism ring of H as a
$\operatorname {\mathrm {End}}_{C(V)}(H)$
 denote the endomorphism ring of H as a 
 $C(V)$
-module with right
$C(V)$
-module with right 
 $C(V)$
-action. Then the action of V on H as left multiplication induces a G-equivariant embedding
$C(V)$
-action. Then the action of V on H as left multiplication induces a G-equivariant embedding 
 $V\hookrightarrow \mathrm {End}_{C(V)}(H)$
, which maps
$V\hookrightarrow \mathrm {End}_{C(V)}(H)$
, which maps 
 $\widehat {L}\hookrightarrow H_{\widehat {\mathbb {Z}}}$
. The functoriality of (2.1) induces embeddings
$\widehat {L}\hookrightarrow H_{\widehat {\mathbb {Z}}}$
. The functoriality of (2.1) induces embeddings 
 $$ \begin{align*} \mathbf{V}_{B}\hookrightarrow \mathrm{End}_{C(L)}(\mathbf{H}_{B})\quad\textrm{and}\quad \mathbf{V}_{dR,M(\mathbb{C})}\hookrightarrow \mathrm{End}_{C(V)}(\mathbf{H}_{dR,M(\mathbb{C})}), \end{align*} $$
$$ \begin{align*} \mathbf{V}_{B}\hookrightarrow \mathrm{End}_{C(L)}(\mathbf{H}_{B})\quad\textrm{and}\quad \mathbf{V}_{dR,M(\mathbb{C})}\hookrightarrow \mathrm{End}_{C(V)}(\mathbf{H}_{dR,M(\mathbb{C})}), \end{align*} $$
the latter being compatible with filtration. By [Reference PeraMP16, 1.2, 1.4, 3.11], these embeddings are the same as the one induced by 
 $\pi $
 above with the natural forgetful map
$\pi $
 above with the natural forgetful map 
 $\operatorname {\mathrm {End}}_{C(V)}(\mathbf {H})\rightarrow \operatorname {\mathrm {End}}(\mathbf {H})$
. In particular, the embedding
$\operatorname {\mathrm {End}}_{C(V)}(\mathbf {H})\rightarrow \operatorname {\mathrm {End}}(\mathbf {H})$
. In particular, the embedding 
 $\mathbf {V}_{dR}\hookrightarrow \operatorname {\mathrm {End}}_{C(V)}(\mathbf {H}_{dR})$
 is compatible with filtrations and connection and
$\mathbf {V}_{dR}\hookrightarrow \operatorname {\mathrm {End}}_{C(V)}(\mathbf {H}_{dR})$
 is compatible with filtrations and connection and 
 $V_{\ell , \mathrm{\acute{e}t}}\hookrightarrow \operatorname {\mathrm {End}}_{C(V)}(\mathbf {H}_{\ell , \mathrm{\acute{e}t}})$
 as
$V_{\ell , \mathrm{\acute{e}t}}\hookrightarrow \operatorname {\mathrm {End}}_{C(V)}(\mathbf {H}_{\ell , \mathrm{\acute{e}t}})$
 as 
 $\mathbb {Z}_\ell $
-lisse sheaves with compatible Galois action on each fibre.Footnote 7
$\mathbb {Z}_\ell $
-lisse sheaves with compatible Galois action on each fibre.Footnote 7
 Moreover, there is a canonical quadratic form 
 $\mathbf {Q}:\mathbf {V}_{dR}\rightarrow \mathcal {O}_M$
 given on sections by
$\mathbf {Q}:\mathbf {V}_{dR}\rightarrow \mathcal {O}_M$
 given on sections by 
 $v\circ v=\mathbf {Q}(v)\cdot \mathrm {Id}$
, where the composition takes places in
$v\circ v=\mathbf {Q}(v)\cdot \mathrm {Id}$
, where the composition takes places in 
 $\mathrm {End}_{C(V)}(\mathbf {H}_{dR})$
. Similarly, there is also a canonical quadratic form on
$\mathrm {End}_{C(V)}(\mathbf {H}_{dR})$
. Similarly, there is also a canonical quadratic form on 
 $\mathbf {V}_{\ell ,\mathrm{\acute{e}t}}$
 induced by composition in
$\mathbf {V}_{\ell ,\mathrm{\acute{e}t}}$
 induced by composition in 
 $\operatorname {\mathrm {End}}_{C(V)}(\mathbf {H}_{\ell , \mathrm{\acute{e}t}})$
 and valued in the constant sheaf
$\operatorname {\mathrm {End}}_{C(V)}(\mathbf {H}_{\ell , \mathrm{\acute{e}t}})$
 and valued in the constant sheaf 
 $\underline {\mathbb {Z}_\ell }$
.
$\underline {\mathbb {Z}_\ell }$
.
2.3 Special divisors on M over 
 $\mathbb {Q}$
$\mathbb {Q}$
 For any vector 
 $\lambda \in L_{\mathbb {R}}$
 such that
$\lambda \in L_{\mathbb {R}}$
 such that 
 $Q(\lambda )>0$
, let
$Q(\lambda )>0$
, let 
 $\lambda ^{\bot }$
 be the set of elements of
$\lambda ^{\bot }$
 be the set of elements of 
 $D_{L}$
 orthogonal to
$D_{L}$
 orthogonal to 
 $\lambda $
. Let
$\lambda $
. Let 
 $\beta \in L^{\vee }/L$
 and
$\beta \in L^{\vee }/L$
 and 
 $m\in Q(\beta )+\mathbb {Z}$
 with
$m\in Q(\beta )+\mathbb {Z}$
 with 
 $m>0$
 and define the complex orbifold
$m>0$
 and define the complex orbifold 
 $$ \begin{align*} Z(\beta,m)(\mathbb{C}):=\bigsqcup_{g\in G(\mathbb{Q})\backslash G(\mathbb{A}_f)/\mathbb{K}}\Gamma_{g}\backslash\left(\bigsqcup_{\lambda\in \beta_g+L_g,\, Q(\lambda)=m}\lambda^{\bot}\right) \end{align*} $$
$$ \begin{align*} Z(\beta,m)(\mathbb{C}):=\bigsqcup_{g\in G(\mathbb{Q})\backslash G(\mathbb{A}_f)/\mathbb{K}}\Gamma_{g}\backslash\left(\bigsqcup_{\lambda\in \beta_g+L_g,\, Q(\lambda)=m}\lambda^{\bot}\right) \end{align*} $$
where 
 $\Gamma _g=G(\mathbb {Q})\cap g\mathbb {K} g^{-1}$
,
$\Gamma _g=G(\mathbb {Q})\cap g\mathbb {K} g^{-1}$
, 
 $L_g\subset V$
 is the lattice determined by
$L_g\subset V$
 is the lattice determined by 
 $\widehat {L_{g}}=g\bullet \widehat {L}$
 and
$\widehat {L_{g}}=g\bullet \widehat {L}$
 and 
 $\beta _g=g\bullet \beta \in L_{g}^{\vee }/L_g$
. Then
$\beta _g=g\bullet \beta \in L_{g}^{\vee }/L_g$
. Then 
 $Z(\beta ,m)(\mathbb {C})$
 is the set of complex points of a disjoint union of Shimura varieties associated with orthogonal lattices of signature
$Z(\beta ,m)(\mathbb {C})$
 is the set of complex points of a disjoint union of Shimura varieties associated with orthogonal lattices of signature 
 $(b-1,2)$
 and it admits a canonical model
$(b-1,2)$
 and it admits a canonical model 
 $Z(\beta ,m)$
 over
$Z(\beta ,m)$
 over 
 $\mathbb {Q}$
 for
$\mathbb {Q}$
 for 
 $b\geq 2$
.Footnote 8 The natural map
$b\geq 2$
.Footnote 8 The natural map 
 $Z(\beta ,m)(\mathbb {C})\rightarrow M(\mathbb {C})$
 descends to a finite unramified morphism
$Z(\beta ,m)(\mathbb {C})\rightarrow M(\mathbb {C})$
 descends to a finite unramified morphism 
 $Z(\beta ,m)\rightarrow M$
. Étally locally on
$Z(\beta ,m)\rightarrow M$
. Étally locally on 
 $Z(\beta ,m)$
, this map is a closed immersion defined by a single equation, and hence its scheme theoretic image gives an effective Cartier divisor on M, which we will also denote by
$Z(\beta ,m)$
, this map is a closed immersion defined by a single equation, and hence its scheme theoretic image gives an effective Cartier divisor on M, which we will also denote by 
 $Z(\beta ,m)$
.Footnote 9
$Z(\beta ,m)$
.Footnote 9
2.4 Integral models
 We recall the construction of an integral model of M from [Reference Andreatta, Goren, Howard and PeraAGHMP18, 4.4]; see also [Reference Howard and Madapusi PeraHM17, 6.3] and the original work of Kisin [Reference KisinKis10] and Madapusi Pera [Reference PeraMP16]. Let p be a prime number. We say that L is almost self-dual at p if either L is self-dual at p or 
 $p=2$
,
$p=2$
, 
 $\dim _{\mathbb {Q}}(V)$
 is odd and
$\dim _{\mathbb {Q}}(V)$
 is odd and 
 $|L^{\vee }/L|$
 is not divisible by
$|L^{\vee }/L|$
 is not divisible by 
 $4$
. The following proposition is parts of [Reference Andreatta, Goren, Howard and PeraAGHMP18, Proposition 4.4.1, Theorem 4.4.6] and [Reference Howard and Madapusi PeraHM17, Remark 6.3.1].
$4$
. The following proposition is parts of [Reference Andreatta, Goren, Howard and PeraAGHMP18, Proposition 4.4.1, Theorem 4.4.6] and [Reference Howard and Madapusi PeraHM17, Remark 6.3.1].
Proposition 2.1. There exists a flat, normal Deligne–Mumford 
 $\mathbb {Z}$
-stack
$\mathbb {Z}$
-stack 
 $\mathcal {M}$
 with the following properties.
$\mathcal {M}$
 with the following properties. 
- 
1.  $\mathcal {M}_{\mathbb {Z}_{(p)}}$
 is smooth over $\mathcal {M}_{\mathbb {Z}_{(p)}}$
 is smooth over $\mathbb {Z}_{(p)}$
 if L is almost self-dual at p; $\mathbb {Z}_{(p)}$
 if L is almost self-dual at p;
- 
2. the Kuga–Satake abelian scheme  $A^{\mathrm {univ}}\rightarrow M$
 extends to an abelian scheme $A^{\mathrm {univ}}\rightarrow M$
 extends to an abelian scheme $\mathcal {A}^{\mathrm {univ}}\rightarrow \mathcal {M}$
 and the $\mathcal {A}^{\mathrm {univ}}\rightarrow \mathcal {M}$
 and the $C(L)$
-action on $C(L)$
-action on $A^{\mathrm {univ}}$
 also extends to a $A^{\mathrm {univ}}$
 also extends to a $C(L)$
-action on $C(L)$
-action on $\mathcal {A}^{\mathrm {univ}}$
; $\mathcal {A}^{\mathrm {univ}}$
;
- 
3. the line bundle  $\mathcal {F}^{1}V_{dR}$
 extends canonically to a line bundle $\mathcal {F}^{1}V_{dR}$
 extends canonically to a line bundle $\boldsymbol {\omega }$
 over $\boldsymbol {\omega }$
 over $\mathcal {M}$
. $\mathcal {M}$
.
- 
4. the extension property: for  $E/\mathbb {Q}_p$
 finite, $E/\mathbb {Q}_p$
 finite, $t\in M(E)$
 such that $t\in M(E)$
 such that $A^{\mathrm {univ}}_t$
 has potentially good reduction over $A^{\mathrm {univ}}_t$
 has potentially good reduction over $\mathcal {O}_E$
, then t extends to a map $\mathcal {O}_E$
, then t extends to a map $\operatorname {\mathrm {Spec}}(\mathcal {O}_E)\rightarrow \mathcal {M}$
. $\operatorname {\mathrm {Spec}}(\mathcal {O}_E)\rightarrow \mathcal {M}$
.
 For p such that L is self-dual at p, we now discuss the extensions of 
 $\mathbf {V}_{dR}, \mathbf {V}_{\ell ,\mathrm{\acute{e}t}}, \ell \neq p$
 over
$\mathbf {V}_{dR}, \mathbf {V}_{\ell ,\mathrm{\acute{e}t}}, \ell \neq p$
 over 
 $\mathcal {M}_{\mathbb {Z}_{(p)}}$
 and recall the construction of
$\mathcal {M}_{\mathbb {Z}_{(p)}}$
 and recall the construction of 
 $\mathbf {V}_{cris}$
. For ease of reading, we will denote the extensions by the same notation. We will use these notions to provide an ad hoc definition of the reduction of the K3 type motives defined in Section 2.2.
$\mathbf {V}_{cris}$
. For ease of reading, we will denote the extensions by the same notation. We will use these notions to provide an ad hoc definition of the reduction of the K3 type motives defined in Section 2.2.
 By (2) in Proposition 2.1, there are natural extensions of 
 $\mathbf {H}_{dR}, \mathbf {H}_{\ell , \mathrm{\acute{e}t}}$
 as the first relative de Rham homology and the
$\mathbf {H}_{dR}, \mathbf {H}_{\ell , \mathrm{\acute{e}t}}$
 as the first relative de Rham homology and the 
 $\mathbb {Z}_\ell $
-Tate module of
$\mathbb {Z}_\ell $
-Tate module of 
 $\mathcal {A}^{\mathrm {univ}}$
, and we define
$\mathcal {A}^{\mathrm {univ}}$
, and we define 
 $\mathbf {H}_{cris}$
 to be the first relative crystalline homology
$\mathbf {H}_{cris}$
 to be the first relative crystalline homology 
 $$ \begin{align*}\mathrm{Hom}\left(R^{1}\pi_{cris,*}\mathcal{O}^{cris}_{\mathcal{A}_{\mathbb{F}_p}/\mathbb{Z}_p},\mathcal{O}^{cris}_{\mathcal{M}_{\mathbb{F}_{p}/\mathbb{Z}_p}}\right).\end{align*} $$
$$ \begin{align*}\mathrm{Hom}\left(R^{1}\pi_{cris,*}\mathcal{O}^{cris}_{\mathcal{A}_{\mathbb{F}_p}/\mathbb{Z}_p},\mathcal{O}^{cris}_{\mathcal{M}_{\mathbb{F}_{p}/\mathbb{Z}_p}}\right).\end{align*} $$
 By [Reference Andreatta, Goren, Howard and PeraAGHMP18, Remark 4.2.3], there exists a canonical extension of 
 $\mathbf {V}_{\ell , \mathrm{\acute{e}t}}\hookrightarrow \operatorname {\mathrm {End}}_{C(L)}(\mathbf {H}_{\ell , \mathrm{\acute{e}t}})$
 over
$\mathbf {V}_{\ell , \mathrm{\acute{e}t}}\hookrightarrow \operatorname {\mathrm {End}}_{C(L)}(\mathbf {H}_{\ell , \mathrm{\acute{e}t}})$
 over 
 $\mathcal {M}_{\mathbb {Z}_{(p)}}$
. Note that
$\mathcal {M}_{\mathbb {Z}_{(p)}}$
. Note that 
 $L_{\mathbb {Z}_{(p)}}$
 is a
$L_{\mathbb {Z}_{(p)}}$
 is a 
 $\mathbb {Z}_{(p)}$
-representation of
$\mathbb {Z}_{(p)}$
-representation of 
 $\mathrm {GSpin}(L_{\mathbb {Z}_{(p)}},Q)$
, then by [Reference Andreatta, Goren, Howard and PeraAGHMP18, Propositions 4.2.4, 4.2.5], there is a vector bundle with integrable connection
$\mathrm {GSpin}(L_{\mathbb {Z}_{(p)}},Q)$
, then by [Reference Andreatta, Goren, Howard and PeraAGHMP18, Propositions 4.2.4, 4.2.5], there is a vector bundle with integrable connection 
 $\mathbf {V}_{dR}$
 over
$\mathbf {V}_{dR}$
 over 
 $\mathcal {M}_{\mathbb {Z}_{(p)}}$
 and a canonical embedding into
$\mathcal {M}_{\mathbb {Z}_{(p)}}$
 and a canonical embedding into 
 $\operatorname {\mathrm {End}}_{C(L)}(\mathbf {H}_{dR})$
 extending their counterparts over M; moreover, there is an F-crystal
$\operatorname {\mathrm {End}}_{C(L)}(\mathbf {H}_{dR})$
 extending their counterparts over M; moreover, there is an F-crystal 
 $\mathbf {V}_{cris}$
 with a canonical embedding into
$\mathbf {V}_{cris}$
 with a canonical embedding into 
 $\mathrm {End}_{C(L)}(\mathbf {H}_{cris})$
. Both embeddings realise
$\mathrm {End}_{C(L)}(\mathbf {H}_{cris})$
. Both embeddings realise 
 $\mathbf {V}_{dR}$
 and
$\mathbf {V}_{dR}$
 and 
 $\mathbf {V}_{cris}$
 as local direct summands of
$\mathbf {V}_{cris}$
 as local direct summands of 
 $\operatorname {\mathrm {End}}_{C(L)}(\mathbf {H}_{dR})$
 and
$\operatorname {\mathrm {End}}_{C(L)}(\mathbf {H}_{dR})$
 and 
 $\mathrm {End}_{C(L)}(\mathbf {H}_{cris})$
 and these two embeddings are compatible with the canonical crystalline-de Rham comparison.
$\mathrm {End}_{C(L)}(\mathbf {H}_{cris})$
 and these two embeddings are compatible with the canonical crystalline-de Rham comparison.
 For a point 
 $x\in \mathcal {M}(\mathbb {F}_q)$
, where q is a power of p, we consider the fibre of
$x\in \mathcal {M}(\mathbb {F}_q)$
, where q is a power of p, we consider the fibre of 
 $(\mathbf {V}_{\ell , \mathrm{\acute{e}t}}, \mathbf {V}_{dR},\mathbf {V}_{cris})$
 at x of the ad hoc motive attached to x, where q-Frobenius
$(\mathbf {V}_{\ell , \mathrm{\acute{e}t}}, \mathbf {V}_{dR},\mathbf {V}_{cris})$
 at x of the ad hoc motive attached to x, where q-Frobenius 
 $\operatorname {\mathrm {Frob}}_x$
 acts on
$\operatorname {\mathrm {Frob}}_x$
 acts on 
 $\mathbf {V}_{\ell , \mathrm{\acute{e}t},x}$
 and semi-linear crystalline Frobenius
$\mathbf {V}_{\ell , \mathrm{\acute{e}t},x}$
 and semi-linear crystalline Frobenius 
 $\varphi _x$
 acts on
$\varphi _x$
 acts on 
 $\mathbf {V}_{cris,x}$
. Although these realisations are not as closely related as the analogous characteristic
$\mathbf {V}_{cris,x}$
. Although these realisations are not as closely related as the analogous characteristic 
 $0$
 situation, there is a good notion of algebraic cycles in
$0$
 situation, there is a good notion of algebraic cycles in 
 $(\mathbf {V}_{\ell , \mathrm{\acute{e}t}}, \mathbf {V}_{dR},\mathbf {V}_{cris})$
, namely the special endomorphisms of the Kuga–Satake abelian varieties discussed in the following subsection.
$(\mathbf {V}_{\ell , \mathrm{\acute{e}t}}, \mathbf {V}_{dR},\mathbf {V}_{cris})$
, namely the special endomorphisms of the Kuga–Satake abelian varieties discussed in the following subsection.
2.5 Special endomorphisms and integral models of special divisors
 We recall the definition of special endomorphisms from [Reference Andreatta, Goren, Howard and PeraAGHMP18, §§4.3,4.5]. For an 
 $\mathcal {M}$
-scheme S, we use
$\mathcal {M}$
-scheme S, we use 
 $A_S$
 to denote
$A_S$
 to denote 
 $\mathcal {A}^{\mathrm {univ}}_S$
, the pull-back of the universal Kuga–Satake abelian scheme to S.
$\mathcal {A}^{\mathrm {univ}}_S$
, the pull-back of the universal Kuga–Satake abelian scheme to S.
Definition 2.2. An endomorphism 
 $v\in \operatorname {\mathrm {End}}_{C(L)}(A_S)$
 is special if
$v\in \operatorname {\mathrm {End}}_{C(L)}(A_S)$
 is special if 
- 
1. for prime p such that L is self-dual at p, all homological realisations of v lie in the image of  $\mathbf {V}_{?}\hookrightarrow \operatorname {\mathrm {End}}_{C(L)}(\mathbf {H}_{?})$
 given in Sections 2.2,2.4;Footnote 10 and $\mathbf {V}_{?}\hookrightarrow \operatorname {\mathrm {End}}_{C(L)}(\mathbf {H}_{?})$
 given in Sections 2.2,2.4;Footnote 10 and
- 
2. for p such that L is not self-dual, after choosing an auxiliary maximal lattice  $L^\diamond $
 of signature $L^\diamond $
 of signature $(b^\diamond , 2)$
, which is self-dual at p and admits an isometric embedding $(b^\diamond , 2)$
, which is self-dual at p and admits an isometric embedding $L\hookrightarrow L^\diamond $
, the image of v under the canonical embedding $L\hookrightarrow L^\diamond $
, the image of v under the canonical embedding $\operatorname {\mathrm {End}}_{C(L)}(A_S)\hookrightarrow \operatorname {\mathrm {End}}_{C(L^\diamond )}(A^\diamond _S)$
 has all its homological realisations lying in the image of $\operatorname {\mathrm {End}}_{C(L)}(A_S)\hookrightarrow \operatorname {\mathrm {End}}_{C(L^\diamond )}(A^\diamond _S)$
 has all its homological realisations lying in the image of $\mathbf {V}_{?}^\diamond \hookrightarrow \operatorname {\mathrm {End}}_{C(L^\diamond )}(\mathbf {H}_{?}^\diamond )$
.Footnote 11 $\mathbf {V}_{?}^\diamond \hookrightarrow \operatorname {\mathrm {End}}_{C(L^\diamond )}(\mathbf {H}_{?}^\diamond )$
.Footnote 11
We use 
 $V(A_S)$
 to denote the
$V(A_S)$
 to denote the 
 $\mathbb {Z}$
-module of special endomorphisms of
$\mathbb {Z}$
-module of special endomorphisms of 
 $A_S$
.
$A_S$
.
 By [Reference Andreatta, Goren, Howard and PeraAGHMP18, Prop.4.5.4], there is a positive definite quadratic form 
 $Q:V(A_S)\rightarrow \mathbb {Z}$
 such that for each
$Q:V(A_S)\rightarrow \mathbb {Z}$
 such that for each 
 $v\in V(A_S)$
, we have
$v\in V(A_S)$
, we have 
 $v\circ v=Q(v)\cdot \mathrm {Id}_{A_S}$
.Footnote 12
$v\circ v=Q(v)\cdot \mathrm {Id}_{A_S}$
.Footnote 12
Definition 2.3. When S is a 
 $\mathcal {M}_{\mathbb {Z}_{(p)}}$
-scheme, v is a special endomorphism of the p-divisible group
$\mathcal {M}_{\mathbb {Z}_{(p)}}$
-scheme, v is a special endomorphism of the p-divisible group 
 $A_S[p^\infty ]$
 if
$A_S[p^\infty ]$
 if 
 $v\in \operatorname {\mathrm {End}}_{C(L)}(A_S[p^\infty ])$
 and the crystalline realisation of x (respectively, image of x under the canonical embedding
$v\in \operatorname {\mathrm {End}}_{C(L)}(A_S[p^\infty ])$
 and the crystalline realisation of x (respectively, image of x under the canonical embedding 
 $\operatorname {\mathrm {End}}_{C(L)}(A_S[p^\infty ])\hookrightarrow \operatorname {\mathrm {End}}_{C(L^\diamond )}(A^\diamond _S[p^\infty ])$
) lies in
$\operatorname {\mathrm {End}}_{C(L)}(A_S[p^\infty ])\hookrightarrow \operatorname {\mathrm {End}}_{C(L^\diamond )}(A^\diamond _S[p^\infty ])$
) lies in 
 $\mathbf {V}_{cris}$
 (respectively,
$\mathbf {V}_{cris}$
 (respectively, 
 $\mathbf {V}^\diamond _{cris}$
) if L is self-dual at p (respectively, otherwise).Footnote 13
$\mathbf {V}^\diamond _{cris}$
) if L is self-dual at p (respectively, otherwise).Footnote 13
 For an odd prime p such that L is self-dual at p, for a point 
 $x\in \mathcal {M}(\mathbb {F}_{p^r})$
 by [Reference PeraMP15, Theorem 6.4],Footnote 14, we have isometries
$x\in \mathcal {M}(\mathbb {F}_{p^r})$
 by [Reference PeraMP15, Theorem 6.4],Footnote 14, we have isometries 
 $$\begin{align*}V(\mathcal{A}^{\mathrm{univ}}_x)\otimes \mathbb{Q}_\ell \cong \lim_{n\rightarrow\infty}\mathbf{V}_{\ell,\acute{\mathrm{e}}\mathrm{t},x}^{\operatorname{\mathrm{Frob}}_x^n=1},\ell\neq p, \quad V(\mathcal{A}^{\mathrm{univ}}_x)\otimes \mathbb{Q}_p \cong \lim_{n\rightarrow\infty}(\mathbb{Q}_{p^{rn}}\otimes\mathbf{V}_{cris,x})^{\varphi_x=1}.\end{align*}$$
$$\begin{align*}V(\mathcal{A}^{\mathrm{univ}}_x)\otimes \mathbb{Q}_\ell \cong \lim_{n\rightarrow\infty}\mathbf{V}_{\ell,\acute{\mathrm{e}}\mathrm{t},x}^{\operatorname{\mathrm{Frob}}_x^n=1},\ell\neq p, \quad V(\mathcal{A}^{\mathrm{univ}}_x)\otimes \mathbb{Q}_p \cong \lim_{n\rightarrow\infty}(\mathbb{Q}_{p^{rn}}\otimes\mathbf{V}_{cris,x})^{\varphi_x=1}.\end{align*}$$
Therefore, we view special endomorphisms of 
 $\mathcal {A}^{\mathrm {univ}}_x$
 as the algebraic cycles of the ad hoc motive
$\mathcal {A}^{\mathrm {univ}}_x$
 as the algebraic cycles of the ad hoc motive 
 $(\mathbf {V}_{\ell , \mathrm{\acute{e}t},x}, \mathbf {V}_{dR,x},\mathbf {V}_{cris,x})$
.
$(\mathbf {V}_{\ell , \mathrm{\acute{e}t},x}, \mathbf {V}_{dR,x},\mathbf {V}_{cris,x})$
.
 For 
 $m\in \mathbb {Z}_{>0}$
, the special divisor
$m\in \mathbb {Z}_{>0}$
, the special divisor 
 $\mathcal {Z}(m)$
 is defined as the Deligne–Mumford stack over
$\mathcal {Z}(m)$
 is defined as the Deligne–Mumford stack over 
 $\mathcal {M}$
 with functor of points
$\mathcal {M}$
 with functor of points 
 $\mathcal {Z}(m)(S)=\{v\in V(A_S) \mid Q(v)=m\}$
 for any
$\mathcal {Z}(m)(S)=\{v\in V(A_S) \mid Q(v)=m\}$
 for any 
 $\mathcal {M}$
-scheme S. More generally, in [Reference Andreatta, Goren, Howard and PeraAGHMP18, §4.5], for
$\mathcal {M}$
-scheme S. More generally, in [Reference Andreatta, Goren, Howard and PeraAGHMP18, §4.5], for 
 $\beta \in L^\vee /L, m\in Q(\beta )+\mathbb {Z}, m>0$
, there is also a special cycle
$\beta \in L^\vee /L, m\in Q(\beta )+\mathbb {Z}, m>0$
, there is also a special cycle 
 $\mathcal {Z}(\beta ,m)$
 defined as a Deligne–Mumford stack over
$\mathcal {Z}(\beta ,m)$
 defined as a Deligne–Mumford stack over 
 $\mathcal {M}$
 parametrising points with certain special quasi-endomorphisms and
$\mathcal {M}$
 parametrising points with certain special quasi-endomorphisms and 
 $\mathcal {Z}(m)=\mathcal {Z}(0,m)$
. By [Reference Andreatta, Goren, Howard and PeraAGHMP18, Proposition 4.5.8], the generic fibre
$\mathcal {Z}(m)=\mathcal {Z}(0,m)$
. By [Reference Andreatta, Goren, Howard and PeraAGHMP18, Proposition 4.5.8], the generic fibre 
 $\mathcal {Z}(\beta ,m)_{\mathbb {Q}}$
 is equal to the divisor
$\mathcal {Z}(\beta ,m)_{\mathbb {Q}}$
 is equal to the divisor 
 $Z(\beta ,m)$
 defined in Section 2.3. Moreover, étale locally on the source,
$Z(\beta ,m)$
 defined in Section 2.3. Moreover, étale locally on the source, 
 $\mathcal {Z}(\beta ,m)$
 is an effective Cartier divisor on
$\mathcal {Z}(\beta ,m)$
 is an effective Cartier divisor on 
 $\mathcal {M}$
, and we will use the same notation for the Cartier divisor on
$\mathcal {M}$
, and we will use the same notation for the Cartier divisor on 
 $\mathcal {M}$
 defined by étale descent.
$\mathcal {M}$
 defined by étale descent.
2.6 Reformulation of Theorem 1.8
Using the notion of special endomorphisms, Theorem 1.8 is a direct consequence of the following theorem.
Theorem 2.4. Assume that 
 $b\geq 3$
. Let K be a number field, let
$b\geq 3$
. Let K be a number field, let 
 $D\in \mathbb {Z}_{>0}$
 be a fixed integer represented by
$D\in \mathbb {Z}_{>0}$
 be a fixed integer represented by 
 $(L,Q)$
. Let
$(L,Q)$
. Let 
 $\mathcal {Y}\in \mathcal {M}(\mathcal {O}_K)$
, and assume that
$\mathcal {Y}\in \mathcal {M}(\mathcal {O}_K)$
, and assume that 
 $\mathcal {Y}_K\in M(K)$
 is Hodge-generic. Then there are infinitely many places
$\mathcal {Y}_K\in M(K)$
 is Hodge-generic. Then there are infinitely many places 
 $\mathfrak {P}$
 of K such that
$\mathfrak {P}$
 of K such that 
 $\mathcal {Y}_{\overline {\mathfrak {P}}}$
 lies in the image of
$\mathcal {Y}_{\overline {\mathfrak {P}}}$
 lies in the image of 
 $\mathcal {Z}(Dm^2)\rightarrow \mathcal {M}$
 for some
$\mathcal {Z}(Dm^2)\rightarrow \mathcal {M}$
 for some 
 $m\in \mathbb {Z}_{>0}$
.Footnote 15 Equivalently, for a Kuga–Satake abelian variety
$m\in \mathbb {Z}_{>0}$
.Footnote 15 Equivalently, for a Kuga–Satake abelian variety 
 $\mathcal {A}$
 over
$\mathcal {A}$
 over 
 $\mathcal {O}_K$
 parametrised by
$\mathcal {O}_K$
 parametrised by 
 $\mathcal {M}$
 such that
$\mathcal {M}$
 such that 
 $\mathcal {A}_{\overline {K}}$
 does not have any special endomorphisms, there are infinitely many
$\mathcal {A}_{\overline {K}}$
 does not have any special endomorphisms, there are infinitely many 
 $\mathfrak {P}$
 such that
$\mathfrak {P}$
 such that 
 $\mathcal {A}_{\overline {\mathfrak {P}}}$
 admits a special endomorphism v such that
$\mathcal {A}_{\overline {\mathfrak {P}}}$
 admits a special endomorphism v such that 
 $v\circ v=[Dm^2]$
 for some
$v\circ v=[Dm^2]$
 for some 
 $m\in \mathbb {Z}_{>0}$
.
$m\in \mathbb {Z}_{>0}$
.
3 The global height
 In this section, we begin the proof of Theorem 2.4 (and, in particular, Theorem 1.8) by studying the height of a given 
 $\mathcal {O}_K$
-point with respect to a sequence of arithmetic special divisors. In Section 3.1, we follow [Reference BruinierBru02], [Reference BorcherdsBor98] and endow the special divisors
$\mathcal {O}_K$
-point with respect to a sequence of arithmetic special divisors. In Section 3.1, we follow [Reference BruinierBru02], [Reference BorcherdsBor98] and endow the special divisors 
 $\mathcal {Z}(m)$
,
$\mathcal {Z}(m)$
, 
 $m\in \mathbb {Z}_{>0}$
 (defined in Section2.3, 2.5) with Green functions
$m\in \mathbb {Z}_{>0}$
 (defined in Section2.3, 2.5) with Green functions 
 $\Phi _m$
, thereby bestowing on them the structure of arithmetic divisors. In Section 3.2, we recall the modularity theorem of the generating series of arithmetic special divisors
$\Phi _m$
, thereby bestowing on them the structure of arithmetic divisors. In Section 3.2, we recall the modularity theorem of the generating series of arithmetic special divisors 
 $(\mathcal {Z}(m),\Phi _m)$
 proved by Howard–Madapusi-Pera [Reference Howard and Madapusi PeraHM17], and in Section 3.3, we use this to deduce asymptotic estimates for the global height
$(\mathcal {Z}(m),\Phi _m)$
 proved by Howard–Madapusi-Pera [Reference Howard and Madapusi PeraHM17], and in Section 3.3, we use this to deduce asymptotic estimates for the global height 
 $h_{\widehat {\mathcal {Z}}(m)}(\mathcal {Y})$
.
$h_{\widehat {\mathcal {Z}}(m)}(\mathcal {Y})$
.
 For simplicity, we assume that 
 $b\geq 3$
 as in [Reference BruinierBru02], and we refer the interested reader to [Reference Bruinier and KühnBK03, Reference Bruinier and FunkeBF04, Reference Bruinier and YangBY09] for related results without this assumption. Note that our quadratic form Q differs from the one in [Reference BruinierBru02, Reference Bruinier and KühnBK03] by a factor of
$b\geq 3$
 as in [Reference BruinierBru02], and we refer the interested reader to [Reference Bruinier and KühnBK03, Reference Bruinier and FunkeBF04, Reference Bruinier and YangBY09] for related results without this assumption. Note that our quadratic form Q differs from the one in [Reference BruinierBru02, Reference Bruinier and KühnBK03] by a factor of 
 $-1$
, and hence we shall replace the Weil representation there by its dual. The rest remains the same; namely, we work with the same space of modular forms and harmonic Maass forms and the same Eisenstein series.
$-1$
, and hence we shall replace the Weil representation there by its dual. The rest remains the same; namely, we work with the same space of modular forms and harmonic Maass forms and the same Eisenstein series.
3.1 Arithmetic special divisors and heights
 Let 
 $\rho _L:\mathrm {Mp}_{2}(\mathbb {Z})\rightarrow \mathrm {Aut_{\mathbb {C}}}(\mathbb {C}[L^\vee /L])$
 denote the unitary Weil representation, where
$\rho _L:\mathrm {Mp}_{2}(\mathbb {Z})\rightarrow \mathrm {Aut_{\mathbb {C}}}(\mathbb {C}[L^\vee /L])$
 denote the unitary Weil representation, where 
 $\mathrm {Mp}_{2}(\mathbb {Z})$
 is the metaplectic double cover of
$\mathrm {Mp}_{2}(\mathbb {Z})$
 is the metaplectic double cover of 
 $\mathrm {SL}_{2}(\mathbb {Z})$
; see, for instance, [Reference BruinierBru02, Section 1.1]. Let
$\mathrm {SL}_{2}(\mathbb {Z})$
; see, for instance, [Reference BruinierBru02, Section 1.1]. Let 
 $k=1+\frac {b}{2}$
, and let
$k=1+\frac {b}{2}$
, and let 
 $\mathrm {H}_{2-k}(\rho _{L}^\vee )$
 be the
$\mathrm {H}_{2-k}(\rho _{L}^\vee )$
 be the 
 $\mathbb {C}$
-vector space of vector valued harmonic weak Maass forms of weight
$\mathbb {C}$
-vector space of vector valued harmonic weak Maass forms of weight 
 $2-k$
 with respect to the dual
$2-k$
 with respect to the dual 
 $\rho _L^\vee $
 of the Weil representation as defined in [Reference Bruinier and YangBY09, 3.1].
$\rho _L^\vee $
 of the Weil representation as defined in [Reference Bruinier and YangBY09, 3.1].
 For 
 $\beta \in L^\vee /L$
,
$\beta \in L^\vee /L$
, 
 $m\in \mathbb {Z}+Q(\beta )$
 with
$m\in \mathbb {Z}+Q(\beta )$
 with 
 $m>0$
, let
$m>0$
, let 
 $F_{\beta ,m} \in \mathrm {H}_{2-k}(\rho _{L}^\vee )$
 denote the Hejhal–Poincaré harmonic Maass form defined in [Reference BruinierBru02, Def. 1.8]. In fact,
$F_{\beta ,m} \in \mathrm {H}_{2-k}(\rho _{L}^\vee )$
 denote the Hejhal–Poincaré harmonic Maass form defined in [Reference BruinierBru02, Def. 1.8]. In fact, 
 $F_{\beta ,m}(\tau ):=F_{\beta ,-m}(\tau , \frac {1}{2}+\frac {b}{4})$
 in [Reference BruinierBru02, Def. 1.8], where
$F_{\beta ,m}(\tau ):=F_{\beta ,-m}(\tau , \frac {1}{2}+\frac {b}{4})$
 in [Reference BruinierBru02, Def. 1.8], where 
 $\tau $
 lies in the Poincaré upper half plane
$\tau $
 lies in the Poincaré upper half plane 
 $\mathbb {H}$
. Let
$\mathbb {H}$
. Let 
 $\Phi _{\beta ,m}$
 denote the regularised theta lifting of
$\Phi _{\beta ,m}$
 denote the regularised theta lifting of 
 $F_{\beta ,m}$
 in the sense of Borcherds; see [Reference BruinierBru02, (2.16)] and [Reference Bruinier and FunkeBF04, §5.2]. By [Reference BorcherdsBor98, §6, Thm. 13.3] and [Reference BruinierBru02, §2.2, eqn. (3.40), Thm. 3.16],
$F_{\beta ,m}$
 in the sense of Borcherds; see [Reference BruinierBru02, (2.16)] and [Reference Bruinier and FunkeBF04, §5.2]. By [Reference BorcherdsBor98, §6, Thm. 13.3] and [Reference BruinierBru02, §2.2, eqn. (3.40), Thm. 3.16], 
 $\Phi _{\beta ,m}$
 is a Green functionFootnote 16 for the divisor
$\Phi _{\beta ,m}$
 is a Green functionFootnote 16 for the divisor 
 $\mathcal {Z}(\beta ,m)$
, and we use
$\mathcal {Z}(\beta ,m)$
, and we use 
 $\widehat {\mathcal {Z}}(\beta ,m)$
 to denote the arithmetic divisor
$\widehat {\mathcal {Z}}(\beta ,m)$
 to denote the arithmetic divisor 
 $(\mathcal {Z}(\beta ,m), \Phi _{\beta ,m})$
. Our main focus is the case when
$(\mathcal {Z}(\beta ,m), \Phi _{\beta ,m})$
. Our main focus is the case when 
 $\beta =0$
, and we set
$\beta =0$
, and we set 
 $\Phi _m:=\Phi _{0,m}, \widehat {\mathcal {Z}}(m):=\widehat {\mathcal {Z}}(0,m)$
 for
$\Phi _m:=\Phi _{0,m}, \widehat {\mathcal {Z}}(m):=\widehat {\mathcal {Z}}(0,m)$
 for 
 $m\in \mathbb {Z}_{>0}$
.
$m\in \mathbb {Z}_{>0}$
.
 Let 
 $\widehat {\operatorname {\mathrm {CH}}}^1(\mathcal {M})_{\mathbb {Q}}$
 denote the first arithmetic Chow group of Gillet–Soulé [Reference Gillet and SouléGS90] as defined in [Reference Andreatta, Goren, Howard and PeraAGHMP17, §4.1]. Since
$\widehat {\operatorname {\mathrm {CH}}}^1(\mathcal {M})_{\mathbb {Q}}$
 denote the first arithmetic Chow group of Gillet–Soulé [Reference Gillet and SouléGS90] as defined in [Reference Andreatta, Goren, Howard and PeraAGHMP17, §4.1]. Since 
 $\mathcal {M}$
 is a normal Deligne–Mumford stack, we have a natural isomorphism, as in [Reference SouléSou92, III.4],
$\mathcal {M}$
 is a normal Deligne–Mumford stack, we have a natural isomorphism, as in [Reference SouléSou92, III.4], 
 $$ \begin{align*}\widehat{\mathrm{Pic}}(\mathcal{M})_{\mathbb{Q}}\otimes \mathbb{Q}\xrightarrow{\sim} \widehat{\mathrm{CH}^{1}}(\mathcal{M})_{\mathbb{Q}},\end{align*} $$
$$ \begin{align*}\widehat{\mathrm{Pic}}(\mathcal{M})_{\mathbb{Q}}\otimes \mathbb{Q}\xrightarrow{\sim} \widehat{\mathrm{CH}^{1}}(\mathcal{M})_{\mathbb{Q}},\end{align*} $$
where 
 $\widehat {\operatorname {\mathrm {Pic}}}(\mathcal {M})$
 denotes the group of isomorphism classes of metrised line bundles and
$\widehat {\operatorname {\mathrm {Pic}}}(\mathcal {M})$
 denotes the group of isomorphism classes of metrised line bundles and 
 $\widehat {\operatorname {\mathrm {Pic}}}(\mathcal {M})_{\mathbb {Q}}:=\widehat {\operatorname {\mathrm {Pic}}}(\mathcal {M})\otimes \mathbb {Q}$
; see [Reference Andreatta, Goren, Howard and PeraAGHMP17, §5.1] for more details. Since
$\widehat {\operatorname {\mathrm {Pic}}}(\mathcal {M})_{\mathbb {Q}}:=\widehat {\operatorname {\mathrm {Pic}}}(\mathcal {M})\otimes \mathbb {Q}$
; see [Reference Andreatta, Goren, Howard and PeraAGHMP17, §5.1] for more details. Since 
 $\mathcal {Z}(\beta ,m)$
 is (étale locally) Cartier, then we view
$\mathcal {Z}(\beta ,m)$
 is (étale locally) Cartier, then we view 
 $\widehat {\mathcal {Z}}(\beta ,m)\in \widehat {\operatorname {\mathrm {Pic}}}(\mathcal {M})_{\mathbb {Q}}$
.
$\widehat {\mathcal {Z}}(\beta ,m)\in \widehat {\operatorname {\mathrm {Pic}}}(\mathcal {M})_{\mathbb {Q}}$
.
 Moreover, the line bundle 
 $\boldsymbol {\omega }$
 from Proposition 2.1 is endowed with the Petersson metric defined as follows: the fibre of
$\boldsymbol {\omega }$
 from Proposition 2.1 is endowed with the Petersson metric defined as follows: the fibre of 
 $\boldsymbol {\omega }$
 at a complex point
$\boldsymbol {\omega }$
 at a complex point 
 $[[z],g]\in M(\mathbb {C})$
 is identified with the isotropic line
$[[z],g]\in M(\mathbb {C})$
 is identified with the isotropic line 
 $\mathbb {C} z\subset V_{\mathbb {C}}$
; then we set
$\mathbb {C} z\subset V_{\mathbb {C}}$
; then we set 
 $||z||^2=-\frac {(z.\overline {z})}{4\pi e^{\gamma }}$
, where
$||z||^2=-\frac {(z.\overline {z})}{4\pi e^{\gamma }}$
, where 
 $\gamma =-\Gamma '(1)$
 is the Euler–Mascheroni constant. Hence we get a metrised line bundle
$\gamma =-\Gamma '(1)$
 is the Euler–Mascheroni constant. Hence we get a metrised line bundle 
 $\overline {\boldsymbol {\omega }}\in \widehat {\mathrm {Pic}}(\mathcal {M})$
.
$\overline {\boldsymbol {\omega }}\in \widehat {\mathrm {Pic}}(\mathcal {M})$
.
 Recall that we have a map 
 $\mathcal {Y} \rightarrow \mathcal {M} $
, where
$\mathcal {Y} \rightarrow \mathcal {M} $
, where 
 $\mathcal {Y} = \operatorname {\mathrm {Spec}} \mathcal {O}_K$
. We now define the notion of the height of
$\mathcal {Y} = \operatorname {\mathrm {Spec}} \mathcal {O}_K$
. We now define the notion of the height of 
 $\mathcal {M}$
 with respect to the arithmetic divisors
$\mathcal {M}$
 with respect to the arithmetic divisors 
 $\widehat {\mathcal {Z}}(m)$
 and
$\widehat {\mathcal {Z}}(m)$
 and 
 $\overline {\boldsymbol {\omega }}$
. As in [Reference Andreatta, Goren, Howard and PeraAGHMP17, §§5.1,5.2], [Reference Andreatta, Goren, Howard and PeraAGHMP18, §6.4], the height
$\overline {\boldsymbol {\omega }}$
. As in [Reference Andreatta, Goren, Howard and PeraAGHMP17, §§5.1,5.2], [Reference Andreatta, Goren, Howard and PeraAGHMP18, §6.4], the height 
 $h_{\widehat {\mathcal {Z}}(m)}(\mathcal {Y})$
 of
$h_{\widehat {\mathcal {Z}}(m)}(\mathcal {Y})$
 of 
 $\mathcal {Y}$
 with respect to
$\mathcal {Y}$
 with respect to 
 $\widehat {\mathcal {Z}}(m)$
 (respectively,
$\widehat {\mathcal {Z}}(m)$
 (respectively, 
 $\overline {\boldsymbol {\omega }}$
) is defined as the image of
$\overline {\boldsymbol {\omega }}$
) is defined as the image of 
 $\widehat {\mathcal {Z}}(m)$
 (respectively,
$\widehat {\mathcal {Z}}(m)$
 (respectively, 
 $\overline {\boldsymbol {\omega }}$
) under the composition
$\overline {\boldsymbol {\omega }}$
) under the composition 
 $$ \begin{align*}\widehat{\mathrm{CH}^{1}}(\mathcal{M})_{\mathbb{Q}}\cong \widehat{\operatorname{\mathrm{Pic}}}(\mathcal{M})_{\mathbb{Q}}\rightarrow \widehat{\operatorname{\mathrm{Pic}}}(\mathcal{Y})_{\mathbb{Q}}\xrightarrow{\widehat{\deg}} \mathbb{R},\end{align*} $$
$$ \begin{align*}\widehat{\mathrm{CH}^{1}}(\mathcal{M})_{\mathbb{Q}}\cong \widehat{\operatorname{\mathrm{Pic}}}(\mathcal{M})_{\mathbb{Q}}\rightarrow \widehat{\operatorname{\mathrm{Pic}}}(\mathcal{Y})_{\mathbb{Q}}\xrightarrow{\widehat{\deg}} \mathbb{R},\end{align*} $$
where the middle map is the pull-back of metrised line bundles and the arithmetic degree map 
 $\widehat {\deg }$
 is the extension over
$\widehat {\deg }$
 is the extension over 
 $\mathbb {Q}$
 of the one defined in [Reference Andreatta, Goren, Howard and PeraAGHMP18, 6.4].
$\mathbb {Q}$
 of the one defined in [Reference Andreatta, Goren, Howard and PeraAGHMP18, 6.4].
 Since 
 $\mathcal {Y}$
 and
$\mathcal {Y}$
 and 
 $\mathcal {Z}(m)$
 intersect properly (recall that we assume
$\mathcal {Z}(m)$
 intersect properly (recall that we assume 
 $\mathcal {Y}_K$
 is Hodge-generic), we have the following description of
$\mathcal {Y}_K$
 is Hodge-generic), we have the following description of 
 $h_{\widehat {\mathcal {Z}}(m)}(\mathcal {Y})$
. Let
$h_{\widehat {\mathcal {Z}}(m)}(\mathcal {Y})$
. Let 
 $\mathcal {A}$
 denote
$\mathcal {A}$
 denote 
 $\mathcal {A}^{\mathrm {univ}}_{\mathcal {Y}}$
, where
$\mathcal {A}^{\mathrm {univ}}_{\mathcal {Y}}$
, where 
 $\mathcal {A}^{\mathrm {univ}}$
 is the Kuga–Satake abelian scheme over
$\mathcal {A}^{\mathrm {univ}}$
 is the Kuga–Satake abelian scheme over 
 $\mathcal {M}$
. Using the moduli definition of
$\mathcal {M}$
. Using the moduli definition of 
 $\mathcal {Z}(m)$
 in Section 2.5, the
$\mathcal {Z}(m)$
 in Section 2.5, the 
 $\mathcal {Y}$
-scheme
$\mathcal {Y}$
-scheme 
 $\mathcal {Y}\times _{\mathcal {M}}\mathcal {Z}(m)$
 is given by
$\mathcal {Y}\times _{\mathcal {M}}\mathcal {Z}(m)$
 is given by 
 $$\begin{align*}\mathcal{Y}\times_{\mathcal{M}}\mathcal{Z}(m)(S)=\{v\in V(\mathcal{A}_S)\mid v\circ v=[m]\}\end{align*}$$
$$\begin{align*}\mathcal{Y}\times_{\mathcal{M}}\mathcal{Z}(m)(S)=\{v\in V(\mathcal{A}_S)\mid v\circ v=[m]\}\end{align*}$$
for any 
 $\mathcal {Y}$
-scheme S. Via the natural map
$\mathcal {Y}$
-scheme S. Via the natural map 
 $\mathcal {Y}\times _{\mathcal {M}} \mathcal {Z}(m)\rightarrow \mathcal {Y}$
, and using étale descent, we view
$\mathcal {Y}\times _{\mathcal {M}} \mathcal {Z}(m)\rightarrow \mathcal {Y}$
, and using étale descent, we view 
 $\mathcal {Y}\times _{\mathcal {M}} \mathcal {Z}(m)$
 as a
$\mathcal {Y}\times _{\mathcal {M}} \mathcal {Z}(m)$
 as a 
 $\mathbb {Q}$
-Cartier divisor on
$\mathbb {Q}$
-Cartier divisor on 
 $\mathcal {Y}$
. Therefore,
$\mathcal {Y}$
. Therefore, 
 $$ \begin{align} h_{\widehat{\mathcal{Z}}(m)}(\mathcal{Y})=\sum_{\sigma:K\hookrightarrow\mathbb{C}}\Phi_{m}(\mathcal{Y}^\sigma)+\sum_{\mathfrak{P}}(\mathcal{Y}.\mathcal{Z}(m))_{\mathfrak{P}}\log|\mathcal{O}_{K}/\mathfrak{P}|, \end{align} $$
$$ \begin{align} h_{\widehat{\mathcal{Z}}(m)}(\mathcal{Y})=\sum_{\sigma:K\hookrightarrow\mathbb{C}}\Phi_{m}(\mathcal{Y}^\sigma)+\sum_{\mathfrak{P}}(\mathcal{Y}.\mathcal{Z}(m))_{\mathfrak{P}}\log|\mathcal{O}_{K}/\mathfrak{P}|, \end{align} $$
where for 
 $\sigma :K\hookrightarrow \mathbb {C}$
, we use
$\sigma :K\hookrightarrow \mathbb {C}$
, we use 
 $\mathcal {Y}^\sigma $
 to denote the point in
$\mathcal {Y}^\sigma $
 to denote the point in 
 $M(\mathbb {C})$
 induced by
$M(\mathbb {C})$
 induced by 
 $\operatorname {\mathrm {Spec}}(\mathbb {C})\xrightarrow {\sigma } \operatorname {\mathrm {Spec}}{\mathcal {O}_K}\xrightarrow {\mathcal {Y}} \mathcal {M}$
; and if we denote by
$\operatorname {\mathrm {Spec}}(\mathbb {C})\xrightarrow {\sigma } \operatorname {\mathrm {Spec}}{\mathcal {O}_K}\xrightarrow {\mathcal {Y}} \mathcal {M}$
; and if we denote by 
 $\mathcal {O}_{\mathcal {Y}\times _{\mathcal {M}}\mathcal {Z}(m),v}$
 the étale local ring of
$\mathcal {O}_{\mathcal {Y}\times _{\mathcal {M}}\mathcal {Z}(m),v}$
 the étale local ring of 
 $\mathcal {Y}\times _{\mathcal {M}}\mathcal {Z}(m)$
 at v,
$\mathcal {Y}\times _{\mathcal {M}}\mathcal {Z}(m)$
 at v, 
 $$ \begin{align} (\mathcal{Y}.\mathcal{Z}(m))_{\mathfrak{P}}=\sum_{v\in\mathcal{Y}\times_{\mathcal{M}}\mathcal{Z}(m)(\overline{\mathbb{F}}_{\mathfrak{P}})}\operatorname{\mathrm{length}}(\mathcal{O}_{\mathcal{Y}\times_{\mathcal{M}}\mathcal{Z}(m),v}), \end{align} $$
$$ \begin{align} (\mathcal{Y}.\mathcal{Z}(m))_{\mathfrak{P}}=\sum_{v\in\mathcal{Y}\times_{\mathcal{M}}\mathcal{Z}(m)(\overline{\mathbb{F}}_{\mathfrak{P}})}\operatorname{\mathrm{length}}(\mathcal{O}_{\mathcal{Y}\times_{\mathcal{M}}\mathcal{Z}(m),v}), \end{align} $$
where 
 $\mathbb {F}_{\mathfrak {P}}$
 denotes the residue field of
$\mathbb {F}_{\mathfrak {P}}$
 denotes the residue field of 
 $\mathfrak {P}$
.
$\mathfrak {P}$
.
3.2 Howard–Madapusi-Pera–Borcherds’ modularity theorem
 Let 
 $M_{1+\frac {b}{2}}(\rho _L)$
 denote the
$M_{1+\frac {b}{2}}(\rho _L)$
 denote the 
 $\mathbb {C}$
-vector space of
$\mathbb {C}$
-vector space of 
 $\mathbb {C}[L^\vee /L]$
-valued modular forms of weight
$\mathbb {C}[L^\vee /L]$
-valued modular forms of weight 
 $1+\frac {b}{2}$
 with respect to
$1+\frac {b}{2}$
 with respect to 
 $\rho _L$
 (see see [Reference BruinierBru02, Definition 1.2]). Let
$\rho _L$
 (see see [Reference BruinierBru02, Definition 1.2]). Let 
 $(\mathfrak {e}_\beta )_{\beta \in L^\vee /L}$
 denote the standard basis of
$(\mathfrak {e}_\beta )_{\beta \in L^\vee /L}$
 denote the standard basis of 
 $\mathbb {C}[L^\vee /L]$
.
$\mathbb {C}[L^\vee /L]$
.
Theorem 3.1 [Reference Howard and Madapusi PeraHM17, Theorem 9.4.1]
 Assume 
 $b\geq 3$
, and let
$b\geq 3$
, and let 
 $q=e^{2\pi i \tau }$
. The formal generating series
$q=e^{2\pi i \tau }$
. The formal generating series 
 $$ \begin{align*}\widehat{\Phi}_L=\overline{\boldsymbol{\omega}}^\vee\mathfrak{e}_0+\sum_{\underset{m> 0, m\in Q(\beta)+\mathbb{Z}}{\beta\in L^{\vee}/L}}\widehat{\mathcal{Z}}(\beta,m)\cdot q^m \mathfrak{e}_\beta\end{align*} $$
$$ \begin{align*}\widehat{\Phi}_L=\overline{\boldsymbol{\omega}}^\vee\mathfrak{e}_0+\sum_{\underset{m> 0, m\in Q(\beta)+\mathbb{Z}}{\beta\in L^{\vee}/L}}\widehat{\mathcal{Z}}(\beta,m)\cdot q^m \mathfrak{e}_\beta\end{align*} $$
is an element of 
 $M_{1+\frac {b}{2}}(\rho _L)\otimes \widehat {\mathrm {Pic}}(\mathcal {M})_{\mathbb {Q}}$
. More precisely, for any
$M_{1+\frac {b}{2}}(\rho _L)\otimes \widehat {\mathrm {Pic}}(\mathcal {M})_{\mathbb {Q}}$
. More precisely, for any 
 $\mathbb {Q}$
-linear map
$\mathbb {Q}$
-linear map 
 $\alpha :\widehat {\operatorname {\mathrm {Pic}}}(\mathcal {M})_{\mathbb {Q}}\rightarrow \mathbb {C}$
, we have
$\alpha :\widehat {\operatorname {\mathrm {Pic}}}(\mathcal {M})_{\mathbb {Q}}\rightarrow \mathbb {C}$
, we have 
 $\alpha (\widehat {\Phi }_L)\in M_{1+\frac {b}{2}}(\rho _L)$
.
$\alpha (\widehat {\Phi }_L)\in M_{1+\frac {b}{2}}(\rho _L)$
.
3.3 Asymptotic estimates for the global height
 In this subsection, we provide asymptotic estimates for the global height. First we introduce an Eisenstein series 
 $(\tau ,s)\rightarrow E_{0}(\tau ,s)$
 for
$(\tau ,s)\rightarrow E_{0}(\tau ,s)$
 for 
 $\tau \in \mathbb {H}$
 and
$\tau \in \mathbb {H}$
 and 
 $s\in \mathbb {C}$
 with
$s\in \mathbb {C}$
 with 
 $\operatorname {\mathrm {Re}}(s)>\frac {1}{2}-\frac {b}{4}=1-\frac {k}{2}$
, which serves two purposes. First, the Fourier coefficients of its value at
$\operatorname {\mathrm {Re}}(s)>\frac {1}{2}-\frac {b}{4}=1-\frac {k}{2}$
, which serves two purposes. First, the Fourier coefficients of its value at 
 $s=0$
 give the main term in the Fourier coefficients of
$s=0$
 give the main term in the Fourier coefficients of 
 $\widehat {\Phi }_L$
; see the proof of Proposition 3.2. Second, we will use the Fourier coefficients of
$\widehat {\Phi }_L$
; see the proof of Proposition 3.2. Second, we will use the Fourier coefficients of 
 $E_0(\tau ,s)$
 to describe
$E_0(\tau ,s)$
 to describe 
 $\Phi _m$
 explicitly in Section 5.1.
$\Phi _m$
 explicitly in Section 5.1.
 Let 
 $(\tau ,s)\rightarrow E_{0}(\tau ,s)$
 denote the Eisenstein series defined in [Reference Bruinier and KühnBK03, Equation (1.4), (3.1) with
$(\tau ,s)\rightarrow E_{0}(\tau ,s)$
 denote the Eisenstein series defined in [Reference Bruinier and KühnBK03, Equation (1.4), (3.1) with 
 $\beta = 0,\kappa = 1+\frac{b}{2}$
]. It converges normally on
$\beta = 0,\kappa = 1+\frac{b}{2}$
]. It converges normally on 
 $\mathbb {H}$
 for
$\mathbb {H}$
 for 
 $\mathrm {Re}(s)>1-\frac {k}{2}$
 and defines a
$\mathrm {Re}(s)>1-\frac {k}{2}$
 and defines a 
 $\mathrm {Mp}_{2}(\mathbb {Z})$
-invariant real analytic function.
$\mathrm {Mp}_{2}(\mathbb {Z})$
-invariant real analytic function.
 For a fixed 
 $s\in \mathbb {C}$
 with
$s\in \mathbb {C}$
 with 
 $\mathrm {Re}(s)>1-\frac {k}{2}$
, by [Reference Bruinier and KühnBK03, Proposition 3.1], the Eisenstein series
$\mathrm {Re}(s)>1-\frac {k}{2}$
, by [Reference Bruinier and KühnBK03, Proposition 3.1], the Eisenstein series 
 $E_0(\cdot ,s)$
 has a Fourier expansion of the form
$E_0(\cdot ,s)$
 has a Fourier expansion of the form 
 $$ \begin{align*} E_{0}(\tau,s)=\sum_{\beta\in L^{\vee}/L}\sum_{m\in Q(\beta)+\mathbb{Z}}c_{0}(\beta,m,s,y)e^{2\pi i m x}\mathfrak{e}_{\beta}, \end{align*} $$
$$ \begin{align*} E_{0}(\tau,s)=\sum_{\beta\in L^{\vee}/L}\sum_{m\in Q(\beta)+\mathbb{Z}}c_{0}(\beta,m,s,y)e^{2\pi i m x}\mathfrak{e}_{\beta}, \end{align*} $$
where we write 
 $\tau =x+iy, x\in \mathbb {R}, y\in \mathbb {R}_{>0}$
. By [Reference Bruinier and KühnBK03, Proposition 3.2], the coefficients
$\tau =x+iy, x\in \mathbb {R}, y\in \mathbb {R}_{>0}$
. By [Reference Bruinier and KühnBK03, Proposition 3.2], the coefficients 
 $c_0(\beta ,m,s,y)$
 can be decomposed, for
$c_0(\beta ,m,s,y)$
 can be decomposed, for 
 $m\neq 0$
, as
$m\neq 0$
, as 
 $$ \begin{align} c_0(\beta,m,s,y)=C(\beta,m,s)\mathcal{W}_s(4\pi m y), \end{align} $$
$$ \begin{align} c_0(\beta,m,s,y)=C(\beta,m,s)\mathcal{W}_s(4\pi m y), \end{align} $$
where the function 
 $C(\beta ,m,s)$
 is independent of y (see [Reference Bruinier and KühnBK03, Equation (3.22)]) and
$C(\beta ,m,s)$
 is independent of y (see [Reference Bruinier and KühnBK03, Equation (3.22)]) and 
 $\mathcal {W}_s$
 is defined in [Reference Bruinier and KühnBK03, (3.2)].
$\mathcal {W}_s$
 is defined in [Reference Bruinier and KühnBK03, (3.2)].
 By [Reference Bruinier and KühnBK03, Proposition 3.1, (3.3)], the value at 
 $s=0$
 of
$s=0$
 of 
 $E_0(\tau ,s)$
 is an element of
$E_0(\tau ,s)$
 is an element of 
 $\mathrm {M}_{1+\frac {b}{2}}(\rho _L)$
. For
$\mathrm {M}_{1+\frac {b}{2}}(\rho _L)$
. For 
 $\beta \in L^{\vee }/L$
,
$\beta \in L^{\vee }/L$
, 
 $m\in Q(\beta )+\mathbb {Z}$
 with
$m\in Q(\beta )+\mathbb {Z}$
 with 
 $m\geq 0$
, we denote by
$m\geq 0$
, we denote by 
 $c(\beta ,m)$
 its
$c(\beta ,m)$
 its 
 $(\beta ,m)$
th Fourier coefficient, and we can thus write
$(\beta ,m)$
th Fourier coefficient, and we can thus write 
 $$ \begin{align*} E_0(\tau):=E_0(\tau, 0)=2\mathfrak{e}_0+\sum_{\underset{m\in Q(\beta)+\mathbb{Z},m>0}{\beta\in L^{\vee}/L}}c(\beta,m)q^m \mathfrak{e}_{\beta}, \text{, where }q=e^{2\pi i \tau}. \end{align*} $$
$$ \begin{align*} E_0(\tau):=E_0(\tau, 0)=2\mathfrak{e}_0+\sum_{\underset{m\in Q(\beta)+\mathbb{Z},m>0}{\beta\in L^{\vee}/L}}c(\beta,m)q^m \mathfrak{e}_{\beta}, \text{, where }q=e^{2\pi i \tau}. \end{align*} $$
By definition and [Reference Bruinier and KühnBK03, Proposition 3.1, (3.3)], we have 
 $C(\beta ,n,0)=c(\beta ,n)$
. By [Reference Bruinier and KühnBK03, Prop.4.8], the coefficient
$C(\beta ,n,0)=c(\beta ,n)$
. By [Reference Bruinier and KühnBK03, Prop.4.8], the coefficient 
 $c(\beta ,m)$
 encodes the degree of the special divisor
$c(\beta ,m)$
 encodes the degree of the special divisor 
 $Z(\beta ,m)(\mathbb {C})$
. Moreover, [Reference Bruinier and KussBK01, Proposition 4, equation (19)] gives explicit formulas for
$Z(\beta ,m)(\mathbb {C})$
. Moreover, [Reference Bruinier and KussBK01, Proposition 4, equation (19)] gives explicit formulas for 
 $c(\beta ,m)$
. By [Reference Bruinier and KussBK01, Proposition 14],
$c(\beta ,m)$
. By [Reference Bruinier and KussBK01, Proposition 14], 
 $c(\beta ,m)<0$
 if
$c(\beta ,m)<0$
 if 
 $m\in Q(L+\beta )$
 and
$m\in Q(L+\beta )$
 and 
 $c(\beta ,m)=0$
 if
$c(\beta ,m)=0$
 if 
 $m\notin Q(L+\beta )$
. By [Reference TayouTay20a, Example 2.3], we have that for
$m\notin Q(L+\beta )$
. By [Reference TayouTay20a, Example 2.3], we have that for 
 $m\in Q(L+\beta )$
,Footnote 17
$m\in Q(L+\beta )$
,Footnote 17 
 $$ \begin{align} |c(\beta,m)|=-c(\beta,m)\asymp m^{\frac{b}{2}}. \end{align} $$
$$ \begin{align} |c(\beta,m)|=-c(\beta,m)\asymp m^{\frac{b}{2}}. \end{align} $$
 We will henceforth focus on the case where 
 $\beta =0$
, and we set
$\beta =0$
, and we set 
 $C(m,s):=C(0,m,s)$
 and
$C(m,s):=C(0,m,s)$
 and 
 $c(m):=c(0,m)$
. We are now ready to establish asymptotics for the global height in terms of the Fourier coefficients just defined.
$c(m):=c(0,m)$
. We are now ready to establish asymptotics for the global height in terms of the Fourier coefficients just defined.
Proposition 3.2. For every 
 $\epsilon>0$
 and
$\epsilon>0$
 and 
 $m\in \mathbb {Z}_{>0}$
, we have
$m\in \mathbb {Z}_{>0}$
, we have 
 $$ \begin{align*} h_{\widehat{\mathcal{Z}}(m)}(\mathcal{Y})=\frac{-c(m)}{2}h_{\overline{\boldsymbol{\omega}}}(\mathcal{Y})+O_{\epsilon}(m^{\frac{2+b}{4}+\epsilon}). \end{align*} $$
$$ \begin{align*} h_{\widehat{\mathcal{Z}}(m)}(\mathcal{Y})=\frac{-c(m)}{2}h_{\overline{\boldsymbol{\omega}}}(\mathcal{Y})+O_{\epsilon}(m^{\frac{2+b}{4}+\epsilon}). \end{align*} $$
In particular, we have 
 $h_{\widehat {\mathcal {Z}}(m)}(\mathcal {Y})=O(m^{\frac {b}{2}})$
 as
$h_{\widehat {\mathcal {Z}}(m)}(\mathcal {Y})=O(m^{\frac {b}{2}})$
 as 
 $m\rightarrow \infty $
.
$m\rightarrow \infty $
.
The second claim follows from the first claim and equation (3.4).
Proof. The proof is similar to the one in [Reference TayouTay20a, Proposition 2.5]. For 
 $\widehat {\mathcal {Z}}\in \widehat {\operatorname {\mathrm {CH}}^1}(\mathcal {M})_{\mathbb {Q}} \cong \widehat {\operatorname {\mathrm {Pic}}}(\mathcal {M})_{\mathbb {Q}}$
, the height
$\widehat {\mathcal {Z}}\in \widehat {\operatorname {\mathrm {CH}}^1}(\mathcal {M})_{\mathbb {Q}} \cong \widehat {\operatorname {\mathrm {Pic}}}(\mathcal {M})_{\mathbb {Q}}$
, the height 
 $h_{\widehat {\mathcal {Z}}}(\mathcal {Y})$
 defines a
$h_{\widehat {\mathcal {Z}}}(\mathcal {Y})$
 defines a 
 $\mathbb {Q}$
-linear map
$\mathbb {Q}$
-linear map 
 $\widehat {\operatorname {\mathrm {Pic}}}(\mathcal {M})_{\mathbb {Q}}\rightarrow \mathbb {R}$
; by Theorem 3.1, the following generating series
$\widehat {\operatorname {\mathrm {Pic}}}(\mathcal {M})_{\mathbb {Q}}\rightarrow \mathbb {R}$
; by Theorem 3.1, the following generating series 
 $$ \begin{align*}-h_{\overline{\boldsymbol{\omega}}}(\mathcal{Y})\mathfrak{e}_0+\sum_{\underset{m> 0, m\in Q(\beta)+\mathbb{Z}}{\beta\in L^{\vee}/L}}h_{\widehat{\mathcal{Z}}(\beta,m)}(\mathcal{Y})\cdot q^{m}\mathfrak{e}_\beta\end{align*} $$
$$ \begin{align*}-h_{\overline{\boldsymbol{\omega}}}(\mathcal{Y})\mathfrak{e}_0+\sum_{\underset{m> 0, m\in Q(\beta)+\mathbb{Z}}{\beta\in L^{\vee}/L}}h_{\widehat{\mathcal{Z}}(\beta,m)}(\mathcal{Y})\cdot q^{m}\mathfrak{e}_\beta\end{align*} $$
is the Fourier expansion of an element in 
 $M_{1+\frac {b}{2}}(\rho _L)$
. By [Reference BruinierBru02, p.27], we write
$M_{1+\frac {b}{2}}(\rho _L)$
. By [Reference BruinierBru02, p.27], we write 
 $$ \begin{align*}-h_{\overline{\boldsymbol{\omega}}}(\mathcal{Y})\mathfrak{e}_0+\sum_{\underset{m> 0, m\in Q(\beta)+\mathbb{Z}}{\beta\in L^{\vee}/L}}h_{\widehat{\mathcal{Z}}(\beta,m)}(\mathcal{Y})\cdot q^{m}\mathfrak{e}_\beta=\frac{-h_{\overline{\boldsymbol{\omega}}}(\mathcal{Y})}{2}E_0+g,\end{align*} $$
$$ \begin{align*}-h_{\overline{\boldsymbol{\omega}}}(\mathcal{Y})\mathfrak{e}_0+\sum_{\underset{m> 0, m\in Q(\beta)+\mathbb{Z}}{\beta\in L^{\vee}/L}}h_{\widehat{\mathcal{Z}}(\beta,m)}(\mathcal{Y})\cdot q^{m}\mathfrak{e}_\beta=\frac{-h_{\overline{\boldsymbol{\omega}}}(\mathcal{Y})}{2}E_0+g,\end{align*} $$
where 
 $E_0=E_0(\tau )$
 is the Eisenstein series recalled in Section 3.3 and
$E_0=E_0(\tau )$
 is the Eisenstein series recalled in Section 3.3 and 
 $g\in M_{1+\frac {b}{2}}(\rho _L)$
 is a cusp form; see [Reference BruinierBru02, Def.1.2] for a definition.
$g\in M_{1+\frac {b}{2}}(\rho _L)$
 is a cusp form; see [Reference BruinierBru02, Def.1.2] for a definition.
 For 
 $m\in \mathbb {Z}_{>0}$
, the equation for the
$m\in \mathbb {Z}_{>0}$
, the equation for the 
 $\mathfrak {e}_0$
-component implies that
$\mathfrak {e}_0$
-component implies that 
 $$ \begin{align*}h_{\widehat{\mathcal{Z}}(m)}(\mathcal{Y})=\frac{-c(m)}{2}h_{\overline{\boldsymbol{\omega}}}(\mathcal{Y})+g(m),\end{align*} $$
$$ \begin{align*}h_{\widehat{\mathcal{Z}}(m)}(\mathcal{Y})=\frac{-c(m)}{2}h_{\overline{\boldsymbol{\omega}}}(\mathcal{Y})+g(m),\end{align*} $$
where 
 $g(m)$
 is the mth Fourier coefficient of the
$g(m)$
 is the mth Fourier coefficient of the 
 $\mathfrak {e}_0$
-component of g. We obtain the desired estimate by [Reference SarnakSar90, Prop. 1.5.5], which implies that
$\mathfrak {e}_0$
-component of g. We obtain the desired estimate by [Reference SarnakSar90, Prop. 1.5.5], which implies that 
 $$ \begin{align*}|g(m)|\leq C_{\epsilon,g} m^{\frac{2+b}{4}+\epsilon}\end{align*} $$
$$ \begin{align*}|g(m)|\leq C_{\epsilon,g} m^{\frac{2+b}{4}+\epsilon}\end{align*} $$
for all 
 $\epsilon>0$
, some constant
$\epsilon>0$
, some constant 
 $C_{\epsilon ,g}>0$
 and all
$C_{\epsilon ,g}>0$
 and all 
 $m\in \mathbb {Z}_{>0}$
.
$m\in \mathbb {Z}_{>0}$
.
4 General results on quadratic forms
 In this section, we collect some general results on quadratic forms that will be used in Sections 5–7. First, in Section 4.1, we prove estimates on the number of local representations of integral quadratic forms that will be used in Section 5.1. Then, in Section 4.2, we state results due to Heath-Brown on the number of integral representations of integral quadratic forms that will be used in Sections 6 and 7. In Section 4.3, we apply Heath-Brown’s results to the lattice 
 $(L,Q)$
 in Section 2 and also recall the work of Niedermowwe, which could be viewed as a refinement of Heath-Brown’s work; these results are used in Section 6. The reader may skip this section first and refer back later.
$(L,Q)$
 in Section 2 and also recall the work of Niedermowwe, which could be viewed as a refinement of Heath-Brown’s work; these results are used in Section 6. The reader may skip this section first and refer back later.
4.1 Local estimates of representations by quadratic forms
 Recall that 
 $(L,Q)$
 is an even quadratic lattice of signature
$(L,Q)$
 is an even quadratic lattice of signature 
 $(b,2)$
 with
$(b,2)$
 with 
 $b\geq 3$
, and L is maximal in
$b\geq 3$
, and L is maximal in 
 $V=L\otimes \mathbb {Q}$
. Let
$V=L\otimes \mathbb {Q}$
. Let 
 $r=b+2$
 denote the rank of L, and let
$r=b+2$
 denote the rank of L, and let 
 $\det (L)$
 denote the Gram determinant of L. Let p be a fixed prime, and let
$\det (L)$
 denote the Gram determinant of L. Let p be a fixed prime, and let 
 $\operatorname {\mathrm {val}}_p$
 denote the p-adic valuation. For integers
$\operatorname {\mathrm {val}}_p$
 denote the p-adic valuation. For integers 
 $m\in \mathbb {Z}$
 and
$m\in \mathbb {Z}$
 and 
 $n\in \mathbb {Z}_{\geq 0}$
, we define the set
$n\in \mathbb {Z}_{\geq 0}$
, we define the set 
 $\mathcal {N}_{m}(p^n)$
, its size
$\mathcal {N}_{m}(p^n)$
, its size 
 $N_{m}(p^n)$
 and the density
$N_{m}(p^n)$
 and the density 
 $\mu _{p}(m,n)$
 as follows:
$\mu _{p}(m,n)$
 as follows: 
 $$ \begin{align} \begin{array}{rcl} \displaystyle\mathcal{N}_{m}(p^n)&=&\displaystyle\{v\in L/p^{n}L \mid Q(v)\equiv m (\bmod p^n)\};\\[.1in] \displaystyle N_{m}(p^n)&=&\displaystyle |\mathcal{N}_{m}(p^n)|;\\[.1in] \displaystyle \mu_{p}(m,n)&=& \displaystyle p^{-n(r-1)}N_m(p^n). \end{array} \end{align} $$
$$ \begin{align} \begin{array}{rcl} \displaystyle\mathcal{N}_{m}(p^n)&=&\displaystyle\{v\in L/p^{n}L \mid Q(v)\equiv m (\bmod p^n)\};\\[.1in] \displaystyle N_{m}(p^n)&=&\displaystyle |\mathcal{N}_{m}(p^n)|;\\[.1in] \displaystyle \mu_{p}(m,n)&=& \displaystyle p^{-n(r-1)}N_m(p^n). \end{array} \end{align} $$
 The goal of this subsection is to study the variation of the quantity 
 $\mu _{p}(m,n)$
. Define the quantity
$\mu _{p}(m,n)$
. Define the quantity 
 $w_p(m):=1+\operatorname {\mathrm {val}}_p(m)$
 for
$w_p(m):=1+\operatorname {\mathrm {val}}_p(m)$
 for 
 $p\neq 2$
 and
$p\neq 2$
 and 
 $w_2(m):=1+2\operatorname {\mathrm {val}}_2(2m)$
. Then we prove the following result.
$w_2(m):=1+2\operatorname {\mathrm {val}}_2(2m)$
. Then we prove the following result.
Proposition 4.1. If m is an integer representable by Q over 
 $\mathbb {Z}$
, then we have
$\mathbb {Z}$
, then we have 
 $$ \begin{align*} \left|w_p(m)-\sum_{n=0}^{w_p(m)-1}\frac{\mu_{p}(m,n)}{\mu_{p}(m,w_p(m))}\right|\ll\frac{1}{p}, \end{align*} $$
$$ \begin{align*} \left|w_p(m)-\sum_{n=0}^{w_p(m)-1}\frac{\mu_{p}(m,n)}{\mu_{p}(m,w_p(m))}\right|\ll\frac{1}{p}, \end{align*} $$
where the implied constant is independent of p and m.
 We use an inductive method, due to Hanke [Reference HankeHan04], to compute the quantities 
 $\mu _{p}(m,n)$
. Let
$\mu _{p}(m,n)$
. Let 
 $L_{p}:=L\otimes \mathbb {Z}_p$
 be the completion of L at p. Since L is maximal in V, it follows that
$L_{p}:=L\otimes \mathbb {Z}_p$
 be the completion of L at p. Since L is maximal in V, it follows that 
 $L_p$
 is maximal in
$L_p$
 is maximal in 
 $V\otimes \mathbb {Q}_p$
. Indeed, L being maximal is equivalent to the fact that
$V\otimes \mathbb {Q}_p$
. Indeed, L being maximal is equivalent to the fact that 
 $L^\vee /L$
 has no totally isotropic subgroup; thus its p-torsion, which is equal to
$L^\vee /L$
 has no totally isotropic subgroup; thus its p-torsion, which is equal to 
 $L_p^\vee /L_p$
, has no totally isotropic subgroup implying that
$L_p^\vee /L_p$
, has no totally isotropic subgroup implying that 
 $L_p$
 is maximal. It is well known that the quadratic lattice
$L_p$
 is maximal. It is well known that the quadratic lattice 
 $(L_p,Q)$
 admits an orthogonal decomposition
$(L_p,Q)$
 admits an orthogonal decomposition 
 $$ \begin{align} (L_{p},Q)=\bigoplus_j (L_j,p^{\nu_j}Q_j) \end{align} $$
$$ \begin{align} (L_{p},Q)=\bigoplus_j (L_j,p^{\nu_j}Q_j) \end{align} $$
with 
 $\nu _j\geq 0$
, such that
$\nu _j\geq 0$
, such that 
 $(L_j,Q_j)$
 is a
$(L_j,Q_j)$
 is a 
 $\mathbb {Z}_p$
-unimodular quadratic lattice of dimension
$\mathbb {Z}_p$
-unimodular quadratic lattice of dimension 
 $1$
 or
$1$
 or 
 $2$
. (See, for example, [Reference HankeHan04, (2.3),Lemma 2.1].) Moreover, when
$2$
. (See, for example, [Reference HankeHan04, (2.3),Lemma 2.1].) Moreover, when 
 $p\neq 2$
, then every
$p\neq 2$
, then every 
 $L_j$
 is of dimension
$L_j$
 is of dimension 
 $1$
. For every
$1$
. For every 
 $v\in L_p$
, we write
$v\in L_p$
, we write 
 $v=(v_j)_j$
, and we have
$v=(v_j)_j$
, and we have 
 $$ \begin{align*}Q(v)=\sum_{j}p^{\nu_j}Q_j(v_j).\end{align*} $$
$$ \begin{align*}Q(v)=\sum_{j}p^{\nu_j}Q_j(v_j).\end{align*} $$
Note that since 
 $L_p$
 is maximal, we have
$L_p$
 is maximal, we have 
 $\nu _j\leq 1$
 for each j. For
$\nu _j\leq 1$
 for each j. For 
 $i\in \{0,1\}$
, let
$i\in \{0,1\}$
, let 
 $S_i$
 denote the set of indices j with
$S_i$
 denote the set of indices j with 
 $\nu _j=i$
, and let
$\nu _j=i$
, and let 
 $s_i$
 denote the size of
$s_i$
 denote the size of 
 $S_i$
.
$S_i$
.
 Following [Reference HankeHan04, Definition 3.1], for 
 $n\geq 1$
,
$n\geq 1$
, 
 $v\in \mathcal {N}_{m}(p^n)$
, we say that v is of
$v\in \mathcal {N}_{m}(p^n)$
, we say that v is of 
- 
1. zero type if  $v\equiv 0\ \pmod {p}$
, $v\equiv 0\ \pmod {p}$
,
- 
2. good type if there exists j such that  $v_j\not \equiv 0\ \pmod {p}$
 and $v_j\not \equiv 0\ \pmod {p}$
 and $\nu _j=0$
, or $\nu _j=0$
, or
- 
3. bad type otherwise. 
Let 
 $\mathcal {N}_{m}^{\textrm {good}}(p^n)$
,
$\mathcal {N}_{m}^{\textrm {good}}(p^n)$
, 
 $\mathcal {N}_{m}^{\textrm {bad}}(p^n)$
 and
$\mathcal {N}_{m}^{\textrm {bad}}(p^n)$
 and 
 $\mathcal {N}_{m}^{\textrm {zero}}(p^n)$
 be the set of good type, bad type and zero type solutions, respectively, and set
$\mathcal {N}_{m}^{\textrm {zero}}(p^n)$
 be the set of good type, bad type and zero type solutions, respectively, and set 
 $N_{m}^{?}(p^n)=|\mathcal {N}_{m}^{?}(p^n)|$
 and
$N_{m}^{?}(p^n)=|\mathcal {N}_{m}^{?}(p^n)|$
 and 
 $\mu _p^{?}(m,n)=p^{-n(r-1)}N_m^{?}(p^n)$
, for
$\mu _p^{?}(m,n)=p^{-n(r-1)}N_m^{?}(p^n)$
, for 
 $?=$
 good, bad, or zero. Note also from [Reference HankeHan04, Remark 3.4.1] that we have
$?=$
 good, bad, or zero. Note also from [Reference HankeHan04, Remark 3.4.1] that we have 
 $\mathcal {N}_m(p^n)=\mathcal {N}_m^{\mathrm {good}}(p^n)$
 when
$\mathcal {N}_m(p^n)=\mathcal {N}_m^{\mathrm {good}}(p^n)$
 when 
 $p\nmid m$
;
$p\nmid m$
; 
 $\mathcal {N}_m^{\mathrm {zero}}(p^n)=\emptyset $
 when
$\mathcal {N}_m^{\mathrm {zero}}(p^n)=\emptyset $
 when 
 $p^2\nmid m$
 and
$p^2\nmid m$
 and 
 $n\geq 2$
; and
$n\geq 2$
; and 
 $\mathcal {N}_m^{\mathrm {bad}}(p^n)=\emptyset $
 when
$\mathcal {N}_m^{\mathrm {bad}}(p^n)=\emptyset $
 when 
 $p\nmid 2\det (L)$
.
$p\nmid 2\det (L)$
.
 To state the inductive result on local densities, we need to introduce the auxiliary form 
 $Q'$
, where
$Q'$
, where 
 $Q'$
 is obtained from the orthogonal decomposition given by equation (4.2) of Q by replacing
$Q'$
 is obtained from the orthogonal decomposition given by equation (4.2) of Q by replacing 
 $\nu _j$
 with
$\nu _j$
 with 
 $\nu _j'=1-\nu _j$
 for all j. To distinguish between the local densities of Q and
$\nu _j'=1-\nu _j$
 for all j. To distinguish between the local densities of Q and 
 $Q'$
, we use
$Q'$
, we use 
 $N_{m,Q}^{?}(p^n)$
 and
$N_{m,Q}^{?}(p^n)$
 and 
 $\mu _{p,Q}^{?}(m,n)$
 to emphasis the dependence on the quadratic form. We now recall Hanke’s inductive method with the simplification that L is maximal (only used in (2)).
$\mu _{p,Q}^{?}(m,n)$
 to emphasis the dependence on the quadratic form. We now recall Hanke’s inductive method with the simplification that L is maximal (only used in (2)).
Lemma 4.2 (Hanke)
 Let 
 $n\in \mathbb {Z}_{>0}$
, and set
$n\in \mathbb {Z}_{>0}$
, and set 
 $\delta = 2 \operatorname {\mathrm {val}}_2(p)+1$
.
$\delta = 2 \operatorname {\mathrm {val}}_2(p)+1$
. 
- 
1. For  $n\geq \delta $
 and all integers m, we have $n\geq \delta $
 and all integers m, we have $$\begin{align*}N_m^{\mathrm{good}}(p^n)=p^{(n-\delta)(r-1)}N_m^{\mathrm{good}}(p^\delta); \quad \mu_{p}^{\mathrm{good}}(m,n)=\mu_{p}^{\mathrm{good}}(m,\delta).\end{align*}$$ $$\begin{align*}N_m^{\mathrm{good}}(p^n)=p^{(n-\delta)(r-1)}N_m^{\mathrm{good}}(p^\delta); \quad \mu_{p}^{\mathrm{good}}(m,n)=\mu_{p}^{\mathrm{good}}(m,\delta).\end{align*}$$
- 
2. For m such that  $p\mid m$
, we have $p\mid m$
, we have $$\begin{align*}N_{m,Q}^{\mathrm{bad}}(p^{n+1})=p^{r-s_0} N^{\mathrm{good}}_{\frac{m}{p}, Q'}(p^{n}); \quad \mu_{p,Q}^{\mathrm{bad}}(m,n+1)=p^{1-s_0}\mu_{p,Q'}^{\mathrm{good}}\left(\frac{m}{p},n\right).\end{align*}$$ $$\begin{align*}N_{m,Q}^{\mathrm{bad}}(p^{n+1})=p^{r-s_0} N^{\mathrm{good}}_{\frac{m}{p}, Q'}(p^{n}); \quad \mu_{p,Q}^{\mathrm{bad}}(m,n+1)=p^{1-s_0}\mu_{p,Q'}^{\mathrm{good}}\left(\frac{m}{p},n\right).\end{align*}$$
- 
3. For m such that  $p^2\mid m$
, we have $p^2\mid m$
, we have $$\begin{align*}N_m^{\mathrm{zero}}(p^{n+2})=p^rN_{\frac{m}{p^2}}(p^n); \quad \mu_{p}^{\mathrm{zero}}(m,n+2)=p^{2-r}\mu_{p}\left(\frac{m}{p^2},n\right).\end{align*}$$ $$\begin{align*}N_m^{\mathrm{zero}}(p^{n+2})=p^rN_{\frac{m}{p^2}}(p^n); \quad \mu_{p}^{\mathrm{zero}}(m,n+2)=p^{2-r}\mu_{p}\left(\frac{m}{p^2},n\right).\end{align*}$$
Proof. All the assertions on 
 $\mu _p$
 follow from the assertions on
$\mu _p$
 follow from the assertions on 
 $N_m$
 by definition. The first assertion of the lemma is [Reference HankeHan04, Lemma 3.2]. The third assertion follows from the last two paragraphs in [Reference HankeHan04, p.359]. To recover the second assertion, note that since
$N_m$
 by definition. The first assertion of the lemma is [Reference HankeHan04, Lemma 3.2]. The third assertion follows from the last two paragraphs in [Reference HankeHan04, p.359]. To recover the second assertion, note that since 
 $L_p$
 is maximal, we have
$L_p$
 is maximal, we have 
 $\nu _j\leq 1$
 for all j. Hence Bad-type II points (see [Reference HankeHan04, p.360]) do not exist. Thus, the claim follows from the discussion on Bad-type I points in [Reference HankeHan04, p.359].
$\nu _j\leq 1$
 for all j. Hence Bad-type II points (see [Reference HankeHan04, p.360]) do not exist. Thus, the claim follows from the discussion on Bad-type I points in [Reference HankeHan04, p.359].
Corollary 4.3. For 
 $p\neq 2$
, set
$p\neq 2$
, set 
 $\delta _{p,\det (L)}=1$
 if
$\delta _{p,\det (L)}=1$
 if 
 $p\mid \det (L)$
 and
$p\mid \det (L)$
 and 
 $0$
 otherwise.Footnote 18 Recall the quadratic form
$0$
 otherwise.Footnote 18 Recall the quadratic form 
 $Q'$
 and the integer
$Q'$
 and the integer 
 $s_0$
 defined above. We have
$s_0$
 defined above. We have 
- 
1. If  $n\geq \operatorname {\mathrm {val}}_p(m)+1$
, then $n\geq \operatorname {\mathrm {val}}_p(m)+1$
, then $\mu _{p,Q}(m,n)$
 is equal to $\mu _{p,Q}(m,n)$
 is equal to $$\begin{align*}\sum_{u=0}^{\lfloor \frac{\operatorname{\mathrm{val}}_p(m)}{2}\rfloor} p^{(2-r)u}\mu^{\mathrm{good}}_{p,Q}\left(\frac{m}{p^{2u}},1\right)+\delta_{p,\det(L)}p^{1-s_0}\sum_{u=0}^{\lfloor \frac{\operatorname{\mathrm{val}}_p(m)-1}{2}\rfloor}p^{(2-r)u}\mu^{\mathrm{good}}_{p,Q'}\left(\frac{m}{p^{2u+1}},1\right).\end{align*}$$ $$\begin{align*}\sum_{u=0}^{\lfloor \frac{\operatorname{\mathrm{val}}_p(m)}{2}\rfloor} p^{(2-r)u}\mu^{\mathrm{good}}_{p,Q}\left(\frac{m}{p^{2u}},1\right)+\delta_{p,\det(L)}p^{1-s_0}\sum_{u=0}^{\lfloor \frac{\operatorname{\mathrm{val}}_p(m)-1}{2}\rfloor}p^{(2-r)u}\mu^{\mathrm{good}}_{p,Q'}\left(\frac{m}{p^{2u+1}},1\right).\end{align*}$$
- 
2. If  $1\leq n \leq \operatorname {\mathrm {val}}_p(m)$
 and n odd, then $1\leq n \leq \operatorname {\mathrm {val}}_p(m)$
 and n odd, then $\mu _{p,Q}(m,n)$
 is equal to $\mu _{p,Q}(m,n)$
 is equal to $$\begin{align*}p^{\frac{(2-r)(n-1)}{2}}\mu_{p,Q}(mp^{1-n},1)+\sum_{u=0}^{\frac{n-3}{2}} p^{(2-r)u}\mu^{\mathrm{good}}_{p,Q}\left(\frac{m}{p^{2u}},1\right)+\delta_{p,\det(L)}p^{1-s_0}\sum_{u=0}^{\frac{n-3}{2}}p^{(2-r)u}\mu^{\mathrm{good}}_{p,Q'}\left(\frac{m}{p^{2u+1}},1\right).\end{align*}$$ $$\begin{align*}p^{\frac{(2-r)(n-1)}{2}}\mu_{p,Q}(mp^{1-n},1)+\sum_{u=0}^{\frac{n-3}{2}} p^{(2-r)u}\mu^{\mathrm{good}}_{p,Q}\left(\frac{m}{p^{2u}},1\right)+\delta_{p,\det(L)}p^{1-s_0}\sum_{u=0}^{\frac{n-3}{2}}p^{(2-r)u}\mu^{\mathrm{good}}_{p,Q'}\left(\frac{m}{p^{2u+1}},1\right).\end{align*}$$
- 
3. If  $1\leq n \leq \operatorname {\mathrm {val}}_p(m)$
 and n even, then $1\leq n \leq \operatorname {\mathrm {val}}_p(m)$
 and n even, then $\mu _{p,Q}(m,n)$
 is equal to $\mu _{p,Q}(m,n)$
 is equal to $$\begin{align*}p^{\frac{(2-r)(n-2)}{2}}\mu^{\mathrm{zero}}_{p,Q}(mp^{2-n},2)+\sum_{u=0}^{\frac{n-2}{2}} p^{(2-r)u}\mu^{\mathrm{good}}_{p,Q}\left(\frac{m}{p^{2u}},1\right)+\delta_{p,\det(L)}p^{1-s_0}\sum_{u=0}^{\frac{n-2}{2}}p^{(2-r)u}\mu^{\mathrm{good}}_{p,Q'}\left(\frac{m}{p^{2u+1}},1\right).\end{align*}$$ $$\begin{align*}p^{\frac{(2-r)(n-2)}{2}}\mu^{\mathrm{zero}}_{p,Q}(mp^{2-n},2)+\sum_{u=0}^{\frac{n-2}{2}} p^{(2-r)u}\mu^{\mathrm{good}}_{p,Q}\left(\frac{m}{p^{2u}},1\right)+\delta_{p,\det(L)}p^{1-s_0}\sum_{u=0}^{\frac{n-2}{2}}p^{(2-r)u}\mu^{\mathrm{good}}_{p,Q'}\left(\frac{m}{p^{2u+1}},1\right).\end{align*}$$
Proof. The base cases when 
 $\operatorname {\mathrm {val}}_p(m)\leq 1$
 or
$\operatorname {\mathrm {val}}_p(m)\leq 1$
 or 
 $n\leq 2$
 can be checked directly by definition and Lemma 4.2. For
$n\leq 2$
 can be checked directly by definition and Lemma 4.2. For 
 $n>2$
 and
$n>2$
 and 
 $p^2\mid m$
, by Lemma 4.2,
$p^2\mid m$
, by Lemma 4.2, 
 $$ \begin{align*} \mu_{p,Q}(m,n) & = \mu_{p,Q}^{\mathrm{good}}(m,n)+\mu_{p,Q}^{\mathrm{zero}}(m,n)+\mu_{p,Q}^{\mathrm{bad}}(m,n)\\ &= \mu_{p,Q}^{\mathrm{good}}(m,1)+p^{2-r}\mu_{p,Q}\left(\frac{m}{p^2},n-2\right)+p^{1-s_0}\mu^{\mathrm{good}}_{p,Q'}\left(\frac{m}{p},n-1\right)\\ &=\mu_{p,Q}^{\mathrm{good}}(m,1)+p^{2-r}\mu_{p,Q}\left(\frac{m}{p^2},n-2\right)+p^{1-s_0}\mu^{\mathrm{good}}_{p,Q'}\left(\frac{m}{p},1\right). \end{align*} $$
$$ \begin{align*} \mu_{p,Q}(m,n) & = \mu_{p,Q}^{\mathrm{good}}(m,n)+\mu_{p,Q}^{\mathrm{zero}}(m,n)+\mu_{p,Q}^{\mathrm{bad}}(m,n)\\ &= \mu_{p,Q}^{\mathrm{good}}(m,1)+p^{2-r}\mu_{p,Q}\left(\frac{m}{p^2},n-2\right)+p^{1-s_0}\mu^{\mathrm{good}}_{p,Q'}\left(\frac{m}{p},n-1\right)\\ &=\mu_{p,Q}^{\mathrm{good}}(m,1)+p^{2-r}\mu_{p,Q}\left(\frac{m}{p^2},n-2\right)+p^{1-s_0}\mu^{\mathrm{good}}_{p,Q'}\left(\frac{m}{p},1\right). \end{align*} $$
Then we conclude by induction on 
 $\operatorname {\mathrm {val}}_p(m)$
 and n.
$\operatorname {\mathrm {val}}_p(m)$
 and n.
 The next lemma gives a uniform bound on 
 $|\mu _{p}(m,n)-\mu _p(m,w_p(m))|$
 for primes p, integers m and
$|\mu _{p}(m,n)-\mu _p(m,w_p(m))|$
 for primes p, integers m and 
 $n\in \{2,\ldots ,w_p(m)-1\}$
.
$n\in \{2,\ldots ,w_p(m)-1\}$
.
Lemma 4.4. Let p be prime and m be any integer. For 
 $n\in \{2+\operatorname {\mathrm {val}}_2(p),\ldots ,w_p(m)-1\}$
, we have
$n\in \{2+\operatorname {\mathrm {val}}_2(p),\ldots ,w_p(m)-1\}$
, we have 
 $$\begin{align*}|\mu_{p}(m,n)-\mu_p(m,w_p(m))|\ll \frac{1}{p^{3\lfloor(n/2)\rfloor-2}},\end{align*}$$
$$\begin{align*}|\mu_{p}(m,n)-\mu_p(m,w_p(m))|\ll \frac{1}{p^{3\lfloor(n/2)\rfloor-2}},\end{align*}$$
where the implied constant is absolute.
Proof. First consider the case when p is odd. By Corollary 4.3, we have that for n odd,
 $$ \begin{align*} |\mu_{p}(m,n)-\mu_p(m,w_p(m))| &\leq \displaystyle\left|\frac{\mu_{p,Q}\left(\frac{m}{p^{n-1}},1\right)}{p^{\frac{(r-2)(n-1)}{2}}}\right|\\ &\quad +\displaystyle \left|\sum_{u=\frac{(n-1)}{2}}^{\lfloor \frac{\operatorname{\mathrm{val}}_p(m)}{2}\rfloor} \frac{\mu^{\mathrm{good}}_{p,Q}\left(\frac{m}{p^{2u}},1\right)+\delta_{p,\det(L)}p^{1-s_0}\mu^{\mathrm{good}}_{p,Q'}\left(\frac{m}{p^{2u+1}},1\right)}{p^{(r-2)u}}\right|\\ &\leq \displaystyle\left| \frac{p}{p^{\frac{3(n-1)}{2}}}\right| +\sum_{u=\frac{(n-1)}{2}}^{\lfloor \frac{\operatorname{\mathrm{val}}_p(m)}{2}\rfloor}\left| \frac{p+p^2}{p^{3u}}\right|\\ &\leq \displaystyle\frac{C_1 p^2}{p^{\frac{3(n-1)}{2}}}. \end{align*} $$
$$ \begin{align*} |\mu_{p}(m,n)-\mu_p(m,w_p(m))| &\leq \displaystyle\left|\frac{\mu_{p,Q}\left(\frac{m}{p^{n-1}},1\right)}{p^{\frac{(r-2)(n-1)}{2}}}\right|\\ &\quad +\displaystyle \left|\sum_{u=\frac{(n-1)}{2}}^{\lfloor \frac{\operatorname{\mathrm{val}}_p(m)}{2}\rfloor} \frac{\mu^{\mathrm{good}}_{p,Q}\left(\frac{m}{p^{2u}},1\right)+\delta_{p,\det(L)}p^{1-s_0}\mu^{\mathrm{good}}_{p,Q'}\left(\frac{m}{p^{2u+1}},1\right)}{p^{(r-2)u}}\right|\\ &\leq \displaystyle\left| \frac{p}{p^{\frac{3(n-1)}{2}}}\right| +\sum_{u=\frac{(n-1)}{2}}^{\lfloor \frac{\operatorname{\mathrm{val}}_p(m)}{2}\rfloor}\left| \frac{p+p^2}{p^{3u}}\right|\\ &\leq \displaystyle\frac{C_1 p^2}{p^{\frac{3(n-1)}{2}}}. \end{align*} $$
Here we use the trivial bound that all 
 $|\mu _{p,Q}\left (\frac {m}{p^{n-1}},1\right )|, |\mu ^{\mathrm {good}}_{p,Q}\left (\frac {m}{p^{2u}},1\right )|, |\mu ^{\mathrm {good}}_{p,Q'}\left (\frac {m}{p^{2u+1}},1\right )|$
 are less than p by definition. The case when n is even follows by a similar argument and the trivial bound that
$|\mu _{p,Q}\left (\frac {m}{p^{n-1}},1\right )|, |\mu ^{\mathrm {good}}_{p,Q}\left (\frac {m}{p^{2u}},1\right )|, |\mu ^{\mathrm {good}}_{p,Q'}\left (\frac {m}{p^{2u+1}},1\right )|$
 are less than p by definition. The case when n is even follows by a similar argument and the trivial bound that 
 $\mu ^{\mathrm {zero}}_{p,Q}(mp^{2-n},2)\leq p^r/p^{2(r-1)}=p^{2-r}$
.
$\mu ^{\mathrm {zero}}_{p,Q}(mp^{2-n},2)\leq p^r/p^{2(r-1)}=p^{2-r}$
.
 For 
 $p=2$
, by Lemma 4.2, we obtain analogous statements as Corollary 4.3, except that we can only reduce to
$p=2$
, by Lemma 4.2, we obtain analogous statements as Corollary 4.3, except that we can only reduce to 
 $\mu ^{\mathrm {good}}_{p}(?,3)$
 (instead of
$\mu ^{\mathrm {good}}_{p}(?,3)$
 (instead of 
 $\mu ^{\mathrm {good}}_{p}(?,1)$
). The rest of the argument is the same as in Lemma 4.4, and since
$\mu ^{\mathrm {good}}_{p}(?,1)$
). The rest of the argument is the same as in Lemma 4.4, and since 
 $p=2$
 is fixed, any trivial bound on density is absorbed in the absolute constant.
$p=2$
 is fixed, any trivial bound on density is absorbed in the absolute constant.
 We can actually show that all 
 $\mu _{p}(m,n)$
 are close to
$\mu _{p}(m,n)$
 are close to 
 $1$
 when
$1$
 when 
 $p\nmid 2\det (L)$
.
$p\nmid 2\det (L)$
.
Lemma 4.5. There exists an absolute constant 
 $C_2>0$
 such that for all
$C_2>0$
 such that for all 
 $m,n\in \mathbb {Z}_{>0}$
, all primes
$m,n\in \mathbb {Z}_{>0}$
, all primes 
 $p\nmid 2\det (L)$
, we have
$p\nmid 2\det (L)$
, we have 
 $$\begin{align*}|\mu_{p}(m,n)-1|\leq \frac{C_2}{p}.\end{align*}$$
$$\begin{align*}|\mu_{p}(m,n)-1|\leq \frac{C_2}{p}.\end{align*}$$
Proof. By Corollary 4.3(1), Lemma 4.4, we only need to show the claim for 
 $n=1$
 and
$n=1$
 and 
 $n=\operatorname {\mathrm {val}}_p(m)+1$
. For
$n=\operatorname {\mathrm {val}}_p(m)+1$
. For 
 $n=1$
, we first consider the case when
$n=1$
, we first consider the case when 
 $p\mid m$
. Then
$p\mid m$
. Then 
 $Q(v)\equiv 0\bmod p$
 defines a smooth projective hypersurface in
$Q(v)\equiv 0\bmod p$
 defines a smooth projective hypersurface in 
 $\mathbb {P}^{r-1}$
; except the solution
$\mathbb {P}^{r-1}$
; except the solution 
 $v=0 \bmod p$
, every
$v=0 \bmod p$
, every 
 $p-1$
 solutions of
$p-1$
 solutions of 
 $Q(v)\equiv 0 \bmod p$
 (all these are of good type) correspond to a
$Q(v)\equiv 0 \bmod p$
 (all these are of good type) correspond to a 
 $\mathbb {F}_p$
-point in the hypersurface. Then by the Weil bound (see, for instance, [Reference DeligneDel74, Théorème 8.1]),Footnote 19 there exists a constant
$\mathbb {F}_p$
-point in the hypersurface. Then by the Weil bound (see, for instance, [Reference DeligneDel74, Théorème 8.1]),Footnote 19 there exists a constant 
 $C_3>0$
 independent of p and m such that
$C_3>0$
 independent of p and m such that 
 $$ \begin{align*} |N_{m}^{\mathrm{good}}(p)-p^{r-1}|\leq C_3 p^{r-2}. \end{align*} $$
$$ \begin{align*} |N_{m}^{\mathrm{good}}(p)-p^{r-1}|\leq C_3 p^{r-2}. \end{align*} $$
Therefore, 
 $|\mu _{p}^{\mathrm {good}}(m,1)-1|\leq C_3/p$
.
$|\mu _{p}^{\mathrm {good}}(m,1)-1|\leq C_3/p$
.
 For 
 $p\nmid m$
, we consider the smooth projective hypersurface in
$p\nmid m$
, we consider the smooth projective hypersurface in 
 $\mathbb {P}^r$
 defined by
$\mathbb {P}^r$
 defined by 
 $Q(v)=my^2$
. In this case,
$Q(v)=my^2$
. In this case, 
 $N_m(p)=N^{\mathrm {good}}_m(p)$
 is the number of
$N_m(p)=N^{\mathrm {good}}_m(p)$
 is the number of 
 $\mathbb {F}_p$
-points in the hypersurface such that
$\mathbb {F}_p$
-points in the hypersurface such that 
 $y\neq 0$
 in
$y\neq 0$
 in 
 $\mathbb {F}_p$
. By the Weil bound, the number of
$\mathbb {F}_p$
. By the Weil bound, the number of 
 $\mathbb {F}_p$
-points in the hypersurface is
$\mathbb {F}_p$
-points in the hypersurface is 
 $p^{r-1}+O_m(p^{r-2})$
; the number of
$p^{r-1}+O_m(p^{r-2})$
; the number of 
 $y=0$
 points on the hypersurface is
$y=0$
 points on the hypersurface is 
 $p^{r-2}+O(p^{r-3})$
 by the Weil bound. Then we conclude that there exists a constant
$p^{r-2}+O(p^{r-3})$
 by the Weil bound. Then we conclude that there exists a constant 
 $C_4>0$
 independentFootnote 20 of p and m such that
$C_4>0$
 independentFootnote 20 of p and m such that 
 $|\mu _{p}^{\mathrm {good}}(m,1)-1|\leq C_4/p$
. In particular, for any m, we have
$|\mu _{p}^{\mathrm {good}}(m,1)-1|\leq C_4/p$
. In particular, for any m, we have 
 $$ \begin{align*}\mu_p^{\mathrm{good}}(m,1)\leq 1+\max\{C_3,C_4\}.\end{align*} $$
$$ \begin{align*}\mu_p^{\mathrm{good}}(m,1)\leq 1+\max\{C_3,C_4\}.\end{align*} $$
 For 
 $n=\operatorname {\mathrm {val}}_p(m)+1$
 and
$n=\operatorname {\mathrm {val}}_p(m)+1$
 and 
 $p|m$
, by Corollary 4.3(1), and note that
$p|m$
, by Corollary 4.3(1), and note that 
 $\delta _{p,\det (L)}=0$
, we have
$\delta _{p,\det (L)}=0$
, we have 
 $$ \begin{align*} |\mu_{p}(m,\operatorname{\mathrm{val}}_p(m)+1)-1|&=\left|\mu_p^{\mathrm{good}}(m,1)-1+\sum_{u=1}^{ \left\lfloor {\frac{\operatorname{\mathrm{val}}_p(m)}{2}} \right\rfloor }\frac{\mu_{p}^{\mathrm{good}}(\frac{m}{p^{2u}},1)}{p^{u(r-2)}}\right|\\ &\leq \frac{C_3}{p}+\sum_{u=1}^{ \left\lfloor {\frac{\operatorname{\mathrm{val}}_p(m)}{2}} \right\rfloor }\frac{\max\{C_3,C_4\}+1}{p^{u(r-2)}} \leq \frac{C_5}{p}, \end{align*} $$
$$ \begin{align*} |\mu_{p}(m,\operatorname{\mathrm{val}}_p(m)+1)-1|&=\left|\mu_p^{\mathrm{good}}(m,1)-1+\sum_{u=1}^{ \left\lfloor {\frac{\operatorname{\mathrm{val}}_p(m)}{2}} \right\rfloor }\frac{\mu_{p}^{\mathrm{good}}(\frac{m}{p^{2u}},1)}{p^{u(r-2)}}\right|\\ &\leq \frac{C_3}{p}+\sum_{u=1}^{ \left\lfloor {\frac{\operatorname{\mathrm{val}}_p(m)}{2}} \right\rfloor }\frac{\max\{C_3,C_4\}+1}{p^{u(r-2)}} \leq \frac{C_5}{p}, \end{align*} $$
where we take 
 $C_2=\max \{C_3,C_4,C_5\}$
.
$C_2=\max \{C_3,C_4,C_5\}$
.
 Due to our assumptions that 
 $r\geq 5$
 and L maximal, there is an absolute lower bound for
$r\geq 5$
 and L maximal, there is an absolute lower bound for 
 $\mu _{p}(m,n)$
. The following lemma is well known, but we include it for the convenience of the reader.
$\mu _{p}(m,n)$
. The following lemma is well known, but we include it for the convenience of the reader.
Lemma 4.6. Recall that 
 $r\geq 5$
 and L is maximal. Then for any
$r\geq 5$
 and L is maximal. Then for any 
 $m,n\in \mathbb {Z}_{>0}$
, any prime p, we have
$m,n\in \mathbb {Z}_{>0}$
, any prime p, we have 
 $\mu _{p}(m,n)\geq 1/2$
.
$\mu _{p}(m,n)\geq 1/2$
.
Proof. Since 
 $r\geq 5$
 and L is maximal, then by, for instance, [Reference GersteinGer08, Lemma 6.36], for every prime p, there exists a basis of
$r\geq 5$
 and L is maximal, then by, for instance, [Reference GersteinGer08, Lemma 6.36], for every prime p, there exists a basis of 
 $L_p$
 such that in the coordinate of this basis,
$L_p$
 such that in the coordinate of this basis, 
 $Q((x_1,\dots ,x_r))=x_1x_2+Q_1((x_3,\dots ,x_r))$
, where
$Q((x_1,\dots ,x_r))=x_1x_2+Q_1((x_3,\dots ,x_r))$
, where 
 $Q_1$
 is a quadratic form in
$Q_1$
 is a quadratic form in 
 $(r-2)$
 variables.
$(r-2)$
 variables.
 Recall as in Lemma 4.2 that 
 $\delta =3$
 if
$\delta =3$
 if 
 $p=2$
 and
$p=2$
 and 
 $\delta =1$
 otherwise. Fix an integer
$\delta =1$
 otherwise. Fix an integer 
 $\delta '$
 satisfying
$\delta '$
 satisfying 
 $1\leq \delta '\leq \delta $
. For any
$1\leq \delta '\leq \delta $
. For any 
 $x_1\in (\mathbb {Z}/p^{\delta '})^\times $
 and any
$x_1\in (\mathbb {Z}/p^{\delta '})^\times $
 and any 
 $x_i\in \mathbb {Z}/p^{\delta '}, 3\leq i \leq r$
, there exists a unique
$x_i\in \mathbb {Z}/p^{\delta '}, 3\leq i \leq r$
, there exists a unique 
 $x_2\in \mathbb {Z}/p^{\delta '}$
 such that
$x_2\in \mathbb {Z}/p^{\delta '}$
 such that 
 $Q(x_1,\dots ,x_r))=m\bmod p^{\delta '}$
. Therefore,
$Q(x_1,\dots ,x_r))=m\bmod p^{\delta '}$
. Therefore, 
 $\mu ^{\mathrm {good}}_{p}(m,\delta ')\geq \frac {p-1}{p}\geq 1/2$
, and hence by Lemma 4.2(1), for
$\mu ^{\mathrm {good}}_{p}(m,\delta ')\geq \frac {p-1}{p}\geq 1/2$
, and hence by Lemma 4.2(1), for 
 $n\geq \delta $
,
$n\geq \delta $
, 
 $\mu _{p}(m,n)\geq \mu ^{\mathrm {good}}_p(m,\delta )\geq 1/2$
.
$\mu _{p}(m,n)\geq \mu ^{\mathrm {good}}_p(m,\delta )\geq 1/2$
.
Corollary 4.7. Every large enough 
 $m\in \mathbb {Z}_{>0}$
 is representable by
$m\in \mathbb {Z}_{>0}$
 is representable by 
 $(L,Q)$
.
$(L,Q)$
.
Proof. By [Reference Heath-BrownHB96, Theorem 4] (recalled in Theorem 4.9 below, from which we borrow the notations), we can choose a non-negative test function 
 $\omega $
 such that
$\omega $
 such that 
 $\mu _\infty (Q,\omega )>0$
. Then by the Proposition above,
$\mu _\infty (Q,\omega )>0$
. Then by the Proposition above, 
 $\mu (Q,m)>0$
, and hence
$\mu (Q,m)>0$
, and hence 
 $N(Q,m,\omega )$
 is positive for m large enough. Hence m is representable by
$N(Q,m,\omega )$
 is positive for m large enough. Hence m is representable by 
 $(L,Q)$
.
$(L,Q)$
.
Now we are ready to prove the main result of this subsection.
Proof of Proposition 4.1
 For simplicity of notation, we denote 
 $w_p(m)$
 by
$w_p(m)$
 by 
 $w_p$
.
$w_p$
.
 
First case: assume that 
 $p\nmid 2\det (L)$
. By Lemma 4.5,
$p\nmid 2\det (L)$
. By Lemma 4.5, 
 $$ \begin{align} |\mu_{p}(m,w_p)-\mu_{p}(m,1)|\leq |\mu_{p}(m,w_p)-1|+|\mu_{p}(m,1)-1|\leq C_7/p. \end{align} $$
$$ \begin{align} |\mu_{p}(m,w_p)-\mu_{p}(m,1)|\leq |\mu_{p}(m,w_p)-1|+|\mu_{p}(m,1)-1|\leq C_7/p. \end{align} $$
Note that 
 $\mu _{p}(m,0)=1$
 by definition; see 4.1. Then by Lemmas 4.4,4.5 and equation (4.3), we get
$\mu _{p}(m,0)=1$
 by definition; see 4.1. Then by Lemmas 4.4,4.5 and equation (4.3), we get 
 $$ \begin{align*} \left|w_p-\sum_{n=0}^{w_p-1}\frac{\mu_{p}(m,n)}{\mu_{p}(m,w_p)}\right|&\leq\frac{1}{\mu_{p}(m,w_p)}\left[\sum_{n\geq 2}\frac{C_1 p^2}{p^{3\lfloor n/2\rfloor}}+\frac{C_7}{p}+\frac{C_2}{p}\right] \leq \frac{C_8}{\mu_{p}(m,w_p)p}. \end{align*} $$
$$ \begin{align*} \left|w_p-\sum_{n=0}^{w_p-1}\frac{\mu_{p}(m,n)}{\mu_{p}(m,w_p)}\right|&\leq\frac{1}{\mu_{p}(m,w_p)}\left[\sum_{n\geq 2}\frac{C_1 p^2}{p^{3\lfloor n/2\rfloor}}+\frac{C_7}{p}+\frac{C_2}{p}\right] \leq \frac{C_8}{\mu_{p}(m,w_p)p}. \end{align*} $$
We conclude by the fact that 
 $\mu _{p}(m,w_p)$
 is uniformly bounded away from
$\mu _{p}(m,w_p)$
 is uniformly bounded away from 
 $0$
 by Lemma 4.6.
$0$
 by Lemma 4.6.
 
Second case: assume now that 
 $p\mid 2\det (L)$
. By Lemma 4.4, for any
$p\mid 2\det (L)$
. By Lemma 4.4, for any 
 $n\geq 3$
,
$n\geq 3$
, 
 $$ \begin{align} |\mu_{p}(m,w_p)-\mu_{p}(m,n)|\leq \frac{C_9p^2}{p^{3\lfloor n/2\rfloor}}. \end{align} $$
$$ \begin{align} |\mu_{p}(m,w_p)-\mu_{p}(m,n)|\leq \frac{C_9p^2}{p^{3\lfloor n/2\rfloor}}. \end{align} $$
Then, as in the first case, we have
 $$\begin{align*}\left|\sum_{n=3}^{w_p-1}\frac{\mu_{p}(m,w_p)-\mu_{p}(m,n)}{\mu_{p}(m,w_p)}\right|\leq \frac{C_{10}}{p}.\end{align*}$$
$$\begin{align*}\left|\sum_{n=3}^{w_p-1}\frac{\mu_{p}(m,w_p)-\mu_{p}(m,n)}{\mu_{p}(m,w_p)}\right|\leq \frac{C_{10}}{p}.\end{align*}$$
On the other hand, for 
 $0\leq n\leq 2$
, we have for all
$0\leq n\leq 2$
, we have for all 
 $p\mid 2\det (L)$
$p\mid 2\det (L)$
 
 $$\begin{align*}|\mu_{p}(m,w_p)-\mu_{p}(m,n)|\leq |\mu_{p}(m,w_p)-\mu_{p}(m,3)|+|\mu_{p}(m,3)-\mu_{p}(m,n)|\leq C_{11}/p\end{align*}$$
$$\begin{align*}|\mu_{p}(m,w_p)-\mu_{p}(m,n)|\leq |\mu_{p}(m,w_p)-\mu_{p}(m,3)|+|\mu_{p}(m,3)-\mu_{p}(m,n)|\leq C_{11}/p\end{align*}$$
by equation (4.4) and the trivial bound 
 $|\mu _{p}(m,n)|,|\mu _{p}(m,3)|\leq p^3\leq (2\det (L))^3$
. Then we conclude as in the first case.
$|\mu _{p}(m,n)|,|\mu _{p}(m,3)|\leq p^3\leq (2\det (L))^3$
. Then we conclude as in the first case.
4.2 On the number of representations of quadratic forms
Developing a new form of the circle method, Heath-Brown [Reference Heath-BrownHB96] proves a number of results pertaining to the representation of integers by quadratic forms. The purpose of this subsection is to describe the setup used in [Reference Heath-BrownHB96] and recall those results necessary for us in the sequel. We do not entirely keep the notations of [Reference Heath-BrownHB96] since we will only be concerned with homogeneous quadratic forms, which allows us to make certain simplifications in the notation.
 Let 
 $F(\mathbf {x})=F(x_1,\ldots ,x_n)$
 be an integral quadratic form with nonzero discriminant in
$F(\mathbf {x})=F(x_1,\ldots ,x_n)$
 be an integral quadratic form with nonzero discriminant in 
 $n\geq 5$
 variables. A function
$n\geq 5$
 variables. A function 
 $\omega :\mathbb {R}^n\to \mathbb {C}$
 is said to be a smooth weight function if it is infinitely differentiable of compact support. Given a set S of parameters (see [Reference Heath-BrownHB96, Page 6] for what the parameters are allowed to be), Heath-Brown defines a set of weight functions
$\omega :\mathbb {R}^n\to \mathbb {C}$
 is said to be a smooth weight function if it is infinitely differentiable of compact support. Given a set S of parameters (see [Reference Heath-BrownHB96, Page 6] for what the parameters are allowed to be), Heath-Brown defines a set of weight functions 
 $\mathcal {C}(S)$
 in [Reference Heath-BrownHB96, §2].
$\mathcal {C}(S)$
 in [Reference Heath-BrownHB96, §2].
Remark 4.8. The following facts about weight functions will be used later (see, for instance, the observations of [Reference Heath-BrownHB96, p. 162]):
- 
1. There exists a function  $\omega ^{(n)}_0(\mathbf {x}):\mathbb {R}^n\rightarrow [0,2]$
, with compact support in $\omega ^{(n)}_0(\mathbf {x}):\mathbb {R}^n\rightarrow [0,2]$
, with compact support in $[-1,1]^n$
, which belongs to $[-1,1]^n$
, which belongs to $\mathcal {C}(n)$
 such that $\mathcal {C}(n)$
 such that $\omega ^{(n)}_0(\mathbf {x})\geq 2$
 for $\omega ^{(n)}_0(\mathbf {x})\geq 2$
 for $x\in [-1/2,1/2]^n$
 (for instance, by rescaling the function defined by [Reference Heath-BrownHB96, (2.1),(2.2)]). $x\in [-1/2,1/2]^n$
 (for instance, by rescaling the function defined by [Reference Heath-BrownHB96, (2.1),(2.2)]).
- 
2. Let M be an invertible  $n\times n$
 matrix, such that the coefficients of both M and $n\times n$
 matrix, such that the coefficients of both M and $M^{-1}$
 are bounded in absolute value by K. If $M^{-1}$
 are bounded in absolute value by K. If $\omega $
 is a weight function belonging to $\omega $
 is a weight function belonging to $\mathcal {C}(S)$
, then $\mathcal {C}(S)$
, then $\omega (Mx)$
 belongs to $\omega (Mx)$
 belongs to $\mathcal {C}(S,K)$
. $\mathcal {C}(S,K)$
.
 The reason for introducing the set 
 $\mathcal {C}(S)$
 is the following. For the quadratic form F fixed as above, an integer
$\mathcal {C}(S)$
 is the following. For the quadratic form F fixed as above, an integer 
 $m\neq 0$
 and a weight function
$m\neq 0$
 and a weight function 
 $\omega \in \mathcal {C}(S)$
 for some set of parameters S, we define
$\omega \in \mathcal {C}(S)$
 for some set of parameters S, we define 
 $$ \begin{align*} N(F,m,\omega):=\sum_{\substack{\mathbf{x}\in\mathbb{Z}^n\\F(\mathbf{x})=m}}\omega\Bigl(\frac{\mathbf{x}}{\sqrt{m}}\Bigr). \end{align*} $$
$$ \begin{align*} N(F,m,\omega):=\sum_{\substack{\mathbf{x}\in\mathbb{Z}^n\\F(\mathbf{x})=m}}\omega\Bigl(\frac{\mathbf{x}}{\sqrt{m}}\Bigr). \end{align*} $$
The quantity 
 $N(F,m,\omega )$
 then is a weighted sum of representations of m by F, where the coordinates of these representations are bounded by
$N(F,m,\omega )$
 then is a weighted sum of representations of m by F, where the coordinates of these representations are bounded by 
 $O_S(\sqrt {m})$
 since
$O_S(\sqrt {m})$
 since 
 $\omega $
 has compact support. Then [Reference Heath-BrownHB96] gives asymptotics for the size of
$\omega $
 has compact support. Then [Reference Heath-BrownHB96] gives asymptotics for the size of 
 $N(F,m,\omega )$
, where the error term only depends on S.
$N(F,m,\omega )$
, where the error term only depends on S.
More precisely, define the singular integral byFootnote 21
 $$ \begin{align*} \mu_\infty(F,\omega):=\lim_{\epsilon\to 0}\frac{1}{2\epsilon}\int_{|F(\mathbf{x})-1|\leq\epsilon}\omega(\mathbf{x})d\mathbf{x}. \end{align*} $$
$$ \begin{align*} \mu_\infty(F,\omega):=\lim_{\epsilon\to 0}\frac{1}{2\epsilon}\int_{|F(\mathbf{x})-1|\leq\epsilon}\omega(\mathbf{x})d\mathbf{x}. \end{align*} $$
Recall the Siegel mass at p of the quadratic form F given byFootnote 22
 $$ \begin{align*} \mu_p(F,m):=\lim_{k\to\infty}\frac{1}{p^{(n-1)k}}|\bigl\{ \mathbf{x}\ \pmod{p^k}: F(\mathbf{x})\equiv m\ \pmod{p^k}\bigr\}| \end{align*} $$
$$ \begin{align*} \mu_p(F,m):=\lim_{k\to\infty}\frac{1}{p^{(n-1)k}}|\bigl\{ \mathbf{x}\ \pmod{p^k}: F(\mathbf{x})\equiv m\ \pmod{p^k}\bigr\}| \end{align*} $$
and define the singular series by
 $$ \begin{align*} \mu(F,m):=\prod_p\mu_p(F,m). \end{align*} $$
$$ \begin{align*} \mu(F,m):=\prod_p\mu_p(F,m). \end{align*} $$
In our situation with 
 $n\geq 5$
, the singular series always converges absolutely; see also, for instance, [Reference IwaniecIwa97, §11.5]. Now [Reference Heath-BrownHB96, Theorem 4] states the following.
$n\geq 5$
, the singular series always converges absolutely; see also, for instance, [Reference IwaniecIwa97, §11.5]. Now [Reference Heath-BrownHB96, Theorem 4] states the following.
Theorem 4.9 [Reference Heath-BrownHB96, Theorem 4]
 Let the notation be as above, and let 
 $\omega \in \mathcal {C}(S)$
 be a weight function for some set of parameters S. Then
$\omega \in \mathcal {C}(S)$
 be a weight function for some set of parameters S. Then 
 $$ \begin{align*} N(F,m,\omega)=\mu_\infty(F,\omega)\mu(F,m)m^{n/2-1}+O_{F,S,\epsilon}\bigl(m^{(n-1)/4+\epsilon}\bigr). \end{align*} $$
$$ \begin{align*} N(F,m,\omega)=\mu_\infty(F,\omega)\mu(F,m)m^{n/2-1}+O_{F,S,\epsilon}\bigl(m^{(n-1)/4+\epsilon}\bigr). \end{align*} $$
 Note in particular that the error term depends only on F and S and not on the specific weight function 
 $\omega $
 or on m.
$\omega $
 or on m.
We also recall a corollary of the above theorem for positive definite quadratic forms, which will be used in Section 7.
Corollary 4.10 [Reference Heath-BrownHB96, Corollary 1]
Let the notation be as above, and assume further that F is positive definite. Then
 $$\begin{align*}|\{\mathbf{x}\in \mathbb{Z}^n: F(\mathbf{x})=m\}|=\mu_{\infty}(F,1)\mu(F,m)m^{n/2-1}+O_{F,\epsilon}(m^{(n-1)/4+\epsilon}).\end{align*}$$
$$\begin{align*}|\{\mathbf{x}\in \mathbb{Z}^n: F(\mathbf{x})=m\}|=\mu_{\infty}(F,1)\mu(F,m)m^{n/2-1}+O_{F,\epsilon}(m^{(n-1)/4+\epsilon}).\end{align*}$$
4.3 An application of Heath-Brown’s theorem and a result of Niedermowwe
 Recall that 
 $(L,Q)$
 is an even quadratic lattice of signature
$(L,Q)$
 is an even quadratic lattice of signature 
 $(b,2)$
 with
$(b,2)$
 with 
 $b\geq 3$
. We will apply Heath-Brown’s result to
$b\geq 3$
. We will apply Heath-Brown’s result to 
 $(L,Q)$
 (here we identify L with
$(L,Q)$
 (here we identify L with 
 $\mathbb {Z}^{b+2}$
) after we construct suitable smooth weight functions. Moreover, we recall Niedermowwe’s result, which is analogous to Heath-Brown’s result but with sharp weight functions given by characteristic functions of certain expanding domains
$\mathbb {Z}^{b+2}$
) after we construct suitable smooth weight functions. Moreover, we recall Niedermowwe’s result, which is analogous to Heath-Brown’s result but with sharp weight functions given by characteristic functions of certain expanding domains 
 $\Omega _T$
 defined below and keeps track of the dependence of the error term on T.
$\Omega _T$
 defined below and keeps track of the dependence of the error term on T.
 Similar to the definition of the singular integral 
 $\mu _\infty (F,\omega )$
 in Section 4.2, we define a measure
$\mu _\infty (F,\omega )$
 in Section 4.2, we define a measure 
 $\mu _\infty $
 on
$\mu _\infty $
 on 
 $$ \begin{align*} L_{\mathbb{R},1}:=\{\lambda\in L_{\mathbb{R}}:Q(\lambda)=1\} \end{align*} $$
$$ \begin{align*} L_{\mathbb{R},1}:=\{\lambda\in L_{\mathbb{R}}:Q(\lambda)=1\} \end{align*} $$
as follows. For an open bounded subset W of 
 $L_{\mathbb {R}}$
, we set
$L_{\mathbb {R}}$
, we set 
 $$ \begin{align} \mu_\infty(W\cap L_{\mathbb{R},1}):= \lim_{\epsilon\to 0}\frac{1}{2\epsilon} \mu_L\bigl(\{\lambda\in W:|Q(\lambda)-1|<\epsilon\}\bigr), \end{align} $$
$$ \begin{align} \mu_\infty(W\cap L_{\mathbb{R},1}):= \lim_{\epsilon\to 0}\frac{1}{2\epsilon} \mu_L\bigl(\{\lambda\in W:|Q(\lambda)-1|<\epsilon\}\bigr), \end{align} $$
where 
 $\mu _{L}$
 is the Lebesgue measure on
$\mu _{L}$
 is the Lebesgue measure on 
 $L_{\mathbb {R}}$
 normalised so that L has covolume
$L_{\mathbb {R}}$
 normalised so that L has covolume 
 $1$
.Footnote 23
$1$
.Footnote 23
 Let x denote a fixed point in the period domain 
 $D_L$
, and let P denote the negative definite plane (with respect to Q) in
$D_L$
, and let P denote the negative definite plane (with respect to Q) in 
 $L_{\mathbb {R}}$
 associated to x. Let
$L_{\mathbb {R}}$
 associated to x. Let 
 $P^\perp $
 denote the orthogonal complement of P in
$P^\perp $
 denote the orthogonal complement of P in 
 $L_{\mathbb {R}}$
. Given a vector
$L_{\mathbb {R}}$
. Given a vector 
 $\lambda \in L_{\mathbb {R}}$
, we let
$\lambda \in L_{\mathbb {R}}$
, we let 
 $\lambda _x$
 and
$\lambda _x$
 and 
 $\lambda _{x^\bot }$
 denote the projections of
$\lambda _{x^\bot }$
 denote the projections of 
 $\lambda $
 to P and
$\lambda $
 to P and 
 $P^\perp $
, respectively.
$P^\perp $
, respectively.
 We introduce notation for the set of elements in 
 $L_{\mathbb {R},1}$
 with bounded value of
$L_{\mathbb {R},1}$
 with bounded value of 
 $Q(\lambda _x)$
: for
$Q(\lambda _x)$
: for 
 $T>0$
, define
$T>0$
, define 
 $$ \begin{align*} \Omega_{\leq T}:=\{\lambda\in L_{\mathbb{R},1}:\,-Q(\lambda_x)\in[0,T]\}. \end{align*} $$
$$ \begin{align*} \Omega_{\leq T}:=\{\lambda\in L_{\mathbb{R},1}:\,-Q(\lambda_x)\in[0,T]\}. \end{align*} $$
Then the following lemma computes the volume of the sets 
 $\Omega _{\leq T}$
. Recall that
$\Omega _{\leq T}$
. Recall that 
 $k=1+\frac {b}{2}$
.
$k=1+\frac {b}{2}$
.
Lemma 4.11. Let 
 $T>0$
 be a real number. Then
$T>0$
 be a real number. Then 
 $$ \begin{align*}\mu_{\infty}(\Omega_{\leq T})=\frac{(2\pi)^{k}\left((1+T)^{\frac{b}{2}}-1\right)}{\sqrt{|L^{\vee}/L|}\Gamma(k)}.\end{align*} $$
$$ \begin{align*}\mu_{\infty}(\Omega_{\leq T})=\frac{(2\pi)^{k}\left((1+T)^{\frac{b}{2}}-1\right)}{\sqrt{|L^{\vee}/L|}\Gamma(k)}.\end{align*} $$
Proof
 For 
 $\epsilon>0$
, let
$\epsilon>0$
, let 
 $U_{T,\epsilon }:=\{x\in L_{\mathbb {R}}:|Q(x)-1|<\epsilon ,\, -Q(\lambda _x)<T\}$
. Then
$U_{T,\epsilon }:=\{x\in L_{\mathbb {R}}:|Q(x)-1|<\epsilon ,\, -Q(\lambda _x)<T\}$
. Then 
 $\Omega _{\leq T}=U_{T,\epsilon }\cap L_{\mathbb {R},1}$
 and by definition
$\Omega _{\leq T}=U_{T,\epsilon }\cap L_{\mathbb {R},1}$
 and by definition 
 $$ \begin{align*}\mu_{\infty}(\Omega_{\leq T})=\lim_{\epsilon\rightarrow 0}\frac{\mu_{L}(U_{T,\epsilon})}{2\epsilon}.\end{align*} $$
$$ \begin{align*}\mu_{\infty}(\Omega_{\leq T})=\lim_{\epsilon\rightarrow 0}\frac{\mu_{L}(U_{T,\epsilon})}{2\epsilon}.\end{align*} $$
Let 
 $\mathcal {E}$
 be an orthogonal basis of
$\mathcal {E}$
 be an orthogonal basis of 
 $L_{\mathbb {R}}$
 adapted to the decomposition
$L_{\mathbb {R}}$
 adapted to the decomposition 
 $P\oplus P^{\bot }$
 and in which the bilinear form associated to Q has the intersection matrix
$P\oplus P^{\bot }$
 and in which the bilinear form associated to Q has the intersection matrix 
 $$ \begin{align*}\begin{pmatrix} -1&0&0\\ 0&-1&0\\ 0&0&I_b\\ \end{pmatrix},\end{align*} $$
$$ \begin{align*}\begin{pmatrix} -1&0&0\\ 0&-1&0\\ 0&0&I_b\\ \end{pmatrix},\end{align*} $$
where 
 $I_b$
 denotes the
$I_b$
 denotes the 
 $b\times b$
 identity matrix. Let
$b\times b$
 identity matrix. Let 
 $\mu _{\mathcal {E}}$
 be the associated Lebesgue measure for which the
$\mu _{\mathcal {E}}$
 be the associated Lebesgue measure for which the 
 $\mathbb {Z}$
-span of
$\mathbb {Z}$
-span of 
 $\mathcal {E}$
 is of covolume
$\mathcal {E}$
 is of covolume 
 $1$
. By change of variables, we have
$1$
. By change of variables, we have 
 $$ \begin{align*} \mu_{L}(U_{T,\epsilon})&=\frac{2^{1+\frac{b}{2}}}{\sqrt{|L^{\vee}/L|}}\mu_{\mathcal{E}}(U_{T,\epsilon}) \\[4pt] &=\frac{2^{1+\frac{b}{2}}}{\sqrt{|L^{\vee}/L|}}\int_{\underset{\underset{x^2_1+x_2^2<T}{|x_1^2+x_2^2-y_1^2-\cdots-y_b^2+1|<\epsilon}}{(x_1,x_2,y_1,\cdots,y_b)\in\mathbb{R}^{b+2}}} dx_1 dx_2dy_1\cdots dy_b\\[4pt] &=\frac{2^{2+\frac{b}{2}}\pi}{\sqrt{|L^{\vee}/L|}}\int_{0}^{\sqrt{T}}\left(\int_{1+r^2-\epsilon<y_1^2+\cdots+y_b^2<1+r^2+\epsilon}dy_1\cdots dy_b \right) rdr\\[4pt] &=\frac{2(2\pi)^{1+\frac{b}{2}}}{\sqrt{|L^{\vee}/L|}\Gamma\left(1+\frac{b}{2}\right)}\int_{0}^{\sqrt{T}}\left((1+r^2+\epsilon)^{\frac{b}{2}}-\left(1+r^2-\epsilon\right)^{\frac{b}{2}}\right)rdr\\[4pt] &=2\epsilon.\frac{(2\pi)^{1+\frac{b}{2}} \left((1+T)^{\frac{b}{2}}-1\right)}{\sqrt{|L^{\vee}/L|}\Gamma\left(1+\frac{b}{2}\right)}+O(\epsilon^2). \end{align*} $$
$$ \begin{align*} \mu_{L}(U_{T,\epsilon})&=\frac{2^{1+\frac{b}{2}}}{\sqrt{|L^{\vee}/L|}}\mu_{\mathcal{E}}(U_{T,\epsilon}) \\[4pt] &=\frac{2^{1+\frac{b}{2}}}{\sqrt{|L^{\vee}/L|}}\int_{\underset{\underset{x^2_1+x_2^2<T}{|x_1^2+x_2^2-y_1^2-\cdots-y_b^2+1|<\epsilon}}{(x_1,x_2,y_1,\cdots,y_b)\in\mathbb{R}^{b+2}}} dx_1 dx_2dy_1\cdots dy_b\\[4pt] &=\frac{2^{2+\frac{b}{2}}\pi}{\sqrt{|L^{\vee}/L|}}\int_{0}^{\sqrt{T}}\left(\int_{1+r^2-\epsilon<y_1^2+\cdots+y_b^2<1+r^2+\epsilon}dy_1\cdots dy_b \right) rdr\\[4pt] &=\frac{2(2\pi)^{1+\frac{b}{2}}}{\sqrt{|L^{\vee}/L|}\Gamma\left(1+\frac{b}{2}\right)}\int_{0}^{\sqrt{T}}\left((1+r^2+\epsilon)^{\frac{b}{2}}-\left(1+r^2-\epsilon\right)^{\frac{b}{2}}\right)rdr\\[4pt] &=2\epsilon.\frac{(2\pi)^{1+\frac{b}{2}} \left((1+T)^{\frac{b}{2}}-1\right)}{\sqrt{|L^{\vee}/L|}\Gamma\left(1+\frac{b}{2}\right)}+O(\epsilon^2). \end{align*} $$
Dividing by 
 $2\epsilon $
 and letting
$2\epsilon $
 and letting 
 $\epsilon $
 go to zero, we get the desired result.
$\epsilon $
 go to zero, we get the desired result.
 We now describe the desired estimates for 
 $\bigl |\bigl \{ \lambda \in L:Q(\lambda )=m,\,\lambda /\sqrt {m}\in \Omega _{\leq T}\bigr \}\bigr |$
 in two cases.
$\bigl |\bigl \{ \lambda \in L:Q(\lambda )=m,\,\lambda /\sqrt {m}\in \Omega _{\leq T}\bigr \}\bigr |$
 in two cases.
4.3.1 Assume 
 $T\leq 1$
$T\leq 1$
 In this case, we only need a good upper bound, and hence we construct a suitable smooth weight function 
 $\omega :L_{\mathbb {R}}\to \mathbb {R}$
 as follows and apply Heath-Brown’s theorem.
$\omega :L_{\mathbb {R}}\to \mathbb {R}$
 as follows and apply Heath-Brown’s theorem.
Corollary 4.12. Given 
 $(L,Q)$
 as above, for any
$(L,Q)$
 as above, for any 
 $m\in \mathbb {Z}_{>0}$
, any
$m\in \mathbb {Z}_{>0}$
, any 
 $0<T\leq 1$
, we have
$0<T\leq 1$
, we have 
 $$\begin{align*}\bigl|\bigl\{ \lambda\in L:Q(\lambda)=m,\,\lambda/\sqrt{m}\in \Omega_{\leq T}\bigr\}\bigr|=O_Q(m^{\frac{b}{2}}T)+O_{Q,T,\epsilon}(m^{(b+1)/4+\epsilon}).\end{align*}$$
$$\begin{align*}\bigl|\bigl\{ \lambda\in L:Q(\lambda)=m,\,\lambda/\sqrt{m}\in \Omega_{\leq T}\bigr\}\bigr|=O_Q(m^{\frac{b}{2}}T)+O_{Q,T,\epsilon}(m^{(b+1)/4+\epsilon}).\end{align*}$$
Proof. By Remark 4.8, there exist smooth functions 
 $\omega _P:P\to [0,2]$
 and
$\omega _P:P\to [0,2]$
 and 
 $\omega _{P^\perp }:P^\perp \to [0,2]$
 such that
$\omega _{P^\perp }:P^\perp \to [0,2]$
 such that 
- 
1.  $\omega _P(\lambda _x)\geq 1$
 for elements $\omega _P(\lambda _x)\geq 1$
 for elements $\lambda _x\in P$
 with $\lambda _x\in P$
 with $Q(\lambda _x)<T$
 and $Q(\lambda _x)<T$
 and $\omega _P(\lambda _x)=0$
 if $\omega _P(\lambda _x)=0$
 if $Q(\lambda _x)>2T$
. $Q(\lambda _x)>2T$
.
- 
2.  $\omega _{P^\perp }(\lambda _{x^\perp })\geq 1$
 if $\omega _{P^\perp }(\lambda _{x^\perp })\geq 1$
 if $Q(\lambda _{x^\perp })\leq 1$
 and $Q(\lambda _{x^\perp })\leq 1$
 and $\omega _{P^\perp }(\lambda _{x^\perp })=0$
 if $\omega _{P^\perp }(\lambda _{x^\perp })=0$
 if $Q(\lambda _{x^\perp })\geq 2$
. $Q(\lambda _{x^\perp })\geq 2$
.
We define 
 $\omega (\lambda )=\omega _P(\lambda _x)\omega _{P^\perp }(\lambda _{x^\perp })$
, and by construction,
$\omega (\lambda )=\omega _P(\lambda _x)\omega _{P^\perp }(\lambda _{x^\perp })$
, and by construction, 
 $\omega \in \mathcal {C}(b,T)$
.
$\omega \in \mathcal {C}(b,T)$
.
 By definition, 
 $\bigl |\bigl \{ \lambda \in L:Q(\lambda )=m,\,\lambda /\sqrt {m}\in \Omega _{\leq T}\bigr \}\bigr |\leq N(Q,m,\omega )$
. By definition and Lemma 4.11, the singular integral
$\bigl |\bigl \{ \lambda \in L:Q(\lambda )=m,\,\lambda /\sqrt {m}\in \Omega _{\leq T}\bigr \}\bigr |\leq N(Q,m,\omega )$
. By definition and Lemma 4.11, the singular integral 
 $\mu _\infty (Q,\omega )\ll \mu _\infty (\Omega _{\leq 2T})=O(T)$
. Then the assertion follows by applying Theorem 4.9 to
$\mu _\infty (Q,\omega )\ll \mu _\infty (\Omega _{\leq 2T})=O(T)$
. Then the assertion follows by applying Theorem 4.9 to 
 $\omega $
 and the fact that
$\omega $
 and the fact that 
 $\mu (Q,m)=O_F(1)$
 (since
$\mu (Q,m)=O_F(1)$
 (since 
 $b\geq 3$
).
$b\geq 3$
).
4.3.2 Assume 
 $T\geq 1$
$T\geq 1$
In this case, we will need the exact main term along with an error term with explicit dependence on T, and we will apply Niedermowwe’s work [Reference NiedermowweNie10].
 For the convenience of later use, for an integer 
 $m\geq 1$
, we define the quantity
$m\geq 1$
, we define the quantity 
 $$ \begin{align} a(m)=\frac{-c(m)\Gamma(k)\sqrt{|L^\vee/L|}}{2(2\pi)^{k}}, \end{align} $$
$$ \begin{align} a(m)=\frac{-c(m)\Gamma(k)\sqrt{|L^\vee/L|}}{2(2\pi)^{k}}, \end{align} $$
where 
 $c(m)$
 is the mth Fourier coefficient of the Eisenstein series defined in Section 3.3. Note that
$c(m)$
 is the mth Fourier coefficient of the Eisenstein series defined in Section 3.3. Note that 
 $a(m)$
 grows as
$a(m)$
 grows as 
 $\asymp m^{\frac {b}{2}}$
. We have the following proposition, which follows from work of Niedermowwe [Reference NiedermowweNie10].
$\asymp m^{\frac {b}{2}}$
. We have the following proposition, which follows from work of Niedermowwe [Reference NiedermowweNie10].
Proposition 4.13. Let 
 $A>1$
 be a positive real number. For any
$A>1$
 be a positive real number. For any 
 $m\in \mathbb {Z}_{>0}$
,
$m\in \mathbb {Z}_{>0}$
, 
 $T\geq 1$
, we have
$T\geq 1$
, we have 
 $$ \begin{align*} \bigl|\bigl\{ \lambda\in L:Q(\lambda)=m,\,\lambda/\sqrt{m}\in \Omega_{\leq T}\bigr\}\bigr|= a(m)\mu_\infty(\Omega_{\leq T})+O\bigl(m^{\frac{b}{2}}T^{\frac{b}{2}}\log(mT)^{-A}\bigr). \end{align*} $$
$$ \begin{align*} \bigl|\bigl\{ \lambda\in L:Q(\lambda)=m,\,\lambda/\sqrt{m}\in \Omega_{\leq T}\bigr\}\bigr|= a(m)\mu_\infty(\Omega_{\leq T})+O\bigl(m^{\frac{b}{2}}T^{\frac{b}{2}}\log(mT)^{-A}\bigr). \end{align*} $$
Proof. In [Reference NiedermowweNie10, Theorem 3.6], Niedermowwe estimates the number of lattice points with fixed norm in homogeneously expanding rectangular regions. His proof carries over without change for our region, yielding thatFootnote 24
 $$\begin{align*}\bigl|\bigl\{ \lambda\in L:Q(\lambda)=m,\,\lambda/\sqrt{m}\in \Omega_{\leq T}\bigr\}\bigr|= \mu_\infty(\Omega_{\leq T})m^{\frac{b}{2}}\mu(Q,m)+O\bigl(m^{\frac{b}{2}}T^{\frac{b}{2}}\log(mT)^{-A}\bigr).\end{align*}$$
$$\begin{align*}\bigl|\bigl\{ \lambda\in L:Q(\lambda)=m,\,\lambda/\sqrt{m}\in \Omega_{\leq T}\bigr\}\bigr|= \mu_\infty(\Omega_{\leq T})m^{\frac{b}{2}}\mu(Q,m)+O\bigl(m^{\frac{b}{2}}T^{\frac{b}{2}}\log(mT)^{-A}\bigr).\end{align*}$$
We then deduce the desired formula by the explicit formula for 
 $c(m)$
 in [Reference Bruinier and KussBK01, (22),(23)], which asserts that
$c(m)$
 in [Reference Bruinier and KussBK01, (22),(23)], which asserts that 
 $\displaystyle c(m)=-\frac {2(2\pi )^{\frac {b}{2}+1}m^{\frac {b}{2}}}{\sqrt {|L^\vee /L|}\Gamma (\frac {b}{2}+1)}\prod _p \mu _p(Q,m)$
.
$\displaystyle c(m)=-\frac {2(2\pi )^{\frac {b}{2}+1}m^{\frac {b}{2}}}{\sqrt {|L^\vee /L|}\Gamma (\frac {b}{2}+1)}\prod _p \mu _p(Q,m)$
.
 We conclude this section by an integral computation similar to Lemma 4.11, which will be used later. For 
 $s\in \mathbb {R}$
, consider the function
$s\in \mathbb {R}$
, consider the function 
 $$ \begin{align*} h_s:L_{\mathbb{R}}&\rightarrow \mathbb{R}^+\\ \lambda&\mapsto \left(\frac{1}{1-Q(\lambda_x)}\right)^{k-1+s}. \end{align*} $$
$$ \begin{align*} h_s:L_{\mathbb{R}}&\rightarrow \mathbb{R}^+\\ \lambda&\mapsto \left(\frac{1}{1-Q(\lambda_x)}\right)^{k-1+s}. \end{align*} $$
Lemma 4.14. For 
 $s>0$
, we have
$s>0$
, we have 
 $$ \begin{align*} \int_{L_{\mathbb{R},1}}h_s(\lambda)d\mu_{\infty}(\lambda)= \frac{b}{4}\cdot \frac{|c(m)|}{s\cdot a(m)}. \end{align*} $$
$$ \begin{align*} \int_{L_{\mathbb{R},1}}h_s(\lambda)d\mu_{\infty}(\lambda)= \frac{b}{4}\cdot \frac{|c(m)|}{s\cdot a(m)}. \end{align*} $$
Proof. As in the proof of Lemma 4.11, we define 
 $L_\epsilon =:\{x\in L_{\mathbb {R}}:|Q(x)-1|<\epsilon \}$
. Then
$L_\epsilon =:\{x\in L_{\mathbb {R}}:|Q(x)-1|<\epsilon \}$
. Then 
 $$ \begin{align*} \lim_{\epsilon\rightarrow 0} \frac{1}{2\epsilon}&\int_{L_{\epsilon}}\left(\frac{1}{1-Q(\lambda_x)}\right)^{k-1+s}d\mu_{\infty}(\lambda)\\&=\lim_{\epsilon\rightarrow 0}\frac{2^{\frac{b}{2}}}{\epsilon\sqrt{|L^\vee/L|}}\int_{(x_1,x_2)\in \mathbb{R}^2}\int_{\underset{|y_1^2+\cdots+y_b^2-x_1^2-x_2^2-1|<\epsilon}{(y_1,\dots, y_b)\in \mathbb{R}^b}}\frac{dx_1dx_2dy_1\cdots dy_b}{\left(1+x_1^2+x_2^2\right)^{k-1+s}}\\ &=\frac{2(2\pi)^{1+\frac{b}{2}}}{\Gamma\left(\frac{b}{2}\right).\sqrt{|L^\vee/L|}}\int_{0}^{+\infty}\left(\frac{1}{1+r^2}\right)^{s+1}rdr\\ &=\frac{(2\pi)^{1+\frac{b}{2}}}{\Gamma\left(\frac{b}{2}\right).\sqrt{|L^\vee/L|}}\frac{1}{s}. \end{align*} $$
$$ \begin{align*} \lim_{\epsilon\rightarrow 0} \frac{1}{2\epsilon}&\int_{L_{\epsilon}}\left(\frac{1}{1-Q(\lambda_x)}\right)^{k-1+s}d\mu_{\infty}(\lambda)\\&=\lim_{\epsilon\rightarrow 0}\frac{2^{\frac{b}{2}}}{\epsilon\sqrt{|L^\vee/L|}}\int_{(x_1,x_2)\in \mathbb{R}^2}\int_{\underset{|y_1^2+\cdots+y_b^2-x_1^2-x_2^2-1|<\epsilon}{(y_1,\dots, y_b)\in \mathbb{R}^b}}\frac{dx_1dx_2dy_1\cdots dy_b}{\left(1+x_1^2+x_2^2\right)^{k-1+s}}\\ &=\frac{2(2\pi)^{1+\frac{b}{2}}}{\Gamma\left(\frac{b}{2}\right).\sqrt{|L^\vee/L|}}\int_{0}^{+\infty}\left(\frac{1}{1+r^2}\right)^{s+1}rdr\\ &=\frac{(2\pi)^{1+\frac{b}{2}}}{\Gamma\left(\frac{b}{2}\right).\sqrt{|L^\vee/L|}}\frac{1}{s}. \end{align*} $$
The lemma now follows from the definition of 
 $a(m)$
.
$a(m)$
.
5 First step in the archimedean estimate and uniform diophantine bounds
 We keep the notations from Section 2 and Section 3. Namely, 
 $(L,Q)$
 is an even maximal lattice of signature
$(L,Q)$
 is an even maximal lattice of signature 
 $(b,2)$
 with
$(b,2)$
 with 
 $b\geq 3$
. Recall that
$b\geq 3$
. Recall that 
 $\mathcal {M}$
 is the integral model over
$\mathcal {M}$
 is the integral model over 
 $\mathbb {Z}$
 of the associated GSpin Shimura variety M and
$\mathbb {Z}$
 of the associated GSpin Shimura variety M and 
 $\widehat {\mathcal {Z}}(m):=(\mathcal {Z}(m),\Phi _m)$
 are the arithmetic special divisor on
$\widehat {\mathcal {Z}}(m):=(\mathcal {Z}(m),\Phi _m)$
 are the arithmetic special divisor on 
 $\mathcal {M}$
 for
$\mathcal {M}$
 for 
 $m\in \mathbb {Z}_{>0}$
. Throughout this section and the rest of the paper, we assume that the equation
$m\in \mathbb {Z}_{>0}$
. Throughout this section and the rest of the paper, we assume that the equation 
 $Q(v)=m$
 has a solution in L – that is,
$Q(v)=m$
 has a solution in L – that is, 
 $\mathcal {Z}(m)\neq \emptyset $
. As in Theorem 2.4,
$\mathcal {Z}(m)\neq \emptyset $
. As in Theorem 2.4, 
 $\mathcal {Y}\in \mathcal {M}(\mathcal {O}_K)$
 such that
$\mathcal {Y}\in \mathcal {M}(\mathcal {O}_K)$
 such that 
 $\mathcal {Y}_K$
 is Hodge-generic and
$\mathcal {Y}_K$
 is Hodge-generic and 
 $\mathcal {Y}^\sigma \in M(\mathbb {C})$
 via
$\mathcal {Y}^\sigma \in M(\mathbb {C})$
 via 
 $\sigma : K\hookrightarrow \mathbb {C}$
.
$\sigma : K\hookrightarrow \mathbb {C}$
.
 The main goal of this section is to give a first estimate of the archimedean term in the height formula given by equation (3.1); more precisely, we show that for a fixed 
 $\sigma $
 and for every m,
$\sigma $
 and for every m, 
 $$ \begin{align} \Phi_m(\mathcal{Y}^\sigma)\asymp -m^{\frac{b}{2}}\log m + A(m, \mathcal{Y}^\sigma) + o(m^{\frac{b}{2}}\log m), \end{align} $$
$$ \begin{align} \Phi_m(\mathcal{Y}^\sigma)\asymp -m^{\frac{b}{2}}\log m + A(m, \mathcal{Y}^\sigma) + o(m^{\frac{b}{2}}\log m), \end{align} $$
where 
 $A(m, \mathcal {Y}^\sigma )$
 is a non-negative real number (see equation (5.7) and Theorem 5.7 for the precise statement).
$A(m, \mathcal {Y}^\sigma )$
 is a non-negative real number (see equation (5.7) and Theorem 5.7 for the precise statement).
 An important consequence (Theorem 5.8) of this estimate is the following uniform diophantine bounds. For a fixed finite place 
 $\mathfrak {P}$
 and a fixed
$\mathfrak {P}$
 and a fixed 
 $\sigma $
, we have
$\sigma $
, we have 
 $$ \begin{align} (\mathcal{Y}.\mathcal{Z}(m))_{\mathfrak{P}}=O(m^{\frac{b}{2}}\log m),\quad \Phi_m(\mathcal{Y}^\sigma)=O(m^{\frac{b}{2}}\log m). \end{align} $$
$$ \begin{align} (\mathcal{Y}.\mathcal{Z}(m))_{\mathfrak{P}}=O(m^{\frac{b}{2}}\log m),\quad \Phi_m(\mathcal{Y}^\sigma)=O(m^{\frac{b}{2}}\log m). \end{align} $$
This consequence is one of the key inputs for the estimates in Sections6–7.
 Throughout this section, x will denote a 
 $\mathbb {C}$
-point of M, which is not contained in any special divisor. This section is organised as follows. First, in Section 5.1, we follow Bruinier [Reference BruinierBru02] and Bruinier–Kühn [Reference Bruinier and KühnBK03] to express
$\mathbb {C}$
-point of M, which is not contained in any special divisor. This section is organised as follows. First, in Section 5.1, we follow Bruinier [Reference BruinierBru02] and Bruinier–Kühn [Reference Bruinier and KühnBK03] to express 
 $\Phi _m(x)$
 as a sum of two terms
$\Phi _m(x)$
 as a sum of two terms 
 $$ \begin{align*}\Phi_m(x)=\phi_m(x)-b^{\prime}m(k/2),\end{align*} $$
$$ \begin{align*}\Phi_m(x)=\phi_m(x)-b^{\prime}m(k/2),\end{align*} $$
where 
 $\phi _m(x)$
 and the function
$\phi _m(x)$
 and the function 
 $b_m(s)$
 are defined in equations (5.3), (5.4) and (5.5). Then, in Section 5.2, we use results from [Reference Bruinier and KühnBK03] to prove that
$b_m(s)$
 are defined in equations (5.3), (5.4) and (5.5). Then, in Section 5.2, we use results from [Reference Bruinier and KühnBK03] to prove that 
 $b^{\prime }m(k/2)\asymp m^{\frac {b}{2}}\log m$
. Next, in Section 5.3, we prove that
$b^{\prime }m(k/2)\asymp m^{\frac {b}{2}}\log m$
. Next, in Section 5.3, we prove that 
 $\phi _m(x)= A(m,x)+O(m^{\frac {b}{2}})$
, where
$\phi _m(x)= A(m,x)+O(m^{\frac {b}{2}})$
, where 
 $A(m,x)$
, as above, is non-negative. In Section 5.4, we put together the results of Sections5.1–5.3 to deduce equations (5.1) and (5.2).
$A(m,x)$
, as above, is non-negative. In Section 5.4, we put together the results of Sections5.1–5.3 to deduce equations (5.1) and (5.2).
5.1 Bruinier’s explicit formula for the Green function 
 $\Phi _m$
$\Phi _m$
 There is an another expression for the Green function 
 $\Phi _m$
 introduced in Section 3.1 due to Bruinier (see [Reference BruinierBru02, §2] and [Reference Bruinier and KühnBK03, §4]); this expression will allow us to make explicit computations later. As in Section 3.3, let
$\Phi _m$
 introduced in Section 3.1 due to Bruinier (see [Reference BruinierBru02, §2] and [Reference Bruinier and KühnBK03, §4]); this expression will allow us to make explicit computations later. As in Section 3.3, let 
 $k=1+\frac {b}{2}$
, and
$k=1+\frac {b}{2}$
, and 
 $s\in \mathbb {C}$
 with
$s\in \mathbb {C}$
 with 
 $\mathrm {Re}(s)>\frac {k}{2}$
. We pick a lift of
$\mathrm {Re}(s)>\frac {k}{2}$
. We pick a lift of 
 $x\in M(\mathbb {C})$
 to the period domain
$x\in M(\mathbb {C})$
 to the period domain 
 $D_L$
 and still use x to denote the lift. Recall from Section 2.1 that x defines a negative definite planeFootnote 25
$D_L$
 and still use x to denote the lift. Recall from Section 2.1 that x defines a negative definite planeFootnote 25 
 $P_x$
 of
$P_x$
 of 
 $L_{\mathbb {R}}$
 and for
$L_{\mathbb {R}}$
 and for 
 $\lambda \in L_{\mathbb {R}}$
, we denote by
$\lambda \in L_{\mathbb {R}}$
, we denote by 
 $\lambda _x$
 the orthogonal projection of
$\lambda _x$
 the orthogonal projection of 
 $\lambda $
 on
$\lambda $
 on 
 $P_x$
. Let
$P_x$
. Let 
 $$ \begin{align*}F(s,z)=H\left(s-1+\frac{k}{2},s+1-\frac{k}{2},2s;z\right),\text{ where } H(a,b,c;z)=\sum_{n\geq 0}\frac{(a)_n(b)_n}{(c)_n}\frac{z^n}{n!}\end{align*} $$
$$ \begin{align*}F(s,z)=H\left(s-1+\frac{k}{2},s+1-\frac{k}{2},2s;z\right),\text{ where } H(a,b,c;z)=\sum_{n\geq 0}\frac{(a)_n(b)_n}{(c)_n}\frac{z^n}{n!}\end{align*} $$
is the Gauss hypergeometric function as in [Reference Abramowitz and StegunAS64, Chapter 15] and 
 $(a)_n=\frac {\Gamma (a+n)}{\Gamma (a)}$
 for
$(a)_n=\frac {\Gamma (a+n)}{\Gamma (a)}$
 for 
 $a,b,c,z\in \mathbb {C}$
 and
$a,b,c,z\in \mathbb {C}$
 and 
 $|z|<1$
. Finally, letFootnote 26
$|z|<1$
. Finally, letFootnote 26 
 $$ \begin{align} \phi_{m}(x,s)=2\frac{\Gamma(s-1+\frac{k}{2})}{\Gamma(2s)}\sum_{Q(\lambda)=m, \lambda\in L}\left(\frac{m}{m-Q(\lambda_x)}\right)^{s-1+\frac{k}{2}} F\left(s,\frac{m}{m-Q(\lambda_x)}\right). \end{align} $$
$$ \begin{align} \phi_{m}(x,s)=2\frac{\Gamma(s-1+\frac{k}{2})}{\Gamma(2s)}\sum_{Q(\lambda)=m, \lambda\in L}\left(\frac{m}{m-Q(\lambda_x)}\right)^{s-1+\frac{k}{2}} F\left(s,\frac{m}{m-Q(\lambda_x)}\right). \end{align} $$
By [Reference BruinierBru02, Proposition 2.8, Theorem 2.14], the function 
 $\phi _{m}(x,s)$
 admits a meromorphic continuation to
$\phi _{m}(x,s)$
 admits a meromorphic continuation to 
 $\mathrm {Re}(s)>1$
 with a simple pole at
$\mathrm {Re}(s)>1$
 with a simple pole at 
 $s=\frac {k}{2}$
 with residue
$s=\frac {k}{2}$
 with residue 
 $-c(m)$
, where
$-c(m)$
, where 
 $c(m)$
 is the Fourier coefficient defined in Section 3.3; see also [Reference Bruinier and KühnBK03, Proposition 4.3] for the value of the residue.
$c(m)$
 is the Fourier coefficient defined in Section 3.3; see also [Reference Bruinier and KühnBK03, Proposition 4.3] for the value of the residue.
 We regularise 
 $\phi _m(x,s)$
 at
$\phi _m(x,s)$
 at 
 $s=k/2$
 by defining
$s=k/2$
 by defining 
 $\phi _{m}(x)$
 to be the constant term at
$\phi _{m}(x)$
 to be the constant term at 
 $s=\frac {k}{2}$
 of the Laurent expansion of
$s=\frac {k}{2}$
 of the Laurent expansion of 
 $\phi _{m}(x,s)$
. As in [Reference Bruinier and KühnBK03, Prop.4.2], for
$\phi _{m}(x,s)$
. As in [Reference Bruinier and KühnBK03, Prop.4.2], for 
 $x\in D_L$
, we have
$x\in D_L$
, we have 
 $$ \begin{align} \phi_m(x)=\lim_{s\rightarrow \frac{k}{2}}\left(\phi_{m}(x,s)+\frac{c(m)}{s-\frac{k}{2}}\right). \end{align} $$
$$ \begin{align} \phi_m(x)=\lim_{s\rightarrow \frac{k}{2}}\left(\phi_{m}(x,s)+\frac{c(m)}{s-\frac{k}{2}}\right). \end{align} $$
 To compare 
 $\phi _m(x)$
 with
$\phi _m(x)$
 with 
 $\Phi _m(x)$
, we recall that
$\Phi _m(x)$
, we recall that 
 $C(n,s), n\in \mathbb {Z}, s\in \mathbb {C}, \operatorname {\mathrm {Re}}(s)>1-\frac {k}{2}$
 is part of the Fourier coefficient of
$C(n,s), n\in \mathbb {Z}, s\in \mathbb {C}, \operatorname {\mathrm {Re}}(s)>1-\frac {k}{2}$
 is part of the Fourier coefficient of 
 $E_0(\tau ,s)$
 defined in Section 3.3. For
$E_0(\tau ,s)$
 defined in Section 3.3. For 
 $s\in \mathbb {C}$
 with
$s\in \mathbb {C}$
 with 
 $\mathrm {Re}(s)>1$
, defineFootnote 27
$\mathrm {Re}(s)>1$
, defineFootnote 27 
 $$ \begin{align} b_m(s)=-\frac{C\left(m,s-\frac{k}{2}\right)\cdot\left(s-1+\frac{k}{2}\right)}{\left(2s-1\right)\cdot\Gamma\left(s+1-\frac{k}{2}\right)}. \end{align} $$
$$ \begin{align} b_m(s)=-\frac{C\left(m,s-\frac{k}{2}\right)\cdot\left(s-1+\frac{k}{2}\right)}{\left(2s-1\right)\cdot\Gamma\left(s+1-\frac{k}{2}\right)}. \end{align} $$
By [Reference BruinierBru02, Theorem 1.9], 
 $b_m(s)$
 is a holomorphic function of s in the region
$b_m(s)$
 is a holomorphic function of s in the region 
 $\mathrm {Re}(s)>1$
.
$\mathrm {Re}(s)>1$
.
Proposition 5.1 [Reference BruinierBru02, Proposition 2.11]
 For 
 $x\in D_{L}$
, we have
$x\in D_{L}$
, we have 
 $$ \begin{align*}\Phi_m(x)=\phi_m(x)-b^{\prime}m(k/2).\end{align*} $$
$$ \begin{align*}\Phi_m(x)=\phi_m(x)-b^{\prime}m(k/2).\end{align*} $$
 This proposition shows in particular that 
 $\phi _{m}$
 is also a Green function for the arithmetic cycle
$\phi _{m}$
 is also a Green function for the arithmetic cycle 
 $\mathcal {Z}(m)$
.
$\mathcal {Z}(m)$
.
5.2 Estimating 
 $b^{\prime }m(k/2)$
$b^{\prime }m(k/2)$
The main result of this subsection is the following.
Proposition 5.2. Let 
 $m\in \mathbb {Z}_{>0}$
 such that
$m\in \mathbb {Z}_{>0}$
 such that 
 $\mathcal {Z}(m)\neq \emptyset $
; and if b is odd, we further assume that for a fixed D,
$\mathcal {Z}(m)\neq \emptyset $
; and if b is odd, we further assume that for a fixed D, 
 $\sqrt {m/D}\in \mathbb {Z}$
, as in Theorem 2.4. Then as
$\sqrt {m/D}\in \mathbb {Z}$
, as in Theorem 2.4. Then as 
 $m\rightarrow +\infty $
, we have
$m\rightarrow +\infty $
, we have 
 $$ \begin{align*}b^{\prime}m(k/2)=|c(m)|\log m+o\left(c(m)\log m\right).\end{align*} $$
$$ \begin{align*}b^{\prime}m(k/2)=|c(m)|\log m+o\left(c(m)\log m\right).\end{align*} $$
In particular, 
 $b^{\prime }m(k/2)\asymp m^{\frac {b}{2}}\log m$
.
$b^{\prime }m(k/2)\asymp m^{\frac {b}{2}}\log m$
.
Lemma 5.3 below reduces the proposition into computations of certain local invariants of the lattice L at primes p.
 In order to state the lemma, we recall some notations from [Reference Bruinier and KühnBK03] and Section 4.1. Recall that 
 $r=b+2$
, and let D be the fixed integer in Theorem 2.4; let d be
$r=b+2$
, and let D be the fixed integer in Theorem 2.4; let d be 
 $$ \begin{align*} &(-1)^{\frac{r}{2}}\det(L),\, \text{if r is even};\\ &2(-1)^{\frac{r+1}{2}}D\det(L),\, \text{otherwise}, \end{align*} $$
$$ \begin{align*} &(-1)^{\frac{r}{2}}\det(L),\, \text{if r is even};\\ &2(-1)^{\frac{r+1}{2}}D\det(L),\, \text{otherwise}, \end{align*} $$
where 
 $\det (L)$
 denote the Gram determinant of L. Let
$\det (L)$
 denote the Gram determinant of L. Let 
 $d_0$
 denote the fundamental discriminant of number field
$d_0$
 denote the fundamental discriminant of number field 
 $\mathbb {Q}(\sqrt {d})$
, and let
$\mathbb {Q}(\sqrt {d})$
, and let 
 $\chi _{d_{0}}$
 be the quadratic character associated to
$\chi _{d_{0}}$
 be the quadratic character associated to 
 $d_0$
. The polynomial
$d_0$
. The polynomial 
 $\mathrm {L}_m^{(p)}(t)$
 is defined by
$\mathrm {L}_m^{(p)}(t)$
 is defined by 
 $$ \begin{align*}\mathrm{L}_m^{(p)}(t)=N_{m}(p^{w_p})t^{w_p}+(1-p^{r-1}t)\sum_{n=0}^{w_p-1}N_{m}(p^n)t^n\in\mathbb{Z}[t],\end{align*} $$
$$ \begin{align*}\mathrm{L}_m^{(p)}(t)=N_{m}(p^{w_p})t^{w_p}+(1-p^{r-1}t)\sum_{n=0}^{w_p-1}N_{m}(p^n)t^n\in\mathbb{Z}[t],\end{align*} $$
where, as in Section 4.1, 
 $N_{m}(p^n)=\#\{v\in L/p^nL;\,Q(v)\equiv m\ \pmod {p^n}\}$
 and
$N_{m}(p^n)=\#\{v\in L/p^nL;\,Q(v)\equiv m\ \pmod {p^n}\}$
 and 
 $w_p:=w_p(m)=1+\operatorname {\mathrm {val}}_{p}(m)$
 for
$w_p:=w_p(m)=1+\operatorname {\mathrm {val}}_{p}(m)$
 for 
 $p\neq 2$
 and
$p\neq 2$
 and 
 $w_2:=w_2(m)=1+2\operatorname {\mathrm {val}}_2(2m)$
.Footnote 28
$w_2:=w_2(m)=1+2\operatorname {\mathrm {val}}_2(2m)$
.Footnote 28
Lemma 5.3 (Bruinier–Kühn)
 Let 
 $D\in \mathbb {Z}_{>0}$
 be the fixed integer in Theorem 2.4 for all
$D\in \mathbb {Z}_{>0}$
 be the fixed integer in Theorem 2.4 for all 
 $m\in \mathbb {Z}_{>0}$
 such that
$m\in \mathbb {Z}_{>0}$
 such that 
 $\sqrt {m/D}\in \mathbb {Z}$
 (and representable by
$\sqrt {m/D}\in \mathbb {Z}$
 (and representable by 
 $(L,Q)$
); we have
$(L,Q)$
); we have 
 $$\begin{align*}\frac{b^{\prime}m\left(\frac{k}{2}\right)}{b_m\left(\frac{k}{2}\right)}=\log(m)+2\frac{\sigma_{m}'(k)}{\sigma_{m}(k)}+O(1),\end{align*}$$
$$\begin{align*}\frac{b^{\prime}m\left(\frac{k}{2}\right)}{b_m\left(\frac{k}{2}\right)}=\log(m)+2\frac{\sigma_{m}'(k)}{\sigma_{m}(k)}+O(1),\end{align*}$$
where for 
 $s\in \mathbb {C}$
,
$s\in \mathbb {C}$
, 
 $\mathrm {Re}(s)>0$
, the function
$\mathrm {Re}(s)>0$
, the function 
 $\sigma _{m}$
 is given by
$\sigma _{m}$
 is given by 
 $$ \begin{align} \sigma_{m}(s)=\left\{\begin{array}{ll} \underset{p\mid 2m\det(L)}{\prod}\frac{\mathrm{L}_m^{(p)}\left(p^{1-\frac{r}{2}-s}\right)}{1-\chi_{d_{0}}(p)p^{-s}},\,\textrm{if}\, r\,\textrm{is even},\\ \underset{p\mid 2m\det(L)}{\prod}\frac{1-\chi_{d_{0}}(p)p^{\frac{1}{2}-s}}{1-p^{1-2s}}\mathrm{L}_m^{(p)}\left(p^{1-\frac{r}{2}-s}\right),\, \textrm{if}\, r\,\textrm{is odd}. \end{array} \right. \end{align} $$
$$ \begin{align} \sigma_{m}(s)=\left\{\begin{array}{ll} \underset{p\mid 2m\det(L)}{\prod}\frac{\mathrm{L}_m^{(p)}\left(p^{1-\frac{r}{2}-s}\right)}{1-\chi_{d_{0}}(p)p^{-s}},\,\textrm{if}\, r\,\textrm{is even},\\ \underset{p\mid 2m\det(L)}{\prod}\frac{1-\chi_{d_{0}}(p)p^{\frac{1}{2}-s}}{1-p^{1-2s}}\mathrm{L}_m^{(p)}\left(p^{1-\frac{r}{2}-s}\right),\, \textrm{if}\, r\,\textrm{is odd}. \end{array} \right. \end{align} $$
Proof. Taking logarithmic derivatives in equation (5.5) at 
 $s=\frac {k}{2}$
 yields
$s=\frac {k}{2}$
 yields 
 $$ \begin{align*} \frac{b^{\prime}m\left(\frac{k}{2}\right)}{b_m\left(\frac{k}{2}\right)}=\frac{C'(m,0)}{C(m,0)}-\frac{2}{b}-\Gamma'(1) \end{align*} $$
$$ \begin{align*} \frac{b^{\prime}m\left(\frac{k}{2}\right)}{b_m\left(\frac{k}{2}\right)}=\frac{C'(m,0)}{C(m,0)}-\frac{2}{b}-\Gamma'(1) \end{align*} $$
Then we conclude by [Reference Bruinier and KühnBK03, Theorem 4.11, (4.73), (4.74)], since both 
 $d_0$
 and k are independent of m. (Our definition of d above differs from the definition in [Reference Bruinier and KühnBK03] by
$d_0$
 and k are independent of m. (Our definition of d above differs from the definition in [Reference Bruinier and KühnBK03] by 
 $m/D$
, which is a square and hence yields the same
$m/D$
, which is a square and hence yields the same 
 $d_0$
.)
$d_0$
.)
Proof of Proposition 5.2
 By definition, 
 $b_m(k/2)=-c(m)=|c(m)|$
. Therefore, by Lemma 5.3, it is enough to show that
$b_m(k/2)=-c(m)=|c(m)|$
. Therefore, by Lemma 5.3, it is enough to show that 
 $$ \begin{align*}\frac{\sigma_{m}'(k)}{\sigma_{m}(k)}=o(\log(m)).\end{align*} $$
$$ \begin{align*}\frac{\sigma_{m}'(k)}{\sigma_{m}(k)}=o(\log(m)).\end{align*} $$
Taking the logarithmic derivative in equation (5.6) at 
 $s=k$
, we get for r even
$s=k$
, we get for r even 
 $$ \begin{align*} \frac{\sigma_{m}'(k)}{\sigma_{m}(k)}=-\sum_{p\mid 2m\det(L)}\left(\frac{p^{1-r}\mathrm{L}_m^{(p)'}\left(p^{1-r}\right)}{\mathrm{L}_m^{(p)}\left(p^{1-r}\right)}+\frac{\chi_{d_0}(p)}{p^k-\chi_{d_0}(p)}\right)\log (p), \end{align*} $$
$$ \begin{align*} \frac{\sigma_{m}'(k)}{\sigma_{m}(k)}=-\sum_{p\mid 2m\det(L)}\left(\frac{p^{1-r}\mathrm{L}_m^{(p)'}\left(p^{1-r}\right)}{\mathrm{L}_m^{(p)}\left(p^{1-r}\right)}+\frac{\chi_{d_0}(p)}{p^k-\chi_{d_0}(p)}\right)\log (p), \end{align*} $$
and for r odd
 $$ \begin{align*} \frac{\sigma_{m}'(k)}{\sigma_{m}(k)}=-\sum_{p\mid 2m\det(L)}\left(\frac{p^{1-r}\mathrm{L}_m^{(p)'}\left(p^{1-r}\right)}{\mathrm{L}_m^{(p)}\left(p^{1-r}\right)}-\frac{\chi_{d_0}(p)}{p^{k-\frac{1}{2}}-\chi_{d_0}(p)}+\frac{2}{p^{2k-1}-1}\right) \log(p). \end{align*} $$
$$ \begin{align*} \frac{\sigma_{m}'(k)}{\sigma_{m}(k)}=-\sum_{p\mid 2m\det(L)}\left(\frac{p^{1-r}\mathrm{L}_m^{(p)'}\left(p^{1-r}\right)}{\mathrm{L}_m^{(p)}\left(p^{1-r}\right)}-\frac{\chi_{d_0}(p)}{p^{k-\frac{1}{2}}-\chi_{d_0}(p)}+\frac{2}{p^{2k-1}-1}\right) \log(p). \end{align*} $$
 Since 
 $k=1+\frac {b}{2}\geq \frac {5}{2}$
, we have
$k=1+\frac {b}{2}\geq \frac {5}{2}$
, we have 
 $$ \begin{align*} \left|\sum_{p\mid 2m\det(L)}\frac{\chi_{d_0}(p)\log(p)}{p^k-\chi_{d_0}(p)}\right|\leq \sum_{p}\frac{\log(p)}{p^{5/2}-1}<+\infty, \end{align*} $$
$$ \begin{align*} \left|\sum_{p\mid 2m\det(L)}\frac{\chi_{d_0}(p)\log(p)}{p^k-\chi_{d_0}(p)}\right|\leq \sum_{p}\frac{\log(p)}{p^{5/2}-1}<+\infty, \end{align*} $$
 $$ \begin{align*} \left|\sum_{p\mid 2m\det(L)}\frac{\chi_{d_0}(p)\log(p)}{p^{k-\frac{1}{2}}-\chi_{d_0}(p)}\right|\leq \sum_{p}\frac{\log(p)}{p^{2}-1}<+\infty, \end{align*} $$
$$ \begin{align*} \left|\sum_{p\mid 2m\det(L)}\frac{\chi_{d_0}(p)\log(p)}{p^{k-\frac{1}{2}}-\chi_{d_0}(p)}\right|\leq \sum_{p}\frac{\log(p)}{p^{2}-1}<+\infty, \end{align*} $$
 $$ \begin{align*} \left|\sum_{p\mid 2m\det(L)}\frac{2\log p}{p^{2k-1}-1}\right|\leq \sum_{p}\frac{2\log(p)}{p^{4}-1}<+\infty. \end{align*} $$
$$ \begin{align*} \left|\sum_{p\mid 2m\det(L)}\frac{2\log p}{p^{2k-1}-1}\right|\leq \sum_{p}\frac{2\log(p)}{p^{4}-1}<+\infty. \end{align*} $$
Hence it remains to treat the 
 $L^{(p)}_m$
 term. We have
$L^{(p)}_m$
 term. We have 
 $\mathrm {L}^{(p)}_{m}(p^{1-r})=N_{m}(p^{w_p})p^{(1-r)w_p}$
 and
$\mathrm {L}^{(p)}_{m}(p^{1-r})=N_{m}(p^{w_p})p^{(1-r)w_p}$
 and 
 $$ \begin{align*}\mathrm{L}^{(p)'}_{m}(p^{1-r})=w_pN_{m}(p^{w_p})p^{(1-r)(w_p-1)}-\sum_{n=0}^{w_p-1}N_{m}(p^n)p^{(n-1)(1-r)}.\end{align*} $$
$$ \begin{align*}\mathrm{L}^{(p)'}_{m}(p^{1-r})=w_pN_{m}(p^{w_p})p^{(1-r)(w_p-1)}-\sum_{n=0}^{w_p-1}N_{m}(p^n)p^{(n-1)(1-r)}.\end{align*} $$
Hence
 $$ \begin{align*} \left|\frac{p^{1-r}\mathrm{L}_m^{(p)'}\left(p^{1-r}\right)}{\mathrm{L}_m^{(p)}\left(p^{1-r}\right)}\right|=\left|w_p-\sum_{n=0}^{w_p-1}\frac{N_{m}(p^n)}{N_{m}(p^{w_p})}p^{(n-w_p)(1-r)}\right|=\left|w_p-\sum_{n=0}^{w_p-1}\frac{\mu_{p}(m,n)}{\mu_{p}(m,w_p)}\right|\leq \frac{C}{p}, \end{align*} $$
$$ \begin{align*} \left|\frac{p^{1-r}\mathrm{L}_m^{(p)'}\left(p^{1-r}\right)}{\mathrm{L}_m^{(p)}\left(p^{1-r}\right)}\right|=\left|w_p-\sum_{n=0}^{w_p-1}\frac{N_{m}(p^n)}{N_{m}(p^{w_p})}p^{(n-w_p)(1-r)}\right|=\left|w_p-\sum_{n=0}^{w_p-1}\frac{\mu_{p}(m,n)}{\mu_{p}(m,w_p)}\right|\leq \frac{C}{p}, \end{align*} $$
where 
 $\mu _{p}(m,n)=p^{-n(r-1)}N_{m}(p^n)$
 as in Section 4.1, and the last inequality follows from Proposition 4.1 with constant C only depending on
$\mu _{p}(m,n)=p^{-n(r-1)}N_{m}(p^n)$
 as in Section 4.1, and the last inequality follows from Proposition 4.1 with constant C only depending on 
 $(L,Q)$
 (i.e., is independent of
$(L,Q)$
 (i.e., is independent of 
 $m,p$
). Thus we have
$m,p$
). Thus we have 
 $$ \begin{align*} \left|\sum_{p\mid 2m\det(L) }\frac{p^{1-r}\mathrm{L}_m^{(p)'}\left(p^{1-r}\right)}{\mathrm{L}_m^{(p)}\left(p^{1-r}\right)}\right|\leq C\sum_{p\mid 2m\det(L)}\frac{\log(p)}{p}=O(\log\log(m)). \end{align*} $$
$$ \begin{align*} \left|\sum_{p\mid 2m\det(L) }\frac{p^{1-r}\mathrm{L}_m^{(p)'}\left(p^{1-r}\right)}{\mathrm{L}_m^{(p)}\left(p^{1-r}\right)}\right|\leq C\sum_{p\mid 2m\det(L)}\frac{\log(p)}{p}=O(\log\log(m)). \end{align*} $$
Here we use the fact that for 
 $N\geq 2$
,
$N\geq 2$
, 
 $\sum _{p\mid N}\frac {\log (p)}{p}=O(\log \log (N))$
. Indeed, let
$\sum _{p\mid N}\frac {\log (p)}{p}=O(\log \log (N))$
. Indeed, let 
 $X=\log (N)$
, and use Mertens’ first theorem to write
$X=\log (N)$
, and use Mertens’ first theorem to write 
 $$ \begin{align*} \sum_{p\mid N}\frac{\log(p)}{p}&=\sum_{p\mid N,p<X}\frac{\log(p)}{p}+\sum_{p\mid N,p\geq X}\frac{\log(p)}{p}\leq \log(X)+\frac{1}{X}\sum_{p\mid N}\log(p)+O(1)\\ &\leq \log(X)+\frac{\log(N)}{X}+O(1)\leq \log(\log(N))+O(1). \end{align*} $$
$$ \begin{align*} \sum_{p\mid N}\frac{\log(p)}{p}&=\sum_{p\mid N,p<X}\frac{\log(p)}{p}+\sum_{p\mid N,p\geq X}\frac{\log(p)}{p}\leq \log(X)+\frac{1}{X}\sum_{p\mid N}\log(p)+O(1)\\ &\leq \log(X)+\frac{\log(N)}{X}+O(1)\leq \log(\log(N))+O(1). \end{align*} $$
This concludes the proof of the proposition.
5.3 Estimates on 
 $\phi _m(x)$
$\phi _m(x)$
 Recall that 
 $x\in M(\mathbb {C})$
 is a Hodge-generic point, and we pick a lift of x to
$x\in M(\mathbb {C})$
 is a Hodge-generic point, and we pick a lift of x to 
 $D_L$
. We will associate the quantity
$D_L$
. We will associate the quantity 
 $A(m,x)$
 to x, which is independent of the choice of the lift. Thus, we will also denote this lift by x. Recall from Section 5.1 that for
$A(m,x)$
 to x, which is independent of the choice of the lift. Thus, we will also denote this lift by x. Recall from Section 5.1 that for 
 $\lambda \in L_{\mathbb {R}}$
, we use
$\lambda \in L_{\mathbb {R}}$
, we use 
 $\lambda _x$
 to denote the orthogonal projection of
$\lambda _x$
 to denote the orthogonal projection of 
 $\lambda $
 onto the negative definite plane in
$\lambda $
 onto the negative definite plane in 
 $L_{\mathbb {R}}$
 associated to x. Define
$L_{\mathbb {R}}$
 associated to x. Define 
 $$ \begin{align} A(m,x):=-2\sum_{\underset{|Q(\lambda_x)|\leq 1,Q(\lambda)=1}{\sqrt{m}\lambda\in L}}\log (|Q(\lambda_x)|). \end{align} $$
$$ \begin{align} A(m,x):=-2\sum_{\underset{|Q(\lambda_x)|\leq 1,Q(\lambda)=1}{\sqrt{m}\lambda\in L}}\log (|Q(\lambda_x)|). \end{align} $$
Note that since x is Hodge-generic, for any 
 $\lambda \in L$
,
$\lambda \in L$
, 
 $\lambda _x\neq 0$
. Hence for any
$\lambda _x\neq 0$
. Hence for any 
 $\lambda \in L_{\mathbb {R}}$
 such that
$\lambda \in L_{\mathbb {R}}$
 such that 
 $\mathbb {R}\lambda \cap L\neq \{0\}$
, we also have
$\mathbb {R}\lambda \cap L\neq \{0\}$
, we also have 
 $\lambda _x\neq 0$
. On the other hand, the conditions
$\lambda _x\neq 0$
. On the other hand, the conditions 
 $|Q(\lambda _x)|\leq 1,Q(\lambda )=1$
 cut out a compact region in
$|Q(\lambda _x)|\leq 1,Q(\lambda )=1$
 cut out a compact region in 
 $L_{\mathbb {R}}$
, and hence for a fixed m,
$L_{\mathbb {R}}$
, and hence for a fixed m, 
 $A(m,x)$
 is the sum of finitely many terms. Therefore
$A(m,x)$
 is the sum of finitely many terms. Therefore 
 $A(m,x)$
 is well-defined and non-negative.
$A(m,x)$
 is well-defined and non-negative.
The main purpose of this subsection is to prove the following result.
Proposition 5.4. For 
 $m\in \mathbb {Z}_{>0}$
, we have
$m\in \mathbb {Z}_{>0}$
, we have 
 $$ \begin{align*}\phi_{m}(x)=A(m,x) +O(m^{\frac{b}{2}}).\end{align*} $$
$$ \begin{align*}\phi_{m}(x)=A(m,x) +O(m^{\frac{b}{2}}).\end{align*} $$
 Recall that 
 $F(s,t)$
 from Section 5.1. Since
$F(s,t)$
 from Section 5.1. Since 
 $F(s,0)=1$
, for
$F(s,0)=1$
, for 
 $z\in \mathbb {C}$
 with
$z\in \mathbb {C}$
 with 
 $|z|<1$
, we may write
$|z|<1$
, we may write 
 $F(s,z)=zG(s,z)+1$
. Recall that we set
$F(s,z)=zG(s,z)+1$
. Recall that we set 
 $k=1+\frac {b}{2}$
. From the definitions, we obtain the following decomposition of
$k=1+\frac {b}{2}$
. From the definitions, we obtain the following decomposition of 
 $\phi _{m}(x)$
:
$\phi _{m}(x)$
: 
 $$ \begin{align} \begin{array}{rcl} \phi_{m}(x)&\overset{(5.4)}{=}&\displaystyle \lim_{s\to\frac{k}{2}}\Bigl(\phi_m(x,s)+\frac{c(m)}{s-\frac{k}2} \Bigr) \\[.2in]&\overset{(5.3)}{=}&\displaystyle \lim_{\underset{\operatorname{\mathrm{Re}} s>0}{ s\to 0}}\left(\frac{c(m)}{s}+\frac{4}{b}\sum_{\underset{Q(\lambda)=m}{\lambda\in L}}\Bigl(\frac{m}{m-Q(\lambda_x)}\Bigr)^{k-1+s} F\Bigl(\frac{k}{2}+s,\frac{m}{m-Q(\lambda_x)}\Bigr)\right) \\[.3in]&=&\displaystyle \widetilde{\phi}_m(x,0)+ \lim_{\underset{\operatorname{\mathrm{Re}} s>0}{ s\to 0}}R_x(s,m), \end{array} \end{align} $$
$$ \begin{align} \begin{array}{rcl} \phi_{m}(x)&\overset{(5.4)}{=}&\displaystyle \lim_{s\to\frac{k}{2}}\Bigl(\phi_m(x,s)+\frac{c(m)}{s-\frac{k}2} \Bigr) \\[.2in]&\overset{(5.3)}{=}&\displaystyle \lim_{\underset{\operatorname{\mathrm{Re}} s>0}{ s\to 0}}\left(\frac{c(m)}{s}+\frac{4}{b}\sum_{\underset{Q(\lambda)=m}{\lambda\in L}}\Bigl(\frac{m}{m-Q(\lambda_x)}\Bigr)^{k-1+s} F\Bigl(\frac{k}{2}+s,\frac{m}{m-Q(\lambda_x)}\Bigr)\right) \\[.3in]&=&\displaystyle \widetilde{\phi}_m(x,0)+ \lim_{\underset{\operatorname{\mathrm{Re}} s>0}{ s\to 0}}R_x(s,m), \end{array} \end{align} $$
where for 
 $s\in \mathbb {C}$
 with
$s\in \mathbb {C}$
 with 
 $\operatorname {\mathrm {Re}} s>0$
, we define
$\operatorname {\mathrm {Re}} s>0$
, we define 
 $$ \begin{align*} \begin{array}{rcl} \displaystyle\widetilde{\phi}_{m}(x,s) &=& \displaystyle\frac{4}{b}\sum_{\underset{Q(\lambda)=1}{\sqrt{m}\lambda\in L}} \Bigl(\frac{1}{1-Q(\lambda_x)}\Bigr)^{k+s}G\Bigl(\frac{k}{2}+s,\frac{1}{1-Q(\lambda_x)}\Bigr), \\[.2in] \displaystyle R_x(s,m)&=& \displaystyle\frac{c(m)}{s}+\frac{4}{b}\sum_{\underset{Q(\lambda)=1}{\sqrt{m}\lambda\in L}}\Bigl(\frac{1}{1-Q(\lambda_x)}\Bigr)^{k-1+s}; \displaystyle \end{array} \end{align*} $$
$$ \begin{align*} \begin{array}{rcl} \displaystyle\widetilde{\phi}_{m}(x,s) &=& \displaystyle\frac{4}{b}\sum_{\underset{Q(\lambda)=1}{\sqrt{m}\lambda\in L}} \Bigl(\frac{1}{1-Q(\lambda_x)}\Bigr)^{k+s}G\Bigl(\frac{k}{2}+s,\frac{1}{1-Q(\lambda_x)}\Bigr), \\[.2in] \displaystyle R_x(s,m)&=& \displaystyle\frac{c(m)}{s}+\frac{4}{b}\sum_{\underset{Q(\lambda)=1}{\sqrt{m}\lambda\in L}}\Bigl(\frac{1}{1-Q(\lambda_x)}\Bigr)^{k-1+s}; \displaystyle \end{array} \end{align*} $$
in Section 5.3.2, we will prove that the above series defining 
 $\widetilde {\phi }_m(x,s)$
 indeed converges uniformly absolutely in a small compact neighbourhood of
$\widetilde {\phi }_m(x,s)$
 indeed converges uniformly absolutely in a small compact neighbourhood of 
 $s=0$
 in
$s=0$
 in 
 $\mathbb {C}$
, and hence it defines a function holomorphic at
$\mathbb {C}$
, and hence it defines a function holomorphic at 
 $0$
, and we still denote this function by
$0$
, and we still denote this function by 
 $\widetilde {\phi }_m(x,s)$
. In particular,
$\widetilde {\phi }_m(x,s)$
. In particular, 
 $\widetilde {\phi }_m(x,0)$
 is well defined and equal to
$\widetilde {\phi }_m(x,0)$
 is well defined and equal to 
 $\lim _{\operatorname {\mathrm {Re}} s>0, s\rightarrow 0}\widetilde {\phi }_m(x,s)$
. Therefore, the last equality in equation (5.8) is valid; moreover, since
$\lim _{\operatorname {\mathrm {Re}} s>0, s\rightarrow 0}\widetilde {\phi }_m(x,s)$
. Therefore, the last equality in equation (5.8) is valid; moreover, since 
 $\phi _m(x,s+\frac {k}{2})+\frac {c(m)}{s}$
 admits a holomorphic continuation to
$\phi _m(x,s+\frac {k}{2})+\frac {c(m)}{s}$
 admits a holomorphic continuation to 
 $s=0$
 (see Section 5.1), then
$s=0$
 (see Section 5.1), then 
 $R_x(s,m)$
 admits a holomorphic continuation to
$R_x(s,m)$
 admits a holomorphic continuation to 
 $s=0$
. We use
$s=0$
. We use 
 $R_x(0,m)$
 to denote
$R_x(0,m)$
 to denote 
 $\lim _{\operatorname {\mathrm {Re}} s>0, s\to 0}R_x(s,m)=\lim _{s\in \mathbb {R}_{>0}, s\to 0}R_x(s,m)$
 and rewrite equation (5.8) as
$\lim _{\operatorname {\mathrm {Re}} s>0, s\to 0}R_x(s,m)=\lim _{s\in \mathbb {R}_{>0}, s\to 0}R_x(s,m)$
 and rewrite equation (5.8) as 
 $$ \begin{align} \phi_m(x)=\widetilde{\phi}_{m}(x,0)+R_x(0,m). \end{align} $$
$$ \begin{align} \phi_m(x)=\widetilde{\phi}_{m}(x,0)+R_x(0,m). \end{align} $$
Note that the second equality in equation (5.8) also uses the fact that the ratio of 
 $\Gamma $
-functions in equation (5.3) is holomorphic and has a limit of
$\Gamma $
-functions in equation (5.3) is holomorphic and has a limit of 
 $2/b$
.
$2/b$
.
 In what follows next, we estimate 
 $R_x(0,m)$
 and
$R_x(0,m)$
 and 
 $\widetilde {\phi }_{m}(x,0)$
 using results from Section 4.3, where we use the work of Heath-Brown and Niedermowwe to estimate the number of the lattice points
$\widetilde {\phi }_{m}(x,0)$
 using results from Section 4.3, where we use the work of Heath-Brown and Niedermowwe to estimate the number of the lattice points 
 $\lambda $
 in certain regions in L with
$\lambda $
 in certain regions in L with 
 $Q(\lambda )=m$
.
$Q(\lambda )=m$
.
5.3.1 Bounding 
 $R_x(0,m)$
$R_x(0,m)$
 We only consider 
 $s\in \mathbb {R}_{\geq 0}$
. Recall from Section 4.3 that for
$s\in \mathbb {R}_{\geq 0}$
. Recall from Section 4.3 that for 
 $\lambda \in L_{\mathbb {R},1}=\{\lambda \in L_{\mathbb {R}}:Q(\lambda )=1\}$
, we set
$\lambda \in L_{\mathbb {R},1}=\{\lambda \in L_{\mathbb {R}}:Q(\lambda )=1\}$
, we set 
 $\displaystyle h_s(\lambda )=\left (\frac {1}{1-Q(\lambda _x)}\right )^{k-1+s}$
;
$\displaystyle h_s(\lambda )=\left (\frac {1}{1-Q(\lambda _x)}\right )^{k-1+s}$
; 
 $\displaystyle a(m)=\frac {-c(m)\Gamma (k)\sqrt {|L^\vee /L|}}{2(2\pi )^{k}}>0$
, and
$\displaystyle a(m)=\frac {-c(m)\Gamma (k)\sqrt {|L^\vee /L|}}{2(2\pi )^{k}}>0$
, and 
 $\mu _\infty $
 denotes the measure on
$\mu _\infty $
 denotes the measure on 
 $L_{\mathbb {R},1}$
 defined in equation (4.5).
$L_{\mathbb {R},1}$
 defined in equation (4.5).
 For 
 $s>0$
, Lemma 4.14 yields the equality
$s>0$
, Lemma 4.14 yields the equality 
 $$ \begin{align*}R_x(s,m)=\frac{4}{b}\sum_{\underset{Q(\lambda)=1}{\sqrt{m}\lambda\in L}}h_s(\lambda)-\frac{4a(m)}{b}\int_{L_{\mathbb{R},1}}h_s(\lambda)d\mu_{\infty}(\lambda).\end{align*} $$
$$ \begin{align*}R_x(s,m)=\frac{4}{b}\sum_{\underset{Q(\lambda)=1}{\sqrt{m}\lambda\in L}}h_s(\lambda)-\frac{4a(m)}{b}\int_{L_{\mathbb{R},1}}h_s(\lambda)d\mu_{\infty}(\lambda).\end{align*} $$
Our next result provides the required bound on 
 $R_x(0,m)$
.
$R_x(0,m)$
.
Proposition 5.5. For a given 
 $x\in D_L$
 Hodge-generic, we have
$x\in D_L$
 Hodge-generic, we have 
 $$ \begin{align*}R_x(0,m)=\lim_{s\in \mathbb{R}_{>0}, s\rightarrow 0} R_x(s,m) =O(m^{\frac{b}{2}}).\end{align*} $$
$$ \begin{align*}R_x(0,m)=\lim_{s\in \mathbb{R}_{>0}, s\rightarrow 0} R_x(s,m) =O(m^{\frac{b}{2}}).\end{align*} $$
Proof. Fix 
 $\epsilon>0$
, and we only consider
$\epsilon>0$
, and we only consider 
 $s\in [0,\epsilon ]$
. As in Section 4.3,
$s\in [0,\epsilon ]$
. As in Section 4.3, 
 $\Omega _T=\{\lambda \in L_{\mathbb {R},1}:-Q(\lambda _x)\in [0,T]\}$
. For an integer
$\Omega _T=\{\lambda \in L_{\mathbb {R},1}:-Q(\lambda _x)\in [0,T]\}$
. For an integer 
 $N\geq 0$
, define the set
$N\geq 0$
, define the set 
 $\Theta _N:=\Omega _{N+1}\backslash \Omega _N$
, and note that for
$\Theta _N:=\Omega _{N+1}\backslash \Omega _N$
, and note that for 
 $\lambda \in \Theta _N$
, we have
$\lambda \in \Theta _N$
, we have 
 $$ \begin{align*}h_s(\lambda)=\frac{1}{(N+1)^{s+k-1}}+O\Bigl(\frac{1}{(N+1)^{s+k}}\Bigr). \end{align*} $$
$$ \begin{align*}h_s(\lambda)=\frac{1}{(N+1)^{s+k-1}}+O\Bigl(\frac{1}{(N+1)^{s+k}}\Bigr). \end{align*} $$
To obtain a uniformly absolutely convergent expression for 
 $R_x(s,m)$
 for
$R_x(s,m)$
 for 
 $s\in ]0, \epsilon ]$
, we write
$s\in ]0, \epsilon ]$
, we write 
 $$ \begin{align*} \frac{b}{4}R_x(s,m)= \sum_{N=0}^\infty \Bigl(\sum_{\substack{\lambda\in\Theta_N \\\sqrt{m}\lambda\in L}} h_s(\lambda)-a(m)\int_{\Theta(N)}h_s(\lambda)d\mu_{\infty}(\lambda)\Bigr). \end{align*} $$
$$ \begin{align*} \frac{b}{4}R_x(s,m)= \sum_{N=0}^\infty \Bigl(\sum_{\substack{\lambda\in\Theta_N \\\sqrt{m}\lambda\in L}} h_s(\lambda)-a(m)\int_{\Theta(N)}h_s(\lambda)d\mu_{\infty}(\lambda)\Bigr). \end{align*} $$
We use the above estimate of 
 $h_s(\lambda )$
 for
$h_s(\lambda )$
 for 
 $\lambda \in \Theta _N$
 and bound the associated error term using Proposition 4.13 and Lemma 4.11. More precisely, let
$\lambda \in \Theta _N$
 and bound the associated error term using Proposition 4.13 and Lemma 4.11. More precisely, let 
 $C>0$
 be an absolute constant such that for all
$C>0$
 be an absolute constant such that for all 
 $\lambda \in \Theta _N$
, for all
$\lambda \in \Theta _N$
, for all 
 $s\in [0,\epsilon ]$
, we have
$s\in [0,\epsilon ]$
, we have 
 $|h_s(\lambda )-(N+1)^{-(s+k-1)}|<C(N+1)^{-(s+k)}$
. Then the error term is bounded by
$|h_s(\lambda )-(N+1)^{-(s+k-1)}|<C(N+1)^{-(s+k)}$
. Then the error term is bounded by 
 $$ \begin{align} \begin{array}{rcl} & & \displaystyle C \sum_{N=0}^{\infty} (N+1)^{-(s+k)} \Bigl(\sum_{\substack{\lambda\in\Theta_N \\\sqrt{m}\lambda\in L}}1 + a(m)\mu_\infty(\Theta_N)\Bigr) \\& = & \displaystyle C\sum_{N=1}^\infty (N^{-(s+k)}-(N+1)^{-(s+k)})\Bigl(\sum_{\substack{\lambda\in\Omega_N \\\sqrt{m}\lambda\in L}}1 + a(m)\mu_\infty(\Omega_N)\Bigr) \\ & \ll & \displaystyle a(m) \sum_{N=1}^\infty N^{-(s+k+1)}\cdot N^{\frac{b}{2}} = a(m) \sum_{N=1}^\infty N^{-s-2} \ll a(m)=O(m^{\frac{b}{2}}), \end{array} \end{align} $$
$$ \begin{align} \begin{array}{rcl} & & \displaystyle C \sum_{N=0}^{\infty} (N+1)^{-(s+k)} \Bigl(\sum_{\substack{\lambda\in\Theta_N \\\sqrt{m}\lambda\in L}}1 + a(m)\mu_\infty(\Theta_N)\Bigr) \\& = & \displaystyle C\sum_{N=1}^\infty (N^{-(s+k)}-(N+1)^{-(s+k)})\Bigl(\sum_{\substack{\lambda\in\Omega_N \\\sqrt{m}\lambda\in L}}1 + a(m)\mu_\infty(\Omega_N)\Bigr) \\ & \ll & \displaystyle a(m) \sum_{N=1}^\infty N^{-(s+k+1)}\cdot N^{\frac{b}{2}} = a(m) \sum_{N=1}^\infty N^{-s-2} \ll a(m)=O(m^{\frac{b}{2}}), \end{array} \end{align} $$
where the first equality is a partial summation and the implicit constants above are absolute.
 To bound the main term, we pick some 
 $A>1$
 in Proposition 4.13. By partial summation, we write
$A>1$
 in Proposition 4.13. By partial summation, we write 
 $$ \begin{align*} \begin{array}{rcl} &&\displaystyle \sum_{N=0}^{\infty}\frac{1}{(N+1)^{s+k-1}} \Bigl(\sum_{\substack{\lambda\in\Theta_N \\\sqrt{m}\lambda\in L}}1 -a(m)\mu_\infty(\Theta_N)\Bigr) \\[.2in]&=& \displaystyle \sum_{N=1}^{\infty} \Bigl(\frac{1}{N^{s+k-1}}-\frac{1}{(N+1)^{s+k-1}}\Bigr) \Bigl(\sum_{\substack{\lambda\in\Omega_N \\\sqrt{m}\lambda\in L}}1 -a(m)\mu_\infty(\Omega_N)\Bigr) \\[.2in]&\ll&\displaystyle \displaystyle \sum_{N=1}^{\infty}N^{-(s+k)} \cdot N^{\frac{b}{2}}m^{\frac{b}{2}}(\log mN)^{-A}\leq m^{\frac{b}{2}}\sum_{N=1}^\infty N^{-1}(\log N)^{-A}\ll m^{\frac{b}{2}}, \end{array} \end{align*} $$
$$ \begin{align*} \begin{array}{rcl} &&\displaystyle \sum_{N=0}^{\infty}\frac{1}{(N+1)^{s+k-1}} \Bigl(\sum_{\substack{\lambda\in\Theta_N \\\sqrt{m}\lambda\in L}}1 -a(m)\mu_\infty(\Theta_N)\Bigr) \\[.2in]&=& \displaystyle \sum_{N=1}^{\infty} \Bigl(\frac{1}{N^{s+k-1}}-\frac{1}{(N+1)^{s+k-1}}\Bigr) \Bigl(\sum_{\substack{\lambda\in\Omega_N \\\sqrt{m}\lambda\in L}}1 -a(m)\mu_\infty(\Omega_N)\Bigr) \\[.2in]&\ll&\displaystyle \displaystyle \sum_{N=1}^{\infty}N^{-(s+k)} \cdot N^{\frac{b}{2}}m^{\frac{b}{2}}(\log mN)^{-A}\leq m^{\frac{b}{2}}\sum_{N=1}^\infty N^{-1}(\log N)^{-A}\ll m^{\frac{b}{2}}, \end{array} \end{align*} $$
which is again sufficient. The proposition follows.
5.3.2 Estimating 
 $\widetilde {\phi }_{m}(x,0)$
$\widetilde {\phi }_{m}(x,0)$
 We fix an 
 $\epsilon \in ]0,1/2]$
 and consider
$\epsilon \in ]0,1/2]$
 and consider 
 $s\in \mathbb {C}$
 such that
$s\in \mathbb {C}$
 such that 
 $|s|\leq \epsilon $
. Since
$|s|\leq \epsilon $
. Since 
 $$ \begin{align*}\displaystyle G\left(s+\frac{k}{2},z\right)=\sum_{n=1}^\infty\frac{\Gamma(s+k-1+n)\Gamma(s+1+n)\Gamma(2s+k)}{\Gamma(s+k-1)\Gamma(s+1)\Gamma(2s+k+n)}\frac{z^{n-1}}{n!}\end{align*} $$
$$ \begin{align*}\displaystyle G\left(s+\frac{k}{2},z\right)=\sum_{n=1}^\infty\frac{\Gamma(s+k-1+n)\Gamma(s+1+n)\Gamma(2s+k)}{\Gamma(s+k-1)\Gamma(s+1)\Gamma(2s+k+n)}\frac{z^{n-1}}{n!}\end{align*} $$
converges uniformly absolutely for 
 $|s|\leq \epsilon , |z|\leq 1/2$
, then
$|s|\leq \epsilon , |z|\leq 1/2$
, then 
 $G\left (s+\frac {k}{2},z\right )$
 is absolutely bounded for such s and z.
$G\left (s+\frac {k}{2},z\right )$
 is absolutely bounded for such s and z.
 To show that 
 $\widetilde {\phi }_m(x,s)$
 is holomorphic in
$\widetilde {\phi }_m(x,s)$
 is holomorphic in 
 $|s|<\epsilon $
, we write
$|s|<\epsilon $
, we write 
 $$ \begin{align*} \begin{array}{rcl} \displaystyle\frac{b}{4}\widetilde{\phi}_m(x,s)&=& \displaystyle \sum_{\substack{\sqrt{m}\lambda\in L\\Q(\lambda)=1\\ |Q(\lambda_x)|>1}} \Bigl(\frac{1}{1-Q(\lambda_x)}\Bigr)^{k+s}G\Bigl(\frac{k}{2}+s,\frac{1}{1-Q(\lambda_x)}\Bigr) \\[.2in]&&+\displaystyle \sum_{\substack{\sqrt{m}\lambda\in L\\Q(\lambda)=1\\|Q(\lambda_x)|\leq 1}} \Bigl(\frac{1}{1-Q(\lambda_x)}\Bigr)^{k+s}G\Bigl(\frac{k}{2}+s,\frac{1}{1-Q(\lambda_x)}\Bigr), \end{array} \end{align*} $$
$$ \begin{align*} \begin{array}{rcl} \displaystyle\frac{b}{4}\widetilde{\phi}_m(x,s)&=& \displaystyle \sum_{\substack{\sqrt{m}\lambda\in L\\Q(\lambda)=1\\ |Q(\lambda_x)|>1}} \Bigl(\frac{1}{1-Q(\lambda_x)}\Bigr)^{k+s}G\Bigl(\frac{k}{2}+s,\frac{1}{1-Q(\lambda_x)}\Bigr) \\[.2in]&&+\displaystyle \sum_{\substack{\sqrt{m}\lambda\in L\\Q(\lambda)=1\\|Q(\lambda_x)|\leq 1}} \Bigl(\frac{1}{1-Q(\lambda_x)}\Bigr)^{k+s}G\Bigl(\frac{k}{2}+s,\frac{1}{1-Q(\lambda_x)}\Bigr), \end{array} \end{align*} $$
where, similar to the definition of 
 $A(m,x)$
 in equation (5.7), the second term is a finite sum of holomorphic functions. Thus we only need to show that the first term converges absolutely uniformly on
$A(m,x)$
 in equation (5.7), the second term is a finite sum of holomorphic functions. Thus we only need to show that the first term converges absolutely uniformly on 
 $|s|\leq \epsilon $
. The uniform absolute convergence follows from the boundedness of
$|s|\leq \epsilon $
. The uniform absolute convergence follows from the boundedness of 
 $G(s+k/2,z)$
 in conjunction with an argument identical to equation (5.10), which indeed implies that
$G(s+k/2,z)$
 in conjunction with an argument identical to equation (5.10), which indeed implies that 
 $$\begin{align*}\sum_{\substack{\sqrt{m}\lambda\in L\\Q(\lambda)=1\\ |Q(\lambda_x)|>1}} \Bigl(\frac{1}{1-Q(\lambda_x)}\Bigr)^{k+s}G\Bigl(\frac{k}{2}+s,\frac{1}{1-Q(\lambda_x)}\Bigr)=O(m^{\frac{b}{2}}).\end{align*}$$
$$\begin{align*}\sum_{\substack{\sqrt{m}\lambda\in L\\Q(\lambda)=1\\ |Q(\lambda_x)|>1}} \Bigl(\frac{1}{1-Q(\lambda_x)}\Bigr)^{k+s}G\Bigl(\frac{k}{2}+s,\frac{1}{1-Q(\lambda_x)}\Bigr)=O(m^{\frac{b}{2}}).\end{align*}$$
Therefore,
 $$\begin{align*}\widetilde{\phi}_m(x,0)=\frac{4}{b} \sum_{\substack{\sqrt{m}\lambda\in L\\Q(\lambda)=1\\|Q(\lambda_x)|\leq 1}} \Bigl(\frac{1}{1-Q(\lambda_x)}\Bigr)^{k}G\Bigl(\frac{k}{2},\frac{1}{1-Q(\lambda_x)}\Bigr)+O(m^{\frac{b}{2}}).\end{align*}$$
$$\begin{align*}\widetilde{\phi}_m(x,0)=\frac{4}{b} \sum_{\substack{\sqrt{m}\lambda\in L\\Q(\lambda)=1\\|Q(\lambda_x)|\leq 1}} \Bigl(\frac{1}{1-Q(\lambda_x)}\Bigr)^{k}G\Bigl(\frac{k}{2},\frac{1}{1-Q(\lambda_x)}\Bigr)+O(m^{\frac{b}{2}}).\end{align*}$$
 Obtaining an estimate on the terms with 
 $|Q(\lambda _x)|\leq 1$
 is significantly more difficult since the function
$|Q(\lambda _x)|\leq 1$
 is significantly more difficult since the function 
 $$ \begin{align*}\lambda\mapsto \left(\frac{1}{1-Q(\lambda_x)}\right)^{k}G\left(\frac{k}{2},\frac{1}{1-Q(\lambda_x)}\right)\end{align*} $$
$$ \begin{align*}\lambda\mapsto \left(\frac{1}{1-Q(\lambda_x)}\right)^{k}G\left(\frac{k}{2},\frac{1}{1-Q(\lambda_x)}\right)\end{align*} $$
has a logarithmic singularity along 
 $\{\lambda \in L_{\mathbb {R},1},\, x\in \lambda ^{\bot }\}$
. Since
$\{\lambda \in L_{\mathbb {R},1},\, x\in \lambda ^{\bot }\}$
. Since 
 $\displaystyle G(k/2,z)=\sum _{n=1}^\infty \frac {k-1}{n+k-1}z^{n-1}$
, it follows that there exists an absolute constant
$\displaystyle G(k/2,z)=\sum _{n=1}^\infty \frac {k-1}{n+k-1}z^{n-1}$
, it follows that there exists an absolute constant 
 $C>0$
 such that for
$C>0$
 such that for 
 $z\in [1/2, 1[$
,
$z\in [1/2, 1[$
, 
 $$ \begin{align*} \left|z^{k}G\left(\frac{k}{2},z\right)+\frac{b}{2}\log(1-z)\right| \leq C. \end{align*} $$
$$ \begin{align*} \left|z^{k}G\left(\frac{k}{2},z\right)+\frac{b}{2}\log(1-z)\right| \leq C. \end{align*} $$
Hence, noting that 
 $\displaystyle \sum _{\substack {|Q(\lambda _x)|\leq 1 \\\sqrt {m}\lambda \in L}}1=O(m^{\frac {b}{2}})$
, which follows from either Corollary 4.12 or Proposition 4.13, we have
$\displaystyle \sum _{\substack {|Q(\lambda _x)|\leq 1 \\\sqrt {m}\lambda \in L}}1=O(m^{\frac {b}{2}})$
, which follows from either Corollary 4.12 or Proposition 4.13, we have 
 $$ \begin{align*} \frac{4}{b}\sum_{\substack{\sqrt{m}\lambda\in L\\Q(\lambda)=1\\|Q(\lambda_x)|\leq 1}} \Bigl(\frac{1}{1-Q(\lambda_x)}\Bigr)^{k}G\Bigl(\frac{k}{2},\frac{1}{1-Q(\lambda_x)}\Bigr)&=-2\sum_{\substack{\sqrt{m}\lambda\in L\\Q(\lambda)=1\\|Q(\lambda_x)|\leq 1}}\log\Bigl(\frac{-Q(\lambda_x)}{1-Q(\lambda_x)}\Bigr)+O(m^{\frac{b}{2}}) \\ &=-2\sum_{\substack{\sqrt{m}\lambda\in L\\Q(\lambda)=1\\|Q(\lambda_x)|\leq 1}}\log (|Q(\lambda_x)|)+O(m^{\frac{b}{2}}).\\ \end{align*} $$
$$ \begin{align*} \frac{4}{b}\sum_{\substack{\sqrt{m}\lambda\in L\\Q(\lambda)=1\\|Q(\lambda_x)|\leq 1}} \Bigl(\frac{1}{1-Q(\lambda_x)}\Bigr)^{k}G\Bigl(\frac{k}{2},\frac{1}{1-Q(\lambda_x)}\Bigr)&=-2\sum_{\substack{\sqrt{m}\lambda\in L\\Q(\lambda)=1\\|Q(\lambda_x)|\leq 1}}\log\Bigl(\frac{-Q(\lambda_x)}{1-Q(\lambda_x)}\Bigr)+O(m^{\frac{b}{2}}) \\ &=-2\sum_{\substack{\sqrt{m}\lambda\in L\\Q(\lambda)=1\\|Q(\lambda_x)|\leq 1}}\log (|Q(\lambda_x)|)+O(m^{\frac{b}{2}}).\\ \end{align*} $$
Therefore, we have proved the following proposition.
Proposition 5.6. We have
 $$ \begin{align*}\widetilde{\phi}_m(x,0)=A(m,x)+O(m^{\frac{b}{2}}).\end{align*} $$
$$ \begin{align*}\widetilde{\phi}_m(x,0)=A(m,x)+O(m^{\frac{b}{2}}).\end{align*} $$
Proposition 5.4 follows immediately from equation (5.9) and Propositions 5.5 and 5.6.
5.4 Conclusions
 The following theorems summarise the results proved in the previous subsections. First, we remind the reader that 
 $|c(m)| \asymp m^{b/2}$
.
$|c(m)| \asymp m^{b/2}$
.
Theorem 5.7. For every m representable by 
 $(L,Q)$
, we have
$(L,Q)$
, we have 
 $$\begin{align*}\Phi_m(\mathcal{Y}^\sigma)=c(m)\log m + A(m, \mathcal{Y}^\sigma)+o(|c(m)|\log m).\end{align*}$$
$$\begin{align*}\Phi_m(\mathcal{Y}^\sigma)=c(m)\log m + A(m, \mathcal{Y}^\sigma)+o(|c(m)|\log m).\end{align*}$$
Theorem 5.8. For every positive integer m, we have the following bounds:
- 
(i)  $0\leq A(m,\mathcal {Y}^\sigma )\ll m^{\frac {b}{2}} \log m$
. $0\leq A(m,\mathcal {Y}^\sigma )\ll m^{\frac {b}{2}} \log m$
.
- 
(ii)  $(\mathcal {Y}.\mathcal {Z}(m))_{\mathfrak {P}}\log |\mathcal {O}_{K}/\mathfrak {P}| \ll m^{\frac {b}{2}}\log m$
. $(\mathcal {Y}.\mathcal {Z}(m))_{\mathfrak {P}}\log |\mathcal {O}_{K}/\mathfrak {P}| \ll m^{\frac {b}{2}}\log m$
.
- 
(iii)  $\displaystyle \sum _{\sigma :K\hookrightarrow \mathbb {C}}\frac {\Phi _{m}(\mathcal {Y}^\sigma )}{|\mathrm {Aut}(\mathcal {Y}^\sigma )|} = O(m^{\frac {b}{2}}\log m)$
. $\displaystyle \sum _{\sigma :K\hookrightarrow \mathbb {C}}\frac {\Phi _{m}(\mathcal {Y}^\sigma )}{|\mathrm {Aut}(\mathcal {Y}^\sigma )|} = O(m^{\frac {b}{2}}\log m)$
.
Proof. Recall that 
 $\Phi _m(\mathcal {Y}^{\sigma }) = \phi _m(\mathcal {Y}^{\sigma }) - b_m'(k/2)$
. For every integer
$\Phi _m(\mathcal {Y}^{\sigma }) = \phi _m(\mathcal {Y}^{\sigma }) - b_m'(k/2)$
. For every integer 
 $m>0$
, equation (3.1), Proposition 3.2 and Proposition 5.2 yield
$m>0$
, equation (3.1), Proposition 3.2 and Proposition 5.2 yield 
 $$ \begin{align*}\displaystyle \sum_{\mathfrak{P}} (\mathcal{Y}.\mathcal{Z}(m))_{\mathfrak{P}}\log|\mathcal{O}_{K}/\mathfrak{P}| + \sum_{\sigma: K \hookrightarrow \mathbb{C}} \phi_m(\mathcal{Y}^{\sigma}) \asymp m^{\frac{b}{2}} \log m.\end{align*} $$
$$ \begin{align*}\displaystyle \sum_{\mathfrak{P}} (\mathcal{Y}.\mathcal{Z}(m))_{\mathfrak{P}}\log|\mathcal{O}_{K}/\mathfrak{P}| + \sum_{\sigma: K \hookrightarrow \mathbb{C}} \phi_m(\mathcal{Y}^{\sigma}) \asymp m^{\frac{b}{2}} \log m.\end{align*} $$
 By Proposition 5.4, we have 
 $\phi _m(\mathcal {Y}^{\sigma }) = A(m, \mathcal {Y}^\sigma ) + O(m^{\frac {b}{2}})$
, where
$\phi _m(\mathcal {Y}^{\sigma }) = A(m, \mathcal {Y}^\sigma ) + O(m^{\frac {b}{2}})$
, where 
 $A(m, \mathcal {Y}^\sigma )$
 is a sum of positive quantities and is therefore non-negative. Further, note that
$A(m, \mathcal {Y}^\sigma )$
 is a sum of positive quantities and is therefore non-negative. Further, note that 
 $(\mathcal {Y}.\mathcal {Z}(m))_{\mathfrak {P}}\log |\mathcal {O}_{K}/\mathfrak {P}|$
 is also non-negative for every prime
$(\mathcal {Y}.\mathcal {Z}(m))_{\mathfrak {P}}\log |\mathcal {O}_{K}/\mathfrak {P}|$
 is also non-negative for every prime 
 $\mathfrak {P}$
. Therefore, it follows that
$\mathfrak {P}$
. Therefore, it follows that 
 $A(m, \mathcal {Y}^\sigma ) \ll m^{\frac {b}{2}} \log m$
,
$A(m, \mathcal {Y}^\sigma ) \ll m^{\frac {b}{2}} \log m$
, 
 $(\mathcal {Y}.\mathcal {Z}(m))_{\mathfrak {P}}\log |\mathcal {O}_{K}/\mathfrak {P}| \ll m^{\frac {b}{2}}\log m$
 and a fortiriori that
$(\mathcal {Y}.\mathcal {Z}(m))_{\mathfrak {P}}\log |\mathcal {O}_{K}/\mathfrak {P}| \ll m^{\frac {b}{2}}\log m$
 and a fortiriori that 
 $\Phi _m(\mathcal {Y}^{\sigma }) = O(m^{\frac {b}{2}}\log m)$
.
$\Phi _m(\mathcal {Y}^{\sigma }) = O(m^{\frac {b}{2}}\log m)$
.
6 Second step in bounding the archimedean contribution
 We keep the notations from Section 5.3. Namely 
 $(L,Q)$
 is a quadratic lattice of signature
$(L,Q)$
 is a quadratic lattice of signature 
 $(b,2)$
. We are given a Hodge-generic point
$(b,2)$
. We are given a Hodge-generic point 
 $x = \mathcal {Y}^{\sigma }$
 in the Shimura variety
$x = \mathcal {Y}^{\sigma }$
 in the Shimura variety 
 $M(\mathbb {C})$
 and choose a lift of x to the period domain
$M(\mathbb {C})$
 and choose a lift of x to the period domain 
 $D_L$
, which corresponds to a
$D_L$
, which corresponds to a 
 $2$
-dimensional negative definite (with respect to Q) plane
$2$
-dimensional negative definite (with respect to Q) plane 
 $P\subset L_{\mathbb {R}}$
. Let
$P\subset L_{\mathbb {R}}$
. Let 
 $P^\perp $
 denote the orthogonal complement of P in
$P^\perp $
 denote the orthogonal complement of P in 
 $L_{\mathbb {R}}$
. Then
$L_{\mathbb {R}}$
. Then 
 $P^\perp $
 is a b-dimensional positive definite space. Given a vector
$P^\perp $
 is a b-dimensional positive definite space. Given a vector 
 $\lambda \in L_{\mathbb {R}}$
, we let
$\lambda \in L_{\mathbb {R}}$
, we let 
 $\lambda _x$
 and
$\lambda _x$
 and 
 $\lambda _{x^\bot }$
 denote the projections of
$\lambda _{x^\bot }$
 denote the projections of 
 $\lambda $
 to P and
$\lambda $
 to P and 
 $P^\perp $
, respectively. For
$P^\perp $
, respectively. For 
 $m\in \mathbb {Z}_ {>0}$
, recall that we defined the quantity
$m\in \mathbb {Z}_ {>0}$
, recall that we defined the quantity 
 $A(m,x)$
 in equation (5.7) by
$A(m,x)$
 in equation (5.7) by 
 $$ \begin{align*} A(m,x) =-2\sum_{\underset{\underset{|Q(\lambda_x)|\leq1}{Q(\lambda)=1}}{\sqrt{m}\lambda\in L}}\log (|Q(\lambda_x)|)= \displaystyle2\sum_{\substack{\lambda\in L\\Q(\lambda)=m\\|Q(\lambda_x)|\leq m}} \log\Bigl(\frac{m}{|Q(\lambda_x)|}\Bigr). \end{align*} $$
$$ \begin{align*} A(m,x) =-2\sum_{\underset{\underset{|Q(\lambda_x)|\leq1}{Q(\lambda)=1}}{\sqrt{m}\lambda\in L}}\log (|Q(\lambda_x)|)= \displaystyle2\sum_{\substack{\lambda\in L\\Q(\lambda)=m\\|Q(\lambda_x)|\leq m}} \log\Bigl(\frac{m}{|Q(\lambda_x)|}\Bigr). \end{align*} $$
As x is fixed, we denote 
 $A(m,x)$
 simply by
$A(m,x)$
 simply by 
 $A(m)$
. Also, for a subset
$A(m)$
. Also, for a subset 
 $S\subset \mathbb {Z}_{>0}$
, the logarithmic asymptotic density of S is defined to be
$S\subset \mathbb {Z}_{>0}$
, the logarithmic asymptotic density of S is defined to be 
 $\displaystyle \limsup _{X\rightarrow \infty }\frac {\log |S_X|}{\log X}$
, where
$\displaystyle \limsup _{X\rightarrow \infty }\frac {\log |S_X|}{\log X}$
, where 
 $S_X:=\{a\in S \mid X\leq a < 2X\}$
. The main result of this section is the following bound on
$S_X:=\{a\in S \mid X\leq a < 2X\}$
. The main result of this section is the following bound on 
 $A(m)$
 for positive integers m outside a set of zero logarithmic asymptotic density. Combined with Theorem 5.7, we obtain the estimate for the archimedean term
$A(m)$
 for positive integers m outside a set of zero logarithmic asymptotic density. Combined with Theorem 5.7, we obtain the estimate for the archimedean term 
 $\Phi _m(\mathcal {Y}^\sigma )\asymp - m^{\frac {b}{2}}\log m$
 for such ms.
$\Phi _m(\mathcal {Y}^\sigma )\asymp - m^{\frac {b}{2}}\log m$
 for such ms.
Theorem 6.1. There exists a subset 
 $S_{\mathrm {bad}} \subset \mathbb {Z}_{>0}$
 of logarithmic asymptotic density zero such that for every
$S_{\mathrm {bad}} \subset \mathbb {Z}_{>0}$
 of logarithmic asymptotic density zero such that for every 
 $m\notin S_{\mathrm {bad}}$
, we have
$m\notin S_{\mathrm {bad}}$
, we have 
 $$ \begin{align*} A(m)=o(m^{\frac{b}{2}}\log(m)). \end{align*} $$
$$ \begin{align*} A(m)=o(m^{\frac{b}{2}}\log(m)). \end{align*} $$
 To prove Theorem 6.1, we write 
 $A(m)=A_{\mathrm {mt}}(m)+A_{\mathrm {er}}(m)$
, where we define the main term
$A(m)=A_{\mathrm {mt}}(m)+A_{\mathrm {er}}(m)$
, where we define the main term 
 $A_{\mathrm {mt}}(m)$
 and the error term
$A_{\mathrm {mt}}(m)$
 and the error term 
 $A_{\mathrm {er}}(m)$
 to be
$A_{\mathrm {er}}(m)$
 to be 
 $$ \begin{align*} \begin{array}{rcl} \displaystyle A_{\mathrm{mt}}(m) &=& \displaystyle2\sum_{\substack{\lambda\in L\\Q(\lambda)=m\\1\leq |Q(\lambda_x)|\leq m}} \log\Bigl(\frac{m}{|Q(\lambda_x)|}\Bigr),\\[.3in] \displaystyle A_{\mathrm{er}}(m) &=& \displaystyle2\sum_{\substack{\lambda\in L\\Q(\lambda)=m\\0<|Q(\lambda_x)|<1}} \log\Bigl(\frac{m}{|Q(\lambda_x)|}\Bigr). \end{array} \end{align*} $$
$$ \begin{align*} \begin{array}{rcl} \displaystyle A_{\mathrm{mt}}(m) &=& \displaystyle2\sum_{\substack{\lambda\in L\\Q(\lambda)=m\\1\leq |Q(\lambda_x)|\leq m}} \log\Bigl(\frac{m}{|Q(\lambda_x)|}\Bigr),\\[.3in] \displaystyle A_{\mathrm{er}}(m) &=& \displaystyle2\sum_{\substack{\lambda\in L\\Q(\lambda)=m\\0<|Q(\lambda_x)|<1}} \log\Bigl(\frac{m}{|Q(\lambda_x)|}\Bigr). \end{array} \end{align*} $$
In Section 6.1 and Section 6.2, we obtain bounds for the two terms 
 $A_{\mathrm {mt}}(m)$
 and
$A_{\mathrm {mt}}(m)$
 and 
 $A_{\mathrm {er}}(m)$
, respectively. Theorem 6.1 follows directly from Propositions 6.2 and 6.4. Since we only consider the fixed quadratic form Q in this section, we will not specify the dependence of the implicit constants on Q when we apply the circle method results by Heath-Brown recalled in Sections 4.2–4.3.
$A_{\mathrm {er}}(m)$
, respectively. Theorem 6.1 follows directly from Propositions 6.2 and 6.4. Since we only consider the fixed quadratic form Q in this section, we will not specify the dependence of the implicit constants on Q when we apply the circle method results by Heath-Brown recalled in Sections 4.2–4.3.
6.1 Bounding the main term using the circle method
In this section, we prove the following proposition.
Proposition 6.2. We have
 $$ \begin{align*} \lim_{m\to\infty} \frac{A_{\mathrm{mt}}(m)}{m^{\frac{b}{2}}\log m}=0. \end{align*} $$
$$ \begin{align*} \lim_{m\to\infty} \frac{A_{\mathrm{mt}}(m)}{m^{\frac{b}{2}}\log m}=0. \end{align*} $$
Proof. Fix a real number 
 $T>1$
, and let
$T>1$
, and let 
 $m>T$
 be a positive integer. We break
$m>T$
 be a positive integer. We break 
 $A_{\mathrm {mt}}(m)$
 into two terms
$A_{\mathrm {mt}}(m)$
 into two terms 
 $A_1(m)$
 and
$A_1(m)$
 and 
 $A_2(m)$
, where
$A_2(m)$
, where 
 $A_1(m)$
 is the sum over those
$A_1(m)$
 is the sum over those 
 $\lambda \in L$
 such that
$\lambda \in L$
 such that 
 $|Q(\lambda _x)|\geq m/T$
 and
$|Q(\lambda _x)|\geq m/T$
 and 
 $A_2(m)$
 is the sum over those
$A_2(m)$
 is the sum over those 
 $\lambda \in L$
 such that
$\lambda \in L$
 such that 
 $|Q(\lambda _x)|< m/T$
. We start by bounding
$|Q(\lambda _x)|< m/T$
. We start by bounding 
 $A_1(m)$
. First note that if
$A_1(m)$
. First note that if 
 $\lambda \in L$
 with
$\lambda \in L$
 with 
 $Q(\lambda )=m$
 and
$Q(\lambda )=m$
 and 
 $m/T\leq |Q(\lambda _x)|\leq m$
, then we have
$m/T\leq |Q(\lambda _x)|\leq m$
, then we have 
 $$ \begin{align*}\log\Bigl(\frac{m}{|Q(\lambda_x)|}\Bigr)\leq \log T.\end{align*} $$
$$ \begin{align*}\log\Bigl(\frac{m}{|Q(\lambda_x)|}\Bigr)\leq \log T.\end{align*} $$
Furthermore, by Corollary 4.12,
 $$ \begin{align*} |\{\lambda \in L: Q(\lambda)=m,Q(\lambda_x)\leq m\}|\ll m^{\frac{b}{2}}. \end{align*} $$
$$ \begin{align*} |\{\lambda \in L: Q(\lambda)=m,Q(\lambda_x)\leq m\}|\ll m^{\frac{b}{2}}. \end{align*} $$
Therefore, we obtain the bound
 $$ \begin{align} A_1(m)\ll m^{\frac{b}{2}}\log T. \end{align} $$
$$ \begin{align} A_1(m)\ll m^{\frac{b}{2}}\log T. \end{align} $$
 Next we consider 
 $A_2(m)$
. Once again, we apply Corollary 4.12 to obtain the bound (take
$A_2(m)$
. Once again, we apply Corollary 4.12 to obtain the bound (take 
 $\epsilon =1/4$
)
$\epsilon =1/4$
) 
 $$ \begin{align} \left|\Bigl\{\lambda\in L, Q(\lambda)=m, |Q(\lambda_x)|<\frac{m}{T}\Bigr\}\right|\ll \frac{m^{\frac{b}{2}}}{T} +O_T(m^{\frac{b+2}{4}}). \end{align} $$
$$ \begin{align} \left|\Bigl\{\lambda\in L, Q(\lambda)=m, |Q(\lambda_x)|<\frac{m}{T}\Bigr\}\right|\ll \frac{m^{\frac{b}{2}}}{T} +O_T(m^{\frac{b+2}{4}}). \end{align} $$
 Equations (6.1) and (6.2) and the trivial bound 
 $\log (m/|Q(\lambda _x)|)\leq \log m$
 for
$\log (m/|Q(\lambda _x)|)\leq \log m$
 for 
 $\lambda \in L$
 with
$\lambda \in L$
 with 
 $1\leq |Q(\lambda _x)|\leq m$
 yield the following estimate on
$1\leq |Q(\lambda _x)|\leq m$
 yield the following estimate on 
 $A_{\mathrm {mt}}(m)=A_1(m)+A_2(m)$
:
$A_{\mathrm {mt}}(m)=A_1(m)+A_2(m)$
: 
 $$ \begin{align*} A_{\mathrm{mt}}(m)\ll m^{\frac{b}{2}}\log T+m^{\frac{b}{2}}(\log m)T^{-1}+O_{T}(m^{(b+2)/4}\log m). \end{align*} $$
$$ \begin{align*} A_{\mathrm{mt}}(m)\ll m^{\frac{b}{2}}\log T+m^{\frac{b}{2}}(\log m)T^{-1}+O_{T}(m^{(b+2)/4}\log m). \end{align*} $$
Dividing by 
 $m^{\frac {b}{2}}\log (m)$
 and letting m tend to infinity, we see that
$m^{\frac {b}{2}}\log (m)$
 and letting m tend to infinity, we see that 
 $$ \begin{align*} \limsup_{m\to\infty} \frac{A_{\mathrm{mt}}(m)}{m^{\frac{b}{2}}\log m}\ll \frac{1}{T}. \end{align*} $$
$$ \begin{align*} \limsup_{m\to\infty} \frac{A_{\mathrm{mt}}(m)}{m^{\frac{b}{2}}\log m}\ll \frac{1}{T}. \end{align*} $$
Since this is true for every T, 
 $\displaystyle \lim _{m\rightarrow \infty } \frac {A_{\mathrm {mt}}(m)}{m^{\frac {b}{2}}\log m}$
 exists and is equal to
$\displaystyle \lim _{m\rightarrow \infty } \frac {A_{\mathrm {mt}}(m)}{m^{\frac {b}{2}}\log m}$
 exists and is equal to 
 $0$
.
$0$
.
6.2 Bounding the error term using the diophantine bound
We start with the following (entirely lattice theoretic) lemma.
Lemma 6.3. Let 
 $C>2$
 be a fixed constant, let
$C>2$
 be a fixed constant, let 
 $X>1$
 be a real number, and let
$X>1$
 be a real number, and let 
 $N\geq 2$
 be a positive integer. Suppose S is a set of N vectors in
$N\geq 2$
 be a positive integer. Suppose S is a set of N vectors in 
 $L_{\mathbb {R}}$
 such that
$L_{\mathbb {R}}$
 such that 
 $C\leq Q(v)\ll X$
 and
$C\leq Q(v)\ll X$
 and 
 $|Q(v_x)|< e^{-C}$
 for all
$|Q(v_x)|< e^{-C}$
 for all 
 $v\in S$
. Then there exist two distinct vectors v and
$v\in S$
. Then there exist two distinct vectors v and 
 $v'$
 in S such that their difference
$v'$
 in S such that their difference 
 $w:=v-v'$
 satisfies the following two properties:
$w:=v-v'$
 satisfies the following two properties: 
- 
1.  $-\log (|Q(w_x)|)\gg \min \bigl (-\log (|Q(v_x)|),-\log (|Q(v^{\prime }x)|)\bigr )$ $-\log (|Q(w_x)|)\gg \min \bigl (-\log (|Q(v_x)|),-\log (|Q(v^{\prime }x)|)\bigr )$
- 
2.  $Q(w_{x^\bot })\ll \frac {X}{N^{\frac {2}{b}}}$
. $Q(w_{x^\bot })\ll \frac {X}{N^{\frac {2}{b}}}$
.
All implicit constants here are absolute; in particular, they are independent of 
 $C,X,N$
.
$C,X,N$
.
Proof. The first property is immediate and is satisfied for every pair v and 
 $v'$
. Indeed, we have
$v'$
. Indeed, we have 
 $w_x=v_x-v^{\prime }x$
; and using the triangle inequality, it follows that
$w_x=v_x-v^{\prime }x$
; and using the triangle inequality, it follows that 
 $$ \begin{align*} |Q(w_x)|^{1/2}\leq 2\max(|Q(v_x)|^{1/2},|Q(v^{\prime}x)|^{1/2})<1, \end{align*} $$
$$ \begin{align*} |Q(w_x)|^{1/2}\leq 2\max(|Q(v_x)|^{1/2},|Q(v^{\prime}x)|^{1/2})<1, \end{align*} $$
since 
 $C>2$
. Hence we obtain the first claim.
$C>2$
. Hence we obtain the first claim.
 To obtain the second claim, we remark that if 
 $v\neq v'$
, then
$v\neq v'$
, then 
 $v_{x^\bot }\neq v_{x^\bot }'$
 since otherwise
$v_{x^\bot }\neq v_{x^\bot }'$
 since otherwise 
 $|Q(v-v')|=|Q(v_x-v^{\prime }x)|\in ]0,1[$
 and
$|Q(v-v')|=|Q(v_x-v^{\prime }x)|\in ]0,1[$
 and 
 $v-v'\in L$
. Thus, by considering the projections
$v-v'\in L$
. Thus, by considering the projections 
 $v_{x^\bot }$
 for
$v_{x^\bot }$
 for 
 $v\in S$
, we obtain N vectors in the b-dimensional real vector space
$v\in S$
, we obtain N vectors in the b-dimensional real vector space 
 $P^\perp $
. Let
$P^\perp $
. Let 
 $2T$
 be the smallest distance between the vectors
$2T$
 be the smallest distance between the vectors 
 $v_{x^\perp }$
 for
$v_{x^\perp }$
 for 
 $v\in S$
, where distance is taken with respect to the positive definite form Q on
$v\in S$
, where distance is taken with respect to the positive definite form Q on 
 $P^\perp $
. By the triangle inequality, we have the trivial bound
$P^\perp $
. By the triangle inequality, we have the trivial bound 
 $T=O(X^{1/2})$
. Then the N balls of radii T around the points
$T=O(X^{1/2})$
. Then the N balls of radii T around the points 
 $v_{x^\bot }$
 are disjoint and all lie within the ball of radius
$v_{x^\bot }$
 are disjoint and all lie within the ball of radius 
 $C_0\sqrt {X}$
 around the origin, where
$C_0\sqrt {X}$
 around the origin, where 
 $C_0$
 is an absolute constant depending only on the absolute implicit constant in
$C_0$
 is an absolute constant depending only on the absolute implicit constant in 
 $Q(v)\ll X$
. By comparing volumes, we obtain
$Q(v)\ll X$
. By comparing volumes, we obtain 
 $$ \begin{align*} NT^b\ll X^{\frac{b}{2}}, \end{align*} $$
$$ \begin{align*} NT^b\ll X^{\frac{b}{2}}, \end{align*} $$
from which it follows that 
 $T\ll X^{\frac {1}{2}}/N^{\frac {1}{b}}$
. Therefore, there exist two points v and
$T\ll X^{\frac {1}{2}}/N^{\frac {1}{b}}$
. Therefore, there exist two points v and 
 $v'$
 in S such that
$v'$
 in S such that 
 $$ \begin{align*}Q(v_{x^\bot}-v^{\prime}{x^\bot})\leq T^2\ll \frac{X}{N^{\frac{2}{b}}},\end{align*} $$
$$ \begin{align*}Q(v_{x^\bot}-v^{\prime}{x^\bot})\leq T^2\ll \frac{X}{N^{\frac{2}{b}}},\end{align*} $$
concluding the proof of the lemma.
 The following result controls the error term in 
 $A(m)$
 for most m.
$A(m)$
 for most m.
Proposition 6.4. Let 
 $S_{\mathrm {bad}}\subset \mathbb {N}^\times $
 be the set of integers m such that
$S_{\mathrm {bad}}\subset \mathbb {N}^\times $
 be the set of integers m such that 
 $$ \begin{align} A_{\mathrm{er}}(m)>m^{\frac{b}{2}}. \end{align} $$
$$ \begin{align} A_{\mathrm{er}}(m)>m^{\frac{b}{2}}. \end{align} $$
Then 
 $S_{\mathrm {bad}}$
 has logarithmic asymptotic density zero.
$S_{\mathrm {bad}}$
 has logarithmic asymptotic density zero.
Proof. A crucial ingredient in the proof is the ‘uniform diophantine bound’ in Theorem 5.8 (i). Since 
 $A(m)$
 is a sum of the positive terms
$A(m)$
 is a sum of the positive terms 
 $\log \left (\frac {m}{|Q(\lambda _x)|}\right )$
, each such term must also satisfy the same bound – that is, for all
$\log \left (\frac {m}{|Q(\lambda _x)|}\right )$
, each such term must also satisfy the same bound – that is, for all 
 $\lambda \in L$
 such that
$\lambda \in L$
 such that 
 $Q(\lambda )=m, |Q(\lambda _x)|\leq m$
, we have
$Q(\lambda )=m, |Q(\lambda _x)|\leq m$
, we have 
 $$ \begin{align*}\log\left(\frac{m}{|Q(\lambda_x)|}\right)\ll m^{\frac{b}{2}}\log m.\end{align*} $$
$$ \begin{align*}\log\left(\frac{m}{|Q(\lambda_x)|}\right)\ll m^{\frac{b}{2}}\log m.\end{align*} $$
 Let 
 $\epsilon \in ]0,1[$
 and
$\epsilon \in ]0,1[$
 and 
 $X>1$
, and let
$X>1$
, and let 
 $S_{\mathrm {bad},X}=]X,2X]\cap S_{\mathrm {bad}}$
. We pick a fixed constant
$S_{\mathrm {bad},X}=]X,2X]\cap S_{\mathrm {bad}}$
. We pick a fixed constant 
 $C\in [2,4]$
 and break the interval
$C\in [2,4]$
 and break the interval 
 $]C,X^{\frac {b}{2}}]$
 into the disjoint union of dyadic intervals
$]C,X^{\frac {b}{2}}]$
 into the disjoint union of dyadic intervals 
 $\cup _{i\in I}]Z_i,2Z_i]$
 such that
$\cup _{i\in I}]Z_i,2Z_i]$
 such that 
 $|I|=O(\log (X))$
. Define the three following subsets of
$|I|=O(\log (X))$
. Define the three following subsets of 
 $]X,2X]$
.
$]X,2X]$
. 
- 
1. The set  $B_{1,X}$
 of m such that $B_{1,X}$
 of m such that $$ \begin{align*}|\{\lambda\in L, Q(\lambda)=m, |Q(\lambda_x)|<1\}|\geq X^{\frac{b}{2}-\epsilon}.\end{align*} $$ $$ \begin{align*}|\{\lambda\in L, Q(\lambda)=m, |Q(\lambda_x)|<1\}|\geq X^{\frac{b}{2}-\epsilon}.\end{align*} $$
- 
2. The set  $B_{2,X}$
 of m such that there exists at least one element $B_{2,X}$
 of m such that there exists at least one element $\lambda \in L$
 with $\lambda \in L$
 with $Q(\lambda )=m$
 and $Q(\lambda )=m$
 and $-\log (|Q(\lambda _x)|)\geq X^{\frac {b}{2}}.$ $-\log (|Q(\lambda _x)|)\geq X^{\frac {b}{2}}.$
- 
3. The set  $B_{3,X}$
 of m for which there exists an index $B_{3,X}$
 of m for which there exists an index $i_m\in I$
 such that $i_m\in I$
 such that $$ \begin{align*}|\{\lambda\in L, Q(\lambda)=m, -\log(|Q(\lambda_x)|)\in]Z_{i_m},2Z_{i_m}]\}|\geq \frac{X^{\frac{b}{2}-\epsilon}}{Z_{i_m}}.\end{align*} $$ $$ \begin{align*}|\{\lambda\in L, Q(\lambda)=m, -\log(|Q(\lambda_x)|)\in]Z_{i_m},2Z_{i_m}]\}|\geq \frac{X^{\frac{b}{2}-\epsilon}}{Z_{i_m}}.\end{align*} $$
Notice that if 
 $m\in ]X,2X]\backslash (B_{1,X}\cup B_{2,X} \cup B_{3,X})$
, then we can write
$m\in ]X,2X]\backslash (B_{1,X}\cup B_{2,X} \cup B_{3,X})$
, then we can write 
 $$ \begin{align*} A_{\mathrm{er}}(m) &=2\sum_{\substack{\lambda\in L\\Q(\lambda)=m\\|Q(\lambda_x)|<1}} \log m + 2\sum_{\substack{\lambda\in L\\Q(\lambda)=m\\ -\log(|Q(\lambda_x)|)\in [0, C]}} |\log(|Q(\lambda_x)|)| + 2\sum_{\substack{\lambda\in L\\Q(\lambda)=m\\-\log(|Q(\lambda_x)|)\in ]C, X^{\frac{b}{2}}]}} |\log(|Q(\lambda_x)|)\\ &\leq 2X^{\frac{b}{2}-\epsilon}\cdot(\log(m)+C)+2\sum_{i}\sum_{\underset{-\log|Q(\lambda_x)|\in ]Z_i,2Z_i]}{\lambda\in L,Q(\lambda)=m}}(|\log(|Q(\lambda_x)|)|)\\ &\leq 2 X^{\frac{b}{2}-\epsilon}\log(2X)+ 8 X^{\frac{b}{2}-\epsilon}+4\sum_{i}\frac{X^{\frac{b}{2}-\epsilon}}{Z_i}\cdot Z_i\\ &\leq 14 X^{\frac{b}{2}-\epsilon}\log(2X)\\ \end{align*} $$
$$ \begin{align*} A_{\mathrm{er}}(m) &=2\sum_{\substack{\lambda\in L\\Q(\lambda)=m\\|Q(\lambda_x)|<1}} \log m + 2\sum_{\substack{\lambda\in L\\Q(\lambda)=m\\ -\log(|Q(\lambda_x)|)\in [0, C]}} |\log(|Q(\lambda_x)|)| + 2\sum_{\substack{\lambda\in L\\Q(\lambda)=m\\-\log(|Q(\lambda_x)|)\in ]C, X^{\frac{b}{2}}]}} |\log(|Q(\lambda_x)|)\\ &\leq 2X^{\frac{b}{2}-\epsilon}\cdot(\log(m)+C)+2\sum_{i}\sum_{\underset{-\log|Q(\lambda_x)|\in ]Z_i,2Z_i]}{\lambda\in L,Q(\lambda)=m}}(|\log(|Q(\lambda_x)|)|)\\ &\leq 2 X^{\frac{b}{2}-\epsilon}\log(2X)+ 8 X^{\frac{b}{2}-\epsilon}+4\sum_{i}\frac{X^{\frac{b}{2}-\epsilon}}{Z_i}\cdot Z_i\\ &\leq 14 X^{\frac{b}{2}-\epsilon}\log(2X)\\ \end{align*} $$
One can thus find 
 $X_\epsilon>1$
 such that for
$X_\epsilon>1$
 such that for 
 $X>X_\epsilon $
, we have
$X>X_\epsilon $
, we have 
 $14X^{\frac {b}{2}-\epsilon }\log (2X)<X^{\frac {b}{2}}$
. Hence for all
$14X^{\frac {b}{2}-\epsilon }\log (2X)<X^{\frac {b}{2}}$
. Hence for all 
 $X>X_\epsilon $
, for all
$X>X_\epsilon $
, for all 
 $m\in ]X,2X]\backslash (B_{1,X}\cup B_{2,X}\cup B_{3,X})$
, we get
$m\in ]X,2X]\backslash (B_{1,X}\cup B_{2,X}\cup B_{3,X})$
, we get 
 $A_{\mathrm {er}}(m)\leq m^{\frac {b}{2}}$
. In other words, for
$A_{\mathrm {er}}(m)\leq m^{\frac {b}{2}}$
. In other words, for 
 $X>X_\epsilon $
,
$X>X_\epsilon $
, 
 $S_{\mathrm {bad},X}\subset B_{1,X}\cup B_{2,X}\cup B_{3,X}$
. We will obtain upper bounds on the cardinality of
$S_{\mathrm {bad},X}\subset B_{1,X}\cup B_{2,X}\cup B_{3,X}$
. We will obtain upper bounds on the cardinality of 
 $B_{1,X}$
,
$B_{1,X}$
, 
 $B_{2,X}$
 and
$B_{2,X}$
 and 
 $B_{3,X}$
.
$B_{3,X}$
. 
- 
1. The volume of the region of elements  $\lambda \in L_{\mathbb {R}}$
 such that $\lambda \in L_{\mathbb {R}}$
 such that $X<Q(\lambda )\leq 2X$
 and $X<Q(\lambda )\leq 2X$
 and $|Q(\lambda _x)|<1$
 is bounded by $|Q(\lambda _x)|<1$
 is bounded by $O(X^{\frac {b}{2}})$
, hence a geometry-of-numbers argument implies that the number of elements in L in this region is bounded by $O(X^{\frac {b}{2}})$
, hence a geometry-of-numbers argument implies that the number of elements in L in this region is bounded by $O(X^{\frac {b}{2}})$
. More precisely, we break the set of such $O(X^{\frac {b}{2}})$
. More precisely, we break the set of such $\lambda $
 into a finite union of subsets such that for any two elements $\lambda $
 into a finite union of subsets such that for any two elements $\lambda , \lambda '$
 in each subset, we have $\lambda , \lambda '$
 in each subset, we have $|Q(\lambda _x-\lambda ^{\prime }x)|<1$
; as Q is negative definite on P and $|Q(\lambda _x-\lambda ^{\prime }x)|<1$
; as Q is negative definite on P and $|Q(\lambda _x)|<1$
, we may choose the subsets using $|Q(\lambda _x)|<1$
, we may choose the subsets using $\lambda _x$
 such that the total number of subsets is a constant only depending on Q. Therefore, as in the proof of Lemma 6.3, for each subset, we count the $\lambda _x$
 such that the total number of subsets is a constant only depending on Q. Therefore, as in the proof of Lemma 6.3, for each subset, we count the $\lambda $
 by counting $\lambda $
 by counting $\lambda _{x^\perp }\in P^\perp $
 and then apply a geometry-of-numbers argument on $\lambda _{x^\perp }\in P^\perp $
 and then apply a geometry-of-numbers argument on $P^\perp $
.It thus follows that $P^\perp $
.It thus follows that $$ \begin{align*} |B_{1,X}|=O(X^\epsilon). \end{align*} $$ $$ \begin{align*} |B_{1,X}|=O(X^\epsilon). \end{align*} $$
- 
2. Let  $Y:=|B_{2,X}|\geq 1$
; and for each $Y:=|B_{2,X}|\geq 1$
; and for each $m\in B_{2,X}$
, let $m\in B_{2,X}$
, let $\lambda (m)$
 be an element of L such that $\lambda (m)$
 be an element of L such that $Q(\lambda (m))=m$
 and $Q(\lambda (m))=m$
 and $-\log (|Q(\lambda (m)_x)|)\geq X^{\frac {b}{2}}$
. By Lemma 6.3, we obtain a nonzero integer vector $-\log (|Q(\lambda (m)_x)|)\geq X^{\frac {b}{2}}$
. By Lemma 6.3, we obtain a nonzero integer vector $\lambda $
 in L such that $\lambda $
 in L such that $-\log (|Q(\lambda _x)|)\gg X^{\frac {b}{2}}$
 and $-\log (|Q(\lambda _x)|)\gg X^{\frac {b}{2}}$
 and $Q(\lambda _{x^{\bot }})\ll \frac {X}{Y^{\frac {2}{b}}}$
.Footnote 29 Let $Q(\lambda _{x^{\bot }})\ll \frac {X}{Y^{\frac {2}{b}}}$
.Footnote 29 Let $M=Q(\lambda )$
, and note that $M=Q(\lambda )$
, and note that $M=Q(\lambda _x)+Q(\lambda _{x^\bot })\ll \frac {X}{Y^{\frac {2}{b}}}$
. Theorem 5.8(i) implies Therefore, we obtain $M=Q(\lambda _x)+Q(\lambda _{x^\bot })\ll \frac {X}{Y^{\frac {2}{b}}}$
. Theorem 5.8(i) implies Therefore, we obtain $$ \begin{align*} X^{\frac{b}{2}}\ll -\log (|Q(\lambda_x)|)\ll A(M)\ll M^{\frac{b}{2}}\log M\ll \frac{X^{\frac{b}{2}}\log(X)}{Y}. \end{align*} $$ $$ \begin{align*} X^{\frac{b}{2}}\ll -\log (|Q(\lambda_x)|)\ll A(M)\ll M^{\frac{b}{2}}\log M\ll \frac{X^{\frac{b}{2}}\log(X)}{Y}. \end{align*} $$ $$ \begin{align*}|B_{2,X}|\ll \log(X).\end{align*} $$ $$ \begin{align*}|B_{2,X}|\ll \log(X).\end{align*} $$
- 
3. The set  $B_{3,X}$
 is included in the union of the subsets $B_{3,X}$
 is included in the union of the subsets $B_{3,Z_i}, i\in I$
 formed by the elements $B_{3,Z_i}, i\in I$
 formed by the elements $m\in ]X,2X]$
 such that Suppose that $m\in ]X,2X]$
 such that Suppose that $$ \begin{align*}\left|\{\lambda\in L,\, Q(\lambda)=m,\, -\log(|Q(\lambda_x)|)\in ]Z_i,2Z_i]\}\right|\geq \frac{X^{\frac{b}{2}-\epsilon}}{Z_i}.\end{align*} $$ $$ \begin{align*}\left|\{\lambda\in L,\, Q(\lambda)=m,\, -\log(|Q(\lambda_x)|)\in ]Z_i,2Z_i]\}\right|\geq \frac{X^{\frac{b}{2}-\epsilon}}{Z_i}.\end{align*} $$ $Y:=|B_{3,Z_i}|\geq 1$
 for some $Y:=|B_{3,Z_i}|\geq 1$
 for some $i\in I$
. Then there are at least $i\in I$
. Then there are at least $\lceil \frac {YX^{\frac {b}{2}-\epsilon }}{Z_i}\rceil $
 vectors $\lceil \frac {YX^{\frac {b}{2}-\epsilon }}{Z_i}\rceil $
 vectors $\lambda \in L$
 such that $\lambda \in L$
 such that $Q(\lambda )\in ]X,2X]$
 and $Q(\lambda )\in ]X,2X]$
 and $-\log (|Q(\lambda _x)|)\in ]Z_i,2Z_i]$
. We again use Lemma 6.3 to construct an integral nonzero vector $-\log (|Q(\lambda _x)|)\in ]Z_i,2Z_i]$
. We again use Lemma 6.3 to construct an integral nonzero vector $\lambda \in L$
 such that Let M again denote $\lambda \in L$
 such that Let M again denote $$ \begin{align*}-\log(|Q(\lambda_x)|)\gg Z_i\,\textrm{and}\, Q(\lambda_{x^\bot})\ll \frac{X^{\frac{2\epsilon}{b}} Z_i^{\frac{2}{b}}}{Y^{\frac{2}{b}}}.\end{align*} $$ $$ \begin{align*}-\log(|Q(\lambda_x)|)\gg Z_i\,\textrm{and}\, Q(\lambda_{x^\bot})\ll \frac{X^{\frac{2\epsilon}{b}} Z_i^{\frac{2}{b}}}{Y^{\frac{2}{b}}}.\end{align*} $$ $Q(\lambda )$
, and notice that $Q(\lambda )$
, and notice that $M\ll \frac {X^{2\epsilon /b} Z_i^{2/b}}{Y^{2/b}}$
. Theorem 5.8(i) implies that Thus for every $M\ll \frac {X^{2\epsilon /b} Z_i^{2/b}}{Y^{2/b}}$
. Theorem 5.8(i) implies that Thus for every $$ \begin{align*} Z_i\ll -\log (|Q(\lambda_x)|)\ll A(M)\ll M^{\frac{b}{2}}\log M\ll \frac{X^{\epsilon}Z_i}{Y}. \end{align*} $$ $$ \begin{align*} Z_i\ll -\log (|Q(\lambda_x)|)\ll A(M)\ll M^{\frac{b}{2}}\log M\ll \frac{X^{\epsilon}Z_i}{Y}. \end{align*} $$ $i\in I$
, we have $i\in I$
, we have $|B_{3,Z_i}|\ll X^{\epsilon }$
. Summing over all $|B_{3,Z_i}|\ll X^{\epsilon }$
. Summing over all $i\in I$
 yields $i\in I$
 yields $$ \begin{align*}|B_{3,X}|\ll X^{\epsilon} \log X.\end{align*} $$ $$ \begin{align*}|B_{3,X}|\ll X^{\epsilon} \log X.\end{align*} $$
 Hence we conclude that 
 $\log |S_{\mathrm {bad},X}|\ll \epsilon \log X + \log \log X$
. Thus
$\log |S_{\mathrm {bad},X}|\ll \epsilon \log X + \log \log X$
. Thus 
 $\displaystyle \limsup _{X\rightarrow \infty } \frac {\log |S_{\mathrm {bad},X}|}{\log X}\leq \epsilon $
. As the equality holds for every
$\displaystyle \limsup _{X\rightarrow \infty } \frac {\log |S_{\mathrm {bad},X}|}{\log X}\leq \epsilon $
. As the equality holds for every 
 $\epsilon>0$
, we get the desired result.
$\epsilon>0$
, we get the desired result.
7 Bounding the contribution from a finite place with good reduction
 We keep the notations from the beginning of Section 5: namely, 
 $\mathcal {M}$
 is the integral model over
$\mathcal {M}$
 is the integral model over 
 $\mathbb {Z}$
 of the GSpin Shimura variety associated to an even maximal quadratic lattice
$\mathbb {Z}$
 of the GSpin Shimura variety associated to an even maximal quadratic lattice 
 $(L,Q)$
 with signature
$(L,Q)$
 with signature 
 $(b,2), b\geq 3$
;
$(b,2), b\geq 3$
; 
 $\mathcal {Y}$
 is an
$\mathcal {Y}$
 is an 
 $\mathcal {O}_K$
-point in
$\mathcal {O}_K$
-point in 
 $\mathcal {M}$
 such that
$\mathcal {M}$
 such that 
 $\mathcal {Y}_K$
 is Hodge-generic; and
$\mathcal {Y}_K$
 is Hodge-generic; and 
 $\mathcal {Z}(m)$
 denotes the special divisor over
$\mathcal {Z}(m)$
 denotes the special divisor over 
 $\mathbb {Z}$
 associated to an integer
$\mathbb {Z}$
 associated to an integer 
 $m\in \mathbb {Z}_{>0}$
 and is defined in Section 2.5. We denote the Kuga–Satake abelian scheme over
$m\in \mathbb {Z}_{>0}$
 and is defined in Section 2.5. We denote the Kuga–Satake abelian scheme over 
 $\mathcal {O}_K$
 associated to
$\mathcal {O}_K$
 associated to 
 $\mathcal {Y}$
 by
$\mathcal {Y}$
 by 
 $\mathcal {A}$
 and let A denote
$\mathcal {A}$
 and let A denote 
 $\mathcal {A}_K$
. The assumption of
$\mathcal {A}_K$
. The assumption of 
 $\mathcal {Y}_K$
 being Hodge-generic implies that the lattice of special endomorphisms
$\mathcal {Y}_K$
 being Hodge-generic implies that the lattice of special endomorphisms 
 $V(A_{\overline {K}})$
 (see Section 2.5 for the definition) is just
$V(A_{\overline {K}})$
 (see Section 2.5 for the definition) is just 
 $\{0\}$
. Fix a prime
$\{0\}$
. Fix a prime 
 $\mathfrak {P}$
 of
$\mathfrak {P}$
 of 
 $\mathcal {O}_K$
, let p denote the characteristic of the residue field
$\mathcal {O}_K$
, let p denote the characteristic of the residue field 
 $\mathbb {F}_{\mathfrak {P}}$
, and let e denote the ramification index of
$\mathbb {F}_{\mathfrak {P}}$
, and let e denote the ramification index of 
 $\mathfrak {P}$
 in K. We use
$\mathfrak {P}$
 in K. We use 
 $\mathcal {Y}_{\overline {\mathfrak {P}}}, \mathcal {A}_{\overline {\mathfrak {P}}}$
 to denote the geometric special fibres of
$\mathcal {Y}_{\overline {\mathfrak {P}}}, \mathcal {A}_{\overline {\mathfrak {P}}}$
 to denote the geometric special fibres of 
 $\mathcal {Y},\mathcal {A}$
 at
$\mathcal {Y},\mathcal {A}$
 at 
 $\mathfrak {P}$
.
$\mathfrak {P}$
.
 Recall the intersection multiplicity 
 $(\mathcal {Y}.\mathcal {Z}(m))_{\mathfrak {P}}$
 from equation (3.2): let
$(\mathcal {Y}.\mathcal {Z}(m))_{\mathfrak {P}}$
 from equation (3.2): let 
 $v \in V(\mathcal {A}_{\overline {\mathfrak {P}}})$
 be a special endomorphism of
$v \in V(\mathcal {A}_{\overline {\mathfrak {P}}})$
 be a special endomorphism of 
 $\mathcal {A}_{\overline {\mathfrak {P}}}$
 satisfying
$\mathcal {A}_{\overline {\mathfrak {P}}}$
 satisfying 
 $v\circ v = [m]$
. We denote by
$v\circ v = [m]$
. We denote by 
 $\mathcal {O}_{\mathcal {Y}\times _{\mathcal {M}}\mathcal {Z}(m),v}$
 the étale local ring of
$\mathcal {O}_{\mathcal {Y}\times _{\mathcal {M}}\mathcal {Z}(m),v}$
 the étale local ring of 
 $\mathcal {Y}\times _{\mathcal {M}}\mathcal {Z}(m)$
 at v. Then we have
$\mathcal {Y}\times _{\mathcal {M}}\mathcal {Z}(m)$
 at v. Then we have 
 $$ \begin{align} (\mathcal{Y}.\mathcal{Z}(m))_{\mathfrak{P}}=\sum_{\substack{v\in V(\mathcal{A}_{\overline{\mathfrak{P}}})\\ v\circ v =[ m]}}\operatorname{\mathrm{length}}(\mathcal{O}_{\mathcal{Y}\times_{\mathcal{M}}\mathcal{Z}(m),v}). \end{align} $$
$$ \begin{align} (\mathcal{Y}.\mathcal{Z}(m))_{\mathfrak{P}}=\sum_{\substack{v\in V(\mathcal{A}_{\overline{\mathfrak{P}}})\\ v\circ v =[ m]}}\operatorname{\mathrm{length}}(\mathcal{O}_{\mathcal{Y}\times_{\mathcal{M}}\mathcal{Z}(m),v}). \end{align} $$
In this section, we prove the following result, which controls the above local intersection number on average over m.
Theorem 7.1. Let 
 $D\in \mathbb {Z}_{\geq 1}$
. For
$D\in \mathbb {Z}_{\geq 1}$
. For 
 $X\in \mathbb {Z}_{>0}$
, let
$X\in \mathbb {Z}_{>0}$
, let 
 $S_{D,X}$
 denote the set
$S_{D,X}$
 denote the set 
 $$\begin{align*}\{m\in \mathbb{Z}_{>0}\mid X \leq m<2X,\, \frac{m}{D}\in \mathbb{Z} \cap (\mathbb{Q}^\times)^2\}.\end{align*}$$
$$\begin{align*}\{m\in \mathbb{Z}_{>0}\mid X \leq m<2X,\, \frac{m}{D}\in \mathbb{Z} \cap (\mathbb{Q}^\times)^2\}.\end{align*}$$
Then we have
 $$\begin{align*}\sum_{m\in S_{D,X}}(\mathcal{Y}. \mathcal{Z}(m))_{\mathfrak{P}}=o(X^{\frac{b+1}{2}}\log X).\end{align*}$$
$$\begin{align*}\sum_{m\in S_{D,X}}(\mathcal{Y}. \mathcal{Z}(m))_{\mathfrak{P}}=o(X^{\frac{b+1}{2}}\log X).\end{align*}$$
 This section is organised as follows. First, in Section 7.1, we express 
 $ (\mathcal {Y}.\mathcal {Z}(m))_{\mathfrak {P}}$
 as a sum of lattice point counts over a family of p-adically shrinking lattices. We then prove some preliminary properties of these lattices. Finally, in Section 7.2, we evaluate these lattice counts to prove Theorem 7.1. Needless to say, crucial to the proof of Theorem 7.1 is the fact that we have the global height bound (Theorem 5.8) for every individual m. In Section 7.3, we will illustrate this with an example of a
$ (\mathcal {Y}.\mathcal {Z}(m))_{\mathfrak {P}}$
 as a sum of lattice point counts over a family of p-adically shrinking lattices. We then prove some preliminary properties of these lattices. Finally, in Section 7.2, we evaluate these lattice counts to prove Theorem 7.1. Needless to say, crucial to the proof of Theorem 7.1 is the fact that we have the global height bound (Theorem 5.8) for every individual m. In Section 7.3, we will illustrate this with an example of a 
 $W(\mathbb {F}_q)$
-valued point
$W(\mathbb {F}_q)$
-valued point 
 $\mathcal {Y}' \in \mathcal {M}$
 (which is a posteriori not defined over a number field) with the property that
$\mathcal {Y}' \in \mathcal {M}$
 (which is a posteriori not defined over a number field) with the property that 
 $(\mathcal {Y}.\mathcal {Z}(m))_p$
 is exponential in m for an infinite sequence of positive integers
$(\mathcal {Y}.\mathcal {Z}(m))_p$
 is exponential in m for an infinite sequence of positive integers 
 $m \in \{n\in \mathbb {Z}_{>0}: \frac {n}{D} \in \mathbb {Z}\cap (\mathbb {Q}^\times )^2\}$
.
$m \in \{n\in \mathbb {Z}_{>0}: \frac {n}{D} \in \mathbb {Z}\cap (\mathbb {Q}^\times )^2\}$
.
7.1 The lattices of special endomorphisms
 Let 
 $K_{\mathfrak {P}}$
 denote the completion of K at
$K_{\mathfrak {P}}$
 denote the completion of K at 
 $\mathfrak {P}$
; let
$\mathfrak {P}$
; let 
 $K_{\mathfrak {P}}^{\mathrm {nr}}$
 denote a maximal unramified extension of
$K_{\mathfrak {P}}^{\mathrm {nr}}$
 denote a maximal unramified extension of 
 $K_{\mathfrak {P}}$
, and let
$K_{\mathfrak {P}}$
, and let 
 $\mathcal {O}^{\mathrm {nr}}_{\mathfrak {P}}$
 denote its ring of integers. For every
$\mathcal {O}^{\mathrm {nr}}_{\mathfrak {P}}$
 denote its ring of integers. For every 
 $n \in \mathbb {Z}_{\geq 1}$
, let
$n \in \mathbb {Z}_{\geq 1}$
, let 
 $L_n$
 denote the lattice of special endomorphisms
$L_n$
 denote the lattice of special endomorphisms 
 $V(\mathcal {A}_{\mathcal {O}^{\mathrm {nr}}_{\mathfrak {P}}/\mathfrak {P}^n})$
. By definition,
$V(\mathcal {A}_{\mathcal {O}^{\mathrm {nr}}_{\mathfrak {P}}/\mathfrak {P}^n})$
. By definition, 
 $L_{n+1}\subset L_n$
 for all n. Since
$L_{n+1}\subset L_n$
 for all n. Since 
 $\mathcal {Y}_K$
 is Hodge-generic, then
$\mathcal {Y}_K$
 is Hodge-generic, then 
 $\displaystyle \cap _{n=1}^\infty L_n=\{0\}$
. Recall from Section 2.5 that all
$\displaystyle \cap _{n=1}^\infty L_n=\{0\}$
. Recall from Section 2.5 that all 
 $L_n$
s are equipped with compatible positive definite quadratic forms Q given by
$L_n$
s are equipped with compatible positive definite quadratic forms Q given by 
 $$ \begin{align*}v\circ v =Q(v)\cdot \operatorname{\mathrm{Id}}_{\mathcal{A} \bmod \mathfrak{P}^n}\end{align*} $$
$$ \begin{align*}v\circ v =Q(v)\cdot \operatorname{\mathrm{Id}}_{\mathcal{A} \bmod \mathfrak{P}^n}\end{align*} $$
for every 
 $v\in L_n$
.
$v\in L_n$
.
 The next lemma is a direct consequence of the moduli interpretation of 
 $\mathcal {Z}(m)$
 in Section 2.5.Footnote 30
$\mathcal {Z}(m)$
 in Section 2.5.Footnote 30
Lemma 7.2. The local intersection number is given by
 $$\begin{align*}(\mathcal{Y}. \mathcal{Z}(m))_{\mathfrak{P}}=\sum_{n=1}^\infty |\{v\in L_n \mid Q(v)=m\}|.\end{align*}$$
$$\begin{align*}(\mathcal{Y}. \mathcal{Z}(m))_{\mathfrak{P}}=\sum_{n=1}^\infty |\{v\in L_n \mid Q(v)=m\}|.\end{align*}$$
 Note that the right-hand side above is indeed a finite sum since there are only finitely many vectors v in 
 $L_1$
 with
$L_1$
 with 
 $Q(v)=m$
; and for each vector v, there exists
$Q(v)=m$
; and for each vector v, there exists 
 $n_v\in \mathbb {Z}_{>0}$
 such that
$n_v\in \mathbb {Z}_{>0}$
 such that 
 $v\notin L_{n_v}$
.
$v\notin L_{n_v}$
.
 The following proof uses equation (7.1) and gives a direct description of the length of the étale local rings. Alternatively, one may pick a finite covering of 
 $\mathcal {M}$
 over
$\mathcal {M}$
 over 
 $\mathbb {Z}_p$
 and a section of
$\mathbb {Z}_p$
 and a section of 
 $\mathcal {Y}$
 to the covering space and then deduce the intersection number via the projection formula.
$\mathcal {Y}$
 to the covering space and then deduce the intersection number via the projection formula.
Proof. For the proof of this lemma, we may assume (without loss of generality) that 
 $\mathcal {Y}=\operatorname {\mathrm {Spec}}(\mathcal {O}_{\mathfrak {P}}^{\mathrm {nr}})$
. Consider
$\mathcal {Y}=\operatorname {\mathrm {Spec}}(\mathcal {O}_{\mathfrak {P}}^{\mathrm {nr}})$
. Consider 
 $v\in V(\mathcal {A}_{\overline {\mathfrak {P}}})=L_1$
 satisfying
$v\in V(\mathcal {A}_{\overline {\mathfrak {P}}})=L_1$
 satisfying 
 $v\circ v=[m]$
. As
$v\circ v=[m]$
. As 
 $\mathcal {Y}$
 is a scheme, we use the moduli interpretation of
$\mathcal {Y}$
 is a scheme, we use the moduli interpretation of 
 $\mathcal {Z}(m)$
 to see that the étale local ring
$\mathcal {Z}(m)$
 to see that the étale local ring 
 $\mathcal {O}_{\mathcal {Y}\times _{\mathcal {M}}\mathcal {Z}(m),v}$
 represents the following deformation problem.
$\mathcal {O}_{\mathcal {Y}\times _{\mathcal {M}}\mathcal {Z}(m),v}$
 represents the following deformation problem.
 Consider any local Artin 
 $\mathcal {O}^{\mathrm {nr}}_{\mathfrak {P}}$
-algebra S with residue field
$\mathcal {O}^{\mathrm {nr}}_{\mathfrak {P}}$
-algebra S with residue field 
 $\overline {\mathbb {F}}_{\mathfrak {P}}$
. We may view
$\overline {\mathbb {F}}_{\mathfrak {P}}$
. We may view 
 $\operatorname {\mathrm {Spec}} S$
 as a scheme over
$\operatorname {\mathrm {Spec}} S$
 as a scheme over 
 $\mathcal {M}$
 factoring through
$\mathcal {M}$
 factoring through 
 $\mathcal {Y}$
, and we refer to this scheme as
$\mathcal {Y}$
, and we refer to this scheme as 
 $\mathcal {Y}_S$
. The deformation problem represented by
$\mathcal {Y}_S$
. The deformation problem represented by 
 $\mathcal {O}_{\mathcal {Y}\times _{\mathcal {M}}\mathcal {Z}(m),v}$
 associates to the
$\mathcal {O}_{\mathcal {Y}\times _{\mathcal {M}}\mathcal {Z}(m),v}$
 associates to the 
 $\mathcal {O}^{\mathrm {nr}}_{\mathfrak {P}}$
-algebra S the data
$\mathcal {O}^{\mathrm {nr}}_{\mathfrak {P}}$
-algebra S the data 
 $(\mathcal {Y}_S, w)$
, where w is a special endomorphism of
$(\mathcal {Y}_S, w)$
, where w is a special endomorphism of 
 $\mathcal {A}_S$
 such that the reduction of w (via
$\mathcal {A}_S$
 such that the reduction of w (via 
 $ S\rightarrow \overline {\mathbb {F}}_{\mathfrak {P}}$
) in
$ S\rightarrow \overline {\mathbb {F}}_{\mathfrak {P}}$
) in 
 $V(\mathcal {A}_{\overline {\mathfrak {P}}})$
 is equal to v. Thus the length of
$V(\mathcal {A}_{\overline {\mathfrak {P}}})$
 is equal to v. Thus the length of 
 $\mathcal {O}_{\mathcal {Y}\times _{\mathcal {M}}\mathcal {Z}(m),v}$
 is equal to the largest n such that v lifts to a special endomorphism of
$\mathcal {O}_{\mathcal {Y}\times _{\mathcal {M}}\mathcal {Z}(m),v}$
 is equal to the largest n such that v lifts to a special endomorphism of 
 $\mathcal {Y}_{\mathcal {O}^{\mathrm {nr}}_{\mathfrak {P}}/\mathfrak {P}^n}$
.
$\mathcal {Y}_{\mathcal {O}^{\mathrm {nr}}_{\mathfrak {P}}/\mathfrak {P}^n}$
.
 Let 
 $\mathbf {1}_{L_n}:L_1\rightarrow \{0,1\}$
 denote the characteristic function of
$\mathbf {1}_{L_n}:L_1\rightarrow \{0,1\}$
 denote the characteristic function of 
 $L_n$
. Then by equation (7.1), we have
$L_n$
. Then by equation (7.1), we have 
 $$ \begin{align*} (\mathcal{Y}.\mathcal{Z}(m))_{\mathfrak{P}} &=\sum_{\substack{v\in V(\mathcal{A}_{\overline{\mathfrak{P}}})\\ v\circ v = [m]}}\sum_{n=1}^\infty \mathbf{1}_{L_n}(v)=\sum_{n=1}^\infty \sum_{\substack{v\in L_n\\ v\circ v = [m]}}1.here \end{align*} $$
$$ \begin{align*} (\mathcal{Y}.\mathcal{Z}(m))_{\mathfrak{P}} &=\sum_{\substack{v\in V(\mathcal{A}_{\overline{\mathfrak{P}}})\\ v\circ v = [m]}}\sum_{n=1}^\infty \mathbf{1}_{L_n}(v)=\sum_{n=1}^\infty \sum_{\substack{v\in L_n\\ v\circ v = [m]}}1.here \end{align*} $$
The following proposition generalises [Reference Shankar and TangST19, Thm. 4.1.1, Lem. 4.1.3, Lem. 4.3.2].
Proposition 7.3. Let 
 $\Lambda $
 denote the
$\Lambda $
 denote the 
 $\mathbb {Z}_p$
-lattice of special endomorphisms of the p-divisible group
$\mathbb {Z}_p$
-lattice of special endomorphisms of the p-divisible group 
 $\mathcal {A}[p^\infty ]$
 over
$\mathcal {A}[p^\infty ]$
 over 
 $\mathcal {O}^{\mathrm {nr}}_{\mathfrak {P}}$
 (see Definition 2.3
$\mathcal {O}^{\mathrm {nr}}_{\mathfrak {P}}$
 (see Definition 2.3
 $)$
. Then the
$)$
. Then the 
 $\mathbb {Z}$
-rank of
$\mathbb {Z}$
-rank of 
 $L_n$
 is at most
$L_n$
 is at most 
 $b+2$
 and the
$b+2$
 and the 
 $\mathbb {Z}_p$
-rank of
$\mathbb {Z}_p$
-rank of 
 $\Lambda $
 is at most b. Moreover, there exists a constant
$\Lambda $
 is at most b. Moreover, there exists a constant 
 $n_0$
 such that for
$n_0$
 such that for 
 $n_0'\geq n_0$
,
$n_0'\geq n_0$
, 
 $$\begin{align*}L_{n_0'+ke}=(\Lambda + p^k L_{n_0'}\otimes \mathbb{Z}_p)\cap L_{n_0}\end{align*}$$
$$\begin{align*}L_{n_0'+ke}=(\Lambda + p^k L_{n_0'}\otimes \mathbb{Z}_p)\cap L_{n_0}\end{align*}$$
for 
 $k\geq 1$
. In particular, the rank of
$k\geq 1$
. In particular, the rank of 
 $L_n$
 is independent of n, and we denote it by r.
$L_n$
 is independent of n, and we denote it by r.
Proof. For the claim on ranks, by [Reference Andreatta, Goren, Howard and PeraAGHMP18, Lemma 4.5.2], we reduce to the case when L is self-dual at p. In this case, by the Dieudonné theory, 
 $L_n\otimes _{\mathbb {Z}}\mathbb {Z}_p\subseteq L_1\otimes _{\mathbb {Z}}\mathbb {Z}_p\subseteq \mathbf {V}_{cris,\mathcal {Y}_{\overline {\mathfrak {P}}}}^{\varphi =1}$
, which is a
$L_n\otimes _{\mathbb {Z}}\mathbb {Z}_p\subseteq L_1\otimes _{\mathbb {Z}}\mathbb {Z}_p\subseteq \mathbf {V}_{cris,\mathcal {Y}_{\overline {\mathfrak {P}}}}^{\varphi =1}$
, which is a 
 $\mathbb {Z}_p$
-lattice of rank at most
$\mathbb {Z}_p$
-lattice of rank at most 
 $b+2$
. Hence
$b+2$
. Hence 
 $\operatorname {\mathrm {rank}}_{\mathbb {Z}}L_n\leq b+2$
. For
$\operatorname {\mathrm {rank}}_{\mathbb {Z}}L_n\leq b+2$
. For 
 $\operatorname {\mathrm {rank}}_{\mathbb {Z}_p}\Lambda $
, as in [Reference Shankar and TangST19, Lemma 4.3.2], we make use of the filtration on
$\operatorname {\mathrm {rank}}_{\mathbb {Z}_p}\Lambda $
, as in [Reference Shankar and TangST19, Lemma 4.3.2], we make use of the filtration on 
 $\mathbf {V}_{dR,\mathcal {Y}}$
. By Grothendieck–Messing theory,
$\mathbf {V}_{dR,\mathcal {Y}}$
. By Grothendieck–Messing theory, 
 $\Lambda \subseteq \mathcal {F}^0\mathbf {V}_{dR,\mathcal {Y}_{K^{\mathrm {nr}}}}\cap \mathbf {V}_{cris,\mathcal {Y}_{\overline {\mathfrak {P}}}}^{\varphi =1}$
, so
$\Lambda \subseteq \mathcal {F}^0\mathbf {V}_{dR,\mathcal {Y}_{K^{\mathrm {nr}}}}\cap \mathbf {V}_{cris,\mathcal {Y}_{\overline {\mathfrak {P}}}}^{\varphi =1}$
, so 
 $\operatorname {\mathrm {rank}}_{\mathbb {Z}_p}\Lambda \leq b+1$
, and the equality holds if and only if
$\operatorname {\mathrm {rank}}_{\mathbb {Z}_p}\Lambda \leq b+1$
, and the equality holds if and only if 
 $\mathcal {F}^0\mathbf {V}_{dR, \mathcal {Y}_{K^{\mathrm {nr}}}}=\operatorname {\mathrm {span}}_{K^{\mathrm {nr}}}\Lambda $
. If so, since
$\mathcal {F}^0\mathbf {V}_{dR, \mathcal {Y}_{K^{\mathrm {nr}}}}=\operatorname {\mathrm {span}}_{K^{\mathrm {nr}}}\Lambda $
. If so, since 
 $\Lambda \subseteq \mathbf {V}_{cris,\mathcal {Y}_{\overline {\mathfrak {P}}}}^{\varphi =1}$
, then
$\Lambda \subseteq \mathbf {V}_{cris,\mathcal {Y}_{\overline {\mathfrak {P}}}}^{\varphi =1}$
, then 
 $\operatorname {\mathrm {span}}_{K^{\mathrm {nr}}}\Lambda $
 admits trivial filtration by Mazur’s weak admissibility theorem. This contradicts
$\operatorname {\mathrm {span}}_{K^{\mathrm {nr}}}\Lambda $
 admits trivial filtration by Mazur’s weak admissibility theorem. This contradicts 
 $\mathcal {F}^{1}\mathbf {V}_{dR, \mathcal {Y}_{K^{\mathrm {nr}}}}\neq 0$
. We conclude that
$\mathcal {F}^{1}\mathbf {V}_{dR, \mathcal {Y}_{K^{\mathrm {nr}}}}\neq 0$
. We conclude that 
 $\operatorname {\mathrm {rank}}_{\mathbb {Z}_p}\Lambda \leq b$
.
$\operatorname {\mathrm {rank}}_{\mathbb {Z}_p}\Lambda \leq b$
.
As in [Reference Shankar and TangST19, Lemma 4.1.3], by Serre–Tate theory,
 $$\begin{align*}\cap_{n=1}^\infty(L_n\otimes \mathbb{Z}_p)=\operatorname{\mathrm{End}}_{C(L)}(\mathcal{A}[p^\infty]_{\mathcal{O}^{\mathrm{nr}}_{\mathfrak{P}}})\cap (L_1 \otimes \mathbb{Z}_p)=\Lambda.\end{align*}$$
$$\begin{align*}\cap_{n=1}^\infty(L_n\otimes \mathbb{Z}_p)=\operatorname{\mathrm{End}}_{C(L)}(\mathcal{A}[p^\infty]_{\mathcal{O}^{\mathrm{nr}}_{\mathfrak{P}}})\cap (L_1 \otimes \mathbb{Z}_p)=\Lambda.\end{align*}$$
To prove the last equality above, by [Reference Andreatta, Goren, Howard and PeraAGHMP18, Lemma 4.5.2], we reduce to the self-dual case. Then by Definition 2.3, a 
 $C(L)$
-endomorphism of a p-divisible group is special if its crystalline realisation lies in
$C(L)$
-endomorphism of a p-divisible group is special if its crystalline realisation lies in 
 $\mathbf {V}_{cris,\mathcal {Y}_{\overline {\mathfrak {P}}}}$
, which by Dieudonné theory is equivalent in that it lies in
$\mathbf {V}_{cris,\mathcal {Y}_{\overline {\mathfrak {P}}}}$
, which by Dieudonné theory is equivalent in that it lies in 
 $L_1 \otimes \mathbb {Z}_p$
.
$L_1 \otimes \mathbb {Z}_p$
.
 By [Reference PeraMP16, Lemma 5.9], [Reference Andreatta, Goren, Howard and PeraAGHMP18, Lemma 4.5.2] and the Néron mapping property, an endomorphism of 
 $\mathcal {A}_{\mathcal {O}^{\mathrm {nr}}_{\mathfrak {P}}/\mathfrak {P}^n}$
 is special if and only if its induced endomorphism in
$\mathcal {A}_{\mathcal {O}^{\mathrm {nr}}_{\mathfrak {P}}/\mathfrak {P}^n}$
 is special if and only if its induced endomorphism in 
 $\operatorname {\mathrm {End}}(\mathcal {A}_{\overline {\mathbb {F}}_{\mathfrak {P}}})$
 is special. Therefore, a vector
$\operatorname {\mathrm {End}}(\mathcal {A}_{\overline {\mathbb {F}}_{\mathfrak {P}}})$
 is special. Therefore, a vector 
 $v\in L_1$
 lies in
$v\in L_1$
 lies in 
 $L_n$
 if and only if v deforms to an endomorphism of
$L_n$
 if and only if v deforms to an endomorphism of 
 $\mathcal {A}_{\mathcal {O}^{\mathrm {nr}}_{\mathfrak {P}}/\mathfrak {P}^n}$
. Then the rest of the argument is the same as in the proof of [Reference Shankar and TangST19, Theorem 4.1.1].
$\mathcal {A}_{\mathcal {O}^{\mathrm {nr}}_{\mathfrak {P}}/\mathfrak {P}^n}$
. Then the rest of the argument is the same as in the proof of [Reference Shankar and TangST19, Theorem 4.1.1].
 We now define the successive minima of a lattice following [Reference Eskin and KatznelsonEK95] and discuss the asymptotics of the successive minima of 
 $L_n$
.
$L_n$
.
Definition 7.4.
- 
1. For  $1\leq i\leq r$
, the successive minimum $1\leq i\leq r$
, the successive minimum $\mu _i(n)$
 of $\mu _i(n)$
 of $L_n$
 is defined as $L_n$
 is defined as $$\begin{align*}\inf\{y\in \mathbb{R}_{>0}:\exists v_1,\cdots, v_i\in L_n \text{ linearly independent and } Q(v_j)\leq y^2, 1\leq j\leq i\}.\end{align*}$$ $$\begin{align*}\inf\{y\in \mathbb{R}_{>0}:\exists v_1,\cdots, v_i\in L_n \text{ linearly independent and } Q(v_j)\leq y^2, 1\leq j\leq i\}.\end{align*}$$
- 
2. For  $n\in \mathbb {Z}_{\geq 1}, 1\leq i \leq r$
, define $n\in \mathbb {Z}_{\geq 1}, 1\leq i \leq r$
, define $a_i(n)=\prod _{j=1}^i \mu _j(n)$
; define $a_i(n)=\prod _{j=1}^i \mu _j(n)$
; define $a_0(n)=1$
. $a_0(n)=1$
.
We have the following consequence of Proposition 7.3.
Corollary 7.5. Every successive minimum 
 $\mu _j(n)$
 satisfies
$\mu _j(n)$
 satisfies 
 $\mu _j(n)\ll p^{n/e}$
. If we further assume that
$\mu _j(n)\ll p^{n/e}$
. If we further assume that 
 $r = b+2$
, then
$r = b+2$
, then 
 $a_{b+1}(n) \gg p^{n/e}$
 and
$a_{b+1}(n) \gg p^{n/e}$
 and 
 $a_{b+2}(n) \gg p^{2n/e}$
.
$a_{b+2}(n) \gg p^{2n/e}$
.
Proof. By Proposition 7.3, there exists an absolute bounded 
 $n_0\equiv n\ \pmod {e}$
 such that
$n_0\equiv n\ \pmod {e}$
 such that 
 $$ \begin{align*} L_n=\bigl(\Lambda+p^{(n-n_0)/e}L_{n_0}\otimes \mathbb{Z}_p\bigr)\cap L_{n_0}. \end{align*} $$
$$ \begin{align*} L_n=\bigl(\Lambda+p^{(n-n_0)/e}L_{n_0}\otimes \mathbb{Z}_p\bigr)\cap L_{n_0}. \end{align*} $$
Denote 
 $(n-n_0)/e$
 by k, and note that
$(n-n_0)/e$
 by k, and note that 
 $k\gg n/e$
. Since
$k\gg n/e$
. Since 
 $p^kL_{n_0}\subset L_n$
, it follows that
$p^kL_{n_0}\subset L_n$
, it follows that 
 $\mu _j(n)\ll p^k$
 for every j, proving the first claim.
$\mu _j(n)\ll p^k$
 for every j, proving the first claim.
 Now if the rank r of 
 $L_n$
 is
$L_n$
 is 
 $b+2$
, then (since the rank of
$b+2$
, then (since the rank of 
 $\Lambda $
 is at most b), we clearly have
$\Lambda $
 is at most b), we clearly have 
 $[L_1:L_n] \gg p^{2k}$
. Thus
$[L_1:L_n] \gg p^{2k}$
. Thus 
 $\operatorname {\mathrm {Disc}}(L_n)^{\frac {1}{2}} \gg p^{2k}$
. By [Reference Eskin and KatznelsonEK95, Equations (5),(6)], this implies that
$\operatorname {\mathrm {Disc}}(L_n)^{\frac {1}{2}} \gg p^{2k}$
. By [Reference Eskin and KatznelsonEK95, Equations (5),(6)], this implies that 
 $a_{b+2}(n) \gg p^{2k}$
 as required. In conjunction with
$a_{b+2}(n) \gg p^{2k}$
 as required. In conjunction with 
 $\mu _{b+2}(n)\ll p^k$
, we also immediately obtain that
$\mu _{b+2}(n)\ll p^k$
, we also immediately obtain that 
 $a_{b+1}(n)\gg p^k$
.
$a_{b+1}(n)\gg p^k$
.
Lemma 7.6. For every 
 $\epsilon>0$
, we have
$\epsilon>0$
, we have 
 $a_1(n)\gg _\epsilon n^{\frac {1}{b + \epsilon }}$
. Moreover,
$a_1(n)\gg _\epsilon n^{\frac {1}{b + \epsilon }}$
. Moreover, 
 $a_i(n)\gg _\epsilon n^{\frac {i}{b+\epsilon }}$
.
$a_i(n)\gg _\epsilon n^{\frac {i}{b+\epsilon }}$
.
Proof. Let 
 $\epsilon>0$
. By Theorem 5.8(ii), we have
$\epsilon>0$
. By Theorem 5.8(ii), we have 
 $$ \begin{align} (\mathcal{Y}. \mathcal{Z}(m))_{\mathfrak{P}} \ll m^{\frac{b}{2}}\log m \ll_\epsilon m^{\frac{b+\epsilon}{2}}. \end{align} $$
$$ \begin{align} (\mathcal{Y}. \mathcal{Z}(m))_{\mathfrak{P}} \ll m^{\frac{b}{2}}\log m \ll_\epsilon m^{\frac{b+\epsilon}{2}}. \end{align} $$
 Let 
 $w_0\in L_n$
 denote a vector such that
$w_0\in L_n$
 denote a vector such that 
 $Q(w_0)=a_1(n)^2$
. By taking
$Q(w_0)=a_1(n)^2$
. By taking 
 $m=a_1(n)^2$
 in equation (7.2), we get
$m=a_1(n)^2$
 in equation (7.2), we get 
 $$\begin{align*}n \ll (\mathcal{Y}. \mathcal{Z}(a_1(n)^2))_{\mathfrak{P}} \ll_\epsilon a_1(n)^{b+\epsilon},\end{align*}$$
$$\begin{align*}n \ll (\mathcal{Y}. \mathcal{Z}(a_1(n)^2))_{\mathfrak{P}} \ll_\epsilon a_1(n)^{b+\epsilon},\end{align*}$$
where the first bound follows from Lemma 7.2 and the observation that 
 $w_0\in L_k$
 for all
$w_0\in L_k$
 for all 
 $k\leq n$
. The second assertion follows directly from the first in conjunction with the bound
$k\leq n$
. The second assertion follows directly from the first in conjunction with the bound 
 $a_i(n)\geq a_1(n)^i$
.
$a_i(n)\geq a_1(n)^i$
.
7.2 Proof of Theorem 7.1
 We first introduce some notations. For any positive integers 
 $a<b$
 and
$a<b$
 and 
 $D,X$
 as in Theorem 7.1, define
$D,X$
 as in Theorem 7.1, define 
 $$ \begin{align*} \mathbf{N}_{D}(a,b;X) = \sum_{n = a}^{b}|\{v \in L_n: Q(v) \in S_{D,X} \}|. \end{align*} $$
$$ \begin{align*} \mathbf{N}_{D}(a,b;X) = \sum_{n = a}^{b}|\{v \in L_n: Q(v) \in S_{D,X} \}|. \end{align*} $$
 It is known that 
 $\operatorname {\mathrm {rank}} L_n=b+2$
 if and only if
$\operatorname {\mathrm {rank}} L_n=b+2$
 if and only if 
 $\mathcal {Y}$
 has supersingular reduction at
$\mathcal {Y}$
 has supersingular reduction at 
 $\mathfrak {P}$
.Footnote 31 When
$\mathfrak {P}$
.Footnote 31 When 
 $\mathfrak {P}$
 is a prime of supersingular reduction, we write
$\mathfrak {P}$
 is a prime of supersingular reduction, we write 
 $\mathbf {N}_D(1,\infty ;X)$
 as a sum
$\mathbf {N}_D(1,\infty ;X)$
 as a sum 
 $\mathbf {N}_D(1,\lfloor \frac {e}{4} \log _p X \rfloor ;X)+\mathbf {N}_D(\lceil \frac {e}{4} \log _p X \rceil ,\infty ;X)$
. In the following proposition, we follow [Reference Shankar and TangST19, §4.2, §4.3] to bound the finite contributions for primes
$\mathbf {N}_D(1,\lfloor \frac {e}{4} \log _p X \rfloor ;X)+\mathbf {N}_D(\lceil \frac {e}{4} \log _p X \rceil ,\infty ;X)$
. In the following proposition, we follow [Reference Shankar and TangST19, §4.2, §4.3] to bound the finite contributions for primes 
 $\mathfrak {P}$
 modulo for which
$\mathfrak {P}$
 modulo for which 
 $\mathcal {Y}$
 does not have supersingular reduction and also bound
$\mathcal {Y}$
 does not have supersingular reduction and also bound 
 $\mathbf {N}_D(\lceil \frac {e}{4} \log _p X \rceil ,\infty ;X)$
 for primes
$\mathbf {N}_D(\lceil \frac {e}{4} \log _p X \rceil ,\infty ;X)$
 for primes 
 $\mathfrak {P}$
 modulo for which
$\mathfrak {P}$
 modulo for which 
 $\mathcal {Y}$
 does have supersingular reduction.
$\mathcal {Y}$
 does have supersingular reduction.
Proposition 7.7. Let the notation be as above. Then we have
- 
1. If  $r=\operatorname {\mathrm {rank}} L_n \leq b+1$
, then $r=\operatorname {\mathrm {rank}} L_n \leq b+1$
, then $$\begin{align*}\sum_{n=1}^{\infty}|\{v\in L_n\backslash\{0\}: Q(v)<X\}| =O(X^{\frac{b+1}{2}}).\end{align*}$$ $$\begin{align*}\sum_{n=1}^{\infty}|\{v\in L_n\backslash\{0\}: Q(v)<X\}| =O(X^{\frac{b+1}{2}}).\end{align*}$$
- 
2. If  $r=b+2$
, then $r=b+2$
, then $$\begin{align*}\sum_{n=\lceil\frac{e}{4}\log_p X\rceil}^{\infty}|\{ v\in L_n\backslash\{0\}: Q(v)<X\}=O(X^{\frac{b+1}{2}}) .\end{align*}$$ $$\begin{align*}\sum_{n=\lceil\frac{e}{4}\log_p X\rceil}^{\infty}|\{ v\in L_n\backslash\{0\}: Q(v)<X\}=O(X^{\frac{b+1}{2}}) .\end{align*}$$
Proof. Let 
 $\epsilon \in ]0,1[$
. By Lemma 7.6, there exists a constant
$\epsilon \in ]0,1[$
. By Lemma 7.6, there exists a constant 
 $C_{0, \epsilon }$
 such that
$C_{0, \epsilon }$
 such that 
 $a_1(n)\geq C_{0,\epsilon } n^{1/(b+\epsilon )}$
. Let
$a_1(n)\geq C_{0,\epsilon } n^{1/(b+\epsilon )}$
. Let 
 $C_{1,\epsilon }=C_{0,\epsilon }^{-(b+\epsilon )}$
. If
$C_{1,\epsilon }=C_{0,\epsilon }^{-(b+\epsilon )}$
. If 
 $n> (X^{1/2}C_{0,\epsilon }^{-1})^{b+\epsilon }=C_{1,\epsilon } X^{\frac {b+\epsilon }{2}}$
, then
$n> (X^{1/2}C_{0,\epsilon }^{-1})^{b+\epsilon }=C_{1,\epsilon } X^{\frac {b+\epsilon }{2}}$
, then 
 $a_1(n)>X^{1/2}$
, and hence
$a_1(n)>X^{1/2}$
, and hence 
 $$\begin{align*}\{v \in L_n\backslash\{0\}: Q(v)<X\}=\emptyset.\end{align*}$$
$$\begin{align*}\{v \in L_n\backslash\{0\}: Q(v)<X\}=\emptyset.\end{align*}$$
Therefore, for (1), we have
 $$ \begin{align*} \sum_{n=1}^{\infty}|\{v\in L_n\backslash\{0\}: Q(v)<X\}|&=\sum_{n=1}^{C_{1,\epsilon}X^{\frac{b+\epsilon}{2}}}|\{v\in L_n\backslash\{0\}: Q(v)<X\}|\\ &\overset{(i)}{\ll} \sum_{n=1}^{C_{1,\epsilon}X^{\frac{b+\epsilon}{2}}} \sum_{i=0}^r \frac{X^{\frac{i}{2}}}{a_i(n)}\\ &\overset{(ii)}{\ll_\epsilon} \sum_{n=1}^{C_{1,\epsilon}X^{\frac{b+\epsilon}{2}}} \sum_{i=0}^r \frac{X^{\frac{i}{2}}}{n^{i/(b+\epsilon)}}\\ &=\sum_{i=0}^r\sum_{n=1}^{C_{1,\epsilon}X^{\frac{b+\epsilon}{2}}} \frac{X^{i/2}}{n^{i/(b+\epsilon)}}, \end{align*} $$
$$ \begin{align*} \sum_{n=1}^{\infty}|\{v\in L_n\backslash\{0\}: Q(v)<X\}|&=\sum_{n=1}^{C_{1,\epsilon}X^{\frac{b+\epsilon}{2}}}|\{v\in L_n\backslash\{0\}: Q(v)<X\}|\\ &\overset{(i)}{\ll} \sum_{n=1}^{C_{1,\epsilon}X^{\frac{b+\epsilon}{2}}} \sum_{i=0}^r \frac{X^{\frac{i}{2}}}{a_i(n)}\\ &\overset{(ii)}{\ll_\epsilon} \sum_{n=1}^{C_{1,\epsilon}X^{\frac{b+\epsilon}{2}}} \sum_{i=0}^r \frac{X^{\frac{i}{2}}}{n^{i/(b+\epsilon)}}\\ &=\sum_{i=0}^r\sum_{n=1}^{C_{1,\epsilon}X^{\frac{b+\epsilon}{2}}} \frac{X^{i/2}}{n^{i/(b+\epsilon)}}, \end{align*} $$
where (i) follows from [Reference Eskin and KatznelsonEK95, Lemma 2.4, Equations (5),(6)]Footnote 32 and (ii) follows from Lemma 7.6. For 
 $0\leq i\leq b$
, note that
$0\leq i\leq b$
, note that 
 $$\begin{align*}\sum_{n=1}^{C_{1,\epsilon}X^{\frac{b+\epsilon}{2}}} \frac{X^{\frac{i}{2}}}{n^{i/(b+\epsilon)}} \ll_\epsilon X^{\frac{i}{2}}\cdot (X^{\frac{b+\epsilon}{2}})^{1-\frac{i}{b+\epsilon}}=O(X^{\frac{b+\epsilon}{2}}).\end{align*}$$
$$\begin{align*}\sum_{n=1}^{C_{1,\epsilon}X^{\frac{b+\epsilon}{2}}} \frac{X^{\frac{i}{2}}}{n^{i/(b+\epsilon)}} \ll_\epsilon X^{\frac{i}{2}}\cdot (X^{\frac{b+\epsilon}{2}})^{1-\frac{i}{b+\epsilon}}=O(X^{\frac{b+\epsilon}{2}}).\end{align*}$$
For 
 $i=b+1$
, since
$i=b+1$
, since 
 $\sum _{n=1}^\infty n^{-(b+1)/(b+\epsilon )}$
 converges, we have
$\sum _{n=1}^\infty n^{-(b+1)/(b+\epsilon )}$
 converges, we have 
 $$\begin{align*}\sum_{n=1}^{C_{1,\epsilon}X^{\frac{b+\epsilon}{2}}} \frac{X^{\frac{i}{2}}}{n^{i/(b+\epsilon)}}=O_\epsilon(X^{\frac{b+1}{2}}).\end{align*}$$
$$\begin{align*}\sum_{n=1}^{C_{1,\epsilon}X^{\frac{b+\epsilon}{2}}} \frac{X^{\frac{i}{2}}}{n^{i/(b+\epsilon)}}=O_\epsilon(X^{\frac{b+1}{2}}).\end{align*}$$
For (2), similarly, we have that the left-hand side is bounded by
 $$\begin{align*}\sum_{n=\lceil\frac{e}{4}\log_p X\rceil}^{C_{1,\epsilon}X^{\frac{b+\epsilon}{2}}} \frac{X^{(b+2)/2}}{a_{b+2}(n)}+\sum_{i=0}^{b+1}\sum_{n=\lceil\frac{e}{4}\log_p X\rceil}^{C_{1,\epsilon}X^{\frac{b+\epsilon}{2}}} \frac{X^{\frac{i}{2}}}{n^{i/(b+\epsilon)}}.\end{align*}$$
$$\begin{align*}\sum_{n=\lceil\frac{e}{4}\log_p X\rceil}^{C_{1,\epsilon}X^{\frac{b+\epsilon}{2}}} \frac{X^{(b+2)/2}}{a_{b+2}(n)}+\sum_{i=0}^{b+1}\sum_{n=\lceil\frac{e}{4}\log_p X\rceil}^{C_{1,\epsilon}X^{\frac{b+\epsilon}{2}}} \frac{X^{\frac{i}{2}}}{n^{i/(b+\epsilon)}}.\end{align*}$$
As in (1), the second term is 
 $O_\epsilon (X^{\frac {b+1}{2}})$
. For the first term, by Corollary 7.5, we have
$O_\epsilon (X^{\frac {b+1}{2}})$
. For the first term, by Corollary 7.5, we have 
 $a_{b+2}(n)\gg p^{\frac {2n}{e}}$
. Since the series
$a_{b+2}(n)\gg p^{\frac {2n}{e}}$
. Since the series 
 $\sum _{n=1}^\infty \frac {1}{p^{2n/e}}$
 converges and
$\sum _{n=1}^\infty \frac {1}{p^{2n/e}}$
 converges and 
 $p^{n/e}\geq X^{1/4}$
 when
$p^{n/e}\geq X^{1/4}$
 when 
 $n\geq \lceil \frac {e}{4}\log _p X\rceil $
, the first term is bounded by
$n\geq \lceil \frac {e}{4}\log _p X\rceil $
, the first term is bounded by 
 $O(\frac {X^{\frac {b+2}{2}}}{\sqrt {X}})=O(X^{\frac {b+1}{2}})$
, and hence the result.
$O(\frac {X^{\frac {b+2}{2}}}{\sqrt {X}})=O(X^{\frac {b+1}{2}})$
, and hence the result.
Remark 7.8. In order to prove Theorem 1.8, we do not have to restrict ourselves to sets like 
 $S_{D,X}$
 and can sum over all m. The bounds that the proof of Proposition 7.7 yields are therefore sufficient, even in the case when
$S_{D,X}$
 and can sum over all m. The bounds that the proof of Proposition 7.7 yields are therefore sufficient, even in the case when 
 $\mathfrak {P}$
 is a prime of supersingular reduction.
$\mathfrak {P}$
 is a prime of supersingular reduction.
We are now ready to finish the proof of Theorem 7.1.
Proof of Theorem 7.1
 By Proposition 7.7(1), we may restrict ourselves to the case where the rank of 
 $L_n$
 is equal to
$L_n$
 is equal to 
 $b+2$
. By Proposition 7.7(2), it suffices to prove that
$b+2$
. By Proposition 7.7(2), it suffices to prove that 
 $\mathbf {N}_D(1,\lfloor \frac {e}{4} \log _p X \rfloor ,X) = o(X^{\frac {b+1}{2}}\log X)$
.
$\mathbf {N}_D(1,\lfloor \frac {e}{4} \log _p X \rfloor ,X) = o(X^{\frac {b+1}{2}}\log X)$
.
 To that end, let 
 $1\leq T\leq \lfloor \frac {e}{4} \log _p X \rfloor /e$
 be an integer, and let m be an integer satisfying
$1\leq T\leq \lfloor \frac {e}{4} \log _p X \rfloor /e$
 be an integer, and let m be an integer satisfying 
 $X \leq m < 2X$
. For brevity, let
$X \leq m < 2X$
. For brevity, let 
 $$\begin{align*}\mathbf{N}_1(m) =|\{v \in L_1: Q(v) = m\}|, \quad \mathbf{N}_T(m) = |\{v \in L_{eT}: Q(v) = m\}|.\end{align*}$$
$$\begin{align*}\mathbf{N}_1(m) =|\{v \in L_1: Q(v) = m\}|, \quad \mathbf{N}_T(m) = |\{v \in L_{eT}: Q(v) = m\}|.\end{align*}$$
Then we have the trivial bound
 $$ \begin{align} \sum_{n =1 }^{\lfloor \frac{e}{4}\log_p X \rfloor}|\{v \in L_n: Q(v) = m\}|&= \sum_{n=1}^{eT}|\{v \in L_n: Q(v) = m\}|+\sum_{n=eT+1}^{\lfloor \frac{e}{4}\log_p X \rfloor}|\{v \in L_n: Q(v) = m\}| \end{align} $$
$$ \begin{align} \sum_{n =1 }^{\lfloor \frac{e}{4}\log_p X \rfloor}|\{v \in L_n: Q(v) = m\}|&= \sum_{n=1}^{eT}|\{v \in L_n: Q(v) = m\}|+\sum_{n=eT+1}^{\lfloor \frac{e}{4}\log_p X \rfloor}|\{v \in L_n: Q(v) = m\}| \end{align} $$
 $$ \begin{align} &\leq eT\mathbf{N}_1(m) + \frac{e\log_p X}{4}\mathbf{N}_T(m). \end{align} $$
$$ \begin{align} &\leq eT\mathbf{N}_1(m) + \frac{e\log_p X}{4}\mathbf{N}_T(m). \end{align} $$
 By Corollary 4.10, 
 $eT \mathbf {N}_1(m) \ll eTm^{\frac {b}{2}} \ll eTX^{\frac {b}{2}}$
 and
$eT \mathbf {N}_1(m) \ll eTm^{\frac {b}{2}} \ll eTX^{\frac {b}{2}}$
 and 
 $$\begin{align*}\mathbf{N}_T(m) = \mu_{\infty}(Q_T,1)\mu(Q_T,m)m^{\frac{b}{2}} + O_{T,\epsilon}(m^{(b+1)/4 + \epsilon}),\end{align*}$$
$$\begin{align*}\mathbf{N}_T(m) = \mu_{\infty}(Q_T,1)\mu(Q_T,m)m^{\frac{b}{2}} + O_{T,\epsilon}(m^{(b+1)/4 + \epsilon}),\end{align*}$$
where 
 $Q_T$
 is the positive definite quadratic form on
$Q_T$
 is the positive definite quadratic form on 
 $L_{eT}$
. By Lemma 7.9 below,
$L_{eT}$
. By Lemma 7.9 below, 
 $$ \begin{align*}\mu_{\infty}(Q_T,1)\mu(Q_T,m) \ll p^{-3/5T},\end{align*} $$
$$ \begin{align*}\mu_{\infty}(Q_T,1)\mu(Q_T,m) \ll p^{-3/5T},\end{align*} $$
so we obtain
 $$ \begin{align*}\mathbf{N}_T(m) \ll p^{-3/5T}m^{\frac{b}{2}} + O_{T,\epsilon}(m^{(b+1)/4 + \epsilon}).\end{align*} $$
$$ \begin{align*}\mathbf{N}_T(m) \ll p^{-3/5T}m^{\frac{b}{2}} + O_{T,\epsilon}(m^{(b+1)/4 + \epsilon}).\end{align*} $$
 Therefore, by summing equation (7.3) over 
 $m \in S_{D,X}$
 and by the above bounds on
$m \in S_{D,X}$
 and by the above bounds on 
 $\mathbf {N}_1(m), \mathbf {N}_T(m)$
, we have
$\mathbf {N}_1(m), \mathbf {N}_T(m)$
, we have 
 $$ \begin{align*} \frac{\mathbf{N}_D(1,\lfloor e\log_pX \rfloor,X)}{X^{\frac{b+1}{2}}\log X} \ll \frac{eT}{\log X}+ p^{-3/5T} + \frac{O_{T,\epsilon}(X^{(b+3)/4 + \epsilon} )}{X^{\frac{b+1}{2}}\log X}. \end{align*} $$
$$ \begin{align*} \frac{\mathbf{N}_D(1,\lfloor e\log_pX \rfloor,X)}{X^{\frac{b+1}{2}}\log X} \ll \frac{eT}{\log X}+ p^{-3/5T} + \frac{O_{T,\epsilon}(X^{(b+3)/4 + \epsilon} )}{X^{\frac{b+1}{2}}\log X}. \end{align*} $$
Therefore,
 $$ \begin{align*} \limsup_{X\rightarrow\infty} \frac{\mathbf{N}_D(1,\lfloor e\log_pX \rfloor,X)}{X^{\frac{b+1}{2}}\log X} \ll p^{-3/5T}. \end{align*} $$
$$ \begin{align*} \limsup_{X\rightarrow\infty} \frac{\mathbf{N}_D(1,\lfloor e\log_pX \rfloor,X)}{X^{\frac{b+1}{2}}\log X} \ll p^{-3/5T}. \end{align*} $$
As the above inequality is true for every value of T, we have
 $$ \begin{align*} \mathbf{N}_D(1,\lfloor e\log_pX \rfloor,X)= o(X^{\frac{b+1}{2}}\log X), \end{align*} $$
$$ \begin{align*} \mathbf{N}_D(1,\lfloor e\log_pX \rfloor,X)= o(X^{\frac{b+1}{2}}\log X), \end{align*} $$
whence the theorem follows.
Lemma 7.9. Let Q denote an integral positive definite quadratic form of rank 
 $r\geq 5$
, let
$r\geq 5$
, let 
 $m\geq 1$
 be any integer, and let p denote a prime. Then we have
$m\geq 1$
 be any integer, and let p denote a prime. Then we have 
 $$ \begin{align*}\mu_{\infty}(Q,1) \mu_p(Q,m) \ll \frac{p^r}{|\operatorname{\mathrm{Disc}}(Q)|^{3/20}},\end{align*} $$
$$ \begin{align*}\mu_{\infty}(Q,1) \mu_p(Q,m) \ll \frac{p^r}{|\operatorname{\mathrm{Disc}}(Q)|^{3/20}},\end{align*} $$
where the implicit constant above only depends on r. In particular, for T and p as above, we have
 $$ \begin{align*}\mu_{\infty}(Q_T,1)\mu(Q_T,m) \ll p^{-3/5T}.\end{align*} $$
$$ \begin{align*}\mu_{\infty}(Q_T,1)\mu(Q_T,m) \ll p^{-3/5T}.\end{align*} $$
Proof. The definition of 
 $\mu _{\infty }(Q,1)$
 in Section 4.2 yields that
$\mu _{\infty }(Q,1)$
 in Section 4.2 yields that 
 $\mu _{\infty }(Q,1) \asymp \textrm {Disc}(Q)^{-1/2}$
, where the implicit constant only depends on the rank r. The assertion about
$\mu _{\infty }(Q,1) \asymp \textrm {Disc}(Q)^{-1/2}$
, where the implicit constant only depends on the rank r. The assertion about 
 $Q_T$
 follows from the first assertion, by the fact that
$Q_T$
 follows from the first assertion, by the fact that 
 $\textrm {Disc}(Q_T)^{-1/2}\ll p^{-2T}$
 (from Corollary 7.5) and the fact that for a prime
$\textrm {Disc}(Q_T)^{-1/2}\ll p^{-2T}$
 (from Corollary 7.5) and the fact that for a prime 
 $\ell \neq p$
,
$\ell \neq p$
, 
 $\mu _{\ell }(Q_T,m)$
 is independent of T for
$\mu _{\ell }(Q_T,m)$
 is independent of T for 
 $T\gg 1$
 (from Proposition 7.3). Therefore, it suffices to prove the first assertion.
$T\gg 1$
 (from Proposition 7.3). Therefore, it suffices to prove the first assertion.
 Recall from Sections 4.1–4.2 that we have 
 $\mu _p(Q,m)=\mu _p(m,n)$
 for some sufficiently large integer n. Moreover, following [Reference HankeHan04, §3, pp. 359-360], we have
$\mu _p(Q,m)=\mu _p(m,n)$
 for some sufficiently large integer n. Moreover, following [Reference HankeHan04, §3, pp. 359-360], we have 
 $$ \begin{align*} \mu_p(m,n)=\mu_p^{\mathrm{good}}(m,n)+\mu_p^{\mathrm{bad1}}(m,n)+\mu_p^{\mathrm{bad2}}(m,n)+\mu_p^{\mathrm{zero}}(m,n), \end{align*} $$
$$ \begin{align*} \mu_p(m,n)=\mu_p^{\mathrm{good}}(m,n)+\mu_p^{\mathrm{bad1}}(m,n)+\mu_p^{\mathrm{bad2}}(m,n)+\mu_p^{\mathrm{zero}}(m,n), \end{align*} $$
where the summands come from elements of reduction type good, bad1, bad2 and zero, respectively. To prove the first estimate of the lemma, we once again (as in Section 4.1) use the reduction maps from [Reference HankeHan04, §3]. These immediately yield the following inequalities:
 $$ \begin{align*} \begin{array}{rcl} \mu_p^{\mathrm{good}}(m,n)&\leq& p^3,\\[.1in] \mu_p^{\mathrm{bad1}}(m,n)&\leq& p^4,\\[.15in] \displaystyle\frac{\mu_p^{\mathrm{bad2}}(m,n)}{\operatorname{\mathrm{Disc}}(Q)^{1/2}}&\leq& \displaystyle p^{2-r}\frac{\mu^{\prime\prime}p(m/p^2,n-2)}{\operatorname{\mathrm{Disc}}(Q'')^{1/2}},\\[.2in] \mu_p^{\mathrm{zero}}(m,n)&\leq& p^{2-r}\mu_p(m/p^2,n-2), \end{array} \end{align*} $$
$$ \begin{align*} \begin{array}{rcl} \mu_p^{\mathrm{good}}(m,n)&\leq& p^3,\\[.1in] \mu_p^{\mathrm{bad1}}(m,n)&\leq& p^4,\\[.15in] \displaystyle\frac{\mu_p^{\mathrm{bad2}}(m,n)}{\operatorname{\mathrm{Disc}}(Q)^{1/2}}&\leq& \displaystyle p^{2-r}\frac{\mu^{\prime\prime}p(m/p^2,n-2)}{\operatorname{\mathrm{Disc}}(Q'')^{1/2}},\\[.2in] \mu_p^{\mathrm{zero}}(m,n)&\leq& p^{2-r}\mu_p(m/p^2,n-2), \end{array} \end{align*} $$
where in the third line, 
 $Q''$
 is a quadratic form of rank r constructed from Q (see [Reference HankeHan04, p.360] for the definition of
$Q''$
 is a quadratic form of rank r constructed from Q (see [Reference HankeHan04, p.360] for the definition of 
 $Q''$
) and
$Q''$
) and 
 $\mu _p''$
 is the density corresponding to
$\mu _p''$
 is the density corresponding to 
 $Q''$
. Furthermore, it is easy to check that we have
$Q''$
. Furthermore, it is easy to check that we have 
 $\operatorname {\mathrm {Disc}}(Q'')\geq \operatorname {\mathrm {Disc}}(Q)/p^{2r}$
. Then we obtain the bound
$\operatorname {\mathrm {Disc}}(Q'')\geq \operatorname {\mathrm {Disc}}(Q)/p^{2r}$
. Then we obtain the bound 
 $\displaystyle \frac {\mu _p(m,n)}{\operatorname {\mathrm {Disc}}(Q)^{1/2}}\leq \frac {p^r}{\operatorname {\mathrm {Disc}}(Q)^{3/20}}$
 by induction on n, along with the observation that in each step of the induction,
$\displaystyle \frac {\mu _p(m,n)}{\operatorname {\mathrm {Disc}}(Q)^{1/2}}\leq \frac {p^r}{\operatorname {\mathrm {Disc}}(Q)^{3/20}}$
 by induction on n, along with the observation that in each step of the induction, 
 $\operatorname {\mathrm {Disc}}(Q'')$
 decreases by at most
$\operatorname {\mathrm {Disc}}(Q'')$
 decreases by at most 
 $p^{2r}$
 and
$p^{2r}$
 and 
 $r-2\geq 3$
.
$r-2\geq 3$
.
7.3 A transcendental example
 We now demonstrate an example of a point 
 $\mathcal {Y}'\in \mathcal {M}(W(\mathbb {F}_q))$
 with the property that
$\mathcal {Y}'\in \mathcal {M}(W(\mathbb {F}_q))$
 with the property that 
 $(\mathcal {Y}'.\mathcal {Z}(m))_p$
 is exponential in m for an infinite sequence of
$(\mathcal {Y}'.\mathcal {Z}(m))_p$
 is exponential in m for an infinite sequence of 
 $m \in S$
, where
$m \in S$
, where 
 $S = \{\mathbb {Z}_{>0} \cap (\mathbb {Q}^\times )^2\}$
 and
$S = \{\mathbb {Z}_{>0} \cap (\mathbb {Q}^\times )^2\}$
 and 
 $\mathrm {char}\, \mathbb {F}_q =p$
. Similar examples can be analogously constructed with
$\mathrm {char}\, \mathbb {F}_q =p$
. Similar examples can be analogously constructed with 
 $m\in S_D= \{\mathbb {Z}_{>0} \cap D\cdot (\mathbb {Q}^\times )^2$
. As this example isn’t necessary for any of the main results and only serves to highlight the importance of the global height bound, we will be brief in our exposition.
$m\in S_D= \{\mathbb {Z}_{>0} \cap D\cdot (\mathbb {Q}^\times )^2$
. As this example isn’t necessary for any of the main results and only serves to highlight the importance of the global height bound, we will be brief in our exposition.
 For simplicity, assume that the rank of the lattice defining the Shimura variety is even and at least 
 $12$
. Let
$12$
. Let 
 $b = 2c$
. We may choose our Shimura variety
$b = 2c$
. We may choose our Shimura variety 
 $\mathcal {M}$
 such that it admits a map from the modular curve in characteristic 0 and hence contains a CM point
$\mathcal {M}$
 such that it admits a map from the modular curve in characteristic 0 and hence contains a CM point 
 $\mathcal {Y}$
 whose lattice of special endomorphisms L also has rank
$\mathcal {Y}$
 whose lattice of special endomorphisms L also has rank 
 $b = 2c$
. We may also assume that L represents every large enough positive integer.
$b = 2c$
. We may also assume that L represents every large enough positive integer.
 Let p be a large enough prime of ordinary reduction for this point. We also assume that p doesn’t divide the discriminant of the lattice of special endomorphisms of 
 $\mathcal {Y}$
. Let y denote the mod p reduction of
$\mathcal {Y}$
. Let y denote the mod p reduction of 
 $\mathcal {Y}$
 – we may assume (by increasing p if necessary) that
$\mathcal {Y}$
 – we may assume (by increasing p if necessary) that 
 $\mathcal {Y}$
 is the canonical lift of y and therefore L is also the lattice of special endomorphisms of y. Let q be such that
$\mathcal {Y}$
 is the canonical lift of y and therefore L is also the lattice of special endomorphisms of y. Let q be such that 
 $y \in \mathcal {M}(\mathbb {F}_q)$
.
$y \in \mathcal {M}(\mathbb {F}_q)$
.
The lemma below follows from Serre–Tate theory and [Reference PeraMP16, Corollaries 5.17,5.19]:
Lemma 7.10. Let 
 $\Lambda \subset L\otimes \mathbb {Z}_p$
 denote a self-dualFootnote 33
$\Lambda \subset L\otimes \mathbb {Z}_p$
 denote a self-dualFootnote 33 
 $\mathbb {Z}_p$
-submodule. Then there exists a point
$\mathbb {Z}_p$
-submodule. Then there exists a point 
 $\mathcal {Y}_{\Lambda } \in \mathcal {M}(W(\mathbb {F}_q))$
 lifting y whose
$\mathcal {Y}_{\Lambda } \in \mathcal {M}(W(\mathbb {F}_q))$
 lifting y whose 
 $\mathbb {Z}_p$
-lattice of special endomorphisms is
$\mathbb {Z}_p$
-lattice of special endomorphisms is 
 $\Lambda $
. Further, we have that the
$\Lambda $
. Further, we have that the 
 $\mathbb {Z}$
-lattice of special endomorphisms of
$\mathbb {Z}$
-lattice of special endomorphisms of 
 $\mathcal {Y}_{\Lambda } \bmod p^{n+1}$
 is
$\mathcal {Y}_{\Lambda } \bmod p^{n+1}$
 is 
 $(\Lambda + p^nL\otimes \mathbb {Z}_p) \cap L$
.
$(\Lambda + p^nL\otimes \mathbb {Z}_p) \cap L$
.
 Our example 
 $\mathcal {Y}'$
 will equal
$\mathcal {Y}'$
 will equal 
 $\mathcal {Y}_{\Lambda }$
 for an appropriate choice of
$\mathcal {Y}_{\Lambda }$
 for an appropriate choice of 
 $\Lambda $
. A choice of
$\Lambda $
. A choice of 
 $\Lambda $
 that is ‘very well approximated’ by
$\Lambda $
 that is ‘very well approximated’ by 
 $\mathbb {Z}$
-sublattices of L will have the property that
$\mathbb {Z}$
-sublattices of L will have the property that 
 $(\mathcal {Y}_{\Lambda }.\mathcal {Z}(m))$
 is exponential in terms of m for infinitely many m. Indeed, the following lemma makes this precise.
$(\mathcal {Y}_{\Lambda }.\mathcal {Z}(m))$
 is exponential in terms of m for infinitely many m. Indeed, the following lemma makes this precise.
Lemma 7.11. Suppose that a rank 
 $r\geq 5$
 self-dual sublattice
$r\geq 5$
 self-dual sublattice 
 $\Lambda \subset L\otimes \mathbb {Z}_p$
 has the following properties:
$\Lambda \subset L\otimes \mathbb {Z}_p$
 has the following properties: 
- 
1.  $\Lambda $
 contains no integer elements – that is, $\Lambda $
 contains no integer elements – that is, $\Lambda \cap L = \{0\}$
. $\Lambda \cap L = \{0\}$
.
- 
2. There exists an increasing sequence of rank r sublattices  $L_i\subset L$
 with discriminants $L_i\subset L$
 with discriminants $D_i$
 such that $D_i$
 such that $\Lambda \equiv L_{n_i}\, \mod p^{N_i}$
, where $\Lambda \equiv L_{n_i}\, \mod p^{N_i}$
, where $N_i \geq e^{e^{D_i}}$
. $N_i \geq e^{e^{D_i}}$
.
Then there exists an increasing sequence of perfect squares 
 $m_i$
 such that
$m_i$
 such that 
 $(\mathcal {Y}_{\Lambda },\mathcal {Z}(m_i))_p$
 is exponential in
$(\mathcal {Y}_{\Lambda },\mathcal {Z}(m_i))_p$
 is exponential in 
 $m_i$
.
$m_i$
.
Proof. We first note that property 1 implies that 
 $\mathcal {Y}_{\Lambda }$
 isn’t contained in any special divisor
$\mathcal {Y}_{\Lambda }$
 isn’t contained in any special divisor 
 $\mathcal {Z}(m)$
, so the intersection
$\mathcal {Z}(m)$
, so the intersection 
 $(\mathcal {Y}_{\Lambda }.\mathcal {Z}(m))_p$
 is well defined for every positive integer m. Property 2 implies that the lattice of special endomorphisms of
$(\mathcal {Y}_{\Lambda }.\mathcal {Z}(m))_p$
 is well defined for every positive integer m. Property 2 implies that the lattice of special endomorphisms of 
 $\mathcal {Y}_{\Lambda } \bmod p^{N_i+1}$
 is
$\mathcal {Y}_{\Lambda } \bmod p^{N_i+1}$
 is 
 $L_i + p^{N_i}L$
. The lattice
$L_i + p^{N_i}L$
. The lattice 
 $L_i$
, having rank at least 5, must locally represent perfect squares satisfying congruence conditions modulo a power of
$L_i$
, having rank at least 5, must locally represent perfect squares satisfying congruence conditions modulo a power of 
 $D_i$
, where the power depends only on the rank r and nothing else. Therefore,
$D_i$
, where the power depends only on the rank r and nothing else. Therefore, 
 $L_i$
 must represent perfect squares (again satisfying these congruence conditions) having size bounded by
$L_i$
 must represent perfect squares (again satisfying these congruence conditions) having size bounded by 
 $e^{D_i}$
, because if a quadratic form having rank at least 4 locally represents integers that are large relative to the discriminant, it must actually represent such integers too.
$e^{D_i}$
, because if a quadratic form having rank at least 4 locally represents integers that are large relative to the discriminant, it must actually represent such integers too.
 Pick some perfect square 
 $m_i < e^{D_i}$
, which
$m_i < e^{D_i}$
, which 
 $L_i$
 represents. Then we have (by Lemma 7.2)
$L_i$
 represents. Then we have (by Lemma 7.2) 
 $(\mathcal {Y}_{\Lambda }.\mathcal {Z}(m_i))_p> N_i$
. The lemma follows.
$(\mathcal {Y}_{\Lambda }.\mathcal {Z}(m_i))_p> N_i$
. The lemma follows.
 We now only need to find a 
 $\mathbb {Z}_p$
-sublattice of L that satisfies the properties of Lemma 7.11. To that end, we may assume that L has an integral orthogonal basis
$\mathbb {Z}_p$
-sublattice of L that satisfies the properties of Lemma 7.11. To that end, we may assume that L has an integral orthogonal basis 
 $e_1,f_1,\ldots e_c,f_c$
. For elements
$e_1,f_1,\ldots e_c,f_c$
. For elements 
 $\mu _1\ldots \mu _c \in \mathbb {Z}_p$
, we consider the rank
$\mu _1\ldots \mu _c \in \mathbb {Z}_p$
, we consider the rank 
 $c \mathbb {Z}_p$
-sublattice defined by
$c \mathbb {Z}_p$
-sublattice defined by 
 $\Lambda = \textrm {Span}_{\mathbb {Z}_p}\{e_i + \mu f_i \}$
. The fact that
$\Lambda = \textrm {Span}_{\mathbb {Z}_p}\{e_i + \mu f_i \}$
. The fact that 
 $b\geq 10$
 implies that
$b\geq 10$
 implies that 
 $\Lambda $
 has rank
$\Lambda $
 has rank 
 $\geq 5$
. Insisting that the
$\geq 5$
. Insisting that the 
 $\mu _i$
 are irrational implies that
$\mu _i$
 are irrational implies that 
 $\Lambda $
 has property 1. We now pick the
$\Lambda $
 has property 1. We now pick the 
 $\mu _i$
 so that
$\mu _i$
 so that 
 $\Lambda $
 satisfies property 2. We will write
$\Lambda $
 satisfies property 2. We will write 
 $\mu = \sum _{i\geq 0} a_i p^i$
, with
$\mu = \sum _{i\geq 0} a_i p^i$
, with 
 $0\leq a_i \leq p-1$
 and
$0\leq a_i \leq p-1$
 and 
 $a_0 = 1$
. We define the
$a_0 = 1$
. We define the 
 $a_i$
 as follows: suppose that
$a_i$
 as follows: suppose that 
 $a_n \neq 0$
; we define
$a_n \neq 0$
; we define 
 $a_i = 0$
 for
$a_i = 0$
 for 
 $n+1 \leq i \leq e^{e^{p^n}}$
, and we then define
$n+1 \leq i \leq e^{e^{p^n}}$
, and we then define 
 $a_{i} = 1$
 for
$a_{i} = 1$
 for 
 $i = \lceil e^{e^{p^n}}\rceil $
. This implies that
$i = \lceil e^{e^{p^n}}\rceil $
. This implies that 
 $\sum _{i\le n} a_i p^i \equiv \mu \bmod p^N$
 with
$\sum _{i\le n} a_i p^i \equiv \mu \bmod p^N$
 with 
 $N\geq e^{e^{p^n}}$
 – that is, there is an integer
$N\geq e^{e^{p^n}}$
 – that is, there is an integer 
 $x_n$
 of size
$x_n$
 of size 
 $O(p^n)$
 that approximates
$O(p^n)$
 that approximates 
 $\mu \bmod p^N$
, with N double-exponential in the size of
$\mu \bmod p^N$
, with N double-exponential in the size of 
 $x_n$
. Having defined
$x_n$
. Having defined 
 $\mu $
 in this way, we pick
$\mu $
 in this way, we pick 
 $\mu _i = \mu $
 for all i, and the lattice
$\mu _i = \mu $
 for all i, and the lattice 
 $\Lambda $
 created this way must also have property 2.
$\Lambda $
 created this way must also have property 2.
 Choosing 
 $\mathcal {Y}' = \mathcal {Y}_{\Lambda }$
, we obtain our example by Lemma 7.11.
$\mathcal {Y}' = \mathcal {Y}_{\Lambda }$
, we obtain our example by Lemma 7.11.
8 Proof of the main theorem
 Let 
 $(L,Q)$
 be a maximal integral quadratic even lattice of signature
$(L,Q)$
 be a maximal integral quadratic even lattice of signature 
 $(b,2)$
 with
$(b,2)$
 with 
 $b\geq 3$
, and let
$b\geq 3$
, and let 
 $\mathcal {M}$
 denote the integral model of the Shimura variety associated to
$\mathcal {M}$
 denote the integral model of the Shimura variety associated to 
 $(L,Q)$
 defined in Section 2. We recall the statement of the main theorem:
$(L,Q)$
 defined in Section 2. We recall the statement of the main theorem:
Theorem 2.4. Let K be a number field, and let 
 $D\in \mathbb {Z}_{>0}$
 be a fixed integer represented by
$D\in \mathbb {Z}_{>0}$
 be a fixed integer represented by 
 $(L,Q)$
. Let
$(L,Q)$
. Let 
 $\mathcal {Y}\in \mathcal {M}(\mathcal {O}_K)$
, and assume that
$\mathcal {Y}\in \mathcal {M}(\mathcal {O}_K)$
, and assume that 
 $\mathcal {Y}_K\in M(K)$
 is Hodge-generic. Then there are infinitely many places
$\mathcal {Y}_K\in M(K)$
 is Hodge-generic. Then there are infinitely many places 
 $\mathfrak {P}$
 of K such that
$\mathfrak {P}$
 of K such that 
 $\mathcal {Y}_{\overline {\mathfrak {P}}}$
 lies in the image of
$\mathcal {Y}_{\overline {\mathfrak {P}}}$
 lies in the image of 
 $\mathcal {Z}(Dm^2)\rightarrow \mathcal {M}$
 for some
$\mathcal {Z}(Dm^2)\rightarrow \mathcal {M}$
 for some 
 $m\in \mathbb {Z}_{>0}$
. Equivalently, for a Kuga–Satake abelian variety
$m\in \mathbb {Z}_{>0}$
. Equivalently, for a Kuga–Satake abelian variety 
 $\mathcal {A}$
 over
$\mathcal {A}$
 over 
 $\mathcal {O}_K$
 parametrised by
$\mathcal {O}_K$
 parametrised by 
 $\mathcal {M}$
 such that
$\mathcal {M}$
 such that 
 $\mathcal {A}_{\overline {K}}$
 does not have any special endomorphisms, there are infinitely many
$\mathcal {A}_{\overline {K}}$
 does not have any special endomorphisms, there are infinitely many 
 $\mathfrak {P}$
 such that
$\mathfrak {P}$
 such that 
 $\mathcal {A}_{\overline {\mathfrak {P}}}$
 admits a special endomorphism v such that
$\mathcal {A}_{\overline {\mathfrak {P}}}$
 admits a special endomorphism v such that 
 $v\circ v=[Dm^2]$
 for some
$v\circ v=[Dm^2]$
 for some 
 $m\in \mathbb {Z}_{>0}$
.
$m\in \mathbb {Z}_{>0}$
.
In this section, we will prove Theorem 2.4 using results proved in the previous sections. First, we recall results and definitions that we will need to prove the main theorem.
We have the expression
 $$ \begin{align} h_{\widehat{\mathcal{Z}}(m)}(\mathcal{Y})=\sum_{\sigma:K\hookrightarrow \mathbb{C}}\Phi_m(\mathcal{Y}^\sigma)+\sum_{\mathfrak{P}} (\mathcal{Y}. \mathcal{Z}(m))_{\mathfrak{P}} \log |\mathcal{O}_K/\mathfrak{P}|. \end{align} $$
$$ \begin{align} h_{\widehat{\mathcal{Z}}(m)}(\mathcal{Y})=\sum_{\sigma:K\hookrightarrow \mathbb{C}}\Phi_m(\mathcal{Y}^\sigma)+\sum_{\mathfrak{P}} (\mathcal{Y}. \mathcal{Z}(m))_{\mathfrak{P}} \log |\mathcal{O}_K/\mathfrak{P}|. \end{align} $$
In Sections 5, 6 and 7, we proved results bounding the terms in equation (8.1), which we restate below for the convenience of the reader.
- 
Theorem 5.7. For every m representable by  $(L,Q)$
, we have $(L,Q)$
, we have $$\begin{align*}\Phi_m(\mathcal{Y}^\sigma)=c(m)\log m + A(m, \mathcal{Y}^\sigma)+o(|c(m)|\log m).\end{align*}$$ $$\begin{align*}\Phi_m(\mathcal{Y}^\sigma)=c(m)\log m + A(m, \mathcal{Y}^\sigma)+o(|c(m)|\log m).\end{align*}$$
- 
Theorem 6.1. There exists a subset  $S_{\mathrm {bad}} \subset \mathbb {Z}_{>0}$
 of logarithmic asymptotic density zero such that for every $S_{\mathrm {bad}} \subset \mathbb {Z}_{>0}$
 of logarithmic asymptotic density zero such that for every $m\notin S_{\mathrm {bad}}$
, we have $m\notin S_{\mathrm {bad}}$
, we have $$ \begin{align*} A(m,\mathcal{Y}^{\sigma})=o(m^{\frac{b}{2}}\log(m)). \end{align*} $$ $$ \begin{align*} A(m,\mathcal{Y}^{\sigma})=o(m^{\frac{b}{2}}\log(m)). \end{align*} $$
- 
Theorem 7.1. Given  $D, X\in \mathbb {Z}_{>0}$
, let $D, X\in \mathbb {Z}_{>0}$
, let $S_{D,X}$
 denote the set For a fixed prime $S_{D,X}$
 denote the set For a fixed prime $$\begin{align*}\{m\in \mathbb{Z}_{>0}\mid X \leq m<2X, \sqrt{m/D}\in \mathbb{Z} \}.\end{align*}$$ $$\begin{align*}\{m\in \mathbb{Z}_{>0}\mid X \leq m<2X, \sqrt{m/D}\in \mathbb{Z} \}.\end{align*}$$ $\mathfrak {P}$
 of K and a fixed D, we have $\mathfrak {P}$
 of K and a fixed D, we have $$\begin{align*}\sum_{m\in S_{D,X}}(\mathcal{Y}. \mathcal{Z}(m))_{\mathfrak{P}}=o(X^{\frac{b+1}{2}}\log X).\end{align*}$$ $$\begin{align*}\sum_{m\in S_{D,X}}(\mathcal{Y}. \mathcal{Z}(m))_{\mathfrak{P}}=o(X^{\frac{b+1}{2}}\log X).\end{align*}$$
Proof of Theorem 2.4
 Assume for contradiction that there exists 
 $D\in \mathbb {Z}_{>0}$
 represented by L such that there are only finitely many
$D\in \mathbb {Z}_{>0}$
 represented by L such that there are only finitely many 
 $\mathfrak {P}$
 for which
$\mathfrak {P}$
 for which 
 $\mathcal {Y}_{\overline {\mathfrak {P}}}$
 lies in the image of
$\mathcal {Y}_{\overline {\mathfrak {P}}}$
 lies in the image of 
 $\mathcal {Z}(m)$
, where
$\mathcal {Z}(m)$
, where 
 $m/D$
 is a perfect square. Therefore, for such m,
$m/D$
 is a perfect square. Therefore, for such m, 
 $(\mathcal {Y},\mathcal {Z}(m))_{\mathfrak {P}}=0$
 for all but finitely many
$(\mathcal {Y},\mathcal {Z}(m))_{\mathfrak {P}}=0$
 for all but finitely many 
 $\mathfrak {P}$
.
$\mathfrak {P}$
.
 For 
 $X\in \mathbb {Z}_{>0}$
, let
$X\in \mathbb {Z}_{>0}$
, let 
 $S^{\mathrm {good}}_{D,X}$
 denote the set
$S^{\mathrm {good}}_{D,X}$
 denote the set 
 $\{m\in S_{D,X}\mid m\notin S_{\mathrm {bad}}\}$
, where
$\{m\in S_{D,X}\mid m\notin S_{\mathrm {bad}}\}$
, where 
 $S_{D,X}$
 is defined in Theorem 7.1 and
$S_{D,X}$
 is defined in Theorem 7.1 and 
 $S_{\mathrm {bad}}$
 is the union of the sets of log asymptotic density
$S_{\mathrm {bad}}$
 is the union of the sets of log asymptotic density 
 $0$
 in Theorem 6.1 by taking
$0$
 in Theorem 6.1 by taking 
 $x=\mathcal {Y}^\sigma $
 for all
$x=\mathcal {Y}^\sigma $
 for all 
 $\sigma :K\hookrightarrow \mathbb {C}$
. Then
$\sigma :K\hookrightarrow \mathbb {C}$
. Then 
 $S_{\mathrm {bad}}$
 is also of log asymptotic density
$S_{\mathrm {bad}}$
 is also of log asymptotic density 
 $0$
 and
$0$
 and 
 $|S^{\mathrm {good}}_{D,X}|\asymp X^{1/2}$
 as
$|S^{\mathrm {good}}_{D,X}|\asymp X^{1/2}$
 as 
 $X\rightarrow \infty $
. On the other hand, by assumption, D is representable by
$X\rightarrow \infty $
. On the other hand, by assumption, D is representable by 
 $(L,Q)$
; then each
$(L,Q)$
; then each 
 $m\in S_{D,X}$
 is representable by
$m\in S_{D,X}$
 is representable by 
 $(L,Q)$
, and hence
$(L,Q)$
, and hence 
 $\mathcal {Z}(m)\neq \emptyset $
.
$\mathcal {Z}(m)\neq \emptyset $
.
 We sum (8.1) over 
 $m\in S^{\mathrm {good}}_{D,X}$
 and note that for each
$m\in S^{\mathrm {good}}_{D,X}$
 and note that for each 
 $m\in S^{\mathrm {good}}_{D,X}$
,
$m\in S^{\mathrm {good}}_{D,X}$
, 
 $m\asymp X$
. For the archimedean term, by Theorem 5.7, we have
$m\asymp X$
. For the archimedean term, by Theorem 5.7, we have 
 $$ \begin{align} \sum_{m\in S^{\mathrm{good}}_{D,X}}\sum_{\sigma:K\hookrightarrow\mathbb{C}}\frac{\Phi_{m}(\mathcal{Y}^\sigma)}{|\mathrm{Aut}(\mathcal{Y}^\sigma)|}\asymp -X^{\frac{b+1}{2}}\log X. \end{align} $$
$$ \begin{align} \sum_{m\in S^{\mathrm{good}}_{D,X}}\sum_{\sigma:K\hookrightarrow\mathbb{C}}\frac{\Phi_{m}(\mathcal{Y}^\sigma)}{|\mathrm{Aut}(\mathcal{Y}^\sigma)|}\asymp -X^{\frac{b+1}{2}}\log X. \end{align} $$
 For a fixed 
 $\mathfrak {P}$
, since
$\mathfrak {P}$
, since 
 $(\mathcal {Y}.\mathcal {Z}(m))_{\mathfrak {P}}\geq 0$
 for all m, then by Theorem 7.1,
$(\mathcal {Y}.\mathcal {Z}(m))_{\mathfrak {P}}\geq 0$
 for all m, then by Theorem 7.1, 
 $$\begin{align*}\sum_{m\in S^{\mathrm{good}}_{D,X}}(\mathcal{Y}. \mathcal{Z}(m))_{\mathfrak{P}} \log|\mathcal{O}_K/\mathfrak{P}| \leq\sum_{m\in S_{D,X}}(\mathcal{Y}. \mathcal{Z}(m))_{\mathfrak{P}} \log|\mathcal{O}_K/\mathfrak{P}|=o(X^{\frac{b+1}{2}}\log X).\end{align*}$$
$$\begin{align*}\sum_{m\in S^{\mathrm{good}}_{D,X}}(\mathcal{Y}. \mathcal{Z}(m))_{\mathfrak{P}} \log|\mathcal{O}_K/\mathfrak{P}| \leq\sum_{m\in S_{D,X}}(\mathcal{Y}. \mathcal{Z}(m))_{\mathfrak{P}} \log|\mathcal{O}_K/\mathfrak{P}|=o(X^{\frac{b+1}{2}}\log X).\end{align*}$$
Since 
 $(\mathcal {Y},\mathcal {Z}(m))_{\mathfrak {P}}=0$
 for all but finitely many
$(\mathcal {Y},\mathcal {Z}(m))_{\mathfrak {P}}=0$
 for all but finitely many 
 $\mathfrak {P}$
, we have
$\mathfrak {P}$
, we have 
 $$ \begin{align} \sum_{m\in S^{\mathrm{good}}_{D,X}}\sum_{\mathfrak{P}}(\mathcal{Y}. \mathcal{Z}(m))_{\mathfrak{P}} \log|\mathcal{O}_K/\mathfrak{P}|=o(X^{\frac{b+1}{2}}\log X). \end{align} $$
$$ \begin{align} \sum_{m\in S^{\mathrm{good}}_{D,X}}\sum_{\mathfrak{P}}(\mathcal{Y}. \mathcal{Z}(m))_{\mathfrak{P}} \log|\mathcal{O}_K/\mathfrak{P}|=o(X^{\frac{b+1}{2}}\log X). \end{align} $$
 By Proposition 3.2, we have 
 $\displaystyle \sum _{m\in S^{\mathrm {good}}_{D,X}} h_{\widehat {\mathcal {Z}}(m)}(\mathcal {Y}) = O(X^{\frac {b+1}{2}})$
, which contradicts equation (8.1).
$\displaystyle \sum _{m\in S^{\mathrm {good}}_{D,X}} h_{\widehat {\mathcal {Z}}(m)}(\mathcal {Y}) = O(X^{\frac {b+1}{2}})$
, which contradicts equation (8.1).
9 Applications: Picard rank jumps and exceptional isogenies
 In this section, we will elaborate on a number of applications: K3 surfaces and rational curves on them, exceptional splittings of Kuga-Satake abelian varieties and abelian varieties parametrised by unitary Shimura varieties. Then we set our results in context with past work of Charles [Reference CharlesCha18] and Shankar–Tang [Reference Shankar and TangST19] that deals with Shimura varieties associated to quadratic lattices of signature 
 $(2,2)$
.
$(2,2)$
.
9.1 Picard rank jumps in families of K3 surfaces and rational curves
 For background on K3 surfaces, we refer to [Reference HuybrechtsHuy16]. Let X be a K3 surface over a number field K. By replacing K with a finite extension if necessary, we may assume that 
 $\mathrm {Pic}(X_{\overline {K}})=\mathrm {Pic}(X)$
. For any embedding
$\mathrm {Pic}(X_{\overline {K}})=\mathrm {Pic}(X)$
. For any embedding 
 $\sigma : K \hookrightarrow \mathbb {C}$
, the
$\sigma : K \hookrightarrow \mathbb {C}$
, the 
 $\mathbb {Z}$
-module
$\mathbb {Z}$
-module 
 $H^2(X_{\sigma }^{an},\mathbb {Z})$
 endowed with the intersection form Q given by Poincaré duality is an unimodular even lattice of signature
$H^2(X_{\sigma }^{an},\mathbb {Z})$
 endowed with the intersection form Q given by Poincaré duality is an unimodular even lattice of signature 
 $(3,19)$
. The first Chern class map
$(3,19)$
. The first Chern class map 
 $$ \begin{align*}c_1:\mathrm{Pic}(X)\rightarrow H^2(X_{\sigma}^{an},\mathbb{Z})\end{align*} $$
$$ \begin{align*}c_1:\mathrm{Pic}(X)\rightarrow H^2(X_{\sigma}^{an},\mathbb{Z})\end{align*} $$
is a primitive embedding. By the Hodge index theorem, 
 $\mathrm {Pic}(X)$
 has signature
$\mathrm {Pic}(X)$
 has signature 
 $(1,\rho (X)-1)$
, where
$(1,\rho (X)-1)$
, where 
 $\rho (X)$
 is the Picard rank of X. Let
$\rho (X)$
 is the Picard rank of X. Let 
 $(L,Q)$
 be a maximal orthogonal lattice to
$(L,Q)$
 be a maximal orthogonal lattice to 
 $\mathrm {Pic}(X)$
 in
$\mathrm {Pic}(X)$
 in 
 $H^2(X_{\sigma }^{an},\mathbb {Q})$
. Then
$H^2(X_{\sigma }^{an},\mathbb {Q})$
. Then 
 $(L,-Q)$
 is an even lattice whose genus is independent of the choice of
$(L,-Q)$
 is an even lattice whose genus is independent of the choice of 
 $\sigma $
 and L and has signature
$\sigma $
 and L and has signature 
 $(b,2)$
, where
$(b,2)$
, where 
 $b=20-\rho (X)$
. Let
$b=20-\rho (X)$
. Let 
 $\mathcal {M}$
 be the GSpin Shimura variety associated to
$\mathcal {M}$
 be the GSpin Shimura variety associated to 
 $(L,-Q)$
. By [Reference AndréAnd96, Main Lemma 1.7.1], up to extending K, the Kuga-Satake abelian variety associated to X, denoted by A, is defined over K and corresponds to a K-point
$(L,-Q)$
. By [Reference AndréAnd96, Main Lemma 1.7.1], up to extending K, the Kuga-Satake abelian variety associated to X, denoted by A, is defined over K and corresponds to a K-point 
 $x\in \mathcal {M}(K)$
.
$x\in \mathcal {M}(K)$
.
Proof of Theorem 1.1
 Since X has everywhere good reduction, up to extending K, by [Reference AndréAnd96, Lemma 9.3.1], the corresponding Kuga–Satake abelian variety A also has potentially good reduction everywhere. Then by Proposition 2.1(4), it gives rise to an 
 $\mathcal {O}_K$
-point
$\mathcal {O}_K$
-point 
 $\mathcal {Y}$
 of
$\mathcal {Y}$
 of 
 $\mathcal {M}$
. It is Hodge-generic by construction of the Shimura variety
$\mathcal {M}$
. It is Hodge-generic by construction of the Shimura variety 
 $\mathcal {M}$
 and by the Lefschetz theorem on
$\mathcal {M}$
 and by the Lefschetz theorem on 
 $(1,1)$
 classes. By Theorem 1.8, there exist infinitely many places
$(1,1)$
 classes. By Theorem 1.8, there exist infinitely many places 
 $\mathfrak {P}$
 of K and
$\mathfrak {P}$
 of K and 
 $m>0$
, such that the geometric fibre of the reduction A, denoted by
$m>0$
, such that the geometric fibre of the reduction A, denoted by 
 $A_{\overline {\mathfrak {P}}}$
, has a special endomorphism s such that
$A_{\overline {\mathfrak {P}}}$
, has a special endomorphism s such that 
 $s\circ s=[m]$
. By [Reference AndréAnd96, Main Lemma 1.7.1 (ii)], a special endomorphism of
$s\circ s=[m]$
. By [Reference AndréAnd96, Main Lemma 1.7.1 (ii)], a special endomorphism of 
 $A_{\overline {\mathfrak {P}}}$
 corresponds to a line bundle L on
$A_{\overline {\mathfrak {P}}}$
 corresponds to a line bundle L on 
 $X_{\overline {\mathfrak {P}}}$
 such that
$X_{\overline {\mathfrak {P}}}$
 such that 
 $Q(L)=-m$
 and is orthogonal to the image of
$Q(L)=-m$
 and is orthogonal to the image of 
 $\mathrm {Pic}(X)$
 inside
$\mathrm {Pic}(X)$
 inside 
 $\mathrm {Pic}(X_{\overline {\mathfrak {P}}})$
 under the specialisation map. This proves Theorem 1.1.
$\mathrm {Pic}(X_{\overline {\mathfrak {P}}})$
 under the specialisation map. This proves Theorem 1.1.
Proof of Corollary 1.3
Let X be a K3 surface defined over a number field that has potentially everywhere good reduction. Then by Theorem 1.1, X has infinitely many specialisations where the geometric Picard rank jumps. If X has finitely many unirational specialisations, then the strategy of [Reference Li and LiedtkeLL12] can be applied; more precisely, the statements [Reference Li and LiedtkeLL12, Proposition 4.2] are satisfied, and we can thus conclude by the proof of [Reference Li and LiedtkeLL12, Theorem 4.3].
9.2 Kuga–Satake abelian varieties
 Via the exceptional isomorphism between 
 $\operatorname {\mathrm {GSp}}_4$
 and
$\operatorname {\mathrm {GSp}}_4$
 and 
 $\operatorname {\mathrm {GSpin}}(V)$
 with
$\operatorname {\mathrm {GSpin}}(V)$
 with 
 $b=3$
, as in [Reference Kudla and RapoportKR00], the moduli space
$b=3$
, as in [Reference Kudla and RapoportKR00], the moduli space 
 $\mathcal {S}_2$
 of principally polarised abelian surfacesFootnote 34 is a GSpin Shimura variety. In this case, let B be a principally polarised abelian surface; then as in [Reference Kudla and RapoportKR00], the special endomorphisms are
$\mathcal {S}_2$
 of principally polarised abelian surfacesFootnote 34 is a GSpin Shimura variety. In this case, let B be a principally polarised abelian surface; then as in [Reference Kudla and RapoportKR00], the special endomorphisms are 
 $s\in \operatorname {\mathrm {End}}(B)$
 such that
$s\in \operatorname {\mathrm {End}}(B)$
 such that 
 $s^\dagger =s$
 and
$s^\dagger =s$
 and 
 $\operatorname {\mathrm {tr}} s =0$
, where
$\operatorname {\mathrm {tr}} s =0$
, where 
 $\dagger $
 denotes the Rosati involution. Indeed, let A denote the Kuga–Satake abelian variety (of dimension
$\dagger $
 denotes the Rosati involution. Indeed, let A denote the Kuga–Satake abelian variety (of dimension 
 $2^{2+3-1}=16$
) at the point
$2^{2+3-1}=16$
) at the point 
 $[B]\in \mathcal {S}_2$
 and
$[B]\in \mathcal {S}_2$
 and 
 $A=A^+\times A^-$
 given in Section 2.2; Kudla and Rapoport gave a moduli interpretation of special divisors by defining special endomorphisms to be
$A=A^+\times A^-$
 given in Section 2.2; Kudla and Rapoport gave a moduli interpretation of special divisors by defining special endomorphisms to be 
 $s\in \operatorname {\mathrm {End}}_{C^+(L)}(A^+)$
 such that
$s\in \operatorname {\mathrm {End}}_{C^+(L)}(A^+)$
 such that 
 $s^\dagger =s$
 and
$s^\dagger =s$
 and 
 $\operatorname {\mathrm {tr}} s =0$
 (see [Reference Kudla and RapoportKR00, §1, Definition 2.1]). By [Reference Kudla and RapoportKR00, §1], we have
$\operatorname {\mathrm {tr}} s =0$
 (see [Reference Kudla and RapoportKR00, §1, Definition 2.1]). By [Reference Kudla and RapoportKR00, §1], we have 
 $C^+(V)\cong M_4(\mathbb {Q})$
, and hence
$C^+(V)\cong M_4(\mathbb {Q})$
, and hence 
 $A^+$
 is isogenous to
$A^+$
 is isogenous to 
 $B^4$
; moreover, the special endomorphisms induces
$B^4$
; moreover, the special endomorphisms induces 
 $s_B\in \operatorname {\mathrm {End}}(B)\otimes \mathbb {Q}$
 such that
$s_B\in \operatorname {\mathrm {End}}(B)\otimes \mathbb {Q}$
 such that 
 $s_B^\dagger =s_B$
 and
$s_B^\dagger =s_B$
 and 
 $\operatorname {\mathrm {tr}} s_B =0$
.
$\operatorname {\mathrm {tr}} s_B =0$
.
 The Kudla–Rapoport version of special endomorphisms allows us to deduce Theorem 1.4 from Theorem 2.4. We now work with the general setting as in Assumption 1.5 since the argument is the same. Recall that 
 $b=2n-1$
 for
$b=2n-1$
 for 
 $n\in \mathbb {Z}_{>0}$
, and we assume that
$n\in \mathbb {Z}_{>0}$
, and we assume that 
 $C^+(V)\cong M_{2^n}(\mathbb {Q})$
; then
$C^+(V)\cong M_{2^n}(\mathbb {Q})$
; then 
 $A^+$
 is isogenous to
$A^+$
 is isogenous to 
 $B^{2^n}$
, where B is an abelian variety with
$B^{2^n}$
, where B is an abelian variety with 
 $\dim B= 2^n$
. By [Reference van GeemenvG08, §5.2], if
$\dim B= 2^n$
. By [Reference van GeemenvG08, §5.2], if 
 $[A]$
 is a Hodge generic point in
$[A]$
 is a Hodge generic point in 
 $\mathcal {M}$
, then
$\mathcal {M}$
, then 
 $\operatorname {\mathrm {End}}(A^+_{\bar {K}})\otimes \mathbb {Q}=C^+(V)$
, and in particular,
$\operatorname {\mathrm {End}}(A^+_{\bar {K}})\otimes \mathbb {Q}=C^+(V)$
, and in particular, 
 $\operatorname {\mathrm {End}}(B_{\bar {K}})=\mathbb {Z}$
 and B is geometrically simple.
$\operatorname {\mathrm {End}}(B_{\bar {K}})=\mathbb {Z}$
 and B is geometrically simple.
 To translate a special endomorphism of the Kuga–Satake abelian variety A to a special endomorphism of 
 $A^+$
, we choose an element
$A^+$
, we choose an element 
 $\delta _0\in Z(C(L))\cap C(L)^-$
 such that
$\delta _0\in Z(C(L))\cap C(L)^-$
 such that 
 $\delta _0^*=\delta _0$
, where
$\delta _0^*=\delta _0$
, where 
 $Z(C(L))$
 denote the centre of
$Z(C(L))$
 denote the centre of 
 $C(L)$
 and
$C(L)$
 and 
 $(-)^*$
 denote the unique involution on
$(-)^*$
 denote the unique involution on 
 $C(V)$
 that acts trivially on V (see, for instance, [Reference Andreatta, Goren, Howard and PeraAGHMP17, §2.1] for a concrete definition). Indeed, let
$C(V)$
 that acts trivially on V (see, for instance, [Reference Andreatta, Goren, Howard and PeraAGHMP17, §2.1] for a concrete definition). Indeed, let 
 $e_1,\dots , e_{b+2}\in L$
 be a basis of V such that
$e_1,\dots , e_{b+2}\in L$
 be a basis of V such that 
 $Q(v)=d_1x_1^2+\cdots + d_{b+2}x_{b+2}^2$
 for
$Q(v)=d_1x_1^2+\cdots + d_{b+2}x_{b+2}^2$
 for 
 $v=x_1e_1+\cdots + x_{b+2}e_{b+2}$
. Since
$v=x_1e_1+\cdots + x_{b+2}e_{b+2}$
. Since 
 $b\equiv 3 \bmod 4$
, we may take
$b\equiv 3 \bmod 4$
, we may take 
 $\delta _0=e_1\cdots e_{b+2}$
 and note that
$\delta _0=e_1\cdots e_{b+2}$
 and note that 
 $\delta _0^2=\prod _{i=1}^{b+2} d_i$
. Via the usual
$\delta _0^2=\prod _{i=1}^{b+2} d_i$
. Via the usual 
 $C(L)$
-action on A, the element
$C(L)$
-action on A, the element 
 $\delta _0\in C(L)^-$
 induces an endomorphism
$\delta _0\in C(L)^-$
 induces an endomorphism 
 $\delta _0:A^-\rightarrow A^+$
; and hence for any special endomorphism
$\delta _0:A^-\rightarrow A^+$
; and hence for any special endomorphism 
 $v\in \operatorname {\mathrm {End}}_{C(L)}(A)$
 defined in Section 2.5, since
$v\in \operatorname {\mathrm {End}}_{C(L)}(A)$
 defined in Section 2.5, since 
 $v:A^+\rightarrow A^-$
 and
$v:A^+\rightarrow A^-$
 and 
 $\delta _0\in Z(C(L))$
, we have
$\delta _0\in Z(C(L))$
, we have 
 $s:=\delta _0\circ v\in \operatorname {\mathrm {End}}_{C^+(L)}(A^+)$
. Since
$s:=\delta _0\circ v\in \operatorname {\mathrm {End}}_{C^+(L)}(A^+)$
. Since 
 $C^+(V)\cong M_{2^n}(\mathbb {Q})$
 and
$C^+(V)\cong M_{2^n}(\mathbb {Q})$
 and 
 $A^+$
 is isogenous to
$A^+$
 is isogenous to 
 $B^{2^n}$
, we obtain
$B^{2^n}$
, we obtain 
 $s_B\in \operatorname {\mathrm {End}}(B)\otimes \mathbb {Q}$
. Since s is not a scalar multiplication on
$s_B\in \operatorname {\mathrm {End}}(B)\otimes \mathbb {Q}$
. Since s is not a scalar multiplication on 
 $A^+$
,
$A^+$
, 
 $s_B$
 is not a scalar multiplication on B.
$s_B$
 is not a scalar multiplication on B.
Proof of Theorem 1.4 and Theorem 1.6
 Using the notation as above, let 
 $D=\prod _{i=1}^{b+2} d_i$
. By Corollary 4.7, without loss of generality, we may multiple D by a square number such that D is representable by
$D=\prod _{i=1}^{b+2} d_i$
. By Corollary 4.7, without loss of generality, we may multiple D by a square number such that D is representable by 
 $(L,Q)$
. For a finite place
$(L,Q)$
. For a finite place 
 $\mathfrak {P}$
, if v is a special endomorphism of
$\mathfrak {P}$
, if v is a special endomorphism of 
 $A_{\overline {\mathfrak {P}}}$
 such that
$A_{\overline {\mathfrak {P}}}$
 such that 
 $v\circ v=[Dm^2]$
, then
$v\circ v=[Dm^2]$
, then 
 $\delta _0\circ v$
 induces a quasi-endomorphism
$\delta _0\circ v$
 induces a quasi-endomorphism 
 $s_B$
 on
$s_B$
 on 
 $B_{\overline {\mathfrak {P}}}$
 such that
$B_{\overline {\mathfrak {P}}}$
 such that 
 $s_B\circ s_B=[Q(\delta )Q(v)]=[D^2m^2]$
. Since
$s_B\circ s_B=[Q(\delta )Q(v)]=[D^2m^2]$
. Since 
 $s_B$
 is not a scalar multiplication,
$s_B$
 is not a scalar multiplication, 
 $\ker (s_B-[Dm])$
 is a nontrivial simple factor of
$\ker (s_B-[Dm])$
 is a nontrivial simple factor of 
 $B_{\overline {\mathfrak {P}}}$
, and hence
$B_{\overline {\mathfrak {P}}}$
, and hence 
 $B_{\overline {\mathfrak {P}}}$
 is nonsimple. We conclude by Theorem 2.4 that there are infinitely many such
$B_{\overline {\mathfrak {P}}}$
 is nonsimple. We conclude by Theorem 2.4 that there are infinitely many such 
 $\mathfrak {P}$
.
$\mathfrak {P}$
.
 Via the algorithm in the proof of [Reference van GeemenvG00, Thm. 7.7], here is an example when 
 $C^+(V)=M_{2^n}(\mathbb {Q})$
: assume
$C^+(V)=M_{2^n}(\mathbb {Q})$
: assume 
 $b\equiv 3 \bmod 8$
, and consider
$b\equiv 3 \bmod 8$
, and consider 
 $Q(x)=-x_1^2-x_2^2+\sum _{i=3}^{b+1} x_i^2 +d x_{b+2}^2$
.
$Q(x)=-x_1^2-x_2^2+\sum _{i=3}^{b+1} x_i^2 +d x_{b+2}^2$
.
9.3 Abelian varieties parametrised by unitary Shimura varieties
 We recall the moduli interpretation of the Shimura varieties attached to 
 $\operatorname {\mathrm {GU}}(r,1)$
 following [Reference Kudla and RapoportKR14, §2] (see also [BHK+
Reference Chen, Gounelas and Liedtke17, §2.2]). Recall that E is an imaginary quadratic field. Consider the moduli problem that associates to a locally noetherian
$\operatorname {\mathrm {GU}}(r,1)$
 following [Reference Kudla and RapoportKR14, §2] (see also [BHK+
Reference Chen, Gounelas and Liedtke17, §2.2]). Recall that E is an imaginary quadratic field. Consider the moduli problem that associates to a locally noetherian 
 $\mathcal {O}_E$
-scheme S the groupoid of triples
$\mathcal {O}_E$
-scheme S the groupoid of triples 
 $(B,\iota , \lambda )$
, where B is an abelian scheme over S,
$(B,\iota , \lambda )$
, where B is an abelian scheme over S, 
 $\iota : \mathcal {O}_E\hookrightarrow \operatorname {\mathrm {End}}_S(B)$
 and
$\iota : \mathcal {O}_E\hookrightarrow \operatorname {\mathrm {End}}_S(B)$
 and 
 $\lambda :B\rightarrow B^\vee $
 is a principal polarisation such that
$\lambda :B\rightarrow B^\vee $
 is a principal polarisation such that 
- 
1.  $\iota (a)^\dagger =\iota (a^\sigma )$
, where $\iota (a)^\dagger =\iota (a^\sigma )$
, where $\dagger $
 is the Rosati involution and $\dagger $
 is the Rosati involution and $\sigma $
 is the nontrivial element in $\sigma $
 is the nontrivial element in $\operatorname {\mathrm {Gal}}(E/\mathbb {Q})$
; and $\operatorname {\mathrm {Gal}}(E/\mathbb {Q})$
; and
- 
2.  $\iota (a)$
 acts on $\iota (a)$
 acts on $\operatorname {\mathrm {Lie}} A$
 with characteristic polynomial $\operatorname {\mathrm {Lie}} A$
 with characteristic polynomial $(T-\varphi (a))^r(T-\varphi (a)^\sigma )$
, where $(T-\varphi (a))^r(T-\varphi (a)^\sigma )$
, where $\varphi :\operatorname {\mathrm {Spec}}\mathcal {O}_E\rightarrow S$
 is the structure morphism. $\varphi :\operatorname {\mathrm {Spec}}\mathcal {O}_E\rightarrow S$
 is the structure morphism.
This moduli space 
 $\mathcal {M}(r,1)$
 is a Deligne–Mumford stack over
$\mathcal {M}(r,1)$
 is a Deligne–Mumford stack over 
 $\mathcal {O}_E$
 such that
$\mathcal {O}_E$
 such that 
 $\mathcal {M}(r,1)_E$
 is a disjoint union of Shimura varieties attached to
$\mathcal {M}(r,1)_E$
 is a disjoint union of Shimura varieties attached to 
 $\operatorname {\mathrm {GU}}(r,1)$
 (see, for instance, [Reference Kudla and RapoportKR14, Prop. 2.19, Prop. 4.4]). Similarly, we define
$\operatorname {\mathrm {GU}}(r,1)$
 (see, for instance, [Reference Kudla and RapoportKR14, Prop. 2.19, Prop. 4.4]). Similarly, we define 
 $\mathcal {M}(1,0)$
. In particular, after enlarging K by a finite extension that contains E, the abelian variety A in Corollary 1.7 gives a K-point on
$\mathcal {M}(1,0)$
. In particular, after enlarging K by a finite extension that contains E, the abelian variety A in Corollary 1.7 gives a K-point on 
 $\mathcal {M}(r,1)$
.
$\mathcal {M}(r,1)$
.
 To relate 
 $\mathcal {M}(r,1)$
 to the GSpin Shimura variety
$\mathcal {M}(r,1)$
 to the GSpin Shimura variety 
 $\mathcal {M}$
 defined in Section 2, we pick an auxiliary elliptic curve
$\mathcal {M}$
 defined in Section 2, we pick an auxiliary elliptic curve 
 $A_0$
 defined over a finite extension of E such that
$A_0$
 defined over a finite extension of E such that 
 $\mathcal {O}_E\subset \operatorname {\mathrm {End}}(A_0)$
 and the action of
$\mathcal {O}_E\subset \operatorname {\mathrm {End}}(A_0)$
 and the action of 
 $\mathcal {O}_E$
 on
$\mathcal {O}_E$
 on 
 $\operatorname {\mathrm {Lie}} A_0$
 is given by the embedding of
$\operatorname {\mathrm {Lie}} A_0$
 is given by the embedding of 
 $\mathcal {O}_E$
 into the definition field of
$\mathcal {O}_E$
 into the definition field of 
 $A_0$
, and hence
$A_0$
, and hence 
 $A_0$
 is a point on
$A_0$
 is a point on 
 $\mathcal {M}(1,0)$
. As in [BHK+
Reference Chen, Gounelas and Liedtke17, §§2.1, 2.2], pick an embedding of the definition field of
$\mathcal {M}(1,0)$
. As in [BHK+
Reference Chen, Gounelas and Liedtke17, §§2.1, 2.2], pick an embedding of the definition field of 
 $A_0$
 (respectively, A) into
$A_0$
 (respectively, A) into 
 $\mathbb {C}$
, and let
$\mathbb {C}$
, and let 
 $W_0$
 (respectively, W) denote the E-vector space
$W_0$
 (respectively, W) denote the E-vector space 
 $H_{1,B}(A_0(\mathbb {C}), \mathbb {Q})$
 (respectively,
$H_{1,B}(A_0(\mathbb {C}), \mathbb {Q})$
 (respectively, 
 $H_{1,B}(A(\mathbb {C}), \mathbb {Q})$
), where the E-vector space structure is induced by the
$H_{1,B}(A(\mathbb {C}), \mathbb {Q})$
), where the E-vector space structure is induced by the 
 $\mathcal {O}_E$
-action on
$\mathcal {O}_E$
-action on 
 $A_0$
 (respectively, A). There exists a unique Hermitian form
$A_0$
 (respectively, A). There exists a unique Hermitian form 
 $\psi $
 of signature
$\psi $
 of signature 
 $(r,1)$
 on W such that the symplectic form on
$(r,1)$
 on W such that the symplectic form on 
 $H_{1,B}(A(\mathbb {C}),\mathbb {Q})$
 induced by the polarisation is equal to
$H_{1,B}(A(\mathbb {C}),\mathbb {Q})$
 induced by the polarisation is equal to 
 $\operatorname {\mathrm {tr}}_{E/\mathbb {Q}}((\operatorname {\mathrm {disc}} E)^{-1/2}\psi )$
. Similarly, there exists a Hermitian form
$\operatorname {\mathrm {tr}}_{E/\mathbb {Q}}((\operatorname {\mathrm {disc}} E)^{-1/2}\psi )$
. Similarly, there exists a Hermitian form 
 $\psi _0$
 of signature
$\psi _0$
 of signature 
 $(1,0)$
 on
$(1,0)$
 on 
 $W_0$
 such that
$W_0$
 such that 
 $\operatorname {\mathrm {tr}}_{E/\mathbb {Q}}((\operatorname {\mathrm {disc}} E)^{-1/2}\psi _0)$
 induces the polarisation on
$\operatorname {\mathrm {tr}}_{E/\mathbb {Q}}((\operatorname {\mathrm {disc}} E)^{-1/2}\psi _0)$
 induces the polarisation on 
 $A_0$
. By [BHK+
Reference Chen, Gounelas and Liedtke17, eqns (2.1.4), (2.1.5)],
$A_0$
. By [BHK+
Reference Chen, Gounelas and Liedtke17, eqns (2.1.4), (2.1.5)], 
 $\psi _0$
 and
$\psi _0$
 and 
 $\psi $
 induce a Hermitian form
$\psi $
 induce a Hermitian form 
 $\phi $
 on the E-vector space
$\phi $
 on the E-vector space 
 $\operatorname {\mathrm {Hom}}_{\mathcal {O}_E}(H_{1,B}(A_0(\mathbb {C}), \mathbb {Q}), H_{1,B}(A(\mathbb {C}),\mathbb {Q}))$
 of signature
$\operatorname {\mathrm {Hom}}_{\mathcal {O}_E}(H_{1,B}(A_0(\mathbb {C}), \mathbb {Q}), H_{1,B}(A(\mathbb {C}),\mathbb {Q}))$
 of signature 
 $(r,1)$
. Let V denote the
$(r,1)$
. Let V denote the 
 $\mathbb {Q}$
-vector space
$\mathbb {Q}$
-vector space 
 $\operatorname {\mathrm {Hom}}_{\mathcal {O}_E}(H^1_B(A_0(\mathbb {C}), \mathbb {Q}), H^1_B(A(\mathbb {C}),\mathbb {Q}))$
 endowed with the quadratic form
$\operatorname {\mathrm {Hom}}_{\mathcal {O}_E}(H^1_B(A_0(\mathbb {C}), \mathbb {Q}), H^1_B(A(\mathbb {C}),\mathbb {Q}))$
 endowed with the quadratic form 
 $\operatorname {\mathrm {tr}}_{E/\mathbb {Q}}\phi $
; V is of signature
$\operatorname {\mathrm {tr}}_{E/\mathbb {Q}}\phi $
; V is of signature 
 $(2r,2)$
.
$(2r,2)$
.
 Let 
 $G'$
 denote the subgroup of
$G'$
 denote the subgroup of 
 $\operatorname {\mathrm {GU}}(W_0,\psi _0)\times \operatorname {\mathrm {GU}}(W, \psi )$
 given by pairs whose similitude factors are equal. By [BHK+
Reference Chen, Gounelas and Liedtke17, §§2.1, 6.2] and [Reference HofmannHof14, §4], the induced action of
$\operatorname {\mathrm {GU}}(W_0,\psi _0)\times \operatorname {\mathrm {GU}}(W, \psi )$
 given by pairs whose similitude factors are equal. By [BHK+
Reference Chen, Gounelas and Liedtke17, §§2.1, 6.2] and [Reference HofmannHof14, §4], the induced action of 
 $G'$
 on V gives a group homomorphism
$G'$
 on V gives a group homomorphism 
 $G'\rightarrow \operatorname {\mathrm {SO}}(V)$
, and this group homomorphism is indeed a map between Shimura data (with the Hodge cocharacters given by the ones induced by the Hodge cocharacters of
$G'\rightarrow \operatorname {\mathrm {SO}}(V)$
, and this group homomorphism is indeed a map between Shimura data (with the Hodge cocharacters given by the ones induced by the Hodge cocharacters of 
 $A_0$
 and A); hence we have a map between Shimura varieties
$A_0$
 and A); hence we have a map between Shimura varieties 
 $\operatorname {\mathrm {Sh}}(G')\rightarrow \operatorname {\mathrm {Sh}}(\operatorname {\mathrm {SO}}(V))$
 (with the maximal compact open subgroups of
$\operatorname {\mathrm {Sh}}(G')\rightarrow \operatorname {\mathrm {Sh}}(\operatorname {\mathrm {SO}}(V))$
 (with the maximal compact open subgroups of 
 $G'(\mathbb {A}_f)$
 and
$G'(\mathbb {A}_f)$
 and 
 $\operatorname {\mathrm {SO}}(V)(\mathbb {A}_f)$
 defined by lattices in
$\operatorname {\mathrm {SO}}(V)(\mathbb {A}_f)$
 defined by lattices in 
 $W_0$
 and W given by
$W_0$
 and W given by 
 $H_{1,B}(A_0(\mathbb {C}), \mathbb {Z})$
 and
$H_{1,B}(A_0(\mathbb {C}), \mathbb {Z})$
 and 
 $H_{1,B}(A(\mathbb {C}), \mathbb {Z})$
). By [BHK+
Reference Chen, Gounelas and Liedtke17, Prop. 2.2.1],
$H_{1,B}(A(\mathbb {C}), \mathbb {Z})$
). By [BHK+
Reference Chen, Gounelas and Liedtke17, Prop. 2.2.1], 
 $\operatorname {\mathrm {Sh}}(G')\subset \mathcal {M}(1,0)\times \mathcal {M}(r,1)$
 and
$\operatorname {\mathrm {Sh}}(G')\subset \mathcal {M}(1,0)\times \mathcal {M}(r,1)$
 and 
 $(A_0,A)$
 gives a
$(A_0,A)$
 gives a 
 $\overline {\mathbb {Q}}$
-point on
$\overline {\mathbb {Q}}$
-point on 
 $\operatorname {\mathrm {Sh}}(G')$
 and hence a
$\operatorname {\mathrm {Sh}}(G')$
 and hence a 
 $\overline {\mathbb {Q}}$
-point on
$\overline {\mathbb {Q}}$
-point on 
 $\operatorname {\mathrm {Sh}}(\operatorname {\mathrm {SO}}(V))$
.
$\operatorname {\mathrm {Sh}}(\operatorname {\mathrm {SO}}(V))$
.
 Note that 
 $\operatorname {\mathrm {GSpin}}(V)\rightarrow \operatorname {\mathrm {SO}}(V)$
 induces an open and closed morphism
$\operatorname {\mathrm {GSpin}}(V)\rightarrow \operatorname {\mathrm {SO}}(V)$
 induces an open and closed morphism 
 $M\rightarrow \operatorname {\mathrm {Sh}}(\operatorname {\mathrm {SO}}(V))$
 (with a suitable choice of maximal compact subgroups, which does not affect the rest of the argument), where M is the
$M\rightarrow \operatorname {\mathrm {Sh}}(\operatorname {\mathrm {SO}}(V))$
 (with a suitable choice of maximal compact subgroups, which does not affect the rest of the argument), where M is the 
 $\operatorname {\mathrm {GSpin}}$
 Shimura variety defined in Section 2.1; therefore, by applying a suitable Hecke translate on
$\operatorname {\mathrm {GSpin}}$
 Shimura variety defined in Section 2.1; therefore, by applying a suitable Hecke translate on 
 $\operatorname {\mathrm {Sh}}(\operatorname {\mathrm {SO}}(V))$
, the image of the point
$\operatorname {\mathrm {Sh}}(\operatorname {\mathrm {SO}}(V))$
, the image of the point 
 $(A_0,A)$
 under the Hecke translate lies in a connected component of
$(A_0,A)$
 under the Hecke translate lies in a connected component of 
 $\operatorname {\mathrm {Sh}}(\operatorname {\mathrm {SO}}(V))$
 that lies in the image of M. In particular, there exists a point
$\operatorname {\mathrm {Sh}}(\operatorname {\mathrm {SO}}(V))$
 that lies in the image of M. In particular, there exists a point 
 $Y\in M(\overline {\mathbb {Q}})$
 such that Y maps to the Hecke translate of
$Y\in M(\overline {\mathbb {Q}})$
 such that Y maps to the Hecke translate of 
 $(A_0,A)$
, and hence as
$(A_0,A)$
, and hence as 
 $\mathbb {Q}$
-Hodge structures,
$\mathbb {Q}$
-Hodge structures, 
 $$\begin{align*}\mathbf{V}_{B,Y}\otimes \mathbb{Q}\cong \operatorname{\mathrm{Hom}}_{\mathcal{O}_E}(H_{1,B}(A_0(\mathbb{C}),\mathbb{Q}), H_{1,B}(A(\mathbb{C}),\mathbb{Q})),\end{align*}$$
$$\begin{align*}\mathbf{V}_{B,Y}\otimes \mathbb{Q}\cong \operatorname{\mathrm{Hom}}_{\mathcal{O}_E}(H_{1,B}(A_0(\mathbb{C}),\mathbb{Q}), H_{1,B}(A(\mathbb{C}),\mathbb{Q})),\end{align*}$$
where 
 $\mathbf {V}_{B,Y}$
 denotes the fibre at Y of the local system
$\mathbf {V}_{B,Y}$
 denotes the fibre at Y of the local system 
 $\mathbf {V}_B$
 defined in Section 2.2. We enlarge K by a finite extension so that
$\mathbf {V}_B$
 defined in Section 2.2. We enlarge K by a finite extension so that 
 $Y, A_0$
 and A are all defined over K. Since all Hodge cycles in the category of absolute Hodge motives generated by abelian varieties are absolute Hodge by Deligne’s theorem, then after enlarging K by a finite extension, we have
$Y, A_0$
 and A are all defined over K. Since all Hodge cycles in the category of absolute Hodge motives generated by abelian varieties are absolute Hodge by Deligne’s theorem, then after enlarging K by a finite extension, we have 
 $$ \begin{align} \mathbf{V}_{\ell, \acute{\mathrm{e}}\mathrm{t},Y}\cong \operatorname{\mathrm{Hom}}_{\mathcal{O}_E}(H_{1,\acute{\mathrm{e}}\mathrm{t}}(A_0, \mathbb{Q}_\ell), H_{1,\acute{\mathrm{e}}\mathrm{t}}(A, \mathbb{Q}_\ell)) \end{align} $$
$$ \begin{align} \mathbf{V}_{\ell, \acute{\mathrm{e}}\mathrm{t},Y}\cong \operatorname{\mathrm{Hom}}_{\mathcal{O}_E}(H_{1,\acute{\mathrm{e}}\mathrm{t}}(A_0, \mathbb{Q}_\ell), H_{1,\acute{\mathrm{e}}\mathrm{t}}(A, \mathbb{Q}_\ell)) \end{align} $$
as 
 $\operatorname {\mathrm {Gal}}(\overline {K}/K)$
-modules. We use
$\operatorname {\mathrm {Gal}}(\overline {K}/K)$
-modules. We use 
 $A^{\mathrm {KS}}$
 to denote the Kuga–Satake abelian variety corresponding to
$A^{\mathrm {KS}}$
 to denote the Kuga–Satake abelian variety corresponding to 
 $Y\in M(K)$
.
$Y\in M(K)$
.
Proof of Corollary 1.7
 Since A and 
 $A_0$
 have potentially good reduction everywhere, then after enlarging by K by a finite extension such that both A and
$A_0$
 have potentially good reduction everywhere, then after enlarging by K by a finite extension such that both A and 
 $A_0$
 have good reduction over K, the Galois representation
$A_0$
 have good reduction over K, the Galois representation 
 $\operatorname {\mathrm {Hom}}_{\mathcal {O}_E}(H_{1,\mathrm{\acute{e}t}}(A_0,\mathbb {Q}_\ell ), H_{1,\mathrm{\acute{e}t}}(A,\mathbb {Q}_\ell ))$
 is unramified away from
$\operatorname {\mathrm {Hom}}_{\mathcal {O}_E}(H_{1,\mathrm{\acute{e}t}}(A_0,\mathbb {Q}_\ell ), H_{1,\mathrm{\acute{e}t}}(A,\mathbb {Q}_\ell ))$
 is unramified away from 
 $\ell $
. By [Reference AndréAnd96, Lemma 9.3.1] and equation (9.1), the Kuga–Satake abelian variety
$\ell $
. By [Reference AndréAnd96, Lemma 9.3.1] and equation (9.1), the Kuga–Satake abelian variety 
 $A^{\mathrm {KS}}$
 has potentially good reduction everywhere. Then by Proposition 2.1(4), Y extends to an
$A^{\mathrm {KS}}$
 has potentially good reduction everywhere. Then by Proposition 2.1(4), Y extends to an 
 $\mathcal {O}_K$
-point
$\mathcal {O}_K$
-point 
 $\mathcal {Y}$
 of
$\mathcal {Y}$
 of 
 $\mathcal {M}$
. By Theorem 1.8 and the definition of special endomorphisms (Definition 2.2), there are infinitely many places
$\mathcal {M}$
. By Theorem 1.8 and the definition of special endomorphisms (Definition 2.2), there are infinitely many places 
 $\mathfrak {P}$
 such that
$\mathfrak {P}$
 such that 
 $\mathbf {V}_{\ell , \mathrm{\acute{e}t},\mathcal {Y}_{\mathfrak {P}}}$
 admits a Tate cycle (after possible finite extension of the residue field) for
$\mathbf {V}_{\ell , \mathrm{\acute{e}t},\mathcal {Y}_{\mathfrak {P}}}$
 admits a Tate cycle (after possible finite extension of the residue field) for 
 $\ell $
 not equal to the residue characteristic of
$\ell $
 not equal to the residue characteristic of 
 $\mathfrak {P}$
. For such a prime
$\mathfrak {P}$
. For such a prime 
 $\mathfrak {P}$
, by equation (9.1), there exists an
$\mathfrak {P}$
, by equation (9.1), there exists an 
 $n\in \mathbb {Z}_{>0}$
 such that
$n\in \mathbb {Z}_{>0}$
 such that 
 $\operatorname {\mathrm {Hom}}_{\mathcal {O}_E}(H_{1,\mathrm{\acute{e}t}}(A_0, \mathbb {Q}_\ell ), H_{1,\mathrm{\acute{e}t}}(A,\mathbb {Q}_\ell ))^{\operatorname {\mathrm {Frob}}^n_{\mathfrak {P}}=1}\neq \emptyset $
. In particular,
$\operatorname {\mathrm {Hom}}_{\mathcal {O}_E}(H_{1,\mathrm{\acute{e}t}}(A_0, \mathbb {Q}_\ell ), H_{1,\mathrm{\acute{e}t}}(A,\mathbb {Q}_\ell ))^{\operatorname {\mathrm {Frob}}^n_{\mathfrak {P}}=1}\neq \emptyset $
. In particular, 
 $A_{0,\overline {\mathfrak {P}}}$
 is an isogeny factor of
$A_{0,\overline {\mathfrak {P}}}$
 is an isogeny factor of 
 $A_{\overline {\mathfrak {P}}}$
 by Tate’s theorem.
$A_{\overline {\mathfrak {P}}}$
 by Tate’s theorem.
Acknowledgements
We are very grateful to Fabrizio Andreatta, Olivier Benoist, Laurent Clozel, Edgar Costa, Quentin Guignard, Jonathan Hanke, Benjamin Howard, Christian Liedtke, Yifeng Liu, Chao Li, Davesh Maulik and Jacob Tsimerman for many helpful conversations. Part of this work has been done in S.T.’s PhD thesis, and he is particularly grateful to François Charles. We’re also very grateful to the referee for several valuable suggestions that have improved this paper.
A.N.S. is partially supported by the NSF grant DMS-2100436. A.S. is supported by an NSERC Discovery grant and a Sloan fellowship. Y.T. is partially supported by the NSF grant DMS-1801237. S.T. has received funding from the European Research Council (ERC) under the European Union’s Horizon 2020 research and innovation programme (grant agreement No 715747).
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
