Galois representations for general symplectic groups

We prove the existence of GSpin-valued Galois representations corresponding to cohomological cuspidal automorphic representations of general symplectic groups over totally real number fields under the local hypothesis that there is a Steinberg component. This confirms the Buzzard-Gee conjecture on the global Langlands correspondence in new cases. As an application we complete the argument by Gross and Savin to construct a rank seven motive whose Galois group is of type G_2 in the cohomology of Siegel modular varieties of genus three. Under some additional local hypotheses we also show automorphic multiplicity one as well as meromorphic continuation of the spin L-functions.

Introduction Let G be a connected reductive group over a number field F. The conjectural global Langlands correspondence for G predicts a correspondence between certain automorphic representations of G(A F ) and certain ℓ-adic Galois representations valued in the L-group of G. Let us recall from [BG11, §3.2] a rather precise conjecture on the existence of Galois representations for a connected reductive group G over a number field F. Let π be a cuspidal L-algebraic automorphic representation of G(A F ). (We omit their conjecture in the C-normalization, cf. [BG11,Conj. 5.3.4], but see Theorem 10.1 below.) Denote by G(Q ℓ ) the Langlands dual group of G over Q ℓ , and by L G(Q ℓ ) the L-group of G formed by the semi-direct product of G(Q ℓ ) with Gal(F/F). According to their conjecture, for each prime ℓ and each field isomorphism ι : C ≃ Q ℓ , there should exist a continuous representation ρ π,ι : Gal(F/F) → L G(Q ℓ ), which is a section of the projection L G(Q ℓ ) → Gal(F/F), such that the following holds: at each place v of F where π v is unramified, the restriction ρ π,ι,v : Gal(F v /F v ) → L G(Q ℓ ) corresponds to π v via the unramified Langlands correspondence. Moreover ρ π,ι should satisfy other desiderata, cf. Conjecture 3.2.2 of loc. cit. For instance at places v of F above ℓ, the localizations ρ π,ι,v are potentially semistable and have Hodge-Tate cocharacters determined by the infinite components of π. Note that if G is a split group over F, we may as well take ρ π,ι to have values in G(Q ℓ ). To simplify notation, we often fix ι and write ρ π and ρ π,v for ρ π,ι and ρ π,ι,v , understanding that these representations do depend on the choice of ι in general.
Our main result confirms the conjecture for general symplectic groups over totally real fields in a number of cases. We find these groups interesting for two reasons. Firstly they naturally occur in the moduli spaces of polarized abelian varieties and their automorphic/Galois representations have been useful for arithmetic applications. Secondly new phenomena (as the semisimple rank grows) make the above conjecture sufficiently nontrivial, stemming from the nature of the dual group of a general symplectic group: e.g. faithful representations have large dimensions and locally conjugate representations may not be globally conjugate.
Let F be a totally real number field. Let n ≥ 2. Let GSp 2n denote the split general symplectic group over F (with similitudes in G m over F). The dual group GSp 2n is the general spin group GSpin 2n+1 , which we view over Q ℓ (or over C via ι), admitting the spin representation spin : GSpin 2n+1 → GL 2 n .
Consider the following hypotheses on π.
(St) There is a finite F-place v St such that π v St is the Steinberg representation of GSp 2n (F v St ) twisted by a character. (L-coh) π ∞ | · | n(n+1)/4 is ξ-cohomological for an irreducible algebraic representation ξ of the group (Res F/Q GSp 2n ) ⊗ Q C (Definition 1.8 below). (spin-reg) There is an infinite place v ∞ of F such that π v ∞ is spin-regular. The last condition means that the Langlands parameter of π v 0 maps to a regular parameter for GL 2 n by the spin representation, cf. Definitions 1.2 and 1.3 below. A trace formula argument shows that there are plenty of (in particular infinitely many) π satisfying (St) and (L-coh), cf. [Clo86], whether or not (spin-reg) is imposed. Let S bad denote the finite set of rational primes p such that either p = 2, p ramifies in F, or π v ramifies at a place v of F above p.
(i) The composition is the Galois representation attached to a cuspidal automorphic Sp 2n (A F )-subrepresentation π ♭ contained in π. Further, the composition corresponds to the central character of π via class field theory and ι. (ii) For every finite place v which is not above S bad ∪ {ℓ}, the semisimple part of ρ π (Frob v ) is conjugate to ιφ π v (Frob v ) in GSpin 2n+1 (Q ℓ ), where φ π v is the unramified Langlands parameter of π v .
(v) If n ≥ 3 then the image of ρ π is Zariski dense in GSpin 2n+1 (Q ℓ ) modulo the center. For all n ≥ 2, spin•ρ π is an irreducible 2 n -dimensional representation, which remains irreducible when restricted to any open subgroup of Gal(F/F). (vi) If ρ ′ : Gal(F/F) → GSpin 2n+1 (Q ℓ ) is any other continuous morphism such that, for almost all F-places v where ρ ′ and ρ π are unramified, the semisimple part ρ ′ (Frob v ) ss is conjugate to the semisimple part ρ π (Frob v ) ss , then ρ and ρ ′ are conjugate.
The above theorem in particular associates a weakly compatible system of λ-adic representations to π. See also Proposition 17.1 below for precise statements on the weakly compatible system consisting of spin • ρ π . It is worth noting that the uniqueness in (vi) would be false for general GSpin 2n+1 (Q ℓ )-valued Galois representations in view of Larsen's example below Proposition 5.4 (as long as the finite group in that example can be realized as a Galois group). Our proof of (vi) relies heavily on the fact that ρ π has large image. 1 Employing eigenvarieties, we can either replace condition (spin-reg) with weaker regularity conditions (HT 1 ) and (HT 2 ) as defined on page 13, or dispense with the condition at the expense of losing the Zariski-density and uniqueness of ρ π .
Theorem B (Theorem 14.3). Let π be a cuspidal automorphic representation of GSp 2n (A F ) satisfying (St) and (L-coh). Let ℓ be a prime number and ι : C ∼ → Q ℓ a field isomorphism. Assume that v St ∤ ℓ. Then there exists a continuous representation ρ π = ρ π,ι : Gal(F/F) → GSpin 2n+1 (Q ℓ ), such that (i), (ii), (iii) and (iv) hold. Under conditions (HT 1 ) and (HT 2 ), the statements (v) and (vi) also hold, and ρ π is unique up to conjugacy. 2 Often Galois representations constructed via eigenvarieties are difficult to realize in the cohomology of algebraic varieties but our method shows that spin • ρ π for π as in Theorem B does appear in the cohomology of suitable Shimura varieties (up to normalization, without conditions (HT 1 ) and (HT 2 )). When n = 3 and F = Q, we employ the strategy of Gross and Savin [GS98] to construct a rank 7 motive over Q with Galois group of exceptional type G 2 in the cohomology of Siegel modular varieties of genus 3. The point is that ρ π as in the above theorem factors through G 2 (Q ℓ ) ֒→ GSpin 7 (Q ℓ ) if π comes from an automorphic representation on (an inner form of) G 2 (A) via theta correspondence. In particular we get yet another proof affirmatively answering a question of Serre in the case of G 2 , cf. [KLS10,DR10,Yun14,Pat15] for other approaches to Serre's question (none of which uses Siegel modular varieties). Along the way, we also obtain some new instances of the Buzzard-Gee conjecture for a group of type G 2 . Our result also provides a solid foundation for investigating the suggestion of Gross-Savin that a certain Hilbert modular subvariety of the Siegel modular variety should give rise to the cohomology class for the complement of the rank 7 motive of type G 2 in the rank 8 motive cut out by π, as predicted by the Tate conjecture. See Theorem 15.1, Corollary 15.2, and Remark 15.3 below for details.
As another consequence of our theorems, we deduce multiplicity one theorems for automorphic representations for inner forms of GSp 2n,F under similar hypotheses from the multiplicity formula by Bin Xu [Xua]. As his formula suggests, multiplicity one is not always expected when all hypotheses are dropped.
1 In contrast, for cuspidal automorphic representations of the group Sp 2n (A F ), the corresponding analogue of statement (vi) does hold (cf. Proposition B.1). So failure of (vi) is a new phenomenon for the cuspidal spectrum of the similitude group GSp 2n (A F ) that does not occur in the cuspidal spectrum of Sp 2n (A F ).
2 In the cases where conditions (HT 1 ) and (HT 2 ) do not necessarily hold, Proposition 5.1 gives a description of the set of conjugacy classes of ρ π satisfying (i) through (iv); in particular this set is finite by Corollary 5.3.
By the uniqueness in Theorem B, we have (a version of) strong multiplicity one for the L-packet of π. In Proposition 6.3 we prove a weak Jacquet-Langlands transfer for π in Theorem C. This allows us to propagate multiplicity one from π as above to the corresponding automorphic representations on a certain inner form. See Theorem 16.3 and Remark 16.6 below for details. Note that (weak and strong) multiplicity one theorem for globally generic cuspidal automorphic representations of GSp 4 (A F ) has been known by Jiang and Soudry [Sou87,JS07].
Our results yield a potential version of the spin functoriality, thus also a meromorphic continuation of the spin L-function, for cuspidal automorphic representations of GSp 2n (A F ) satisfying (St), (L-coh), and the following strengthening of (spin-reg): (spin-REG) The representation π v is spin-regular at every infinite place v of F.
Thanks to the potential automorphy theorem of Barnet-Lamb, Gee, Geraghty, and Taylor [BLGGT14,Thm. A] it suffices to check the conditions for their theorem to apply to spin • ρ π (for varying ℓ and ι). This is little more than Theorem A; the details are explained in §17 below.
Theorem D (Corollary 17.4). Under hypotheses (St), (L-coh), and (spin-REG) on π, there exists a finite totally real extension F ′ /F (which can be chosen to be disjoint from any prescribed finite extension of F in F) such that spin • ρ π | Gal(F/F ′ ) is automorphic. More precisely, there exists a cuspidal automorphic representation Π of GL 2 n (A F ′ ) such that • for each finite place w of F ′ not above S bad , the representation ι −1 spin • ρ π | W F ′ w is unramified and its Frobenius semisimplification is the Langlands parameter In particular the partial spin L-function L S (s, π, spin) admits a meromorphic continuation and is holomorphic and nonzero in a right half plane.
We can be precise about the right half plane in terms of π: For instance it is given by Re(s) > 1 if π has unitary central character. Due to the limitation of our method, we cannot control the poles. Before our work, the analytic properties of the spin L-functions have been studied mainly via Rankin-Selberg integrals; some partial results have been obtained for GSp 2n for 2 ≤ n ≤ 5 by Andrianov, Novodvorsky, Piatetski-Shapiro, Vo, Bump-Ginzburg, and more recently by Pollack-Shah and Pollack, cf. [PS97,Vo97,BG00,PS,Pol]. See [Pol,1.3] for remarks on spin L-functions with further references.
Finally we comment on the hypotheses of our theorems. The statements (ii) and (iii.c) are not optimal in that we exclude a little more than the finite places v where π v is unramified. This is due to the fact that Shimura varieties are (generally) known to have good reduction at a p-adic place only when p > 2 and the defining data (including the level) are unramified at all p-adic places. 3 Condition (L-coh) is essential to our method but it is perhaps possible to prove Theorem B under a slightly weaker condition that π appears in the coherent cohomology of our Shimura varieties. We did get rid of (spin-reg) in Theorem B but the rather strong condition (spin-REG) in Theorem D is necessary due to the current limitation of potential automorphy theorems. Condition (St) is the most serious but believed to be superfluous. Unfortunately we have no clue how to work around it (although it should be possible to work with some other strong, if ad hoc, local hypotheses). We speculate that a level raising result for automorphic forms on GSp 2n would be a big step forward, but such a result (for n ≥ 3) seems out of reach at the moment. On the other hand, (St) is harmless to assume for local applications, which we intend to pursue in future work. We consider Shimura varieties arising from the group Res F/Q G (and the choice of X as in §7 below). Note that (the Q-points of) Res F/Q G has factor of similitudes in F × , as opposed to Q × , and that our Shimura varieties are not of PEL type (when F Q) but of abelian type. This should already be familiar for n = 1 (though we assume n ≥ 2 for our main theorem to be interesting), where we obtain the usual Shimura curves, cf. [Car86a].
In case F = Q our Shimura varieties are the classical Siegel modular varieties. The idea is to consider the compactly supported étale cohomology where L ξ is the ℓ-adic local system attached to some irreducible complex representation ξ of G. Then H i c (S K , L ξ ) has an action of G(A ∞ F ) × Gal(F/F); and one hopes to prove that through this action the module H i c (S K , L ξ ) realizes the Langlands correspondence. In particular, one tries to attach to a cuspidal automorphic representation π of GSp 2n (A F ) the following virtual Galois representation r 1 (Frob v ) ss is conjugate to r 2 (Frob v ) ss in PGL m (Q ℓ ).
Then r 1 ≃ r 2 ⊗ χ for a continuous character χ : Gal(F/F) → Q × ℓ . The strong irreducibility condition is crucial. The lemma is false if r 1 is only assumed to be irreducible; Blasius constructs counter examples in the article [Bla94]. By counting points on Shimura varieties we control ρ 2 at the unramified places. By a different argument ρ 1 is, up to scalars, also controlled at the unramified places. Hence the lemma applies, and allows us to find a character χ such that ρ 2 ≃ ρ 1 χ.
To prove Theorem A we define and check that ρ π satisfies the desired properties stated in the theorem. The proof of Theorem B is an eigenvariety argument. Unlike in the usual case, we use two pseudorepresentations rather than one to overcome group-theoretic issues with general spin groups. 5 Starting from ρ π that we have constructed in Theorem A for spin-regular automorphic representations π, we begin by interpolating the two representations Gal(F/F) ρ π → GSpin 2n+1 (Q ℓ ) spin → GL 2 n (Q ℓ ) and Gal(F/F) ρ π → GSpin 2n+1 (Q ℓ ) → SO 2n+1 (Q ℓ ) std → GL 2n+1 (Q ℓ ) as pseudorepresentations over the eigenvariety associated to a suitable inner form of G which is compact at all infinite places. However it is unclear how to get the desired GSpin 2n+1 -valued representation from the two pseudorepresentations if we naïvely specialize at a classical point with a non-spin-regular weight. Instead we adapt ideas from Steps 1-3 above to the family setting to construct ρ π as in Theorem B.
In fact we assume that the ℓ-components of π have nonzero Iwahori-invariants at ℓ-adic places in the eigenvariety argument. The assumption is lifted by a patching argument along solvable extensions in Sorensen's version [Sor08]. Some technical issues occur essentially because we do not have a precise control at ℓ over weak base change for GSp 2n at ℓ. We resolve them by using recent work of Bin Xu on GSp 2n [Xua].
Notation We fix the following notation.
• F is a totally real number field, embedded into C.
• O F is the ring of integers of F. • A F is the ring of adèles of F, A F := (F ⊗ R) × (F ⊗ Z).
• If Σ is a finite set of F-places, then A Σ F ⊂ A F is the ring of adèles with trivial components at the places in Σ, and F Σ := v∈Σ F v ; F ∞ := F ⊗ Q R.
• If p is a prime number, then F p := F ⊗ Q Q p .
• ℓ is a fixed prime number (different from p).
• Q ℓ is a fixed algebraic closure of Q ℓ , and ι : C ∼ → Q ℓ is an isomorphism.
• For each prime number p we fix the positive root √ p ∈ R >0 ⊂ C. From ι we then obtain a choice for √ p ∈ Q ℓ . Thus, if q is a prime power, then q x is well-defined in C as well as in Q ℓ for all half integers x ∈ 1 2 Z (for instance q n(n+1)/4 v in Corollary 8.3) • If π is a representation on a complex vector space then we set ιπ := π ⊗ C,ι Q ℓ . Similarly if φ is a local L-parameter of a reductive group G so that φ maps into L G(C) then ιφ is the parameter with values in L G(Q ℓ ) obtained from φ via ι. • Γ := Gal(F/F) is the absolute Galois group of F.
is (one of) the local Galois group(s) of F at the place v. • V ∞ := Hom Q (F, R) is the set of infinite places of F. • c v ∈ Γ is the complex conjugation (well-defined as a conjugacy class) induced by any embedding F ֒→ C extending v ∈ V ∞ . • If G is a locally profinite group equipped with a Haar measure, then we write H(G) for the Hecke algebra of locally constant, complex valued functions with compact support. We write H Q ℓ (G) for the same algebra, but now consisting of Q ℓ -valued functions. • We normalize parabolic induction by the half power of the modulus character as in [BZ77,1.8], so as to preserve unitarity.
The (general) symplectic group. Write A n for the n × n-matrix with zeros everywhere, except on its antidiagonal, where we put ones. Write J n := A n −A n ∈ GL 2n (Z). We define GSp 2n as the algebraic group over Z, such that for all rings R, GSp 2n (R) = {g ∈ GL 2n (R) | t g · J n · g = x · J n for some x ∈ R × }.
Let k be an algebraically closed field of characteristic zero. Write W := ⊕ n i=1 k · e i and • W for the exterior algebra of W . We have a natural k-algebra isomorphism from C + k := C + ⊗ Z k onto • W , cf. [FH91,(20.18)]. Lemma 0.1. When n mod 4 is 0 or 3 (resp. 1 or 2), there exists a symmetric (resp. symplectic) form on the 2 ndimensional vector space underlying the spin representation such that the form is preserved under GSpin 2n+1 (k) up to scalars. The resulting map GSpin 2n+1 → GO 2 n (resp. GSpin 2n+1 → GSp 2 n ) over k followed by the similitude character of GO 2 n (resp. GSp 2 n ) coincides with the spinor norm N .
Proof. We may identify the 2 n -dimensional space with • W . Write * for the main involution on C + k as well as on • W . Given s, t ∈ • W , write β(s, t) ∈ C for the projection of s * ∧ t ∈ • W onto n W = C. It is elementary to check that β(·, ·) is symmetric if n mod 4 is 0 or 3 and symplectic otherwise, cf. [FH91,Exercise 20.38]. Now let x ∈ GSpin 2n+1 (k), also viewed as an element of C + k . Note that x * x ∈ k × is the spinor norm of x. Then β(xs, xt) = (xs) * ∧ (xt) = (x * x)s ∧ t = x * xβ(s, t), completing the proof.

Conventions
Let G be a connected reductive group over Q ℓ . A G-valued (ℓ-adic) Galois representation is a continuous morphism ρ : Γ → G(Q ℓ ). If there is no danger of confusion, we write 'representation' instead of 'G-representation'. We call the representation G-irreducible if its image ρ(Γ) is not contained in any proper parabolic subgroup of G. The representation ρ is semi-simple if for some, thus every (cf. [DMOS82,Prop. I.3.1]), faithful representation f of G, the composition f • ρ is semisimple.
Let r 1 , r 2 : Γ → G(Q ℓ ) be two semisimple continuous Galois representations, that are unramified almost everywhere. It is easily checked that the following statements are equivalent: • There exists a dense subset Σ ⊂ Γ such that for all σ ∈ Σ we have r 1 (σ) ss ∼ r 2 (σ) ss ∈ G(Q ℓ ); • for all σ ∈ Γ we have r 1 (σ) ss ∼ r 2 (σ) ss ∈ G(Q ℓ ); • for (almost) all finite F-places v where r 1 , r 2 are unramified, we have • for all linear representations ρ : G → GL N the representations ρ • r 1 and ρ • r 2 are isomorphic. If one of the above conditions holds, we call r 1 and r 2 locally conjugate, and we write r 1 ≈ r 2 . Definition 1.1. Let T be a maximal torus in a reductive group G over an algebraically closed field. A weight ν ∈ X * (T ) is regular if α ∨ , ν 0 for all coroots α ∨ of T in G.
Definition 1.2. Let φ : W R → GSpin 2n+1 (C) be a Langlands parameter. Denote by T the diagonal maximal torus in GL 2 n and by T its dual torus. We have C × ⊂ W R . The composition is conjugate to the cocharacter z → µ 1 (z)µ 2 (z) given by some µ 1 , µ 2 ∈ X * ( T ) ⊗ Z C = X * (T ) ⊗ Z C such that µ 1 − µ 2 ∈ X * (T ). Then φ is spin-regular if µ 1 is regular (equivalently if µ 2 is regular; note that µ 1 and µ 2 are swapped if spin • φ is conjugated by the image of the element j ∈ W R such that j 2 = −1 and jwj −1 = w for w ∈ W C ).
Let H be a connected reductive group over Q ℓ for the following two definitions (which could be extended to disconnected reductive groups). Let h der denote the Lie algebra of its derived subgroup. Write c for the nontrivial element of Gal(C/R). Definition 1.4 (cf. [Gro]). A continuous representation ρ : Gal(C/R) → H(Q ℓ ) is odd if the trace of c on h der through the adjoint action of ρ(c) is equal to −rank(h der ).
Proof. We may choose a model for the Lie algebra of SO 2n+1 to consist of A ∈ GL 2n+1 such that A+J t AJ −1 = 0, where J is the matrix with 1's on the anti-diagonal and 0's everywhere else. Such an A = (a i,j ) is characterized by the condition a i,j + a n+1−j,n+1−i = 0 for every 1 ≤ i, j ≤ 2n + 1. Write t := ρ ♭ (c). By conjugation and multiplying −1 ∈ GL 2n+1 if necessary, we can assume that t is in the diagonal maximal torus in SO 2n+1 (not only in GO 2n+1 , using the fact that the latter is the product of SO 2n+1 with center) of the form diag(1 a , . Now an explicit computation shows that the trace of the adjoint action of t on Lie (SO 2n+1 ) has trace 2(a − b) 2 + 2(a − b) − n, which is equal to −n = −rank(SO 2n+1 ) in all cases.
Let K be a finite extension of Q ℓ . Fix its algebraic closure K and write K for its completion. Definition 1.6 (cf. [BG11,2.4]). Let ρ : Gal(K/K) → H(Q ℓ ) be a continuous representation. We say that ρ is crystalline/semistable/de Rham/Hodge-Tate if for some faithful (thus every) algebraic representation ξ : H → GL N over Q ℓ , the composition ξ • ρ is crystalline/semistable/de Rham/Hodge-Tate. Now suppose that ρ is Hodge-Tate. For each field embedding i : Q ℓ → K, a cocharacter µ HT (ρ, i) : G m → H over Q ℓ is called a Hodge-Tate cocharacter for ρ and i if for some (thus every) algebraic representation ξ : H → GL(V ) on a finite dimensional Q ℓ -vector space V , the cocharacter ξ • ρ induces the Hodge-Tate decomposition Proof. This is obvious by considering ξ • f • ρ for any faithful algebraic representation ξ : H 2 → GL N .
We go back to the global setting. A continuous representation ρ : Example 1. Let Π ξ be the set of (irreducible) discrete series representations which have the same infinitesimal and central characters as ξ ∨ . Then Π ξ is a discrete series L-packet, whose L-parameter is going to be denoted by φ ξ : Write Ω H for the Weyl group of T in H. We define µ Hodge (φ) to be µ 1 viewed as an element of X * ( T ) C /Ω H . When µ 1 happens to be integral, i.e. in X * ( T ), then we may also view µ Hodge (φ) as a conjugacy class of cocharacters G m → H over C.
Let f : H 1 → H 2 be a morphism of connected reductive groups over R whose image is normal in H 2 such that f has abelian kernel and cokernel. (Later we will consider the surjection from GSpin 2n+1 to GO 2n+1 .) Denote by f : H 2 → H 1 the dual morphism. We choose maximal tori Lemma 1.10. With the above notation, let π 2 be a member of the L-packet for φ 2 . Then the pullback of π 2 via f decomposes as a finite direct sum of irreducible representations of H 1 (R), and all of them lie in the L-packet for Proof. This is property (iv) of the Langlands correspondence for real groups on page 125 of [Lan89].

Arthur parameters for symplectic groups
Assume π ♭ is a cuspidal automorphic representation of Sp 2n (A F ), such that • π ♭ is cohomological for an irreducible algebraic representation ξ ♭ = ⊗ v∈V ∞ ξ ♭ v of Sp 2n,F⊗C , • there is an auxiliary finite place v St such that the local representation π ♭ v St is the Steinberg representation of Sp 2n (F v St ).
Let us briefly recall the notion of (formal) Arthur parameters as introduced in [Art13]. We will concentrate on the discrete and generic case as this is all we need (after Corollary 2.2 below); refer to loc. cit. for the general case. Here genericity means that no nontrivial representation of SU 2 (R) appears in the global parameter.
For any N ∈ Z ≥1 let θ be the involution on (all the) general linear groups GL N ,F , defined by θ(x) = J N t x −1 J N where J N is the N × N -matrix with 1's on its anti-diagonal, and 0's on all its other entries. A generic discrete Arthur parameter for the group Sp 2n,F is a finite collection of unordered pairs The parameter ψ is said to be simple if r = 1. The representation Π ψ is defined to be the isobaric sum ⊞ r i=1 τ i ; it is a self-dual automorphic representation of GL 2n+1 (A F ).
Exploiting the fact that Sp 2n is a twisted endoscopic group for GL 2n+1 , Arthur attaches [Art13, Thm. 2.2.1] to π ♭ a discrete Arthur parameter ψ. Let π ♯ denote the corresponding isobaric automorphic representation of GL 2n+1 (A F ) as in [Art13,§1.3]. (If ψ is generic, which will be verified soon, then ψ has the form as in the preceding paragraph.) For each F-place v, the representation π ♭ v belongs to the local Arthur packet Π(ψ v ) defined by ψ localized at v. This packet Π(ψ v ) satisfies the character relation ( [Art13, Thm. 2.2.1]) Tr τ(f Here A θ is an intertwining operator from π ♯ v to its θ-twist such that A 2 θ is the identity map. (The precise normalization is not recalled as it does not matter to us.) where the right hand side defines the local packet Π(π Denote by π ♯ the cuspidal automorphic representation τ 1 = Π ψ . Let A θ : Π Ψ ∼ → Π θ Ψ the canonical intertwining operator such that A 2 θ is the identity and A θ preserves the Whittaker model. Write η for the L-morphism L Sp 2n,F v → L GL 2n+1,F v extending the standard representation Sp 2n = SO 2n+1 (C) → GL 2n+1 (C) such that η| W F v is the identity map onto W F v .
Proof. The morphism η * : H unr (GL 2n+1 (F v )) → H unr (Sp 2n (F v )) is surjective because the restriction of finite dimensional characters of GL 2n+1 to SO 2n+1 generate the space spanned by finite dimensional characters of SO 2n+1 . The lemma now follows from Equation (2.1).
The existence of the Galois representation ρ π ♯ attached to π ♯ follows from [HT01, Thm. VII.1.9], which builds on earlier work by Clozel and Kottwitz. (The local hypothesis in that theorem is satisfied by Lemma 2.1. However this lemma is unnecessary for the existence of ρ π ♯ if we appeal to the main result of [Shi11].) The theorem of [HT01] is stated over imaginary CM fields but can be easily adapted to the case over totally real fields, cf. [CHT08,Prop. 4 To state the Hodge-theoretic property at ℓ precisely, we introduce some notation based on §1. At each y ∈ V ∞ we have a real L-parameter φ ξ ♭ ,y : W F y → L Sp 2n arising from ξ ♭ y . The parameter is L-algebraic as well as C-algebraic. Via the embedding y : F ֒→ C we may identify the algebraic closure F y with C so that W F y = W C . The restriction φ ξ ♭ ,y | W F y : W C → SO 2n+1 (C) gives rise to µ Hodge (ξ ♭ , y) := µ Hodge (φ ξ ♭ ,w | W F y ), a conjugacy class of cocharacters G m → SO 2n+1 (C).

Theorem 2.4. There exists an irreducible Galois representation
unique up to SO 2n+1 (Q ℓ )-conjugation, attached to π ♭ (and ι) such that the following hold.
(iv) For every v|ℓ, the Frobenius semisimplification of the Weil-Deligne representation attached to the de Rham representation ρ π ♭ ,v is isomorphic to the Weil-Deligne representation attached to π ♭ v under the local Langlands correspondence.
Lemma 2.7. Suppose that π is a twist of the Steinberg representation at a finite place. Then π v is essentially tempered at all places v.
Proof. Let π ♭ be as in the previous lemma. We know that π ♭ is the Steinberg representation at a finite place and ξ ♭ -cohomological, where ξ ♭ is the restriction of ξ to Sp 2n,F⊗C (which is still irreducible). Let π ♯ be the self-dual cuspidal automorphic representation of GL 2n+1 (A F ) as above. Note also that π ♯ is C-algebraic (and regular); this is checked using the explicit description of the archimedean L-parameters. Hence  ]. This implies that π ∞ itself is essentially tempered. (Indeed, after twisting by a character, one can assume that π ∞ restricts to a unitary tempered representation on Sp 2n (F v ) × Z(F v ), which is of finite index in GSp 2n (F v ). Then temperedness is 6 This is equivalent to saying that ι(std•φ π ♭ v ) is isomorphic to the Frobenius-semisimplification of the Weil-Deligne representation associated to (std•ρ π ♭ )| Γ F v in view of Proposition B.1 and the fact that self-dual representations into GL 2n+1 (Q ℓ ) factor through SO 2n+1 (Q ℓ ).
tested by whether the matrix coefficient (twisted by a character so as to be unitary on Z(F v )) belongs to L 2+ε (GSp 2n (F v )/Z(F v )). This is straightforward to deduce from the same property of matrix coefficient for its restriction to Sp 2n (F v ) × Z(F v ).) Corollary 2.8. π ∞ belongs to the discrete series L-packet Π ξ .
Proof. It follows from the Vogan-Zuckerman classification [VZ84] that Π ξ coincides with the set of essentially tempered ξ-cohomological representations.
Remark 3.4. The lemma may fail when n = 2 but if it fails, Theorem 3.1 tells us that ρ π ♭ (Γ E ) is a Zariski dense subgroup of the principal SL 2 (Q ℓ ). In case n = 3, if we forgo condition (HT 2 ) then it does happen that the Zariski closure of ρ π ♭ (Γ E ) is G 2 , cf. §15 below.
Proof. Let E/F be a finite extension such that the group H = ρ π ♭ (Γ E ) Zar is Zariski connected. Let N v St be the unipotent operator of the Weil-Deligne representation attached to ρ π ♭ ,v St so that it corresponds to the image of (Γ E ) contains some (possibly higher) positive power of N v St , which is again regular unipotent. The representation ρ π ♭ |Γ E is semisimple because it is the restriction to an open subgroup of an irreducible representation. Since ρ π ♭ (Γ E ) contains the regular unipotent N v St , the representation is indecomposable and semisimple, thus irreducible. It follows that H is an irreducible and connected subgroup of SL 2n+1,Q ℓ . By Lemma 3.2, H is a semisimple group, and by Theorem 3.1, H is one of the groups SO 2n+1 , G 2 or SL 2 over Q ℓ .
Definition 3.6. Let G/Q ℓ be a connected reductive group, and ρ a G-valued Galois representation. We call ρ strongly G-irreducible if, for all open subgroups Γ E ⊂ Γ, the restricted representation ρ| Γ E is G-irreducible (cf. Section 1). We often omit G if G is a general linear group.
Remark 3.7. The Tate module of a CM elliptic curve over Q is an example of an irreducible Galois representation that is not strongly irreducible. In fact, this example is typical: Let ρ : Γ → G(Q ℓ ) be an ℓ-adic representation. Let H ρ be the Zariski closure of its image. If F ′ /F is a finite extension with Γ ′ := Gal(F/F ′ ), write H ′ ρ for the Zariski closure of the image of ρ| Γ ′ . Then H ′ ρ is a union of connected components of H ρ (it is closed and of finite index, hence open). We deduce (i) If H ρ is connected, then ρ is irreducible if and only if it is strongly irreducible.
Then for all finite extensions F ′ ⊂ Q of F that are linearly disjoint to M ρ , the representation ρ| Γ ′ is irreducible.
Proof. By Proposition 3.3 the Zariski closure of the image of ρ 1 is connected. Thus, by Remark 3.7.(i) it suffices to show that ρ 1 is irreducible. When n = 2, this is clear since ρ 1 contains a regular unipotent element. Assume n ≥ 3. The image of the map spin : SO 2n+1 → GL 2 n is not contained in any parabolic subgroup. By Lemma 3.3, the projective representation spin • ρ π ♭ is thus irreducible, and consequently ρ 1 is irreducible as well.

Projective representations
A classical theorem for Galois representations states that, if r 1 , r 2 : Γ → GL m (Q ℓ ) are two continuous semisimple representations which are locally conjugate, then they are conjugate. This is a consequence of the Brauer-Nesbitt theorem combined with the Chebotarev density theorem. In this section we give an analogous statement for projective representations r 1 , r 2 : Γ → PGL m (Q ℓ ) (see Proposition 4.4).
Lemma 4.1. Let m, t ≥ 1 be integers. Let r 1 , r 2 be two m-dimensional ℓ-adic representations of Γ such that: • r 1 , r 2 are unramified at almost all places; • r 1 is strongly irreducible; • for almost all places v where r 1 and r 2 are unramified, the semisimple elements r 1 (Frob v ) ss and r 2 (Frob v ) ss are conjugate in the group GL m (Q ℓ )/µ t (Q ℓ ).
Then there exists a continuous character χ : Proof. Consider the quotient Q ℓ /∼ where for x, y ∈ Q ℓ we identify x ∼ y if and only if y = ζx for some ζ ∈ µ t (Q ℓ ). The quotient Q ℓ /∼ is Hausdorff, and thus the locus in Γ where Tr r 1 (σ) ∼ Tr r 2 (σ) is closed. Thus, by Chebotarev's density theorem we have Tr r 1 (σ) ∼ Tr r 2 (σ) for all σ ∈ Γ. We claim that there is an open neighborhood U ⊂ Γ of the identity e ∈ Γ such that Tr r 1 (σ) = Tr r 2 (σ) for all σ ∈ U. To see this, pick some open ideal I ⊂ Z ℓ such that (1 − ζ)m I for all ζ ∈ µ t (Q ℓ ) with ζ 1. Take U ⊂ Γ the set of σ such that for i = 1, 2 we have for all σ ∈ U that Tr r i (σ) ≡ m mod I. Then U is open by continuity of the representations r i . The traces Tr r 1 (σ) and Tr r 2 (σ) agree up to an element ζ σ ∈ µ t (Q ℓ ). Reducing modulo I we get m ≡ ζ σ m.
Since m ζ σ m modulo I, the element ζ σ must be 1 for all σ ∈ U. For the unit element e ∈ Γ we have Tr r i (e) = m (i = 1, 2), consequently U is an open neighborhood of e ∈ Γ. Thus the claim is true. Let E/F be a finite Galois extension so that Γ E ⊂ U. By construction Tr r 1 (σ) = Tr r 2 (σ) for all σ ∈ Γ E and therefore the space H := Hom Γ E (r 1 | Γ E , r 2 | Γ E ) is non-zero. Consider the Γ-action on elements f of the space H defined by σ f := (Q m ℓ ∋ v → r 2 (σ)f (r −1 1 (σ)v)). Let us check that the function σ f is really an element of H, The space H is one-dimensional by Schur's lemma for Γ E (by assumption r 1 | Γ E is irreducible). Consequently there exists a character χ : Γ → Q × ℓ such that σ f = χ(σ)f for all σ ∈ Γ and all f ∈ H. Pick any non-zero element f ∈ H. Then for all v ∈ Q m ℓ and all σ ∈ Γ we have r 2 (σ −1 )f (r 1 (σ)v) = χ(σ) −1 f (v), and therefore f (r 1 (σ)v) = χ(σ) −1 r 2 (σ)f (v) which means that f is an intertwining operator r 1 → r 2 ⊗ χ −1 .
In fact the character χ in the preceding lemma is unique by the following lemma. Proof. The order of χ is finite and divides m since det r = det(r ⊗ χ). Moreover χ has to be unramified at every place where r is unramified, so χ factors through a faithful character on a finite quotient Γ/Γ ′ . If χ 1 then r| Γ ′ is reducible, contradicting the assumption.    Proposition 4.4. Let m ≥ 1 be an integer. Let r 1 , r 2 : Γ → PGL m (Q ℓ ) be two continuous morphisms such that • r 1 , r 2 are unramified at almost all places; Then r 1 is conjugate to r 2 .
Remark 4.5. The second condition of Proposition 4.4 cannot be removed (see Lemma 4.6 below). Blasius constructs in the article [Bla94] examples of pairs of irreducible representations r 1 , r 2 with finite image that satisfy the first and third bullet, but not the conclusion of the proposition.
Proof. By Lemma 4.3 there exist lifts r i of the representations r i such that the determinants det( r i ) are characters of finite order, both of order dividing s ≥ 1. Let v be a finite F-place unramified in both representations and such that r 1 (Frob v ) ss and r 2 (Frob v ) ss are PGL m (Q ℓ )-conjugate. Let GL (s) m be the group defined in the proof of Lemma 4.3. We have PGL m (Q ℓ ) = GL (s) m (Q ℓ )/µ ms (Q ℓ ). Thus r 1 (Frob v ) ss and r 2 (Frob v ) ss are conjugate in GL (s) m (Q ℓ )/µ ms (Q ℓ ). By Lemma 4.1 the representations r 1 and r 2 are conjugate up to twist, which implies that r 1 , r 2 are PGL m (Q ℓ )-conjugate.
Let r : Γ → PGL m (Q ℓ ) be a continuous morphism. Pick a lift r of r to GL m (Q ℓ ) (Lemma 4.3), and consider the semisimplification ( r) ss . The representation r ss := ( r) ss : Γ → PGL m (Q ℓ ) does not depend on the choice of lift r. We call r ss the semisimplification of r.
Lemma 4.6. Let r 1 , r 2 : Γ → PGL m (Q ℓ ) be two continuous morphisms such that • r 1 , r 2 are unramified at almost all F-places; • for almost all finite unramified F-places v, the semisimple part r 1 (Frob v ) ss is conjugate to r 2 (Frob v ) ss in PGL m (Q ℓ ).
Write r 1,ss , r 2,ss for the semisimplification of r 1 , r 2 . Then there exists a finite extension E/F such that r 1,ss | Γ E is PGL m (Q ℓ )-conjugate to r 2,ss | Γ E .
Proof. By Lemma 4.3 there exists lifts r 1 , r 2 of r 1 , r 2 whose determinants have finite order. For almost all places v we have Tr r 1 (Frob v ) = ζ Frob v Tr r 2 (Frob v ) for some element ζ Frob v ∈ µ mr (Q ℓ ). By the Chebotarev density theorem, we get for all σ ∈ Γ that Tr r 1 (σ) = ζ σ Tr r 2 (σ) for some ζ σ ∈ µ mr (Q ℓ ). As in the proof of Lemma 4.1 we can then find a finite extension E/F such that ( r 1 ) ss | Γ E and ( r 2 ) ss | Γ E are conjugate. The lemma follows.

GSpin-valued Galois Representations
In this section we study the notion of local conjugacy for the group GSpin 2n+1 (Q ℓ ). In general it is not expected that local conjugacy implies (global) conjugacy of Galois representations: In the paper [Lar94a, proof of Prop. 3.10] Larsen constructs a certain finite group ∆ (in his text it is called Γ), which is a double cover of the (non-simple) Mathieu group M 10 in the 10-th alternating group A 10 . More precisely, he realizes M 10 ⊂ SO 9 (Q ℓ ) by looking at the standard representation of A 10 ⊂ GL 10 (Q ℓ ). Then ∆ is the inverse image of M 10 in Spin 9 (Q ℓ ). Let us just assume that ∆ can be realized as a Galois group s : Γ ։ ∆. The group ∆ comes with a map φ 1 : ∆ → Spin 9 (Q ℓ ), and η is the composition ∆ ։ M 10 ։ M 10 /A 6 Z/2Z Spin 9 (Q ℓ ). He defines φ 2 (x) := η(x)φ 1 (x). We may define r 1 := φ 1 • s and r 2 := φ 2 • s. Then the argument of Larsen shows that φ 1 (σ) and φ 2 (σ) are Spin 9 (Q ℓ ) conjugate for every σ ∈ Γ, while φ 1 and φ 2 are not Spin 9 (Q ℓ )-conjugate. The maps φ i cannot be GSpin 9 (Q ℓ )-conjugate: If we would have φ 2 = gφ 1 g −1 for some g ∈ GSpin 9 (Q ℓ ) then we can find a z ∈ Q × ℓ , such that h = gz ∈ Spin 9 (Q ℓ ) and hφ 1 h −1 = gφ 1 g −1 = φ 2 which contradicts Larsen's conclusion. Thus, assuming the inverse Galois problem holds over F for ∆, (r 1 , r 2 ) is a pair of locally conjugate, but non-conjugate Galois representations.
In We say that a Galois representation r : Γ → GSpin 2n+1 (Q ℓ ) is in bad position if there exists a quadratic extension E/F such that every σ ∈ Γ\Γ E maps via to an element which has at least one eigenvalue equal to −1.
Proposition 5.1. Let r 1 , r 2 : Γ → GSpin 2n+1 (Q ℓ ) be two Galois representations with r 1 semi-simple. Then r 1 , r 2 are locally conjugate if and only if the following statement holds • There exists an element g ∈ GSpin 2n+1 (Q ℓ ) and a character η : Γ → {±1} such that r 2 = η · gr 1 g −1 , and, if η is non-trivial, r 1 is in bad position with respect to the quadratic extension E/F corresponding to η.
Moreover, if std • r 1 is irreducible, then for all quadratic extensions E/F, r 1 is not conjugate to r 1 · η E/F , where η E/F is the quadratic character corresponding to E/F.
For the second statement of the Proposition, assume r is conjugate to r · η with η a quadratic character of Γ and that std • r is irreducible. Let g ∈ GSpin 2n+1 (Q ℓ ) be such that g(r · η)g −1 = r. By Schur's lemma std(g) is a scalar matrix and g ∈ GSpin 2n+1 (Q ℓ ) is central. Thus r = r · η and hence η = 1. Proof. In small neighborhoods around identity in SL 2n+1 (Q ℓ ) no element has an eigenvalue equal to −1. Let M/F be a finite Galois extension such that (std • q ′ • r)(Γ M ) lies in such an open neighborhood. Then for any Corollary 5.4. Let r 1 , r 2 : Γ → GSpin 2n+1 (Q ℓ ) be two locally conjugate Galois representations, such that the representation (spin • r 1 )| Γ E is irreducible for all quadratic extensions E/F. Then r 1 is GSpin 2n+1 (Q ℓ )-conjugate to r 2 .
Proof. After conjugating r 2 , we may assume it is of the form r 1 η with η character with η 2 = 1. By local conjugacy we have spin • (r 1 η) = η(spin • r 1 ) spin • r 1 . Let g ∈ GL 2 n (Q ℓ ) be a matrix that conjugates η(spin • r 1 ) to spin • r 1 . Let E/F be the field corresponding to the kernel of η. Then, g defines a Γ Eautomorphism of spin • r 1 . Since spin • r 1 is irreducible over Γ E , the matrix g is central by Schur's lemma. Hence η(spin • r 1 ) = spin • r 1 and η = 1.

The trace formula with fixed central character
In this section we recall the general setup for the trace formula with fixed central character 7 and prove some instances of the Langlands functoriality for GSp 2n we will need later.
Let G be a connected reductive group over a number field F with center Z. Write A Z for the maximal Qsplit torus in Res F/Q Z and set A Z,∞ : In what follows we need to choose Haar measures consistently for various groups, but we will suppress these choices as this is quite standard. For instance the same Haar measures on G(A F ) and X have to be chosen for each term in the identity of Lemma 6.1 below.
Let v be a place of F, and X v a closed subgroup of Note that the trace is well defined since the operator G(F v )/X v f v (g)π v (g) has finite rank. Likewise one can define the adelic Hecke algebra H(G(A F ), χ −1 ) and orbital integrals and trace characters for its elements in the evident manner.
cusp,χ is defined by taking trace on the space of square-integrable cuspforms. In general we do not expect that T ell,χ (f ) = T disc,χ (f ) (unless G/Z is anisotropic over F) but the equality should hold only after adding more terms on both sides. However we do have T ell,χ (f ) = T disc,χ (f ) if f satisfies some local hypotheses; this is often referred to as the simple trace formula. For our purpose, we henceforth assume the following. • We also need to consider the central character datum (X 0 , χ 0 ) with X 0 := A Z,∞ and χ 0 : It is easy to check that T G ell,χ 0 k.a. Euler-Poincaré function) for ξ such that Tr π ∞ (f ξ ) computes the Euler-Poincaré characteristic for the Lie algebra cohomology of π ∞ ⊗ ξ for every irreducible admissible representation π ∞ of G(F ∞ ) with central character χ ξ . See Appendix A for details. Analogously we have the notion of Lefschetz functions at a finite place as recalled in Appendix A.
The following simple trace formula is standard for X = A G,∞ and some other choices of X (such as X = Z(G(A F ))), but we want the result to be more flexible. Our proof reduces to the case that X = A G,∞ .
We also know that f v St is strongly cuspidal (Lemma A.7). Hence the simple trace formula [Art88b, Cor. 7.3, 7.4] implies that . We deduce the lemma by averaging over Now we go back to the general central character data and discuss the stabilization for the trace formula with fixed central character under simplifying hypotheses. Assume that G * is quasi-split over F. Write Σ ell,χ (G * ) for the set of X-orbits on the set of F-elliptic stable conjugacy classes in G * (F). Define whereι(γ) is the number of Γ-fixed points in the group of connected components in the centralizer of γ in G * , and SO G * γ,χ (f ) denotes the stable orbital integral of f at γ. If G * has simply connected derived subgroup (such as Sp 2n or GSp 2n ), we always haveι(γ) = 1.
Returning to a general reductive group G, let G * denote its quasi-split inner form over F (with a fixed inner twist G * ≃ G over F). Since Z is canonically identified with the center of G * , we may view (X, χ) as a central character datum for G * . Let f * ∈ H(G * (A F ), χ −1 ) denote a Langlands-Shelstad transfer of f to G * . 8 Such a transfer exists in this fixed-central-character setup: One can lift f via the surjection H(G(A F )) → 8 The transfer for χ −1 -equivariant functions is defined in terms of the usual transfer factors. Its existence is implied by the existence of the usual Langlands-Shelstad transfer (for compactly supported functions). For details, see [Xub,3.3] for instance.
, apply the transfer from H(G(A F )) to H(G * (A F )) (the transfer to quasi-split inner forms is due to Waldspurger), and then take the image under the similar surjection down to H(G * (A F ), χ −1 ).
Let v St be a finite place of F.
From here until the end of this section we assume that G (thus also G * ) has a nontrivial simply connected group as its derived subgroup. (Our main interest lies in is not compact modulo center then no one-dimensional representation thereof is essentially tempered. Let S 0 ⊂ S ∞ ∪ {v St } is a finite subset, and S a finite set of places containing S 0 ∪ S ∞ . Let G * ≃ G over F be an inner twist which is trivialized at each place v S 0 (i.e. up to an inner automorphism the inner twist descends to an isomorphism over F v ). By slight abuse of notation we identify Then we often have weak transfers of automorphic representations between G * and G. Proposition 6.3. Consider π and π ♮ as follows: (1) Suppose that ξ has regular highest weight. Then for each π (resp. π ♮ ) as above, there exists π ♮ (resp. π) as above such that π (2) For each π as above, suppose that • π v ′ is essentially tempered at some finite place v ′ S, • For every τ ∈ A χ (G * ) such that τ S ≃ π S , if τ v St is an unramified twist of the Steinberg representation then τ ∞ is a discrete series representation. Then there exists π ♮ as above such that π ♮ v ≃ π v at every finite place v S ∪ {v St }. Morever the converse is true with G in place of G * and the roles of π and π ♮ switched. Remark 6.4. Corollary 2.8 tells us that the condition in (2) for the transfer from G * to G is satisfied by G * = GSp 2n . Later we will see in Corollary 8.5 that the same is also true for a certain inner form of GSp 2n .
Proof. We will only explain how to go from π to π ♮ as the opposite direction is proved by the exact same Lefschetz function, and f * ∞ is a Lefschetz function for ξ. We know from Lemmas A.4 and A.10 that are associated up to a nonzero constant. Hence cf and f * are associated for some c ∈ C × . The preceding two lemmas imply that By linear independence of characters, we have Let us prove (1). Choose (This is vacuous if there is no such v.) At infinite places, as soon as Tr (f * v |τ v ) 0 at v|∞, the regularity condition on ξ implies that τ v is a discrete series representations and that Tr , the unitary representation τ v St is either an unramified twist of the trivial or Steinberg representation by Lemma A.1. If τ v St were one-dimensional then the global representation τ is one-dimensional by strong approximation for the derived subgroup of G, implying that τ ∞ cannot be tempered. 9 All in all, for all τ as above such that Tr (f * S |τ S ) 0, we see that τ v St is an unramified twist of the Steinberg representation and that Tr (f * S |τ S ) has the same sign. Moreover τ = π contributes nontrivially to the left sum by our assumption. Therefore the right hand side is nonzero, i.e. there exists π ♮ ∈ A χ (G) such that π ♮,S ≃ π ♮,S and m(π ♮ )Tr (f S |π ♮ S ) 0. The nonvanishing of trace confirms the conditions on π ♮ at v St and ∞ by the same argument as above.
Now we prove (2). Make the same choice of is an unramified twist of the Steinberg representation. By the assumption τ ∞ is then a discrete series representation. Hence the nonzero contributions from τ on the left hand side all has the same sign. Thereby we deduce the existence of π ♮ as in (1).
As before G * is a quasi-split group over a totally real field F whose derived subgroup is simply connected. Let E/F be a finite cyclic extension of totally real fields such that for the base change morphism of unramified Hecke algebras, we have from Satake theory that ). Proposition 6.5. Let π be a cuspidal automorphic representation of G * (A F ) such that • π is unramified at all finite places apart from a finite set S, Suppose that either ξ has regular highest weight or that the condition for π in Proposition 6.3.
(2) is satisfied. (This is always true for G * = GSp 2n , cf. Remark 6.4.) Then there exists a cuspidal automorphic representation Proof. We will be brief as our proposition and its proof are very similar to those in Labesse's book [Lab99, §4.6], and also as the proof just mimics the argument for Proposition 6.3 in the twisted case. In particular we leave the reader to find further details about the twisted trace formula for base change in loc. cit. Strictly speaking one has to incorporate the central character datum (X, χ) above in Labesse's argument, but this is done exactly as in the untwisted case. We begin by setting up some notation. TakeK to be a sufficiently small open compact subgroup of We choose the test functions . Given a finite place v S and each place w of E above it, letf w be an arbitrary function in H unr (GSp 2n (E w ,χ −1 )). The image off v in H unr (GSp 2n (F v )) under the base change map is denoted by f v . At infinite places letf ∞ = w|∞fw be the twisted Lefschetz function determined byξ and f ∞ = v|∞ f v the usual Lefschetz function for ξ. Againf ∞ and f ∞ are associated up to a nonzero constant by Lemma A.11. By constructionf and cf are associated for some c ∈ C × . 9 The strong approximation is true since the derived subgroup of our G is simply connected but this is inessential; one can always reduce to this case via z-extensions.
We write TG * θ cusp,χ and TG * θ ell,χ for the cuspidal and elliptic expansions in the base-change twisted trace formula, which are defined analogously as their untwisted analogues. Just like the trace formula for G and f , the twisted trace formula forG andf as well as its stabilization simplifies greatly exactly as in Lemmas 6.1 and 6.2 in light of Lemmas A.8 and A.11. So we have By linear independence of characters and the character identity (6.1), we have where Tr θ denotes the θ-twisted trace (for a suitable intertwining operator for the θ-twist). The right hand side is nonzero as in the proof of Proposition 6.3. Therefore there exists π E :=τ ∈ A χ (GSp 2n (A E )) contributing nontrivially to the left hand side. By construction off such a π E satisfies all the desired properties.

Cohomology of certain Shimura varieties of abelian type
In this section we construct a Shimura datum and then state the outcome of the Langlands-Kottwitz method on the formula computing the trace of the Frobenius and Hecke operators in the case of good reduction.
We first construct our Shimura datum (Res F/Q G, X). The group G/F is a certain inner form of the quasisplit group G * := GSp 2n,F . We recall the classification of such inner forms, and then define our G in terms of this classification. The inner twists of GSp 2n,F are parametrized by the cohomology group H 1 (F, PSp 2n ). Kottwitz defines in [Kot86, Thm. 1.2] for each F-place v a morphism of pointed sets Thus α v is surjective, with trivial kernel as H 1 (R, Sp 2n ) vanishes by [PR94, Chap. 2]. However α v is not a bijection (when n ≥ 2). In fact α −1 v (1) classifies unitary groups associated to Hermitian forms over the Hamiltonian quaternion algebra over F v with signature (a, b) with a + b = n modulo the identification as inner twists between signatures (a, b) and (b, a). (See [Tai15, 3.1.1] for an explicit computation of H 1 (F v , PSp 2n ).) So α −1 v (1) has cardinality ⌊ n 2 ⌋ + 1. There is a unique nontrivial inner twist of GSp 2n,F v (up to isomorphism), to be denoted by GSp cmpt 2n,F v , such that GSp cmpt 2n,F v is compact modulo center. It comes from a definite Hermitian form. By [Kot86, Prop. 2.6] we have an exact sequence In particular there exists an inner twist G of GSp 2n,F such that: then has to be the unique nontrivial inner form of GSp 2n,F v St .
More concretely G can be defined itself as a similitude group. See the first two paragraphs of §12 below.
Let be the Deligne torus Res C/R G m . Over the real numbers the group (Res F/Q G) R decomposes into the product y∈V ∞ G ⊗ F F y . Let I n be the n × n-identity matrix and A n be the n × n-matrix with all entries 0, except those on the anti-diagonal, where we put 1. Let h 0 : → (Res F/Q G) R be the morphism given by for all R-algebras R (the non-trivial component corresponds to the non-compact place v ∞ ∈ V ∞ ). We let X be the (Res F/Q G)(R)-conjugacy class of h 0 . This set X can more familiarly be described as Siegel double half space H n , i.e. the n(n + 1)/2-dimensional space consisting of complex symmetric n × n-matrices with definite (positive or negative) imaginary part. Let us explain how the bijection X H n is obtained. The group GSp 2n (R) acts transitively on H n via fractional linear transformations: Similarly, the stabilizer of h 0 ∈ X is equal to K ∞ . Thus there is an isomorphism X H n under which h 0 corresponds to iI n . It is a routine verification that Deligne's axioms (2.1.1.1), (2.1.1.2), and (2.1.1.3) for Shimura data [Del79] are satisfied for (Res F/Q G, H n ). Since moreover the Dynkin diagram of the group G ad is of type C, it follows from Deligne [Del79, Prop. 2.3.10] that (Res F/Q G, H n ) is of abelian type. 10 We Thus the conjugacy class of µ is fixed by σ if and only if σ ∈ Gal(Q/F). Therefore the reflex field of ( is not of PEL type. If moreover n = 1 then the S K have dimension 1 and they are usually referred to as Shimura curves, which have been extensively studied in the literature. Let ξ = ⊗ y|∞ ξ y be an irreducible algebraic representation of (Res F/Q G) × Q C = y|∞ G(F y ) with each F y canonically identified with C. The central character ω ξ y of ξ y has the form z → z w y for some integer w y ∈ Z.
Lemma 7.1. If there exists a ξ-cohomological discrete automorphic representation π of G(A F ) then w y has the same value for every infinite place y of F.
Proof. Under the assumption, the central character ω π : F × \A × F → C × is an (L-)algebraic Hecke character. Hence ω π = ω 0 | · | w for a finite Hecke character ω 0 and an integer w by Weil [Wei56]. It follows that w = w v for every infinite place v.
In light of the lemma we henceforth make the hypothesis as follows, implying that ξ restricted to the center Z(F) = F × of (Res F/Q G)(Q) = GSp 2n (F) is the w-th power of the norm character N F/Q .
(cent) w y is independent of the infinite place y of F (and denoted by w).
Following [Car86b, 2.1] (especially paragraph 2.1.4) we construct an ℓ-adic sheaf on S K for each sufficiently small open compact subgroup K of G(A ∞ F ) from the ℓ-adic representation ιξ = ξ ⊗ C,ι Q ℓ . For simplicity we write L ιξ for the ℓ-adic sheaf (omitting K). It is worth pointing out that the construction relies on the fact that ξ is trivial on Z(F) ∩ K for small enough K, cf. (12.4) below where we discuss ℓ-adic sheaves further. (For a fixed open compact subgroup K 0 , we see that Without loss of generality we assume throughout that K decomposes into a product Our primary interest lies in the ℓ-adic étale cohomology with compact support We are going to apply the Langlands-Kottwitz method to relate the action of Frobenius elements of Γ at primes of good reduction to the Hecke action. In the PEL case of type A or C, Kottwitz worked it out in [Kot90,Kot92b] including the stabilization. As we are dealing with Shimura varieties of abelian type, we import the result from [KSZ]. In fact the stabilization step is very simple under hypothesis (St).
Suppose that (G, K) is unramified at p. Let p be a finite F-place above p with residue field k(p). Let us introduce some more notation.
• For j ∈ Z ≥1 denote by Q p j the unramified extension of Q p of degree j, and Z p j its integer ring.
• Let σ be the automorphism of F p,j induced by the (arithmetic) Frobenius automorphism on Q p j and the trivial automorphism on F. F p,j ))) be the convolution algebra of compactly supported smooth complex valued functions on G(A ∞ F ) (resp. G(F p ), resp. G(F p,j ))), where the convolution integral is defined by the Haar measure giving the group K (resp. K p resp. G(O F p,j )) measure 1.
• We write H unr (G(F p )) (resp. H unr (G(F p,j ))) for the spherical Hecke algebra, i.e. the algebra of K p (resp. Let E ell (G) denote the set of representatives for isomorphism classes of (G, K)-unramified elliptic endoscopic triples of G. For each (H, s, η 0 ) ∈ E ell (G) we make a fixed choice of an L-morphism η : L H → L G extending η 0 (which exists since the derived group of GSp 2n is simply connected). We recall the notation ι(G, H) ∈ Q and only for the principal endoscopic triple (H, s, η) = (G * , 1, id), which is all we need. (For other endoscopic triples, the reader is referred to (7.3), second display on p.180 and second display on p.186 of [Kot90]; this is adapted to a little more general setup as ours in [KSZ].) We have ι(G, G * ) = 1 and the average of pseudo-coefficients for the discrete times the Euler-Poincaré function for ξ (defined in §6 but using K ∞ of this section): . The main result of [KSZ] is the following (which works for every Shimura variety of abelian type such that the center of G is an induced torus and every Shimura variety of Hodge type), where the starting point is Kisin's proof of the Langlands-Rapoport conjecture for all Shimura varieties of abelian type [Kis13]. When F = Q it was already shown by [Kot90,Kot92b].
Suppose that p and p are as above such that The discussion there is correct in our setting, but it can be false for non-discrete series representations (which are allowed in that paper). For instance when ξ and π ∞ are the trivial representation in the notation of [Kot92a], it is obvious that τ ∞ cannot decompose further even if |π 0 (G(F ∞ )/Z(F ∞ ))| > 1.
Then there exists a positive integer j 0 (depending on ξ, f ∞ , p, p) such that for all j ≥ j 0 we have

Galois representations in the cohomology
Let π be a cuspidal ξ-cohomological automorphic representation of GSp 2n (A F ) satisfying condition (St), and fix the place v St in that condition. Define an inner form G os GSp 2n as in §7; when [F : Q] is even, we take v St in that definition to be the fixed place v St . Let π ♮ be a transfer of π to G(A F ) via Proposition 6.3 (which applies thanks to Remark 6.4) so that St is an unramified twist of the Steinberg representation, and π ♮ ∞ is ξ-cohomological. The aim of this section is to compute a certain π ♮ -isotopical component of the cohomology of the Shimura variety S attached to (G, X).
Let A(π ♮ ) be the set of (isomorphism classes of) cuspidal automorphic representations τ of G(A F ) such that be a sufficiently small decomposed compact open subgroup such that π ♮,∞ has a non-zero K-invariant vector. Let S bad be the set of prime numbers p for which either p = 2, the group Res F/Q G is ramified or to be the virtual Galois representation is the Grothendieck group of the category of continuous representations of Γ on finite dimensional Q ℓ -vector spaces, which are unramified at almost all the places. We compute in this section ρ shim 2 at almost all F-places not diving a prime in S bad . Let Z denote the center of G. Define a rational number where m(τ) is the multiplicity of τ in the discrete automorphic spectrum of G.
Recall the integer w ∈ Z determined by ξ as in condition (cent) of the last section. Let i ∈ Z ≥0 . We write H i (2) (S K , L ξ ) for the L 2 -cohomology of S K with coefficient L ξ . By taking a direct limit we obtain an admissible Similarly we define the compact support cohomology H i c (S K , L ξ ) and the intersection cohomology IH i (S K , L ξ ) as well as their direct limits H i c (S, L ξ ) and IH i (S, L ξ ). The latter two are equipped with commuting actions of G(A ∞ F ) and Γ.
We claim that the finite part of τ does not appear in any parabolic induction of an automorphic representation on a proper Levi subgroup of GSp 2n (A). It suffices to check the analogous claim with τ ♭ (as in Lemma 2.6) and Sp 2n in place of τ and GSp 2n . The latter claim follows from Arthur's main result [Art13, Thm. 1.5.2], Corollary 2.2, and the strong multiplicity one theorem for general linear groups. As a consequence of the claim, the τ ∞ -isotypic part of the E (2) Let ω : F × \A × F → C × denote the common central character of τ, π ♮ , and π. (The central characters are the same as they are equal at almost all places.) Since F is totally real, ω = ω 0 | · | a for a finite character ω 0 and a suitable a ∈ C. Since π ∞ is ξ-cohomological, we must have a = −w. Then π * x |sim| w/2 has unitary central character and is essentially tempered by Lemma 2.7. We are done since π * x ≃ τ x . Proposition 8.2. For almost all finite F-places v not dividing a prime number in S bad and all sufficiently large integers j, we have Tr ρ shim 2 (Frob . Moreover the virtual representation ρ shim 2 is a true representation.
For a ∈ Z ≥1 and m ∈ Z ≥1 let i a : GL m → GL am denote the block diagonal embedding.
Proof of Proposition 8.2. We imitate arguments from [Kot92a]. We consider a function f on G( where the components are chosen in the following way: This is possible since there are only finitely many such τ (one of which is π ♮ ).
There exists a finite set of primes Σ such that , and K Σ a product of hyperspecial subgroups. In the rest of the proof we consider The stabilized Langlands-Kottwitz formula (Theorem 7.3) simplifies as for the same reason as in the proof of Lemma 6.2 due to the special component at the place v St of the function f . Indeed f v St is a stabilizing function (Lemma A.7), thus the stable orbital integral of h H v St vanishes unless H = G * . Note that h G * v St can be chosen to be a Lefschetz function thanks to Lemma A.4. To interpret the above formula on the group G, we recall from Lemmas 6.1 and 6.2 that In the following we choose f in such a way that f G * and h G * have the same stable orbital integrals. Away from the places {v|p, ∞}, the functions f G * ,∞,p and h G * ,∞,p are both obtained from the endoscopic is obtained from φ j via the Frobenius twisted endoscopic transfer from φ j down to G * (F p ). Note that G is quasi-split at p, and thus G * (F p ) = G(F p ). The twisted endoscopic transfer H unr (G(F j )) → H unr (G(F p )) is (for the principal endoscopic group) equal to the unramified base change (use the explicit formula in [Kot90,p.179] that defines the twisted transfer). Therefore we may (and do) take h G * p = f j . Consequently, h G * and f G * have the same stable orbital integrals. By (8.6) and (8.7), we have On the right hand side we used that v Σ to obtain Tr . Applying (8.4) and (8.5), we identify the right hand side of (8.8) with By the choice of our function f the left hand side of (8.8) is equal to the trace of Frob It remains to show that ρ shim 2 is not just a virtual representation but a true representation. To this end we will show that ρ shim 2 is concentrated in the middle degree n(n + 1)/2. There are natural maps from H i c (S, L ξ ) to each of IH i (S, L ξ ) and H i (2) (S, L ξ ). Compatibility with Hecke correspondences implies that both maps are G(A ∞ F )-equivariant; the first map is moreover equivariant for the action of Γ (which commutes with the .
The diagram together with Lemma 8.1 yields a Γ-equivariant isomorphism In view of condition (cent), the intersection complex defined by ξ is pure of weight −w. Hence the action of On the other hand, part (2) of Lemma 8.1 (with v = y) implies that τ v |sim| w/2 = π ♮ v |sim| w/2 is tempered and unitary. Combining with (8.10) and (8.3), we conclude that IH i (S, L ξ )[τ ∞ ] = 0 unless i = n(n + 1)/2. The proof of the proposition is complete.
Remark 8.4. The last paragraph in the above proof simplifies significantly if F Q, in which case S K is proper (thus the compact support cohomology coincides with the intersection cohomology). We could have taken a slightly different path to prove our main results on Galois representations by first proving everything when F Q and then deal with the case F = Q by the patching argument of §14 below (thus avoiding Zucker's conjecture and arithmetic compactifications of S K ).
Proof. The preceding proof shows that H i Since τ ∞ is ξ-cohomological and unitary, we see from [SR99, Thm. 1.8] that τ ∞ must appear in the Vogan-Zuckerman classification given in [VZ84], where the authors compute the Lie algebra cohomology explicitly. It follows from this that τ ∞ is a discrete series representation, thus The G(A ∞ F )-equivariance is clear for the horizontal map, which is induced by the map from the extension-by-zero of L ξ to the Baily-Borel compactification to the intermediate extension thereof. For the vertical map it can be checked as follows (we thank Sophie Morel for the explanation). From the proof of Zucker's conjecture we know that IH i (S, L ξ ) and H i (2) (S, L ξ ) are represented by two complexes of sheaves on the Baily-Borel compactification which are quasi-isomorphic and become canonically isomorphic to L ξ when restricted to the original Shimura variety. The Hecke correspondences extend to the two complexes (so as to define Hecke actions on the intersection and L 2 -cohomologies) and coincide if restricted to the original Shimura variety. Now the point is that the Hecke correspondences extend uniquely for the intersection complex as follows from [Mor08, Lem. 5.1.3], so the same is true for the L 2 -complex via Zucker's conjecture. Therefore the Hecke actions on the two cohomologies are identified via the isomorphism of Zucker's conjecture.

Removing the unwanted multiplicity
Let π be a cuspidal ξ-cohomological automorphic representation of GSp 2n (A F ) satisfying (St) and (spinreg). We constructed in Section 7 a certain Shimura datum (G, X) depending on the place v St . Let π ♮ be the transfer of π to the inner form G(A F ) (Proposition 6.3). Using π ♮ we constructed in Section 8 a Galois representation ρ shim 2 of dimension a(π ♮ ) · 2 n . We want to get rid of the unwanted multiplicity a(π ♮ ). The traces in Proposition 8.2 suggest, but it is a priori not clear, that ρ shim 2 is the a(π ♮ )-th power of an irreducible representation ρ 2 . The goal of this section is to prove that this is actually the case. The main ingredient to remove the unwanted multiplicity is a lemma originating in a letter of Taylor to Clozel, which is recalled in the proof below and applicable only when ξ satisfies the spin-regularity condition (cf. Definition 1.3). (i) There exists a semisimple ℓ-adic representation ρ 2 : Γ → GL 2 n (Q ℓ ), unique up to isomorphism, such that Proof. Write a := a(π ♮ ). , with respect to some embedding j : F ֒→ Q ℓ , has 2 n distinct Hodge-Tate numbers each with multiplicity a. Recall the 2 n -dimensional representation ρ 1 from §3, cf. the diagram below. It is easy to see that ρ 1 has 2 n distinct Hodge-Tate numbers with respect to where v ∞ is the infinite place where φ ξ v is spin-regular. Indeed, in view of Diagram (9.1), it is enough to show that spin • ρ π ♭ has regular Hodge-Tate cocharacter with respect to ι • v ∞ . This follows from the spin-regularity condition via part (iii) of Theorem 2.4.
We claim that there exists a finite extension E/F such that (ρ shim 2 ) ss | Γ E and (i a • ρ 1 ) ss | Γ E are isomorphic up to a character twist. The claim implies the desired statement on the Hodge-Tate numbers of ρ shim 2 , finishing the proof of the lemma.
Let us prove the claim. We have a commutative diagram By Diagram (9.1), the projective representation i a • ρ 1 is also equal to By Theorem 2.4 we have for almost all finite F-places, In (9.3), and in Formulas (9.4)-(9.7) below, we mean with ∼ conjugacy with respect to the group indicated on the right hand side of the formula. By (9.3) as well. By combining Formula (9.4) with Formula (9.2) we get Restricting representations π ♭ v ⊂ π v is known to correspond, in the unramified case, to composition with the natural surjection of dual groups GSpin 2n+1 (Q ℓ ) ։ SO 2n+1 (Q ℓ ) (see, e.g. Bin Xu [Xua, Lem. 5.2]). Thus The last equation holds true for almost all finite F-places v, possibly further excluding finitely many places.

Galois representations with values in the GSpin group
Let π be a cuspidal automorphic representation of GSp 2n (A F ) satisfying the same conditions as at the start of §9. Denote by ω π its central character. We showed in Lemma 9.1 that there exists a 2 n -dimensional Galois representation ρ 2 : Γ → GL 2 n (Q ℓ ). In this section we combine the results from Sections 2-9 to show that the representation ρ 2 factors through the spin representation GSpin 2n+1 (Q ℓ ) → GL 2 n (Q ℓ ).
Denote by S bad the finite set of rational primes p such that either p = 2 or p is ramified in F or π v is ramified at a place v of F above p. (As we commented in introduction, it shouldn't be necessary to include p = 2 in view of [KMP].) In the theorem below the superscript C designates the C-normalization in the sense of [BG11]. Statement (ii)' of the theorem will be upgraded in the next section to include all v which are not above S bad ∪{ℓ}. In the following section (iii.c) of Theorem A will be shown, which will then complete the proof of Theorem A after switching back to the L-normalization. (i') For any automorphic Sp 2n (A F )-subrepresentation π ♭ of π, its associated Galois representation ρ π ♭ is isomor-  Proof. We have the automorphic representation π of GSp 2n (A F ). Consider • π ♭ ⊂ π a cuspidal automorphic Sp 2n (A F )-subrepresentation from Lemma 2.6; • π ♮ the transfer of π to the group G(A F ) from Proposition 6.3; • ρ π ♭ : Γ → SO 2n+1 (Q ℓ ) the Galois representation from Theorem 2.4; • ρ π ♭ a lift of ρ π ♭ to the group GSpin 2n+1 (Q ℓ ) from Proposition 3.5; • ρ 1 : Γ → GL 2 n (Q ℓ ) the composition of ρ π ♭ with the spin representation.
By Proposition 4.4 there exists a character χ : Γ → Q × ℓ such that ρ 2 is conjugate to ρ 1 ⊗ χ. By construction the representation ρ 1 has image inside GSpin 2n+1 (Q ℓ ), and consequently the representation ρ 2 has image in GSpin 2n+1 (Q ℓ ) as well. Thus ρ 2 induces a representation ρ C π : Γ → GSpin 2n+1 (Q ℓ ) such that ρ 2 = spin • ρ C π . Proposition 10.3 (Steinberg). In a semisimple algebraic group H over an algebraically closed field of characteristic 0, two semisimple elements are conjugate if and only if they are conjugate in all linear representations of H.
Remark 10.4. As a further precision to Proposition 10.3, Steinberg remarks at the end of [Ste78] that, for simply connected groups, it suffices to check conjugacy in the fundamental representations. If furthermore the group is of type B or D it suffices to check conjugacy in the spin representation (for simply connected types A and C it suffices to check conjugacy in the standard representation, cf. Proposition B.1).
We have the semisimple elements ρ C π (Frob v ) ss and ιφ π v (Frob v ) in GSpin 2n+1 (Q ℓ ). We know that spin(ρ C π (Frob v ) ss ) and q n(n+1)/4 v · spin(ιφ π v (Frob v )) are conjugate in GL 2 n (Q ℓ ) by Lemma 9.1. We claim that Once the claim is verified, by Corollary 10.5, ρ C π (Frob v ) ss is conjugate to q We prove the claim. Possibly after conjugation by an element of GL 2 n (Q ℓ ), the image of spin•ρ π lies in GO 2 n (resp. GSp 2 n ) if n(n + 1)/2 is even (resp. odd), for some symmetric (resp. symplectic) pairing on the underlying 2 n -dimensional space. Again by the same lemma, we may assume that spin(ιφ π v (Frob v )) also belongs to GO 2 n (resp. GSp 2 n ). Hereafter we let the central characters ω π or ω π v also denote the corresponding Galois characters via class field theory. For almost all v we have the following isomorphisms.
We show statement (i)'. It only remains to check the first part. By Theorem 2.4 and the preceding proof of (ii)', we have for almost all unramified places v that where we also used that the Satake parameter of the restricted representation π ♭ v ⊂ π v is equal to the composition of the Satake parameter of π v with the natural surjection GSpin 2n+1 (C) → SO 2n+1 (C) (cf. [Xua, Lem.
We prove statement (v). The first part follows from part (i) and Lemma 3.3. The second part is a consequence of Proposition 3.8 since spin • ρ C π is a character twist of ρ 1 .
The Galois representation in the cohomology H i (S K , L) is potentially semistable by Kisin [Kis02,Thm. 3.2]. The representation ρ C π appears in this cohomology and is therefore potentially semistable as well. This proves the first assertion of statement (iii).

Compatibility at unramified places
Let π be an automorphic representation of GSp 2n (A F ), satisfying the same conditions as in Section 9. In this section we identify the representation ρ π,v from Theorem 10.1 at all places v not above S bad ∪ {ℓ}.
Proposition 11.1. Let v be a finite F-place such that p := v| Q does not lie in S bad ∪ {ℓ}. Then ρ C π is unramified at v and ρ C π (Frob v ) ss is conjugate to the Satake parameter of ιφ π v |sim| −n(n+1)/4 Proof. Let π ♮ be a transfer of π to the inner form G(A F ) of GSp 2n (A F ) (Proposition 6.3). Let B(π ♮ ) be the set of cuspidal automorphic representations τ of G(A F ) such that • τ v St and π v St are isomorphic up to a twist by an unramified character, To compare with the definition of A(π ♮ ), notice that the condition at v is different. We define an equivalence relation ≈ on the set B(π ♮ ) by declaring that τ 1 ≈ τ 2 if and only if τ 2 ∈ A(τ 1 ) (hence, τ 1 ≈ τ 2 if and only if τ 1,v τ 2,v ). Define a (true) representation of Γ (see (8.1) for ρ shim 2 (τ), cf. Proposition 8.2 and Corollary 8.3) (11.1) ρ shim Recall the definition of a(τ) from (8.2). Define b(π ♮ ) := τ∈B(π ♮ )/≈ a(τ).
We know from 10.1 that each ρ 2 (τ) is strongly irreducible. Since ρ 2 (π ♮ ) and ρ 2 (τ) have the same Frobenius trace at almost all places for τ ∈ B(π ♮ ), we deduce from Corollary 8.3 that ρ 2 (π ♮ ) ≃ ρ 2 (τ). Hence We adapt the argument of Proposition 8.2 to the slightly different setting here. Consider the function f on where f ∞ and f v St are as in the proof of that proposition, and f ∞,v St ,v is such that, for all automorphic representations τ of G(A F ) with τ ∞,K 0 and Tr τ ∞ (f ∞ ) 0, we have (observe the slight difference between Equations (8.5) and (11.2) at the place v): Arguing as in the paragraph between (8.9) and (8.10), but with B(π ♮ ), b(π ♮ ), and ρ shim 3 in place of A(π ♮ ), a(π ♮ ), and ρ shim 2 , we obtain Tr (Frob where the last equality comes from (8.3). Thus the proof boils down to the next lemma (Lemma 11.2). Indeed the lemma and the last equality imply that Tr ρ 2 (π ♮ )(Frob As in the proof of Theorem 10.1, since ρ 2 (π ♮ ) = spin • ρ C π by construction, this shows that the semisimple parts of Lemma 11.2. With the above notation, Proof. Let τ * and π * denote transfers of τ and π ♮ from G to GSp 2n via part (2) of Proposition 6.3; the assumption there is satisfied by Corollary 8.5 (in fact we can just take π * to be π). In particular τ * x ≃ τ x and π * x ≃ π ♮ x at all finite places x where τ x and π ♮ x are unramified). In particular this is true for x = v, so it suffices to show that τ * v ≃ π * v . By [Xua, Thm. 1.8] we see that τ * and π * belong to global L-packets Π 1 = ⊗ x Π 1,x and Π 2 = ⊗ x Π 2,x (as constructed in that paper), respectively, such that Π 1 = Π 2 ⊗ ω for a quadratic Hecke character ω : F × \A × F → {±1} (which is lifted to a character of GSp 2n (A F ) via the similitude character). Since each local L-packet has at most one unramified representation by [Xua,Prop. 4.4.(3)] we see that for almost all finite places x, we have x by the initial assumption at almost all x.) This implies through (ii') of Theorem 10.1 that spin(ρ π ) ≃ spin(ρ π ) ⊗ ω (viewing ω as a Galois character via class field theory). Since spin(ρ π ) is strongly irreducible by the same theorem, it follows that ω = 1. Hence the unramified representations τ * v and π * v belong to the same local L-packet, implying that τ * v ≃ π * v as desired.

Proof of crystallineness
In this section we prove that ρ C π is crystalline at v|ℓ when ℓ S bad . (This was shown in Theorem 10.1 only up to an unspecified quadratic character.) The first step of the proof is to reduce the problem to an auxiliary datum (H δ , Y δ ) of Hodge type with H der δ = G der . In the second step we adapt some well-known arguments from the PEL case (e.g. [HT01, III.2], [TY07, p.477]) to the Hodge type case. Theorem A will be fully established at the end of this section.
Let D be the quaternion algebra over F, unique up to isomorphism, which exactly ramifies at all v ∈ V ∞ \{v ∞ } and no finite places (resp. at no finite places other than v St ) if [F : Q] is odd (resp. even). Let δ be a negative element of Q and fix a square root √ δ ∈ C of δ. Then E δ := F( √ δ) is a CM quadratic extension of F. Let z → z c denote the complex conjugation on E δ . Write T δ for the torus Res E δ /Q G m . Inside T δ we have the subtorus U δ defined by the equation z c z = 1. The center Z of G is the torus G m,F . Write T := Res F/Q G m . We define the amalgated product G δ := (Res F/Q G) * T T δ , defined by taking the quotient of (Res F/Q G) × T δ by the action of T via the formula z · (g, t) = (gz, z −1 t), for all Q-algebras R, where z ∈ T (R), g ∈ Res F/Q G(R), and t ∈ T δ (R). We define the morphism sim δ : G δ → T × U δ by (g, t) → (sim(g)tt c , t/t c ). Define H δ to be the inverse image under sim δ of the subtorus G m × U δ ⊂ T × U δ . The kernel of sim δ is identified with the derived subgroup of Res F/Q G. Moreover the map t → t/t c from T δ to U δ is onto. Thus we have the following commutative diagram with exact rows.
and Res F/Q G der = (H δ ) der = (G δ ) der . We define the hermitian symmetric domain for H δ . If v ∈ V ∞ is an embedding F → R, we extend it to the embedding v δ : We define the morphism h T δ : C × → T δ (R) by h T δ (z) = (1, z, . . . , z) ∈ v∈V ∞ C × for all z ∈ C × (the first coordinate corresponds to the fixed place v ∞ ∈ V ∞ ). Define the morphism . It is straight forward to see that h δ has image in H δ,R . The resulting map C × → G δ (R) is again denoted by h δ . Write Y δ for the H δ (R)-conjugacy class of h δ . It is routine to check that (H δ , Y δ ) is a Shimura datum, which is of abelian type since the reductive group is of type C. This also follows from Lemma 12.2 below.
We would like to check that (H δ , Y δ ) is moreover of Hodge type. Put D δ := D ⊗ F E δ . Let l → l be the involution of the second kind, which is the tensor product of the canonical involution on D with the conjugation c on E δ . Choose ε ∈ D an invertible element with ε = ε (ε will be specified later). We define l * = ε −1 lε, for l ∈ D δ . Then l → l * is an involution of the second kind on D. Let W be the left D δ -module whose underlying space is D n δ on which D δ acts via left multiplication. We define a pairing (12.1) where Tr D δ /E δ is the reduced trace, and v * ,t is the transpose of the vector v * obtained from v by applying * on each coordinate. Then ψ δ,ε is a non-degenerate alternating form on W , and we have for all l ∈ D δ the relation ψ δ,ε (lv, w) = ψ δ,ε (v, l * w).

Lemma 12.1. There is an inclusion
Proof. To construct the desired map we start by realizing G as a concrete matrix group. We introduce an F-linear paring (where t means transpose), t εw).
Define the group G(D n , ψ ε ) over F whose set of R-points over each F-algebra R is given by The equality ψ ε (gv, gw) = λ(g)ψ ε (v, w) is equivalent to g * ǫg = λ(g)ǫ, or to gg = λ(g). (Since GL D (D n ⊗ F R) ≃ GL n (D op ⊗ F R), the left multiplication of g on v and w becomes the right multiplication if g is viewed as an element of GL n (D ⊗ F R).) We claim that, as algebraic groups over F, G G(D n , ψ ε ).
Suppose that F ′ is an extension field of F such that D ⊗ F F ′ ≃ M 2 (F ′ ). The canonical involution l → l on D goes to the canonical involution m → 0 1 −1 0 t m 0 −1 1 0 on M 2 (F ′ ) up to conjugation. From this it is evident that G(D n , ψ ε ) is isomorphic to GSp 2n over F ′ . Taking F ′ = F we see that G(D n , ψ ε ) is a form of the split group GSp 2n over F, which then should be an inner form (as GSp 2n has no nontrivial outer form). If v is a place of F such that D splits at v then G(D n , ψ ε ) ≃ GSp 2n over F v . If v is an infinite place different from v ∞ then D v is the Hamitonian quaternion algebra over R. In this case it is standard that G(D n , ψ ε )(F v ) is compact modulo center. (The subgroup on which λ = 1 is the compact from of Sp 2n (R).) This determines the local invariant classifying G(D n , ψ ε ) as an inner form of GSp 2n at all places but v St . This suffices to determine the invariant of G(D n , ψ ε ) at v St from (7.1). Since ker 1 (F, PSp 2n ) = 1 we conclude that G G(D n , ψ ε ) over F.
Carayol shows in [Car86a, 2.2.4] that, for a particular choice of ε, the paring D δ × D δ → Q defined by the same formula as in (12.1) is a polarization of the Hodge structure We fix henceforth this choice of ǫ. Then (W ⊗ R, ψ δ,ε , h δ ) is a polarized Hodge structure as well. In particular the map ψ from Lemma 12.1 induces an embedding of (H δ , Y δ ) into the Siegel Shimura datum for GSp Q (W , ψ δ Suppose that (G, K) is unramified at ℓ and that ℓ S bad . Then ρ C π is crystalline at the places dividing ℓ.
Proof. Since spin • ρ C π appears as a subspace of H j c (S K , L ξ ) (for j = n(n + 1)/2), it is enough to show that the Γ-representation H j c (S K , L ξ ) is crystalline at the ℓ-adic places for j ≥ 0. This is immediate if L ξ is a constant sheaf (i.e. if ξ is trivial) but we will treat the general case by a more involved argument by reducing to the crystallineness of the universal abelian scheme over the Hodge-type Shimura varieties associated with (H δ , Y δ ).
Step 0. Preliminaries. Let v be an F-place dividing ℓ. We start by fixing the choice of the negative element δ ∈ Q such that Q( √ δ)/Q is split above ℓ. Then E δ = F( √ δ) is split above v. Write Γ E δ = Gal(Q/E δ ). We may identify the local Galois groups Γ E δ ,v δ = Γ v . Since ℓ is unramified in E δ (ℓ is unramified in F because ℓ S bad ), the groups G δ and H δ are unramified over Q ℓ . Let K G δ ,ℓ be the image of K × (O F ⊗ Z Z ℓ ) × in G δ (Q ℓ ). Then K G δ,ℓ is a hyperspecial subgroup of G δ (Q ℓ ) and K H δ ,ℓ := K G δ ,ℓ ∩H δ (Q ℓ ) is a hyperspecial subgroup of H δ (Q p ). Note that K H δ,ℓ ∩ H der δ (Q ℓ ) = K ℓ ∩ G der (F ℓ ) via H der δ = Res F/Q G der . We extend the representation ξ = ⊗ y|∞ ξ y of (Res F/Q G) C to a representation of the larger group G δ ⊃ Res F/Q G, with values in GL N ,C . Let, for each infinite place y of F, ω y : G m,C → G m,C be the central character of ξ y . Condition (cent) tells us that the central character ω of ξ is the base change to C of the character F × → C × given by x → x w . We extend this character to E × δ using the same formula: ω + : E × δ → C × , x → x w . Let g ∈ Res F/Q G(C) and t ∈ T δ (C), then the formula ξ G δ (g, t) = ξ(g)ω + C (t) gives a well-defined representation ξ G δ : G δ,C → GL N ,C extending ξ on (Res F/Q G) C . The restriction of ξ G δ to H δ,C is to be denoted by ξ H δ .
Let S K H δ denote the Shimura variety attached to the datum (H δ , Y δ , K H δ ), defined over the same reflex field F. Write ξ G δ ,ℓ for the composition of ξ G δ (Q ℓ , ι) : . Define ξ ℓ (resp. ξ H δ ,ℓ ) to be the restriction of ξ G δ ,ℓ to (Res F/Q G)(A ∞ ) (resp. H δ (A ∞ )). Let us recall that the ℓ-adic local system L ξ is defined as follows. The composite map where the second map is the projection onto the ℓ-component, is trivial on Z(F) ∩ K and thus on the closure It is standard, as explained in [Car86b, 2.1.4], to construct a lisse Q ℓ -sheaf L ξ on S K from (12.4) using the fact that the Galois group of S K ′ over S K has Galois group K/K (For the construction we need to know that ξ ℓ is trivial Step 1. Reduction where K der := K ∩ G der (A ∞ F )/K ∩ Z der (A ∞ F ) and Z der := Z ∩ G der . Again the analogue is true for the Galois group of S + H δ over S +

K H δ
. The lisse sheaf L + ξ ℓ (resp. L + ξ H δ ,ℓ ) corresponds to the representation of K der ∩ A (Res F/Q G der ) • (resp. K der H δ ∩ A (H der δ ) • ) given by the projection onto the ℓ-component followed by ξ ℓ (resp. ξ H δ ,ℓ ). Now the claim results from the fact that ξ = ξ H δ on Res F/Q G der = H der δ over C.
for all j ≥ 0 as Gal(F/F ℓ )-modules if (12.7) holds. By (12.6) we know that S K is isomorphic to the product of finitely many copies of S + K as F ℓ -schemes. Since the crystallineness of a Galois representation depends only on the restriction to the inertia subgroup [Fon94, Exposé III, 5.1.5], under hypothesis (12.7), we deduce that H For our purpose, it remains to see that given a sufficiently small K, there exists K H δ (possibly after shrinking K) such that (12.7) is satisfied. To this end, write K = K S K S for a finite set of rational primes S excluding ℓ but including all ramified primes of the extension Q( at each finite prime v away from S. (This construction is symmetric so that one can start from K H δ and find K such that (12.7) is true.) Step 2. Proof of crystallineness for Hodge type. Henceforth we concentrate on verifying that H On the other hand, let ξ std = std • ψ be the representation H δ → GSp 2m ⊂ GL 2m . Then ξ std satisfies the condition (cent). Let L std = L std,K H δ be the ℓ-adic local system on S K H δ attached to ξ std . Then we have Write V for the underlying 2m-dimensional vector space of the representation ξ std . Since there exist integers k 1 , k 2 ∈ Z ≥0 such that the representation ξ H δ appears as a direct summand of the representation V ⊗k 1 ⊗ (V ∨ ) ⊗k 2 (see [DMOS82, Prop. I.3.1]), we obtain an inclusion of local systems as a direct summand:

Now it is clearly enough to show that H
To this end, we intend to employ the Γ E δ -equivariant Leray spectral sequence Step 2 -term in (12.8) is pure of weight p + q at almost all finite places of E δ (away from ℓ). Therefore H j (S K H δ , R q s * Q ℓ ) for j ≥ 0 is crystalline as desired.

The eigenvariety
In this section we make the first step to remove the spin-regularity assumption in Theorem A. We use the eigenvariety of Loeffler [Loe11]. See also [Tai15,Che04,Che09,BC09], from which we copied many arguments. Moreover, Daniel Snaith wrote his PhD thesis [Sna] about overconvergent automorphic forms for GSp 2n .
Fix a finite F-place v St and let π be a cohomogical cuspidal automorphic representation of GSp 2n (A F ) satisfying (St) at the place v St . The goal of this section is to construct, under technical assumptions (Even) and (Aux ℓ -1,2), the Galois representation ρ C π : Γ → GSpin 2n+1 (Q ℓ ) attached to π by approximating π with points on the eigenvariety satisfying conditions (St), (L-Coh) and which are spin-regular at a certain infinite place v ∞ .
Our exposition is somewhat complicated by some technical issue coming from the center (which is GL 1 over F) when trying to ensure that classical points are Zariski dense on the eigenvariety. To get around the issue we basically work over the weight space on which the center acts through a finite quotient.

Assumptions. Throughout this section we assume
(Even) The degree [F : Q] is even. (Aux ℓ -1) There exists an embedding λ : F → Q ℓ , which induces an F-prime v λ above ℓ with v λ v St .
(If v St ∤ ℓ, this condition is void. If v St |ℓ, the requirement is that there are at least two F-places above ℓ); (Aux ℓ -2) The representation π λ has an invariant vector under the upper triangular Iwahori group I λ of GSp 2n (F λ ).

Notation.
We begin with a list of notation. • is a finite Galois extension contained in Q ℓ , large enough so that E contains all the images of the elements of Hom Q (F, Q ℓ ) and ξ ⊗ ι Q ℓ can be defined over E. • If X is a rigid variety over E, we write X (Q ℓ ) for the set X (E ′ ) where E ′ ranges over the finite extensions of E contained in Q ℓ . If x ∈ X is a point, we write κ(x) for the residue field at x. We write |X | for the set of closed points in X . • If v is a finite F-place we write κ(v) for the residue field at v and q v = #κ(v).
• By (Even), there exists an inner form G c /F of GSp 2n,F which is anisotropic modulo center at infinity and split at all finite F-places (Section 7). We identify • We normalize the Haar measure on G c (A F ) such that GSp 2n ( O F ) ⊂ G c (A ∞ F ) has volume 1, and the compact group G c (F ⊗ R) has total volume 1.
• Let c ∈ Z 1 (Γ, PSp 2n ) be the cocycle that defines the form G c of GSp 2n,F . • We write T for a maximal torus of G c that corresponds to the diagonal torus in GSp 2n,F at the finite place λ. We define • S bad is the finite set of prime numbers p different from ℓ and such that K p = v|p K v is not hyperspecial.
• We write S = S F,bad for the set of F-places that are either infinite, finite and above a prime number in S bad , or the finite place λ. • Write Γ S = Gal(F S /F) where F S ⊂ Q is the maximal extension of F that is unramified away from S.
• H(G c (F λ )/ /I λ , E) is the algebra of E-valued functions on the double cosets G c (F λ )/ /I λ .
• H + λ is the subalgebra of H(G c (F λ )/ /I λ , E) generated by the characteristic functions of double cosets of the form I λ ς(̟ λ )I λ , where ς ranges over the elements of X * (T ) such that α, ς ≥ 0 for all P-positive roots α of G c (F λ ) = GSp 2n (Q ℓ ).
• V π,alg /E is the one-dimensional T (O F λ )-representation given by taking the O F λ -points of the highest weight of the representation ξ. By [Loe11, Lem. 3.9.3] there exists a smooth character V π,sm such that e λ (V sm,k ⊗ π λ ) 0, for large enough k. Define V π = V π,alg ⊗ V π,sm . • The integer k(V π ) is the least integer k such that the representation V π is k-analytic, i.e. the corresponding character T (O F λ ) → E × is analytic on the cosets of T k , i.e. all the vectors in the representation space are k-analytic in the sense of [Loe11, sect. 2.2].
We call a weight w ∈ X * (T ) dominant if the corresponding integers have k 1 ≥ k 2 ≥ . . . ≥ k n ≥ 0 (no condition on c). We write X * (T 1 ) dom = X * (T 1 ) ∩ X * (T ) dom . We call w dominant regular if the inequalities are strict: k 1 > k 2 > . . . > k n > 0. We write X * (T ) dom,reg for the dominant regular weights.
• I ⊂ G(F λ ) is the monoid generated by the group I λ and the elements µ(̟ λ ) for µ ∈ X * (T ) dom,reg .
• Let Φ + (resp. ∆) be the set of positive (resp. simple) roots of G c,F λ = GSp 2n,Q ℓ and write ρ for 1 2 α∈Φ + α ∈ X * (T ). [Eme,sect. 6.4], W T is representable by a rigid space over E. This space is the weight space. To simplify notation, we often write W = W T and W 1 = W T 1 .

The Weight Spaces W and W arith . For each affinoid E-algebra A, define W T (A) to be the set of locally
Let A be an affinoid algebra. In (ii), we call w alg the algebraic part of w. We write W alg ⊂ W l-alg for the subsets of |W | corresponding to (i) and (ii). We write W arith (A) (resp. W f (A)) for the set of arithmetical (resp. finite on the center) A × -valued weights of T (O F λ ). Loeffler shows [Loe11, Prop. 3.6.2] that W arith (resp. W f ) is representable by a rigid analytic space over E. If ⋆ ⊂ {alg, l-alg, arith, f} is some subset, then we write W ⋆ = i∈⋆ |W i |.
We will later see that the eigenvariety covers the weight space W arith . If F Q the (locally) algebraic points are not dense in W arith . In fact W f ⊂ W arith is closed, and because any U ⊂ Z(O F ) of finite index is Zariski dense, we have W arith,l-alg = |W f |.
We call a subset C ⊂ X * (T 1 )⊗R an affine cone if there exist an integer d ∈ Z ≥0 , linear functionals φ 1 , . . . , φ d ∈ (X * (T 1 ) ⊗ R) * , and positive real numbers c 1 , . . . , c d ∈ R >0 , such that If C ⊂ X * (T 1 ) ⊗ R is a affine cone and ⋆ ⊂ {alg, arith, f} a subset, we write W l-alg,⋆ C ⊂ W l-alg,⋆ for the set of weights w ∈ W l-alg,⋆ whose algebraic part w alg ∈ X * (T ) Density of (Locally) Algebraic Points. We recall the notions "Zariski dense" and "accumulate". Let X be a rigid space over E, S ⊂ |X | a subset. We call the set S ⊂ |X | Zariski dense if for every analytical closed subspace F ⊂ X with S ⊂ |F | we have F red = X red . Let x ∈ X be a point. Then S accumulates at x if there is a basis of affinoid neighborhoods B x of x such that for each U ∈ B x the set S ∩ |U | is Zariski dense in U . If ⋆ ⊂ {alg, l-alg, arith, f} is a subset, then we write W ⋆,E ⊂ |W ⋆ | for the set of those weights w ∈ |W ⋆ | whose image lies in E × ⊂ Q × ℓ .
Lemma 13.3. Let C ⊂ X * (T 1 ) R be a non-empty affine cone. Let X be an irreducible component of W f . The subset W f,l-alg,E C ∩ |X | ⊂ |X | is Zariski dense and accumulates at the set W f,l-alg,E ∩ |X |.
Proof. We reduce the lemma to the weight space of Z × T 1 . We have the following sequence on weight spaces We show that the map ψ surjects onto the space W f,diag we can choose square roots w(x 2 1 ) 1/2 , . . . , w(x 2 d ) 1/2 ∈ Q × ℓ , and use these to extend w to a morphism w : is open, w is locally analytic as soon as w is locally analytic. Finally, if w is finite on the center, then so is w.
The subspace W f,diag Z×T 1 ⊂ W f Z×T 1 is closed and also open because it is the complement of a closed subset:

Thus the image of ψ is a union of connected components.
We show that ψ is locally an open immersion. Let ε > 0 be a positive number.
If moreover ε < |w(x)|, then |t ′ | < |w(x)| thus |w(x) + t ′ | = |w(x)| and hence |u(x)/u ′ (x) − 1| < ε/|w(x)|. Thus, by taking ε sufficiently small, u(x)/u ′ (x) lies in an arbitrarily small neighborhood of 1, and we can make sure that this neighborhood does not contain −1 for any x ∈ {x 1 , x 2 , . . . , x d }. Consequently, the mapping Hence the set ψ(W Spaces of ℓ-adic automorphic forms. Let R be an E-algebra and W be an R-module with left I-action. We define  as O rig (U ′ )-Banach module, and this isomorphism is compatible with eH + (G c )e-action. (iv) If T ∈ eH + (G)e is supported in ∪ µ∈X * (T ) dom,reg I λ µ(̟ λ )I λ , and k ∈ Z ≥1 is such that k ≥ max(k(U ), k(U ′ )), then the action of T on M(e, U , V π , W ∞ , k + 1) in fact defines a continuous map T k : M(e, U , V π , W ∞ , k + 1) → M(e, U , V π , W ∞ , k); and if k ≥ max(k(U ), k(U ′ )) + 1, we have a commutative diagram where i k is as above. In particular, the endomorphism of M(e, U , V π , W ∞ , k) defined by T is compact.
Proof. Properties (i) to (iv) are proved in Theorem 3.7.2 of [Loe11] and Property (v) is Corollary 3.7.3 in Loeffler.
We should mention that Loeffler works with a slightly different space of ℓ-adic automorphic forms (the space where W ∞ is the trivial representation). However, his proofs are valid also in our context.
The Eigenvariety. Using the spaces of ℓ-adic automorphic forms from the previous subsection we construct an adjustment of the eigenvariety by Loeffler from [Loe11] for the group G c over the field F with respect to the finite prime p := λ, the parabolic subgroup equal to P defined above (which is just the upper triangular Borel subgroup of G c,F λ = GSp 2n,Q ℓ ) and the locally algebraic representation V π as selected above. Let us explain why the adjustment is needed. In Loeffler's setting for the group G c , classical points on the eigenvariety correspond to automorphic representations that are cohomological for the algebraic representation v|∞ GSp 2n (C) (see [Loe11,Def. 3.8.2]). Consequently, if τ is a cohomological automorphic representation corresponding to a classical point on Loeffler's eigenvariety, the representation τ v (v v ∞ ) is in the lowest weight discrete L-packet. Thus π need not define a point on the eigenvariety, and can't always be interpolated. It is possible to use Loeffler's eigenvariety for the group Res F/Q G c over Q (instead of G c over F); then π will define a point. However, in this case the Hodge-Tate weights vary at all infinite places, hence the required Hodge-Tate results in families are not available  only consider families in which the Hodge-Tate numbers lie in a bounded interval). Fortunately, Chenevier had to deal with a similar issue in [Che09] for eigenvarieties for unitairy groups. We follow his approach by introducing ℓ-adic automorphic forms that are cohomological for the fixed representation W ∞ at the infinite places v v ∞ . In this context we are able to both prove Lemma 13.16 and find a classical point on the eigenvariety corresponding to π.
We are currently in the following situation. For each affinoid U ⊂ W arith we have the Banach module M = M(e, U , V π , W ∞ , k) over O rig (U ) satisfying (Pr), the commutative algebra T with an action on M, the compact operator 1 I λ ηI λ acting as a compact endomorphism on M. [Loe11,Def. 3.11.5]). These links satisfy the compatibility condition α U 2 U 3 α U 1 U 2 = α U 1 U 3 whenever U 1 ⊃ U 2 ⊃ U 3 are affinoid subdomains of W arith (see [Loe11,Lem. 3.12.2]).
Let E ′ /E be a discretely valued extension, and let U ⊂ W be an open affinoid or a point. By definition an E-algebra morphism β : In [Loe11, sect. 3.9] Loeffler investigates the classical subspaces of the spaces of overconvergent automorphic forms corresponding to the fibers of E → W arith above points of U ⊂ W arith that are locally algebraic. If We define the classical subspace . For the definition of the space of k-analytic vectors in the induced representation Ind(V π ⊗w) we refer to [Loe11,§2.2,p.198] where the direct sum ranges over all automorphic representations π of G c (F ∞ ) and m(π) is the multiplicity of π in the discrete spectrum of L 2 -automorphic forms on G c (A F ) (with fixed central character). In particular, only the W ∞ -allowable π contribute.
Theorem 13.5 ( [Loe11, Cor. 3.9.4]). Let τ be an W ∞ -allowable automorphic representation of G c (A F ) such that τ λ is isomorphic to a subquotient of a representation that is parabolically induced from P. Assume e λ τ λ 0. Then there exists a locally algebraic character V τ of T (O F λ ) and, for all k ≥ k(χ), a non-zero H + -invariant finite slope subspace of M(e, 1, V τ , W ∞ , k) cl , which is isomorphic as an e λ H +λ e λ -module to a direct sum of copies of e λ τ λ .
Let τ be an W ∞ -allowable automorphic representation of G c (A F ). Then we say that τ corresponds to the point c ∈ E (E) if the E-valued system of eigenvalues β c : T → E attached to c satisfies β c (T ) = ιTr τ S (T ) ∈ Q ℓ for all T ∈ T. Note that for given τ there could exist several corresponding c, and vice-versa. We call a point c ∈ E (E) classical if it corresponds to an W ∞ -allowable automorphic representation. We write E cl ⊂ |E | for the subset of all classical points. We have ζ(E cl ) ⊂ W l-alg,E .
We now seek to classify the classical points that arise in E cl . Let τ be an automorphic representation of G c (A F ) such that τ K λ I λ 0, τ ∞ is W ∞ -allowable with respect to an algebraic representation W alg of G c (F v ∞ ). Since τ I λ λ 0, the representation τ λ is isomorphic to a subquotient of a parabolically induced representation from P. Following Loeffler's proof for Theorem 13.5, we get the following construction for V τ . We have (ι(W alg ) ⊗ τ ∞ ) G(F v ∞ ) 0. By highest weight theory, W alg arises from parabolic induction from some algebraic character V τ,alg of T (O F λ ). By [Loe11, Lem. 3.9.3] there exists a smooth character V τ,sm such that e λ (U sm,k ⊗ τ λ ) 0, for large enough k. (Here U sm is a representation induced from V τ,sm . See loc. cit. for the precise definition.) Then we take V τ = V τ,alg ⊗ V τ,sm . Then Loeffler shows that, as e λ H +λ e λ -module, τ appears in M(e, 1, V τ , W ∞ , k) cl ). We obtain the following criterion: Proposition 13.6. If V τ = V π ⊗ w for some w ∈ W f , then there exists a classical point c ∈ E cl corresponding to τ.
By Proposition 13.6 the set of classical points c ∈ E f,cl on the eigenvariety corresponding to the automorphic representation π that was fixed at the beginning of the section (p. 36) is non-empty (take w = 1). We fix once and for all a choice of such a point c π ∈ E cl .
Theorem 13.7 (Loeffler). Let w ∈ W f,l-alg,E dom , and let w alg ∈ W f,alg dom be the algebraic part of w.
Let C ⊂ X * (T 1 ) ⊗ R be an affine cone. We call the cone C admissible if C ∩ C M ∅ for all sufficiently large integers M. We write E cl C for the set of all c ∈ E cl whose weight lies in W f,l-alg,E C .
We put E f,cl = E f ∩ E cl and . Assume that C ⊂ X * (T 1 ) ⊗ R is an admissible affine cone. Let X be a component of W f . The subset E f,cl C ∩ ζ −1 |X | ⊂ ζ −1 X is Zariski dense and accumulates at the set of classical points E f,cl ∩ ζ −1 |X |.
Proof. We prove the theorem by copying Loeffler's argument, taking into account the adjustment that we work with E f instead of E (otherwise our Theorem 13.8 would be false as stated). Moreover, Loeffler does not state the accumulation property.
Let Z be the spectral variety attached to the choices η, e λ and V π . Let E f X (resp. Z f X ) be the preimages in E f (resp. Z f = Z × W arith W f ) of the irreducible component X . We have a finite map µ = µ X : E f X → Z f X and the usual projections onto weight space ζ = ζ X : E f X → X and δ = δ X : Z f X → X . These maps satisfy the compatibility ζ = δ • µ. ∩ δ(Z f,0 X ). Let z be a point in Z f,0 X lying above w, so that δ(z) = w. By the construction of the spectral variety, Z f has a cover by affinoids U such that U ′ = δ(U ) is affinoid in X , δ : U → U ′ is finite and flat, and U is a connected component of δ −1 (U ′ ). Fix a U in 13 We should mention that Taïbi [Taï12, §3.2] points out a small error in the proof of Loeffler's theorem 3.9.6 in case the group is non-split at λ. Since G c is split at λ, Loeffler's theorem is correct in our setting. Taïbi corrects Loeffler's result for groups that are only quasi-split at ℓ; see [Taï12, Lem. 3.2.1] and the discussion there. this cover that contains z. Since U is quasi-compact and Ψ(1 I λ ηI λ ) does not vanish on µ −1 (U ), the function ord ℓ Ψ(η) has a supremum M. Let C M be the cone defined in (13.2). By definition of C M , if w ∈ W f,l-alg,E C M then −(1 + α ∨ (w alg )) · v ℓ (α(η)) > M for all roots α ∈ ∆. By Lemma 13.3 there exists an affinoid U ′′ ⊂ U ′ such that By the classicality criterion, Theorem 13.7, the intersection Y ∩ ζ −1 Because the irreducible component Z f,0 is arbitrary, the first part of the theorem follows.
The argument for the accumulation property is similar: Assume c ∈ E f,cl ; let w be the weight of c, and z be the image of c in the spectral variety. Let U , U ′ be as in the above proof. Consider the U ′′ ⊂ U ′ such that . Then E f,cl C is contained in E f,cl ⋆ and the corollary follows from Theorem 13.8 and Lemma 13.3.

Galois representations at classical points.
Let ς : G m → GSp 2n be a dominant cocharacter (with respect to the upper triangular Borel subgroup). Let η ς be the highest weight representation of GSpin 2n+1 attached to ς. Consider the subalgebra T O E ⊂ T of functions which take values in the ring of integers O E (rather than just E).
For each finite F-place v S, define χ ς = ι(q ρ,ς v ) · Tr η ς in the ring Q ℓ [ T ] W of W -invariant regular functions on T over Q ℓ , where W is the Weyl group of T and T is the dual torus of T . Let v be a finite F-place which is not in S. Write S for the Satake transform from H( where ̟ v ∈ F v is a uniformizer at v and the coefficients d ς (µ) are integers. We define the Hecke operator Let c ∈ |E f | be a point and β its corresponding system of eigenvalues. Assume that η ς is highest weight representation of GSpin 2n+1 with ς ∈ X * ( T ) + . Write N = dim(η ς ). We say that c has a Galois representation at ς if there exists a representation ρ ς c : Γ S → GL N (Q ℓ ) which is unramified away from S and such that Tr ρ ς c (Frob v ) = β(T ς (v)) for all v S.

Interpolating Galois representations.
Let ς : G m → GSp 2n be a dominant cocharacter (with respect to the upper triangular Borel subgroup). Let η ς be the highest weight representation of GSpin 2n+1 attached to ς. Let f : X → E f be a morphism of rigid spaces with X reduced. Let C ⊂ f −1 (E f,cl ) be a subset of points such that each point c ∈ C has a Galois representation for ς and C ⊂ X is Zariski dense.
Proposition 13.10 (Chenevier). There exists a continuous pseudocharacter T η of Γ S with values in O rig (X ) such that at every c ∈ C the pseudocharacter T η specializes to the trace character of ρ ς c .
Remark 13.11. On the ring O rig (X ) we put the coarsest locally convex topology such that all the restriction maps O rig (X ) → O rig (U ), U ⊂ X affinoid subdomain, are continuous, where O rig (U ) is equipped with its usual Banach algebra topology (cf. [BC09,Def. 4

.2.2]).
Proof. Using [Loe11, Prop. 3.3.3, Prop. 3.5.2] we see that and moreover Ψ : We check that the ring O rig (E f ) ≤1 is compact. Bellaiche-Chenevier define [BC09, Def. 7.2.10] that a rigid analytic space Y over Q ℓ is nested if it has an admissible covering by open affinoids They mention that any finite product of nested spaces is again nested, and A 1 and G m are nested spaces. Moreover, any space that is finite over a nested space is again nested [BC09, 7.2.11.(i)]. Loeffler shows in [Loe11, Prop. 3.6.2] that W arith is finite étale over a rigid ball. Consequently W arith is nested. Since, by point (i), the eigenvariety E f is finite over W arith × G m , it is nested. Bellaiche-Chenevier show [BC09, 7.2.11.(ii)] that for any reduced and nested rigid analytic space Y , the ring of bounded The rigid space X need not be nested, so there is no a priori reason that O rig (X ) ≤1 is compact. However, )) c∈C ∈ c∈C Q ℓ lies in the image of i. Since i • ψ : H → c∈C Q ℓ is injective, has closed image, and the Frobenius elements are dense in Γ S , i • ψ induces a map T η from Γ S to O rig (X ). The map T η is easily checked to be a pseudocharacter (check it on the dense subset C ⊂ |X |).
Step 1. Construct the pseudocharacter for the standard representation and the spinor norm, and construct also corresponding big Galois representations on (covers of parts of) the eigenvariety. Let c be a classical point in E f such that one of the corresponding automorphic representations τ c of G c (A F ) is cohomological for an algebraic representation ξ c of (Res F/Q G) C whose highest weight maps to a regular weight of GL 2n+1 (Q ℓ ) under the standard representation GSpin 2n+1 (Q ℓ ) → GL 2n+1 (Q ℓ ) (which factors through SO 2n+1 (Q ℓ )). Choose τ ♭ c ⊂ τ c an automorphic representation of G 1 c (A F ) contained in τ c . By Taïbi's recent result [Tai15] we can attach a (formal) Arthur parameter ψ c to τ ♭ c . As in the quasi-split case, cf. Lemma 2.1 and Corollary 2.2, the parameter ψ c is simple and generic, and thus given by a self-dual unitary cuspidal automorphic representation τ We are now in place to interpolate the standard representation. By Corollary 13.9 the subset E f,cl std ⊂ E f is Zariski dense. Take X = E f , f = id : E f → E f and C = E f,cl std . Then Equation (13.4) shows that each classical point c ∈ E f,cl std has a Galois representation for 'std' (cf. below (13.3)). By Proposition 13.10 there exist unique continuous pseudocharacter T std : Γ S → O rig (E f ) such that for all c ∈ E f,cl std we have T std,c = Tr (ρ std c ) at the residue field κ(c) of c ∈ E f,cl std . Even though we have not yet constructed the Galois representation ρ C c : Γ S → GSpin 2n+1 (Q ℓ ) for a dense set of classical points, its spinor norm N • ρ C c is easily constructed using class field theory and the central character of τ c for c ∈ E f,cl (cf. Theorem A.(i)). By interpolating we obtain the character T N : Let x ∈ E f be a point, κ(x) the residue field at x and let κ(x) be an algebraic closure of κ(x). We may (and often do) identify κ(x) Q ℓ as E-algebras. By Taylor's theorem [Tay91, Thm. 1], the pseudocharacter T std ⊗ κ(x) arises from the trace of a Galois representation r std,x : Γ S → GL 2n+1 (κ(x)). We write E f irr ⊂ |E f | for the locus of those x ∈ |E f | such that r std,x is (absolutely) irreducible.
Lemma 13.12 (Chenevier, cf 1 , σ 2 , . . . , σ m 2 ∈ Γ S (with m = 2n + 1) such that the m 2 × m 2 matrix (Tr r std, Proof. Let σ 1 , σ 2 , . . . , σ s ∈ Γ S such that the elements r std (U )(σ i ) generate the algebra A std as R-module. Then the map ϕ : is a lineair R-injection because the reduced trace, denoted by Trd, is non-degenerate on an Azumaya algebra. Then ϕ is a homeomorphism onto its image, which is a closed submodule of R s [BGR84, 3.7.3]. Thus, to check that r std (U ) is continuous, it suffices to check the continuity of ϕ • r std (U ). Since the projection of ϕ • r std (U ) onto the i-th copy of R is given by σ → Trd(r std (U )(σ i σ)) = T std (σ i σ), the desired continuity follows from the continuity of T std . The topology on A × std is induced from the embedding A × std → A 2 std , x → (x, x −1 ). Hence the mapping r std (U ) Γ S : Γ S → A × std is continuous if the maps σ → r std (U )(σ) and σ → r std (U )(σ −1 ) are continuous. The second mapping is the first map composed with σ → σ −1 and hence continuous.
We write ϑ for the composition X → E f irr . We choose x π ∈ |X | a point such that ϑ(x π ) = c π .
Step 2. Construction of the pseudocharacter attached to the spin representation. We define the following sets of classical points: Proof. Recall that U ⊂ E f was constructed in such a way that E f,cl ⋆ ∩ |U | is dense in U (see above (13.5)). Write . The mapping ϑ : X → U is finite and X , U are integral. By Lemma 13.2, ϑ −1 (S ⋆ ) ⊂ X is Zariski dense. Similarly, ϑ −1 (S ⋆ ) accumulates at X cl : If x ∈ X cl is a point, then there is an affine neighborhood U x ⊂ U such that S ⋆ ∩ |U x | is dense in U x . By Lemma 13.1 we may assume that U x is irreducible.
To show that the sets X cl St,⋆ ⊂ |X | are Zariski dense and accumulate at X cl St , we first construct a nilpotent operator N on X . We distinguish between two cases. Second, by the assumptions made at the beginning of this section, the infinite place v ∞ corresponds via the isomorphism ι to a place λ above ℓ which is different from v St . Since we restricted the Galois representation to the decomposition group at v St (as opposed to the place λ|ℓ), the Hodge-Tate weights are constant in the family of representations V of Γ v St . By the construction of the eigenvariety E f , the classical points correspond to automorphic representations which have Iwahori fixed vectors at all the F-places above ℓ. In particular, the family V is semi-stable at a dense set of classical points (Theorem 2.4.(v)). Berger-Colmez require in their Theorem C that the representation is semi-stable with Hodge-Tate weights in some fixed integral interval I ⊂ Z. As our weights are constant, this condition is verified.
At this point we have checked all the conditions in Theorem C of Berger-Colmez for our V , hence their theorem applies, so the module D st (V ) is locally free of rank 2n + 1. Let x ∈ X be a point. By [BC08, Thm. C.(4)] we have κ(x) ⊗ B D st (V ) D st (V x ). Moreover, the ring B st comes with a nilpotent operator N and a Frobenius ϕ. Thus, on D x = D st (V x ) we have a nilpotent L ⊗ Q ℓ B-endomorphism N x : D x → D x , and an action of elements σ ∈ W L , given by ϕ −v L (σ) where v L : W F → Z is the map so that σ ∈ W F acts on the residue field of F via a → a q v L (σ) with q the cardinality of the residue field of L. Similarly, on the module D st (V ) the element N ∈ B st defines a family of operators N . Since κ(x) ⊗ B D st (V ) D st (V x ) at the points x ∈ X , the operator N interpolates the N x that we considered above. Proof. This can be proved in the same way as in Lemma 13.15 using local-global compatibility at the places dividing ℓ (Theorem 2.4.(iv)).
We drop the assumption that either v St ∤ ℓ or v St |ℓ and return to the general setting. Proof. Since N is a nilpotent (2n + 1) × (2n + 1)-matrix, N 2n+1 vanishes on X . Consider the locus where N has maximal order, X N -max := {x ∈ X | N 2n x 0} ⊂ X . Then X N -max ⊂ X is open and nonempty (since x π ∈ X N -max ), thus dense since X is irreducible. By Lemmas 13.15 and 13.16 we have the inclusion Proposition 13.18. There exists a unique pseudocharacter T spin : Γ S → O rig (X ) such that T spin ⊗ κ(c) = Tr (spin • ρ C c ) for all c ∈ X cl St,spin,std .
Proof. By Proposition 13.17 the subset X cl St,spin,std ⊂ X is Zariski dense. Thus the proposition follows from Proposition 13.10 and Equation (13.7).
Step 3. Construction of the GSpin-valued representation ρ C π . Write L for the function field of X (so L = Frac(B)). Let L be an algebraic closure of L. Since B is a Tate algebra, it is complete for the Gauss norm. The fields L and L inherit a Hausdorff topology from (extension of) this Gauss norm. From the pseudocharacter T spin we obtain a continuous semisimple representation r spin (L) : Γ S → GL 2 n (L) by [Tay91,Thm. 1].
Let x ∈ X be a point. Proof. Let x ∈ X cl St,spin,std be a point where X is smooth. There is a corresponding ℓ-adic representation r x : Γ → GL 2 n (k(x)). By extending the base ℓ-adic field E if necessary, we may assume that r x has coefficient field k(x). The pseudocharacter T spin localized at x gives rise to a true representation r : Γ → GL 2 n (B sh x ) (Rouquier and Nyssen's theorem [Rou96,Nys96]). Let Γ F ′ ⊂ Γ S be an open subgroup. Taking the group algebra, we obtain a morphism of B sh . The residual representation r F ′ ⊗ B sh x B sh x /m x coincides with spin • ρ C τ x | Γ F ′ (their trace characters agree). Hence r F ′ ⊗ B sh x /m x is absolutely irreducible. By Wedderburn's theorem, the map r F ′ ⊗ B sh x /m x has image equal to M 2 n (B sh x /m x ). By Nakayama's lemma, the map r F ′ is surjective, so r F ′ ⊗ L is surjective as well. Hence r spin (L)| Γ F ′ is irreducible for all F ′ /F. By taking the trace of the dual representation r std (B) ∨ , we obtain the pseudocharacter T std ∨ with values in B. In fact, T std is equal to T std ∨ because T std ⊗ κ(c) = T std ∨ ⊗ κ(c) for all c ∈ X cl reg and X cl std is Zariski dense in X (Lemma 13.14). Write r std (L) = r std (B) ⊗ B L. We have Tr r std (L) = Tr r std (L) ∨ , and therefore r std (L) induces a representation r SO : Γ → SO 2n+1 (L). Propositions 3.5 and 4.4 are true (without changing the proofs) more generally for any coefficient field C, which is of characteristic 0, algebraically closed and has a Hausdorff topology. In particular we can lift r SO (L) to a continuous representation r SO (L) : Γ S → GSpin 2n+1 (L).
Lemma 13.20. Let ϕ : GL N 1 ,B → GL N 2 ,B be a B-morphism, and assume that M ∈ GL N 1 (L) is some matrix with Tr (M j ) ∈ B for all integers j ≥ 1. Then Tr (ϕ(M) j ) ∈ B for all j ≥ 1.
Proof. Since the map ϕ sends M ss to ϕ(M) ss , we may and do assume M is semisimple. Inside the group GL N 1 (L) the matrix M has the same characteristic polynomial as its companion matrix where the η i are certain irreducible representations of GL 2n+1,Q and the a i are rational numbers. We define the pseudocharacter T η : Γ → B by T η (σ) = k i=1 a i · Tr (η i • r std (B))(σ). Let v S. We have for all c ∈ X cl std and all integers j ≥ 1, (we fixed an embedding κ(c) ⊂ Q ℓ ). Hence also, for i = 1, . . . , k, Taking traces and the linear combination k i=1 a i · (⋆) on both sides, we get for all j ≥ 1 On the other hand we have the representation r spin (L), which we can compose with [s • P] : GL 2 n (L) → GL N (L) (where P is the surjection of GL 2 n onto PGL 2 n ). Since Tr r spin (L)(Frob The right hand sides of (13.10) and (13.9) agree, thus (∀c ∈ X cl std,spin ) : Expand T η (Frob j v ): . The conclusion is that for all j ≥ 1  Let χ be as in Proposition 13.21 and define r(L) := χ · r SO (L) : Γ S → GSpin 2n+1 (L). We embed B sh x π in L. We would like to show that r(L) has image in GSpin 2n+1 (B sh x π ) so that we can specialize r(L) at the point x π ∈ X cl . Write r std (B sh x π ) for the representation r std (B) ⊗ B B sh x π .
Lemma 13.22. We have r std (B sh x π ) ≃ r std (B sh x π ) ∨ . Proof. In [Car94, Thm. 1] Carayol proves the Brauer-Nesbitt Theorem over local rings, under the condition that the residual representation is absolutely irreducible. Carayol's condition is satisfied for r std (B sh x π ): We have r std (B sh x π ) ⊗ B sh x π /m x π ρ C π ♭ * , which is indeed irreducible by Theorem 2.4.(vii). Thus the equality Tr r std (B sh x π ) = Tr r std (B sh x π ) ∨ implies the lemma.
By Lemma 13.22, r std (B sh x π ) is valued in SO(B sh x π , ·, · ) for some perfect paring ·, · on (B sh x π ) 2n+1 . We write r SO (B sh x π ) : Γ → SO 2n+1 (B sh x π ) for the induced representation. In the rest of this section, whenever we write SO 2n+1 (B sh x π ) or GSpin 2n+1 (B sh x π ) we refer to the special orthogonal group or general spinor group constructed with respect to this paring.
Proposition 13.23. There exists an element g ∈ GSpin 2n+1 (L) such that the conjugated representation gr(L)g −1 has image in GSpin 2n+1 (B sh x π ) and q • gr(L)g −1 = r SO (B sh x π ). Proof. Note that the map GSpin 2n+1 → SO 2n+1 is surjective in the étale topology in characteristic prime to two. (The double covering Spin 2n+1 → SO 2n+1 is already surjective.) Since B sh x π is strictly henselian, the map GSpin 2n+1 (B sh x π ) → SO 2n+1 (B sh x π ) is surjective as well. In particular the square in the diagram below is Cartesian.
Observe that the SO 2n+1 (L)-valued representations q • r(L) and std • r SO (B sh x π ) ⊗ B sh x π L become isomorphic as GL 2n+1 (L)-valued representations. In the proof of Proposition 13.17 we saw that X N -max is a non-empty open in X . Consequently, std • q • r(L) is irreducible, and hence semi-simple. Thus, by Proposition B.1 there exist g ∈ SO 2n+1 (L) such that g(q • r(L))g −1 = r SO (B sh x π ). Choose a lift g of g via the surjection GSpin 2n+1 (L) → SO 2n+1 (L). Replacing r(L) by gr(L) g −1 we may assume that q • r(L) and r SO (B sh x π ) are (not just isomorphic but) equal. In particular the image of r(L) under q lands in SO 2n+1 (B sh x π ). We conclude that the image of r(L) is contained in GSpin 2n+1 (B sh x π ).
Replace r(L) by its conjugate gr(L)g −1 , as constructed in Proposition 13.23. The residue field κ(B sh x π ) of B sh x π coincides with Q ℓ . We define the representation Unwinding the above constructions and definitions, we have Proposition 13.24. We have as pseudocharacters Γ → Q ℓ .
Proof. We compute This proves (i). Using the above computation, we have also 13.6)).
This proves (ii). The computation for (iii) is similar.
Let v be an F-place that is not in S. Let ς spin , ς std , ς N ∈ X * ( T ) dom be the highest weights of the representations spin, std and N of GSpin 2n+1 . We write T spin (v, j) = T j·ς spin (v), T std (v, j) = T j·ς std (v) and T N (v, j) = T j·ς N (v) ∈ T (Recall, T ς (v) ∈ T was defined in (13.3)).
Corollary 13.25. For all v S and j ∈ Z ≥1 we have Proof. For all c ∈ X cl St,spin,std and all j ∈ Z ≥1 we have by Equation (13.7). We established in Proposition 13.17 that X cl St,spin,std ⊂ X is dense. Hence (13.13) holds for all points in X , so also for x π ∈ X . Part (i) follows from Proposition 13.24 and Equation (13.13). The proofs for (ii) and (iii) are similar, the required ingredients for (ii) are: Equation (13.4) (the required equality at the points c ∈ E cl std ), above Equation (13.5) + Corollary 13.9 (for the density of those points).
Theorem 13.26. Let π be as in Theorem B, and assume conditions (Aux ℓ -i), i = 1, 2, and (Even). Then Theorem B is true for π.
Proof. Let β : T → Q ℓ be the system of eigenvalues attached to the point c π ∈ E f . Then, for all T ∈ T, ιTr π S (T ) = β(T ) = Ψ(T ) ⊗ E f κ(c π ). Taking T = T spin (v, j), we obtain from Corollary 13.25.(i), . for all v S and all j ≥ 1. Thus for all v S, we have (a) in (c) (13.14) Statements (b) and (c) are deduced in the same way.
By Corollary 10.5, two semisimple elements in the group GSpin 2n+1 (Q ℓ ) are conjugate if and only if they have the same spinor norm and are conjugate in the spin representation. Thus (13.14).(a,c) implies Part (ii).
We check (iii). The trace character of spin•ρ C π , multiplied by a nonzero integer, agrees with the trace of ρ shim 2 in Proposition 8.2. Thus spin•ρ C π appears in H * c (S K , L ξ ), which is potentially semi-stable by Kisin [Kis02, Thm. 3.2]. Statements (iii.a) and (iii.b) can be proved using the same argument we carried out in the proof of part (iii) of Theorem 10.1. Statement (iii.c) follows from Proposition 12.3. Statement (iv) can be deduced as in the proof of (iv) in Theorem 1.5 via (i) of the theorem. Finally statements (v) and (vi) follow under the assumption of (HT 1 ) and (HT 2 ) from Lemma 3.3 and Proposition 5.4 respectively.

Patching
In Section 13 we constructed ρ π under conditions (Aux ℓ -1) and (Aux ℓ -2) on the prime number ℓ and condition (Even) that the degree [F : Q] is even. We use a patching/base change argument to remove these conditions and prove Theorem B.
Let π be a cuspidal automorphic representation of GSp 2n (A F ) satisfying (St) and (L-coh). Consider an irreducible sub Sp 2n (A F )-representation π ♭ of π. We write I 1 (π) for the set of finite extensions F ′ /F such that • F ′ /F is solvable and totally real with [F ′ : Q] even, • F ′ has at least two places above ℓ, • F ′ is large enough such that for every F-place λ|ℓ and for every F ′ -place λ ′ |λ, the L-parameter φ π ♭ λ and the central character ω π λ are unramified when restricted to W F ′ λ ′ . For each F ′ ∈ I 1 (π), Proposition 6.5 provides us with a weak base change π F ′ of π, which still satisfies (St) and (L-coh). By Lemma 2.7 and its proof, all local components of π ♭ (resp. π, π F ′ ) are tempered (resp. essentially tempered). The L-parameter φ π ♭ λ above is uniquely determined by the condition that its L-packet contains π ♭ λ , cf. [Art13, Thm. 1.5.1].
Lemma 14.1. For each F ′ ∈ I 1 (π), statements (i)-(iv) of Theorem A are true for π F ′ (in place of π) except that (iii.c) holds under the extra condition that π is unramified at all ℓ-adic places.
Proof. Obviously F ′ satisfies (Even) and (Aux ℓ -1). A large part of the proof would be to show that π F ′ satisfies condition (Aux ℓ -2). For a technical reason we prove only a weaker form, which still suffices for our purpose.
Choose π ♭ F ′ ⊂ π F ′ to be any irreducible sub Sp 2n (A F ′ )-representation. We claim that φ π ♭ F ′ ,λ | W F ′ λ ′ is unramified for each F ′ -place λ ′ above ℓ. We obtain a cuspidal automorphic representation π ♯ of GL 2n+1 (A F ) from π ♭ as in §2. Write π ♯ F ′ for the Arthur-Clozel base change of π ♯ to F ′ . It is easy to check that π ♭ F ′ is a weak base change of π ♭ to Sp 2n (A F ′ ) and has a Steinberg component at a finite place. Since π ♯ F ′ is a weak transfer of π ♭ F ′ by a direct computation of Satake parameters, it follows from Arthur's classification [Art13, Thm. 1.5.2] that the L-parameter φ π ♭ F ′ ,v transfers to φ π ♯ F ′ ,v at each place v of F ′ via the standard embedding SO 2n+1 (C) ֒→ GL 2n+1 (C). In particular the parameter φ π ♭ F ′ ,λ is unramified on W F ′ λ ′ for each λ ′ |ℓ by the third condition on F ′ above (and the fact that the Arthur-Clozel base change corresponds to restriction on the Galois side via the local Langlands correspondence).
To sum up, the hypotheses of Theorem 13.26 are satisfied for F ′ and σ ⊗ χ in place of F and π. Hence there exists a Galois representation ρ σ⊗χ . We obtain ρ σ by untwisting and then simply put ρ π F ′ := ρ σ . It remains to check that (i)-(iv) of Theorem A hold true for π F ′ and ρ π F ′ . We have the set of bad places S bad (π F ′ ) (resp. S bad (σ ⊗ χ)) for π F ′ (resp. σ ⊗ χ) in the same way S bad for π. A priori we have (ii) of the theorem for finite places outside S bad (σ ⊗ χ), which may not cover all finite places away from S bad (π F ′ ). However we can freely choose the auxiliary character χ to be unramified at any finite place not above ℓ, so we fully verify part (ii) of Theorem A. (Recall that σ is isomorphic to π F ′ away from ℓ-adic places by construction.) We easily see (i) and (iv) of the theorem for π F ′ from those for σ ⊗ χ. As before (iii.a) and (iii.b) are deduced as in the proof of Theorem 10.1. Finally we check (iii.c) when π is unramified at all ℓ-adic places. Then Proposition 6.5 ensures that π F ′ is also unramified at all ℓ-adic places, so condition (Aux ℓ -2) already holds for π F ′ . Applying Theorem 13.26 to π F ′ , we see in particular that π F ′ is crystalline at ℓ-adic places.
We recall Sorensen's patching result [Sor08, Thm. 1]. Let I be a nonempty collection of finite solvable extensions F ′ over F. We say that I has uniformly bounded height if the length of the Z-module Z/[F ′ : F]Z is uniformly bounded by an integer H I . For a finite set S of F-places, we say that I is S-general if the following property holds: For each field extension L of F (in F) which is a subfield of a member of I , and for each L-place v not lying above any place of S, either (a) L ∈ I or (b) there are infinitely many cyclic extensions K of L of prime degree such that each K is a subfield of a member of I and v splits in K. 14 Proposition 14.2 (Sorensen). Let I be an S-general collection of finite solvable extensions F ′ over F with uniformly bounded heights in the above sense. Suppose that a collection of isomorphism classes of m-dimensional semisimple Galois representations {r F ′ : Γ → GL m (Q ℓ ) | F ′ ∈ I } satisfies the following conditions: Then there exists a continuous semisimple representation r : Γ → GL m (Q ℓ ) such that for all F ′ ∈ I , we have r| Γ F ′ ≃ r F ′ .

Theorem 14.3. Theorem B is true.
Proof. We present a proof under the temporary assumption that F has at least two ℓ-adic places (i.e. the second condition on I 1 (π)). This assumption will be removed at the very end.
Let π, π ♭ , and I 1 (π) be as at the start of this section. For each F-place λ above ℓ, let d λ ∈ Z ≥1 denote the order of the image of the inertia subgroup under φ π ♭ λ . Take d to be the least common multiple of d λ 's. Define a subcollection I (π) ⊂ I 1 (π) consisting of F ′ ∈ I (π) such that [F ′ : F] divides 2d, so that I (π) has uniformly bounded height. Choose S to be the set of all ℓ-adic places of F. We claim that I (π) is S-general. Once the claim is proven, we apply Sorensen's result to r F ′ := spin • ρ π F ′ for F ′ ∈ I (π) to construct r : Γ F → GL 2 n (Q ℓ ).
Let us verify the claim. Let L be an extension of F contained in L ′ ∈ I (π). Without loss of generality we may assume L I (π) so that d ′ := [L ′ : L] > 1. For each L-place δ above an ℓ-adic place λ of F, let H δ denote the image of the inertia subgroup of W L δ under the L-parameter φ π ♭ λ . The second condition for I 1 (π) implies that |H δ | divides d ′ . An application of Galois theory and weak approximation 15 produces a family of extensions L(v, w) of L, where v and w run over places of L not above ℓ, such that • v and w split completely in L(v, w), • the second characterizing property of I 1 (π) holds for L(v, w) (in place of F ′ ). By the first condition [L(v, w) : Q] is equal to [L ′ : Q]. Hence L(v, w) ∈ I (π). For each v and w, fix an intermediate extension K(v, w) between L(v, w) and L such that [K(v, w) : L] is a prime. Then for each fixed v ∤ ℓ, the collection K(v, w) for varying w yields infinitely many non-identical extensions of L in which v splits. Therefore I (π) is S-general as claimed.
We show that r factors through GSpin 2n+1 (Q ℓ ) ⊂ GL 2 n (Q ℓ ) (possibly after conjugation). Then we have a morphism of groups Γ → π 0 (r(Γ)), where π 0 denotes the group of connected components. Let Γ F ′ be the kernel of the map Γ → π 0 (r(Γ)). Pick F ′′ ∈ I 1 (π) such that F ′′ is linearly disjoint to F ′ . After conjugating r, we may assume that r(Γ F ′′ ) is contained in GSpin 2n+1 (Q ℓ ). Since the neutral component of the Zariski closure of the image is insensitive to shrinking Γ to an open subgroup, we have r( The subgroups Γ F ′ and Γ F ′′ generate Γ F (since F ′ and F ′′ are linearly disjoint). Hence (14.1) implies r(Γ F ) ⊂ GSpin 2n+1 (Q ℓ ). We thus obtain a Galois representation ρ π : Γ → GSpin 2n+1 (Q ℓ ) such that spin • ρ π = r. We now check that properties (i) through (iv) from Theorem A hold for ρ π . Statements (iii.a) and (iii.b) follow from the arguments for (iii.a) and (iii.b) in the proof of Theorem 10.1 as before. The remaining (i), (ii), (iii.c), and (iv) are either local statements or immediately reduced to local statements, which can be checked by passing to F ′ ∈ I (π) in which the place in question splits completely and applying Lemma 14.1.
Parts (v) and (vi) of Theorem A follow from hypotheses (HT 1 ) and (HT 2 ) in the same way as in the proof of Theorem 13.26.
Finally we get rid of the temporary assumption that F has at least two ℓ-adic places. This is done by reducing to the previous case via Proposition 14.2 applied to quadratic extensions of F in which the unique ℓ-adic place of F splits.

Galois representations for the exceptional group G 2
As an application of our main theorems we realize some instances of the global Langlands correspondence for G 2 in the cohomology of Siegel modular varieties of genus 3 via theta correspondence, following the strategy of Gross-Savin [GS98]. In particular the constructed Galois representations will be motivic and come in compatible families as such. We work over F = Q (as opposed to a general totally real field) mainly because this is the case in [GS98].
More precisely we are writing G 2 for the split simple group of type G 2 defined over Z. Denote by G c 2 the inner form of G 2 over Q which is split at all finite places such that G c 2 (R) is compact. The dual group of G 2 is G 2 (C) and fits in the diagram The basic idea appears in the proof of [Art13, Lem. 6.2.1], for instance, though the prescribed local properties are somewhat different.
such that G 2 (C) = SO 7 (C) ∩ Spin 7 (C). The subgroup PGL 2 (C) is given by a choice of a regular unipotent element of SO 8 (C). See [GS98, for details. Note that the spin representation of Spin 7 is orthogonal and thus factors through SO 8 . The 8-dimensional representation G 2 (C) ֒→ GL 8 (C) decomposes into 1-dimensional and 7-dimensional irreducible pieces. The former is the trivial representation. The latter factors through SO 7 (C). Evidently all this is true with Q ℓ in place of C. The (exceptional) theta lift from each of G 2 and G c 2 to PGSp 6 using the fact that (G 2 , PGSp 6 ) and (G c 2 , PGSp 6 ) are dual reductive pairs in groups of type E 7 [GRS97,GS98]. In this section we concentrate on the case of G c 2 , only commenting on the case of G 2 at the end. Every irreducible admissible representation of G c 2 (R) is finite-dimensional, and both (C-)cohomological and L-cohomological since the half sum of all positive roots of G 2 is integral. Note that an automorphic representation π of PGSp 6 (A) is the same as an automorphic representation of GSp 6 (A) with trivial central character, so we will use them interchangeably. For such a π the subgroup ρ π (Γ) of GSpin 7 (Q ℓ ) is contained in Spin 7 (Q ℓ ) by (i) of Theorem A.
Theorem 15.1. Let σ be an automorphic representation of G c 2 (A). Assume that • σ admits a theta lift to an automorphic representation π on PGSp 6 (A).
• σ v St is the Steinberg representation at a finite place v St .
Before starting the proof, we recall the basic properties of the theta lift π. We see from [GS98, §4 Prop. 3.1, §4 Prop. 3.19, §5 Cor. 4.9] that π is cuspidal, that π v St is the Steinberg representation, and that π v is unramified whenever σ v is unramified at a finite place v and the unramified L-parameters are related via Furthermore π ∞ is an L-algebraic discrete series representation whose parameter can be explicitly described in terms of σ ( §3 Cor. 3.9 of loc. cit.).
Proof. We apply Theorem B to the above π to obtain a continuous representation ρ π : Γ → Spin 7 (Q ℓ ). Note that spin • ρ π is a semisimple representation by construction. Since the image of ρ π ♭ contains a regular unipotent element of SO 7 (Q ℓ ), it follows that ρ π (Γ) contains a regular unipotent of Spin 7 (Q ℓ ) and also that of SO 8 (Q ℓ ). By (15.1) and the Chebotarev density theorem, the image of ρ π is locally contained in G 2 in the terminology of Gross-Savin, so [GS98, §2 Cor. 2.4] implies that ρ π (Γ) is contained in G 2 (Q ℓ ) (given as SO 7 (Q ℓ ) ∩ Spin 7 (Q ℓ ) for a suitable choice of the embedding SO 7 ֒→ SO 8 ; here spin : Spin 7 ֒→ SO 8 is fixed). Hence we have ρ σ satisfying (4), namely that ρ π ≃ ζ • ρ σ . Assertions (1)-(3) of the theorem follow from Theorem B and the fact that the set of Weyl group orbits on the maximal torus (resp. on the cocharacter group of a maximal torus) for G 2 maps injectively onto that for Spin 7 . (The latter can be checked explicitly.) Example 2. There is a unique automorphic representation σ of G c 2 (A) unramified outside 5 such that σ 5 is the Steinberg representation and σ ∞ is the trivial representation [GS98, §1 Prop. 7.12]. Proposition 5.8 in §5 of loc. cit. (via a computer calculation due to Lansky and Pollack) tells us that σ admits a nontrivial theta lift to PGSp 6 (A). Proposition 5.5 in the same section gives another example of nontrivial theta lift but we will not consider it here.
We confirm the prediction of Gross-Savin that a rank 7 motive whose motivic Galois group is G 2 is realized in the middle degree cohomology of a Siegel modular variety of genus 3.
Corollary 15.2. Let σ be as in Example 2. Write π for its theta lift. Then ρ σ has Zariski dense image in G 2 (Q ℓ ). Moreover spin • ρ π is isomorphic to the direct sum of η • ρ σ and the trivial representation. In particular η • ρ σ and the trivial representation appear in the π ∞ -isotypic part in H 6 c (S, Q ℓ )(3), where S is the tower of Siegel modular varieties for GSp 6 and (3) denotes the Tate twist (i.e. the cube power of the cyclotomic character).
Proof. If the image is not dense in G 2 (Q ℓ ) then the proof of [GS98, §2 Prop. 2.3] shows that the Zariski closure of ρ π (Γ) is PGL 2 . However we see from the explicit computation of Hecke operators at 2 and 3 on σ carried out by Lansky-Pollack [LP02, p.45, Table V] that the Satake parameters at 2 and 3 do not come from PGL 2 . 17 We conclude that ρ σ (Γ) is dense in G 2 (Q ℓ ). The second assertion of the corollary is clear from (4) of Theorem 15.1 and the construction of ρ π .
Remark 15.3. The Tate conjecture predicts the existence of an algebraic cycle on S which should give rise to the trivial representation in the corollary. Gross  (See Section 6 of their paper for the hypothesis. They prescribe a special kind of supercuspidal representation instead of the Steinberg representation.) In our notation, their ρ σ is constructed inside the SO 7 -valued representation ρ π ♭ , where the point is to show that the image is contained and Zariski dense in G 2 [KLS10, Cor. 9.5]. 18

Automorphic multiplicity
In this section we prove multiplicity one results for automorphic representations of GSp 2n (A F ) and those of the inner form G(A F ). For GSp 2n we deduce this from Bin Xu's multiplicity formula using the strong irreducibility of the associated Galois representations. The result is then transferred to G(A F ) via the trace formula. This is standard except when the highest weight of ξ is not regular: in that case we need the input from Shimura varieties that the automorphic representations of G(A F ) of interest are concentrated in the middle degree.
Theorem 16.1. Let n ≥ 2. Let π be a cuspidal automorphic representation of GSp 2n (A F ) such that conditions (St) and (L-Coh) hold. If n > 2 we also assume that ρ π ♭ satisfies (HT 1 ) and (HT 2 ) for some infinite F-place v ∞ and for some cuspidal automorphic sub Sp 2n (A F )-representation π ♭ of π, cf. Lemma 2.6. Then spin • ρ π is strongly irreducible. Moreover, the automorphic multiplicity m(π) of π is equal to 1, i.e. Theorem C is true.
Remark 16.2. Conditions (HT 1 ) and (HT 2 ) may be translated to conditions on the L-parameter of π ♭ v ∞ (or on that of π v ∞ ) via Theorem 2.4 (iii).
Proof. Proposition 3.8 tells us that spin • ρ π is strongly irreducible. By Bin Xu [Xua, Prop. 1.7] we have the formula where m(π ♭ ) is 1 in our case by Arthur [Art13, Thm. 1.5.2]. The group Y (π) is equal to the set of characters ω : GSp 2n (A F ) → C × which are trivial on GSp 2n (F)A × F Sp 2n (A F ) ⊂ GSp 2n (A F ) and are such that π ≃ π ⊗ ω. The definition of the subgroup α(S φ ) of Y (π) is not important for us: We claim that Y (π) = 1. Let ω ∈ Y (π) and let χ : Γ → Q × ℓ be the corresponding character via class field theory. Because the representations have the same local components at unramified places, we get from Proposition 5.4 that χρ π ≃ ρ π . Thus also χ(spin • ρ π ) ≃ spin • ρ π . Since spin • ρ π is strongly irreducible it follows that χ = 1 and hence ω is trivial as well.
We now prove an analogue of Theorem 16.1 for inner forms of GSp 2n,F . Since Arthur's and Bin Xu's results have not been written up yet for non-trivial inner forms, we only obtain a partial result. Let G be an inner form of GSp 2n,F in the construction of Shimura varieties, cf. §7. Theorem 16.3. Let π be a cuspidal automorphic representation of G(A F ), such that the conditions (L-coh), (HT 1 ) and (HT 2 ) hold, and for some place v ∈ Σ ∞ we assume that π v is isomorphic to a twist of the Steinberg representation. Then the automorphic multiplicity of π is equal to 1.
17 The authors check [LP02,§4.3] that the Satake parameters do not come from SL 2 via the map SL 2 (C) → G 2 (C) induced by a regular unipotent element. But the latter map factors through the projection SL 2 → PGL 2 .
18 Thereby they give an affirmative answer to Serre's question on the motivic Galois group of type G 2 , since it is well known that ρ π ♭ appears in the cohomology of a unitary PEL-type Shimura variety after a quadratic base change, along the way to proving a result on the inverse Galois problem. Sometimes this contribution of [KLS10] is overlooked in the literature.
We have π as in the statement of Proposition 16.2 appearing in the left sum of (16.2). So both sides are positive in that equation. In particular there exists π * contributing to the right hand side such that m(π * ) > 0. Any other τ * in the sum is isomorphic to π * at all finite places away from v St . We also know that τ * v St and π * v St differ by an unramified character and that τ ∞ and π ∞ belong to the same L-packet. Now we claim that To see this, we apply [Xua, Thm. 1.8] to deduce that τ * and π * belong to the same global L-packet as in that paper, by the same argument as in the proof of Lemma 11.2. Since the local L-packet for GSp 2n (F v St ) of (any character twist of) the Steinberg representation is a singleton by [Xua,Prop. 4.4, Thm. 4.6], the claim follows. 19 We have shown that the right hand side of (16.2) may be summed over τ * which is isomorphic to π * away from infinity and belongs to Π G * ξ at infinity. Each τ * has automorphic multiplicty one by Theorem 16.1 and Lemma 16.4. (Without the lemma, some m(τ * ) could be zero.) So (16.2) comes down to Recall that the sum runs over τ such that τ ∞,v St ≃ π ∞,v St , τ ∞ ∈ Π G ξ , and τ v St ≃ π v St ⊗ ǫ for an unramified character ǫ. By Lemma 16.4, the contribution from τ with τ ∞ ≃ π ∞ is already |Π G ξ |m(π), and the other τ (if any) contributes nonnegatively. We conclude that m(π) = 1. (Moreover, all τ in the sum with m(τ) > 0 should be isomorphic to π at v St ; this gets used in the next corollary.) Consequently we deduce that the Galois representation ρ 2 appears in the cohomology with multiplicity one, cf. §9.
Corollary 16.5. In the setting of Theorem 16.3, the integer a(π) defined in (8.2) is equal to one. (Note that π here is π ♮ there.) Proof. The last paragraph in the proof of the preceding theorem shows that for every τ ∈ A(π), we have an isomorphism τ v St ≃ π v St . Since τ ∞ ∈ Π G ξ for every τ ∈ A(π) by Corollary 8.5, it follows from Theorem 16.3, Lemma 16.4, and Remark 7.2 that Remark 16.6. The same argument proves Theorem 16.3 for all inner forms G of GSp 2n as long as the highest weight of ξ is regular. Note that we used the fact that G is the particular inner form twice when invoking Corollary 8.5 and the trace formula for compact quotients in the proof of Lemma 16.4; let us explain how to get around them for general G. The corollary is unnecessary since any ξ-cohomological representation belongs to discrete series if the highest weight is regular. Then we employ the simple trace formula with pseudocoefficients for two discrete series representations as in the case of G * in the proof of Lemma 16.4. Instead of appealing to the essential temperedness, we use the fact that if Tr (f τ ∞ |σ ∞ ) 0 then σ ∞ is cohomological (this is true even if ξ has non-regular highest weight). Then σ ∞ has to be in discrete series again by the regularity of highest weight, and the rest of the argument goes through unchanged.

Meromorphic continuation of the Spin L-function
Let π be a cuspidal automorphic representation of GSp 2n (A F ) unramified away from a finite set of places S. The partial spin L-function for π away from S is by definition ) .
Various analytic properties of this function would be accessible if the Langlands functoriality conjecture for the L-morphism spin were known. However we are far from it when n ≥ 3. In particular no results have been known about the meromorphic (or analytic) continuation of L S (s, π, spin) when n ≥ 6 (see introduction for some results when 2 ≤ n ≤ 5).
The aim of this final section is to establish Theorem D on meromorphic continuation for L-algebraic π under hypotheses (St), (L-coh), and (spin-REG) by applying a potential automorphy theorem, namely Theorem 19 Lemma 2.1 implies that the L-parameter W F v St × SU 2 (R) → SO 2n+1 (C) for the Steinberg representation of Sp 2n (F v St ) restricts to the principal representation of SU 2 (R) in SO 2n+1 (C). A lift of this to a GSpin 2n+1 (C)-valued parameter is attached to the Steinberg representation of GSp 2n (F v St ) in Xu's construction. This is enough to imply that the group Sφ in [Xua,Prop. 4.4] is trivial.
(2) R π,λ | Γ v is de Rham for every v|ℓ. Moreover it is crystalline if π v is unramified and v S bad .
Remark 17.3. Although we do not need it, we can choose M π such that R π,λ is valued in GL 2 n (M π,λ ) for every λ. Concretely we may take M π to be the field of definition for the π ∞ -isotypic part in the compact support Betti cohomology with Q-coefficients (with respect to the local system arising from ξ). When the coefficients are extended to M π,λ the π ∞ -isotypic part becomes a λ-adic representation of Γ via étale cohomology, which is isomorphic to a single copy of R π,λ if the coefficients are further extended to M π,λ by Corollary 16.5.
Proof. The first four assertions are immediate from Theorem 10.1. The first part of (5) is clear from Lemma 0.1. Let us check the second part of (5). Consider the diagram . The outer triangle commutes by the definition of µ λ . The right triangle also commutes by Lemma 0.1. Hence µ λ = N • ρ π . By (L-coh) we know that ̟ π v |·| n(n+1)/4 is the inverse of the central character of some irreducible algebraic representation ξ v at each infinite place v. Hence ̟ π v |·| n(n+1)/4 : R × → C × is the w-th power map, where w ∈ Z is as in (cent) of §7 (in particular w is independent of v). Hence ̟ π|·| n(n+1)/4 = ̟ π | · | n(n+1)/2 corresponds via class field theory and ι to an even Galois character of Γ (regardless of the parity of w). On the other hand, µ λ corresponds to ̟ π via class field theory and ι in the L-normalization, cf. Theorem A. We conclude that µ λ,v (c v ) = (−1) n(n+1)/2 for each v|∞. Now that we proved the lemma, Theorem A of [BLGGT14] implies Corollary 17.4. Theorem D is true.
Proof. The conditions of the theorem in loc. cit. are verified by the above lemma with the following additional observation: the characters µ λ forms a weakly compatible system since they are associated to the central character of π (which is an algebraic Hecke character).
Remark 17.5. For the lack of precise local Langlands correspondence for general symplectic groups (however note that Bin Xu established a slightly weaker version in [Xua]), we cannot extend the partial spin L-function for π to a complete L-function by filling in the bad places. However the method of proof for the corollary yields a finite alternating product of completed L-functions made out of Π as in Theorem D, by an argument based on Brauer induction theorem as in the proof of [HSBT10,Thm. 4.2]; this alternating product should be equal to the completed spin L-function as this is indeed true away from S.

Appendix A. Lefschetz functions
We collect some results on Lefschetz functions that are used in the text. In this appendix, F is a nonarchimedean local field of residue characteristic p, except in Lemma A.12 at the end, where F is global. We collect the required results from the literature and prove some lemmas to deal with small technical difficulties (non-compact center, twisted group).
To help the readers we clarify some terminology. There are three names for the function whose trace computes the Euler-Poincaré characteristic or the Lefschetz number of the group cohomology (resp. Lie algebra cohomology) for a given reductive p-adic (resp. real) group: they are called Euler-Poincaré functions, Kottwitz functions, or Lefschetz functions. In the real case one can consider twisted coefficients by local systems. There are small differences between the three functions. Euler-Poincaré and Lefschetz functions are considered on either p-adic or real groups, and can be described in terms of pseudo-coefficients for certain discrete series representations. The functions may not be unique but their orbital integrals are well defined. A Kottwitz function mainly refers to a particular function on a p-adic group and gives pseudo-coefficients for the Steinberg representations. It is not just characterized by their traces but can be given by an explicit formula, cf. [Kot88,§2]. A generalization of Kottwitz functions on a p-adic group is given in [SS97] but we will not need it in this paper.
We recall Kottwitz's result. Let G be a connected reductive group and write q(G) for the F-rank of the derived subgroup of G. We now consider the group GL 2n+1 equipped with the involution θ defined by g → J t g −1 J with J the (2n + 1) × (2n + 1) matrix with all entries 0 except those on the antidiagonal, where we put 1. Define GL + 2n+1 := GL 2n+1 ⋉ θ . In [BLS96] Borel, Labesse, and Schwermer introduced twisted Lefschetz functions. Below we will cite mostly from the more recent article of Chenevier-Clozel [CC09,Sect. 3]. The results we need from them are proven in a general twisted setup but specialize to our case as follows. ) is equal to 1.

Let f
Sp 2n (F) Lef be the Lefschetz function on Sp 2n (F) from Proposition A.1. We introduce the notion of associated functions. Let G 0 be a reductive group over F. Suppose that G ′ 0 is an endoscopic group for G 0 (i.e. G ′ 0 is part of an endoscopic datum for G 0 ). We say that the functions f 0 ∈ H(G ′ 0 (F)) and f ′ 0 ∈ H(H ′ 0 (F)) are associated if they have matching orbital integrals in the sense of [KS99, (5.5.1)]. The same definition carries over to the archimedean and adelic setup. Proof of Lemma A.3. We show that for each γ ∈ Sp 2n (F) strongly regular, semisimple and elliptic, we have where δ ranges over a set of representatives of the twisted conjugacy classes in GL 2n+1 (F) which are associated to γ. Note that the stable orbital integral SO γ (f

Sp 2n
Lef ) is equal to the number of conjugacy classes in the stable conjugacy class of γ. Our first claim (1) is that ∆(γ, δ) = 1 for all elliptic δ associated to γ. Assuming that this claim is true, the right hand side of Equation (A.2) is the stable twisted orbital integral SO δθ (Cf GL 2n+1 ,θ Lef ), which equals, up to multiplication by C, the number of twisted conjugacy classes in the stable twisted conjugacy class of δ. Our second claim is that SO γ (f ). Clearly the lemma follows from claims (1) and (2).
Let us now check the two claims. We begin with claim (1). For this we use the formulas in the article of Waldspurger [Wal10, Sect. 10]. The factors ∆(γ, δ) are complicated and involve many notation to introduce properly, for which we do not have the space to introduce. Thus we use, without introducing, the notation from [Wal10]. By [Wal10, Prop. 1.10] (A.3) ∆ Sp 2n , G (y, x) = χ(ηx D P I (1)P I − (−1)) i∈I − * sgn F i /F ±i (C i ).
Since our conjugacy class is elliptic we have H = Sp 2n , the group H − is trivial and the sets I − , I − * are empty. A priori, χ is any quadratic character of F × , and each choice defines a different isomorphism class of twisted endoscopic data. The choice affects the L-morphism: η χ : L H = SO 2n+1 (C) × W F → L G(C) = GL 2n+1 (C) × W F , (g, w) −→ (χ(w)g, w).
Since the Steinberg L-parameter for GL 2n+1 (C), W F × SU 2 (R) → L GL 2n+1 (C), is trivial on W F (and Sym 2n on SU 2 (R)), it factors through η χ only for χ = 1 (and not for non-trivial χ). Consequently the transfer factor in Equation (A.3) is equal to 1, and claim (1) is true. We check claim (2). In Sections 1.3 and 1.4 of [Wal10], Waldspurger describes the (strongly) regular, semisimple (stable) conjugacy classes of Sp 2n (F) in terms of F-algebras. More precisely, a regular semisimple conjugacy class in Sp 2n (F) is given by data (F i , F ±i , c i , x i , I), where I is a finite index set; for each i ∈ I, F ±i is a finite extension of F; for each i ∈ I, F i is a commutative F ± i -algebra of dimension 2; we have i∈I [F i : F] = 2n; τ i is the non-trivial automorphism of F i /F ±i ; for each i ∈ I, we have an an element c i ∈ F × i such that τ i (c i ) = −c i ; x i ∈ F × i such that x i τ i (x i ) = 1; to the data (F i , F ±i , c i , x i , I), Waldspurger attaches a conjugacy class [Wal10, Eq. (1)] and this conjugacy class is required to be regular.
The data (F i , F ±i , c i , x i , I) should be taken up to the following equivalence relation: The index set I is up to isomorphism; the triples (F i , F ±i , x i ) are up to isomorphism; the element c i ∈ F × i is given up to multiplication by the norm group N F i /F ±i (F × i ). The stable conjugacy class is obtained from (F i , F ±i , c i , x i , I) by forgetting the elements c i [Wal10, Sect. 1.4], and keeping only (F i , F ±i , x i , I).
According to [Wal10, Sect. 1.3] a strongly regular, semisimple twisted conjugacy class in GL 2n+1 is given by data (L i , L ±i , y i , y D , J) where 20 a finite index set J; for each i ∈ J, L ±i is a finite extension of F; for each i ∈ J, L i is a commutative L ±i -algebra of dimension 2 over L ±i ; for each i ∈ J, an element y i ∈ L × i ; 2n + 1 = i∈J [L i : F]; y D an element of F × ; to the data (L i , L ±i , y i , y D , J) Waldspurger attaches a twisted conjugacy class [Wal10,p.45] and this class is required to be strongly regular. The data (L i , L ±i , y i , J) should be taken up to the following equivalence relation: (L i , L ±i , J) are under the same equivalence relation as before for the symplectic group; the elements y i are determined up to multiplication by N L i /L ±i (L × i ); y D is determined up to squares F ×2 . The stable conjugacy class of (L i , L ±i , J, y i , y D ) is obtained by taking y i up to L × ±i and forgetting the element y D . By [Wal10, Sect. 1.9] the stable (twisted) conjugacy classes (L i , L ±i , x i , J) and (F i , F ±i , y i , I) correspond if and only if (L i , L ±i , x i , J) = (F i , F ±i , y i , I).
The conjugacy class γ (resp. δ) is elliptic if the algebra F i (resp L i ) is a field. Let's assume that this is the case (otherwise there is nothing to prove, because the equation SO γ (f

Sp 2n
Lef ) = STO δ (Cf GL 2n+1 ,θ Lef ) reduces to 0 = 0). By the description above, to refine the stable conjugacy class (F i , F ±i , x i , I) to a conjugacy class, is to give elements c i ∈ F × i /N F i /F ±i F × i such that τ i (c i ) = −c i . For each i there are 2 choices for this, so we get 2 #I conjugacy classes inside the stable conjugacy class.
To refine the stable twisted conjugacy class (L ±i , L i , y i , J) to a twisted conjugacy class, is to lift y i under the mapping L × i /N L i /L ±i (L × i ) ։ L × i /L × ±i . There are #L × ±i /N L i /L ±i (L × i ) = 2 choices for such a lift for each i ∈ J. We get 2 #J choices to refine the collection (y i ) i∈J . Finally we also have to choose an element y D ∈ F × /F ×2 . In total we have |F × /F ×2 |2 #J twisted conjugacy classes inside the stable twisted conjugacy class. Thus if we take C = |F × /F ×2 | −1 the lemma follows.
We also need Lefschetz functions on the group GSp 2n (F) and its nontrivial inner form G. Unfortunately Proposition A.1 does not apply since the center of GSp 2n (F) is not compact. We follow Labesse to construct Kottwitz functions generally for an arbitrary reductive group G over F. Let A denote the maximal split torus in the center of G. Proof. The proof is quickly reduced to the case when the center is anisotropic, the point being that G(F) 1 and G * (F) 1 are invariant under conjugation. From Proposition A.1 we deduce that SO G γ (f G Lef ) is zero if γ is non-elliptic and equals the number of G(F)-conjugacy classes in the stable conjugacy class of γ if γ is elliptic. Since the same is true for G * it is enough to show that the number of conjugacy classes in a stable conjugacy class is the same for γ and γ * when they are strongly regular and have matching stable conjugacy classes. This follows from the p-adic case in the proof of [Kot88, Thm. 1].
Definition A.6 ( [Lab99, Def. 3.8.1, 3.8.2]). Let φ ∈ H(G(F)). We say that φ is cuspidal if the orbital integrals of φ vanish on all regular non-elliptic semisimple elements, and strongly cuspidal if the orbital integrals of φ vanish on all non-elliptic elements and if the trace of φ is zero on all induced representations from unitary representations on proper parabolic subgroups. The function φ is said to be stabilizing if φ is cuspidal and if the κ-orbital integrals of φ vanish on all semisimple elements for all nontrivial κ.
Lemma A.7. The function f G Lef is strongly cuspidal and stabilizing. If Tr π(f G Lef ) 0 for an irreducible unitary representation π of G(F) then π is an unramified character twist of either the trivial or the Steinberg representation.
Proof. The first assertion is [Lab99, Prop. 3.9.1]. By construction f G Lef is constant on Z(F) ∩ G(F) 1 , which is compact. Since Tr π(f G Lef ) is the sum of Tr π 1 (f G Lef ) over irreducible constituents π 1 of π| G(F) 1 , we may choose π 1 such that Tr π 1 (f G Lef ) 0. The nonvanishing implies that π 1 has trivial central character on Z(F) ∩ G(F) 1 . Thus π 1 descends to a representation π ′ of G ′ (F). Computing Tr π 1 (f G Lef ) by first integrating over A(F)∩G(F) 1 , we see that the result is a nonzero multiple of Tr π ′ (f ′ Lef ). So Tr π ′ (f ′ Lef ) 0. When π is unitary, π 1 and thus also π ′ are unitary. By Proposition A.1, π ′ is either trivial or Steinberg so the same is true for π 1 . Writingπ ′ for the pullback of π ′ to G(F), we see thatπ ′ is either trivial or Steinberg. Now both π andπ ′ are constituents of Ind G(F) G(F) 1 π 1 by Frobenius reciprocity. Hence they are unramified character twists of each other. Assume from now on that G is a non-split inner form of a quasi-split group G * over F. Consider a finite cyclic extension E/F with θ generating the Galois group. PutG * := Res E/F G * equipped with the evident θ-action. (The case G * = GSp 2n is used in the main text.) Lemma A.8. The function fG * Lef is strongly cuspidal and stabilizing on the twisted groupG * θ. There exist constants c ∈ C × such that the functionscf G * Lef and fG lemma End Γ (V ) = t i=1 M d i (C). We obtain an embedding where two matrices X, Y ∈ GL d i (C) are GL d i (C)-congruent if there exists a third matrix g ∈ GL d i (C) such that Y = g t Xg. The image of X χ (φ) in the set on the right hand side decomposes along the product and is in each GL d j (C)-factor equal to the set of congruence classes of invertible symmetric matrices. Since C is algebraically closed of characteristic 2, these classes have exactly one element.