Density theorems for GL(n)\documentclass[12pt]{minimal} \usepackage{amsmath} \usepackage{wasysym} \usepackage{amsfonts} \usepackage{amssymb} \usepackage{amsbsy} \usepackage{mathrsfs} \usepackage{upgreek} \setlength{\oddsidemargin}{-69pt} \begin{document}$${\textrm{GL}}(n)$$\end{document}

Strong bounds—going beyond Sarnak’s density hypothesis—are obtained for the number of automorphic forms for the group Γ0(q)⊆SL(n,Z)\documentclass[12pt]{minimal} \usepackage{amsmath} \usepackage{wasysym} \usepackage{amsfonts} \usepackage{amssymb} \usepackage{amsbsy} \usepackage{mathrsfs} \usepackage{upgreek} \setlength{\oddsidemargin}{-69pt} \begin{document}$$\Gamma _0(q) \subseteq \textrm{SL}(n, {\mathbb {Z}})$$\end{document} violating the Ramanujan conjecture at any given unramified place. The proof is based on a relative trace formula of Kuznetsov type and best-possible bounds for certain Kloosterman sums for GL(n)\documentclass[12pt]{minimal} \usepackage{amsmath} \usepackage{wasysym} \usepackage{amsfonts} \usepackage{amssymb} \usepackage{amsbsy} \usepackage{mathrsfs} \usepackage{upgreek} \setlength{\oddsidemargin}{-69pt} \begin{document}$$\textrm{GL}(n)$$\end{document}. Further applications are given.


Introduction
The concept of families is a very fruitful one in number theory and in particular in the context of automorphic forms. It allows us to study asymptotic properties and has recently been put on some formal ground in [29,32]. On the conceptual side it dampens irregularities of individual members (that may exist or whose non-existence we are unable to prove) and allows statistical concepts and deformation techniques to investigate properties within an ensemble. On the methodological it enables us to use strong analytic tools such as various types of trace formulae. One of the key conjectures in the field of automorphic forms is the Ramanujan conjecture: cuspidal automorphic representations of the group GL(n) over a number field F are tempered (see [4] for a survey). Even for n = 2 this appears to be far out of reach, and as a substitute one considers two types of approximations. On the one hand one can measure the worst case scenario, i.e. the largest distance from the tempered spectrum of an individual member in a family. On the other hand one can try to bound the number of members in a family violating the conjecture relative to the amount by which they violate the conjecture. This is a density result which is a familiar concept from the theory Dirichlet L-functions: although the Riemann hypothesis is far out of reach, we have good bounds for the number N (σ, T, Q) of zeros with real part σ and height T of Dirichlet L-functions with conductor q Q (see e.g. [18,Section 10]). The arithmetic reformulation of this is the Bombieri-Vinogradov theorem which roughly states that primes x are equidistributed in "almost all" residue classes modulo q x 1/2+o(1) (similarly, "almost all" short intervals contain primes). In many applications this serves as a good substitute for the Riemann hypothesis.
In this note we want to consider the automorphic analogue for the family of automorphic forms for the group 0 (q) ⊆ SL n (Z) of matrices whose lowest row is congruent to (0, . . . , 0, * ) modulo q. This is a very natural family as it contains precisely the automorphic forms of conductor dividing q [19]. Let us fix a place v of Q, and for an automorphic form π let us denote by μ π (v) = (μ π (v, 1), . . . , μ π (v, n)) its local spectral parameter (each entry viewed modulo 2πi log p Z if v = p is a prime). Write The representation π is tempered at v if σ π (v) = 0, and the size of σ π (v) measures how far π is from being tempered at v. An example of a non-tempered representation is the trivial representation which satisfies σ triv (v) = (n − 1)/2 for every v. For a finite family F of automorphic representations for GL(n) and σ 0 we define We have trivially N v (0, F) = |F|, and if the trivial representation is contained in F, we have N v ((n − 1)/2, F) 1. One may hope to be able to interpolate linearly between these two extreme cases: This is precisely Sarnak's density hypothesis [28, p. 465] stated there in the context of groups G of real rank 1, the principal congruence subgroup (q) = {γ ∈ G(Z) | γ ≡ id (mod q)} and v = ∞. For families of large level, Sarnak's density hypothesis has recently attracted interest in the context of lifting matrices modulo q [30] and the almost diameter of Ramanujan complexes, and for families with growing infinitesimal character in the context of Golden Gates and quantum computing [26,31]. In each of these cases it is not a spectral gap that is needed, but a certain kind of density result.
The shape of the bound (1.2-1.3) bears a certain similarity to the convexity bound for L-functions in the Selberg class in the critical strip. Unlike the convexity bound for L-functions, (1.2-1.3) is in general a very deep result that is completely open for general groups and families. On the other hand, it is a priori not impossible to even obtain "subconvexity", i.e. a proof of (1.2) with a constant a < (n − 1)/2, if the trivial representation is not in F. The Arthur-Selberg trace formula is usually not sensitive to whether the trivial representation is counted or not, but the Kuznetsov formula can be a versatile tool if no residual spectrum is involved.
For the group GL(2) there exist strong density results for many automorphic families, for instance by Sarnak [27], Iwaniec [17], Huxley [16], Blomer-Buttcane-Raulf [6], also in number field versions [7,8] and for general real rank 1 groups [15,33]. Various results are also available for GL(3), see e.g. [3,5,6]. For higher rank groups the deep analysis of the Arthur-Selberg trace formula of Matz-Templier [25] and Finis-Matz [10] provides as by-products some density results for the family of Maaß forms of Laplace eigenvalue up to height T and fixed level. The value of a is however much larger than (1.3) for n > 2 (at least quadratic in n), so that even the "convexity bound" cannot be obtained.
In the present paper we consider the family F I (q) of cuspidal automorphic representations generated by Maaß forms for the group 0 (q) ⊆ SL n (Z) for a large prime q and Laplace eigenvalue λ in a fixed interval I . If I is not too small, we have |F I (q)| I q n−1 . For this family and any place v = q of Q, we go beyond the density hypothesis and obtain strong "subconvexity" with a value of a = (n − 1)/4, which is halfway between (1.3) and the Ramanujan conjecture.
The theorem remains true for n = 2 (by a slightly different proof), but it is known in this case (see [17] for v = ∞, and the proof for finite v is similar) and recovers Selberg's 3/16 bound for exceptional eigenvalues. For n = 3 and v = ∞ this is [5,Theorem 4]. As mentioned above, for larger n Theorem 1 is completely new. As we shall outline below it appears to be the limit of what is available by any trace formula approach, even in the case n = 2 nothing better is known.
The proof is based on a careful analysis of the arithmetic side of the Kuznetsov formula with a test function on the spectral side that blows up on exceptional Langlands parameters at v (and therefore increases the complexity on the arithmetic side). We denote by λ π (m) the m-th Hecke eigenvalue of π ∈ F I (q). Theorem 2 Keep the assumptions and notation of Theorem 1. Let m ∈ N be coprime to q and Z 1. Then I,n,ε q n−1+ε uniformly in m Z q 2 for a sufficiently small implied constant (depending on I and n).
We shall see in Lemma 4 below that |λ π ( p ν )| 2 is often as big as p 2νσ π ( p) for a prime p and ν ∈ N, so that the "test function" |λ π (m)| 2 Z 2σ π (∞) treats finite places and the infinite place essentially on equal footing.
Let us roughly sketch how one may hope to arrive at Theorem 2. Since the Laplacian eigenvalue is fixed, the Whittaker transforms in the Kuznetsov formula play no major role, and the battle is decided on the level of Kloosterman sums. Very roughly, the Kuznetsov formula takes the shape where W is the Weyl group of permutation matrices, M = (m, 1, . . . , 1) ∈ Z n−1 and S q,w (M, M, c) is a certain generalized Kloosterman sum, defined in (4.2) below, associated with the Weyl element w and moduli c = (c 1 , . . . , c n−1 ). If m Z q, then the off-diagonal term vanishes completely and we are done. We will use this observation in Theorem 4 below. This range of m Z recovers the "convexity bound" with the value (1.3). For larger values of m Z and stronger density results we must deal with the Kloosterman sums appearing in the off-diagonal term and improve on the trivial bound |S q,w ( * , * , c)| (c 1 · · · c n−1 ) 1+ε , see (4.7) below. To obtain such bounds for general groups is a famous open problem. In an ideal world we would have complete Weil-type square root cancellation |S q,w ( * , * , c)| (c 1 · · · c n−1 ) 1/2+ε (at least under certain coprimality assumptions) which allows us to take m Z as large as q 2 . This square-root cancellation implies the statement of Theorem 2 and a density hypothesis halfway between the trivial representation and the Ramanujan conjecture. (Additional square root cancellation in the c 1 , . . . , c n−1 sum would give the full Ramanujan conjecture, but this is of course not in the cards).
Interestingly, this heuristic sketch turns out to be quite far from the truth. Square root cancellation for the size of Kloosterman sums may fail badly, so that we have to arrive at Theorem 2 by a rather different analysis. The key lemma is the following, which seems to be the first explicit analysis of general GL(n) Kloosterman sums beyond hyper-Kloosterman sums [12] associated to the Weyl element w = 1 I n−1 , where I n denotes the n-by-n identity matrix. Note that this is in sharp contrast to the case n = 2, where a Kloosterman sum to prime modulus q has no closed evaluation. The key point is that by multiplicativity the Kloosterman sums in (1.4) contain S q,w ( * , * , (q, . . . , q)) as a large chunk. The critical case is the term corresponding to w = w * where the Kloosterman sum is much bigger than the product of the square root of the moduli (if n > 3). Luckily in this case the remaining piece with moduli (c 1 /q, . . . , c n−1 /q) comes with additional savings since the Weyl element w * imposes certain relations among the c j . That the critical Weyl element is not the long Weyl element, but rather the permutation 1 ↔ n that is relatively "close" to the identity, may also be quite surprising in this context. This analysis is sensitive to q being prime. While the general technique can be applied in a rather broad context (see e.g. [2,24]), the estimation in Theorem 3 is particularly designed to the particular setup of 0 (q), q prime.
Theorem 2 and variations of it have other applications of which we mention here only one, namely a large sieve inequality.

uniformly in x q for a sufficiently small implied constant (in terms of I and n).
This result holds (with literally the same proof) for all q ∈ N. For comparison, Venkatesh [35,Theorem 1] obtained this with x q 1/(2n−2) . A simple corollary is the following best-possible bound for a second moment of Lfunctions on the critical line:

Corollary 5 For q prime and t ∈ R we have
The author would like to thank Farrell Brumley for encouragement and numerous discussions on the subject.

Basic notation
Let U ⊆ GL n be the subgroup of unipotent upper triangular matrices. The Haar measure on U (R) is given by dx = 1 i< j n dx i j . As before let W be the Weyl group of permutation matrices; we identify a permutation matrix and we continue to write dx for the induced measure on the subgroup U w (R). (Here denotes the transpose, so that U is the set of unipotent lower triangular matrices.) As . . , 1), we drop it from the notation of the character.
We multiply two elements in y, y ∈ G n−1 m componentwise, written y · y , so that ι is a homomorphism. We denote the image of R n−1 >0 for (n−1)-tuple of Iwasawa y-coordinates. In particular, for g = diag(y 1 , . . . , y n ) with positive y j we have for the Iwasawa y-coordinates of wι(y) −1 w −1 . Explicitly, combining (2.1) with w −1 in place of w, (2.4) and (2.5), we have We define a measure on R n−1 >0 by d * y = y −2η dy 1 y 1 · · · dy n−1 y n−1 and correspondingly an inner product by We denote the push forward of d * y toT (R) by ι also by d * y.
where c 0 = c n = 1, and a simple computation shows (2.9)

Auxiliary results
As the Iwasawa decomposition (with the compact group on the right) is the Gram-Schmidt orthogonalization of rows starting with the last row, we can compute y(g) explicitly. For 1 j n let j = j (g) be the volume of the parallelepiped spanned by last j rows of g. Then so that by (2.5) we have with the convention 0 (g) = 1. By [11, Corollary 4.2 and p. 11] (or by hand) we confirm the inversion formula for the following (n − 1)-by-(n − 1) tridiagonal Toeplitz matrix Our first lemma will be used to bound the moduli c on the arithmetic side of the Kuznetsov formula.
since the diagonal matrix ι(B)c * multiplies the rows of wxι(y) by the corresponding diagonal entries. Clearly j (wx) 1 since one of the minors is always 1, and clearly From (3.4), and from (3.3) in combination with (3.5), we therefore obtain This shows the first statement of the lemma, and the proof of the second is completed by observing that (2.8) and (3.2) imply We shall see in a moment that the only Weyl elements contributing to the Kuznetsov formula are of the form with identity matrices I d j of dimension d j (i.e. d 1 + . . . + d r = n), so without loss of generality we restrict our attention to such matrices. The following technical result computes the Jacobi determinant for a certain change of variables.
for an arbitrary w as in (3.7). We use induction on r and write w = w I d , We call L(w) the left hand side of (3.8) and R(w) the right hand side. We consider first the quotient L(w )/L(w). The pairs 1 j < i n cancel, and for i > n only j n satisfy the summation condition w (i) < w ( j). We conclude On the other hand, which is easily seen to equal the right hand side of (3.9). Since trivially L(I d ) = R(I d ) = 1, the induction is complete.
Proof We can assume without loss of generality that B j 1, otherwise the volume is 0 as seen in the proof of Lemma 1. For . .
so that by considering the lower right minors we obtain in particular the inequalities Thus if |x 1n | B 1 is fixed, the volume of (x 1,n−1 , x n−1,n ) is O (B 2 log b), and if these are fixed, the volume of (x 1,n−2 , x n−2,n ) is O (B 3 log b), etc. Inductively we obtain the desired bound.
Most likely the statement holds for all w, but the proof is particularly simple for w * which is all we need.

Kloosterman sums
Properties of Kloosterman sums for SL n (Z) have been obtained and summarized in [12]. They generalize in an obvious way to the congruence subgroup 0 (q). The Bruhat decomposition gives GL n (Q) = w∈W G w (Q) with Then provided that If v = id, we drop it from the notation. By [12, p. 175], the Kloosterman sum is non-zero only if w is of the form (3.7). If γ = x 1 c * wx 2 ∈ 0 (q) is a matrix occurring in the sum on the right hand side of (4.2), then any minor of γ , and hence of c * w, obtained by deleting at least the first row and the last column is divisible by q. Hence if w is of the form (3.7), then the summation condition in (4.2) can only be met if Observing that and recalling (2.8), we see that (4.1) is equivalent to Kloosterman sums for SL n (Z) enjoy certain multiplicativity properties in the moduli, cf. [12,Proposition 2.4]. We state only one particular case. Let q be prime, suppose that (c 1 · · · c n−1 , q) = 1 and write qc = (qc 1 , . . . , qc n−1 ). Suppose that w(1) = n and w(n) = 1. Then N , (q, . . . , q))S v 1,w (M, (q N 1 , N 2 , . . . , N n−2 ,q N n−1 ), c) By [9, Theorem 0.3(i)] we have the trivial bound We now give the proof of Theorem 3 from the introduction, which is the first non-trivial bound for a GL n Kloosterman sum other than a hyper-Kloosterman sum. For n = 3, the statement is essentially contained in [5, Lemma 6(c)]. We wish to compute S q,w (M, N , (q, . . . , q)) = 0 where M, N ∈ Z n−1 have entries coprime to q.
As mentioned before, we can assume that w is of the form (3.7), otherwise the Kloosterman sum vanishes by definition. Next assume that d 1 > 1 in (3.7). Applying (4.5) with i = 1 we obtain M n−1 = ±N d 1 −1 q, a contradiction. In the same way we exclude the case d r > 1. For w of the form (3.7) with d 1 = d r = 1 and c * = diag (1/q, 1, . . . , 1, q), we recall the definition (4.2) and consider γ = xc * wy ∈ G w (Q) ∩ 0 (q) with uniquely determined x ∈ U (Z)\U (Q), y ∈ U w (Q)/U w (Z). A system of representatives for U (Z)\U (Q) consists of matrices with rational entries in [0, 1) above the diagonal, and similarly we choose a system of representatives of U w (Q)/U w (Z) where all relevant entries are restricted to [0, 1). We now determine those representatives x, y that satisfy xc * wy ∈ 0 (q). We have 1 * * · · · * x 1,n 1 * · · · * x 2,n . . . . . .
We conclude that all star-ed entries in the (n − 1)-st row of c * wy must be integral, hence 0. We continue with the (n − 2)-nd row of γ . By the same argument we first have qx n−2,n ∈ Z and then also star-ed entry in (n − 2)-nd row of x is integral (hence 0) as well as all star-ed entries in the (n − 2)-nd row of c * wy. Continuing in this way, all star-ed entries must vanish. In other words, x diag(1/q, 1 . . . , 1, q) wy ∈ 0 (q) with x ∈ U (Q), y ∈ U w (Q) and all relevant entries in [0, 1) implies . . .
For these x, y we compute Obviously, this matrix is in 0 (q) if and only if the n − 1 congruences are satisfied. This can be solved easily, and we obtain the explicit expression q .
If (M 1 N 1 , q) = 1, the sum vanishes unless n − 1 = w −1 (n − 1). The latter case happens for w of the form (3.7) with d 1 = d r = 1, if and only if w = w * and then the Kloosterman sum equals q n−2 .

Automorphic forms and Whittaker functions
We denote by { } an orthonormal basis of right O n (R)Z + -invariant automorphic forms for the group 0 (q), cuspidal or Eisenstein series. The space L 2 ( 0 (q)\H) is equipped with the standard inner product f, g = 0 (q)\H f (x y)ḡ(x y)dx d * y. We denote by (q) d a combined sum/integral over the complete spectrum of L 2 ( 0 (q)\H). The relevant spectral decomposition is a special case of Langlands' general theory, see e.g. [1] for a convenient summary in adelic language. All belong to representations of level q | q (cf. [19,Théorème]) and we assume that { } contains all cuspidal newvectors of level q | q. The underlying representation is denoted by π , so ∈ V π . For notational simplicity let us denote the local archimedean Langlands parameter μ π (∞) simply by μ = (μ 1 , . . . , μ n ); it satisfies For a (not necessarily cuspidal) automorphic form and N ∈ N n−1 we define its N -th Fourier coefficient A (N ) by where y ∈T (R) and W μ : R n−1 >0 → C is the standard (spherical) Whittaker function, cf. e.g. [34,Section 2].
The following easy, but important lemma shows that λ π ( p ν ) is (perhaps not always, but sufficiently often) as big as p νσ π ( p) with σ π ( p) as in (1.1).

Lemma 4 For a prime p q and ν > n we have
Proof The following argument is taken from [21, Lemma 3]. We have an identity of power series Without loss of generality let μ π ( p, 1) have the largest real part, i.e. μ π ( p, 1) = σ π ( p). Then ∞ ν=0 p νμ π ( p, 1) Comparing coefficients, we obtain the lemma.
We need an archimedean analogue of this result, which is a bit more technical. Roughly speaking, the growth of W μ near the origin should capture the size of σ π (∞) in the same way as the growth of λ π ( p ν ) captures the size of σ π ( p), but this is harder to see as the Mellin transform of W μ is not perfectly understood and the location of poles is subtle. We start by summarizing some properties. As in [34, (3.1), (3.2)] we consider the re-normalized Whittaker function The corresponding Mellin transform W * μ (s) = R n−1 >0 W * μ (y)y s dy 1 y 1 · · · dy n−1 y n−1 is meromorphic in μ and s ∈ C n−1 [13]. Explicitly, we have [34, (3.7)] but in general there do not seem to be such simple formulae. For s 2 , . . . , s n−1 sufficiently large and s 1 > σ π (∞), the function W * μ (s) is holomorphic by [34,Theorem 3.1]. If in addition μ 1 , . . . , μ n are pairwise distinct, then W * μ (s) has simple poles at s 1 = −μ j , 1 j n, with residue (μ 1 , . . . , μ j−1 , μ j+1 , . . . , μ n−1 ) + μ j n − 1 · 1, see [34,Theorem 3.2]. These statements are proved by a recursion formula [34, (3.5)] of the form where α 1 , α 2 are any two elements from the multi-set {μ 1 , . . . , μ n } and ν − α 1 +α 2 n−2 · 1 ∈ C n−2 is the (n − 2)-tuple of the remaining μ j ; moreover, ( * ) is independent of s 1 and holomorphic in t 1 in a wide vertical strip if s 2 , . . . , s n−1 are sufficiently large, and the other n − 4 arguments of W * ν are independent of t 1 and s 1 . Inductively, starting from the explicit formula for n = 2 and n = 3, we see that in any fixed vertical strip for s 1 and for s 2 , . . . , s n−1 sufficiently large, the only poles can occur at s 1 = −μ j − k for 1 j n, k ∈ N 0 . We conclude that is holomorphic for s 1 > σ π (∞) − 1 (for sufficiently large s 2 , . . . , s n−1 ) and For this statement the assumption that the μ j are pairwise distinct can be dropped by holomorphic continuation (note that by the Luo-Rudnick-Sarnak bounds or even the Jacquet-Shalika bounds | μ j | < 1/2 the gamma factors on the right hand side are always defined).
For β ∈ C let D β = −y∂ y + β. This is a commutative family of differential operators that under Mellin transformation correspond to multiplication with s + β. In the proof of Lemma 6 below we will need to following technical, but elementary lemma. for y ∈ I .
Proof Letw(y) = w(y)y −β , so that Then (5.6) implies Changingw by a fourth root of unity if necessary, we can assume that The condition |w (y)| c 2 w y −1 implies that the slightly weaker inequality holds on some non-empty sub-interval Distinguishing the cases w(a 0 ) > −c 3 y 0 w (y 0 ) and w(a 0 ) −c 3 y 0 w (y 0 ) for c 3 = (b 0 − a 0 )/ √ 8y 0 c 0 /32c 2 , we confirm in both cases Thus there exists a non-empty subinterval I = [a , b ] ⊆ I 0 of length (b 0 − a 0 ) such that |w(y)| 1 10 c 3 c 1 y −α on I . Changing back to w, we obtain (5.7).

Lemma 6
Assume that μ varies in some compact set , and let Z 1. There exist r ∈ N and a compact set S ⊆ R n−1 >0 both depending only on (not on Z ) and a finite collection of (measurable) functions E 1 , . . . , E r : R n−1 >0 → R h depending on and Z that are uniformly bounded (independent of Z ) and supported in S such that r j=1 | E (Z ,1,...,1 for μ ∈ and η as in (2.7).
Proof For Z 1 this is [5,Lemma 1]. For convenience we repeat the short argument in a slightly modified fashion that we will need later. There exists Z 0 > 0 (depending only on ) such that for each μ ∈ we can choose an open set S μ ⊆ R n−1 >0 such that | W μ (y)| > 2Z 0 for all y ∈ S μ or | W μ (y)| > 2Z 0 for all y ∈ S μ . Next choose open neighbourhoods U μ about μ such that | W μ * (y)| > Z 0 for all y ∈ S μ and all μ * ∈ U μ or | W μ (y)| > Z 0 for all y ∈ S μ and all μ * ∈ U μ . By compactness we pick a finite collection of such neighbourhoods U μ 1 , . . . , U μ r covering , and define the corresponding E j to be real-valued functions with support on S μ j and non-vanishing on the interiorS μ j . Now suppose that Z is sufficiently large (in terms of ). We try to mimic the proof of Lemma 4. Assume (without loss of generality by (5.1) and Weyl group symmetry) that (−μ 1 ) = σ π (∞), and with the notation as above let Taking inverse Mellin transforms, we obtain where the differential operators are applied to the first variable y 1 . On the other hand, by Mellin inversion and (5.5) we have the asymptotic expansion (1 + μ k − μ 1 ).
By [12, Theorem A] (with ρ = triv, ν 1 = . . . = ν n−1 = 0) we have For fixed y and fixed compact support of E, it follows from the two bounds in Lemma 1 with M in place of B that the c-sum runs over a finite set (depending on M, y and the support of F), and the U w (R)-integral runs over a compact domain (again depending on M, y and the support of F). In particular the right hand side is absolutely convergent (and the assumption ν j > 2/n in [12, Theorem A] can be dropped; Friedberg works more generally with bounded E rather than compactly supported E). Without loss of generality we can assume that w is of the form (3.7). Now let be a not necessarily cuspidal automorphic form occurring in the spectrum of L 2 ( 0 (q)\H). By unfolding, (5.2) and a change of variables y ← ι(N )y, we have , P where as before μ = μ π (∞). By Parseval we obtain On the other hand, by unfolding and (6.2) we can express P (X ) (6.3) so that y(A) η c 1 · · · c n−1 = X · M · w (X · N ) η by (2.9). We change variables We conclude the following Kuznetsov-type formula.

Lemma 7
Let M, N ∈ N n−1 , X ∈ R n−1 >0 , E a compactly supported function on R n−1 >0 and define F (X ) as in (6.1). Then with A as in (6.3).
As mentioned before, the Kloosterman sum S v q,w (M, N , c) vanishes unless w is of the form (3.7), in which case we have the additional conditions (4.3), as well as (4.5) for i / ∈ {d 1 , . . . , d 1 + . . . + d r −1 }. The c-sum is restricted by Lemma 1 and the support of E.

Proofs of Theorems 1, 2, 4
We start with the proof of Theorem 2. We specialize Lemma 7 to m, 1, . . . , 1), X = (Z , 1, . . . , 1) with (m, q) = 1. We need to bound the spectral side from below and the Kloosterman side from above. By (5.3) and positivity we have By Lemma 6 there is a finite set of compactly supported functions E j such that Thus in order to bound the left hand side of (7.1) it suffices to consider the right hand side of (6.4) for a fixed E (X ) = E (X ) j , and we are left with bounding For w = id we have c 1 = . . . = c n−1 = 1 and hence A = I n , and the contribution is O(q n−1+ε Z 2η 1 ).
Let us now consider the remaining w of the form (3.7). First we bound the moduli c j . To this end we apply Lemma 1 with B = X · M · w (X · N ), so that by (2.6) we obtain B 1 = B n−d 1 = m Z, B n−d 1 +1 = 1/(m Z) if d 1 > 1 and B j = 1 for all other indices. This gives We assume that m Z q 2 with a sufficiently small implied constant, so that c j < q 2 for all j. We may also assume that q is sufficiently large, otherwise there is nothing to prove. Now suppose that d 1 > 1 (but d 1 < n since w = id). Then by (4.5) with i = d 1 − 1 we have c n−d 1 +2 c n−d 1 = ±c 2 n−d 1 +1 m. Using (4.3) and comparing the q-adic valuation on both sides, we conclude from (4.3) that both c n−d 1 +1 and c n−d 1 +2 are divisible by q, which contradicts (7.2) for q sufficiently large. Hence d 1 = 1, and we see from (4.3) that all c j are divisible by q. We write c j = qc j . By (4.6) we obtain S v q,w (M, M, c) = S v q,w ( * , * , (q, . . . , q))S v 1,w (M, (qm, 1, . . . , 1,q), c ) where * is coprime to q. By Theorem 3 the first factor on the right hand side vanishes unless w = w * , in other words, only the trivial Weyl element and w * survive.
(As an aside: if we only wanted to prove Sarnak's density original density hypothesis with an exponent n − 1 − 2σ + ε in Theorem 1, then upon choosing m Z q with a sufficiently small constant, all Weyl elements except the identity would vanish and no further analysis would be necessary. That in the stronger set-up m Z q 2 only w * needs to be considered is an artefact of q being prime).
Our next aim is to estimate |E(y(Aw * x y))E(y(y))|dx d * y.
For the Weyl element w * the consistency relations (4.5) impose serious restrictions on the moduli c 1 , . . . , c n−1 . We apply (4.5) with i = 2, . . . , n − 2 getting (c i ) 2 = c i−1 c i+1 for i = 2, . . . , n − 2. If n 4, then c 2 fixes c 1 and c 3 up to a divisor function, and inductively also c 4 , . . . , c n−1 . Using the trivial bound (4.7), we finally obtain (again changing the value of ε) π ∈F I (q) |λ π (m)| 2 Z 2σ π (∞) I q n−1+ε 1 + q n−2 q n−1 c 2 m Z/q 1 q n−1+ε provided m Z q 2 . In the case n = 3 we quote from [5, (4.2) with N = 1] the average Weil-type bound  (m 2 , 1, . . . , 1). We detect the condition δ λ ∈I by a finite collection of test functions E j with Z = 1 as in the previous proof and apply Lemma 7. For w = id the analogue of (7.2) is x which contradicts (4.3) for x q (with a sufficiently small implied constant) since d 1 = n. So only the trivial Weyl element survives, and we obtain the desired bound.
For v = ∞, Theorem 1 follows directly from Theorem 2 with m = 1, Z q 2 (again with a sufficiently small implied constant). .

Funding Information
Open Access funding enabled and organized by Projekt DEAL.
Open Access This article is licensed under a Creative Commons Attribution 4.0 International License, which permits use, sharing, adaptation, distribution and reproduction in any medium or format, as long as you give appropriate credit to the original author(s) and the source, provide a link to the Creative Commons licence, and indicate if changes were made. The images or other third party material in this article are included in the article's Creative Commons licence, unless indicated otherwise in a credit line to the material. If material is not included in the article's Creative Commons licence and your intended use is not permitted by statutory regulation or exceeds the permitted use, you will need to obtain permission directly from the copyright holder.