Nonperturbative black hole entropy and Kloosterman sums

Non-perturbative quantum corrections to supersymmetric black hole entropy often involve nontrivial number-theoretic phases called Kloosterman sums. We show how these sums can be obtained naturally from the functional integral of supergravity in asymptotically AdS2 space for a class of black holes. They are essentially topological in origin and correspond to charge-dependent phases arising from the various gauge and gravitational Chern-Simons terms and boundary Wilson lines evaluated on Dehn-filled solid 2-torus. These corrections are essential to obtain an integer from supergravity in agreement with the quantum degeneracies, and reveal an intriguing connection between topology, number theory, and quantum gravity. We give an assessment of the current understanding of quantum entropy of black holes.


Introduction
Quantum entropy of a black hole is the full quantum generalization of the celebrated Bekenstein-Hawking entropy including both perturbative and nonperturbative corrections. For supersymmetric black holes, it is defined by a formal functional integral of massless supergravity fields in the near horizon AdS 2 space in the framework of AdS 2 /CF T 1 correspondence [1,2]. The measure of the functional integral is determined by the effective Wilsonian action including all higher derivative terms obtained by integrating out the massive string fields.
There has been considerable progress in evaluating this functional integral for a class of supersymmetric black holes using localization techniques [3][4][5]. In particular, in the simple JHEP03(2015)074 example of one-eighth BPS black holes in N = 8 supersymmetric theory in four dimensions, it seems possible to exactly sum up all perturbative corrections to the Bekenstein-Hawking area formula [4]. It is also clear qualitatively that the nonperturbative corrections expected from the microscopic degeneracy can be reproduced from contributions from subleading saddle points obtained by smooth Z c orbifolds of AdS 2 labeled by a positive integer c [6,7].
Our goal here is to compute explicitly the nonperturbative corrections which involve subtle number theoretic phases called the Kloosterman sums. It has been a long standing puzzle how these phases could possibly arise from a supergravity functional integral. These corrections, even though subleading, are conceptually very important because the exponential of the quantum entropy is expected to yield precisely an integer equal to the quantum degeneracy of the black hole. The nonpertubative corrections including the precise Kloosterman sums are essential to obtain this integrality. This is a nontrivial and stringent constraint. Indeed, it is something of a surprise that a functional integral in the bulk which is intrinsically a complex analytic continuous object could yield a specific integer which is a number theoretic discrete object.
We emphasize that it is meaningful to discuss nonperturbative corrections arising from subleading saddle points only because the full perturbative answer around the leading saddle point can be evaluated exactly using localization. In a typical physics context, when a functional integral is evaluated in the saddle point approximation, the perturbative expansion around the saddle point involves all loops. Usually there is no practical way to evaluate the higher loops. Even if one could, it is only an asymptotic expansion and not a convergent one. So, it is not particularly meaningful to include the contribution from subleading saddle points which are exponentially smaller compared to the perturbative contributions around the leading saddle point. In the present context, by contrast, the evaluation of the functional integral around the localizing saddle point is one-loop exact and can be evaluated explicitly.
Somewhat surprisingly, the supergravity functional integral seems capable of reproducing the intricate structure of the Kloosterman sums. It turns out to be essentially topological in origin. The supergravity action includes Chern-Simons terms (including the higher derivative gravitational Chern-Simons terms) and the quantum entropy functional integral includes boundary Wilson lines. These terms evaluated on the subleading localizing instantons lead to charge-dependent phases which combine nontrivially to yield precisely the Kloosterman sums.
Quantum Entropy connects to the broader problem of Quantum Holography, that is, of understanding finite N quantum effects in the bulk quantum gravity in AdS/CF T holography. Developing on our results can provide the first example of quantum holography where both the bulk and boundary partition functions are computable including all quantum corrections.
The plan of the paper is as follows. In section 2 we review the definition of the classical and generalized Kloosterman sums and the associated Rademacher expansions. In section 3 we discuss the SL(2, Z) family of localizing orbifold solutions that contribute to the nonperturbative corrections to the quantum entropy. Sections 4 and 5 contain the main results of this paper where we describe how various phases and the multiplier system JHEP03(2015)074 in the Kloosterman sums are reproduced from the orbifolded localization instantons. In section 6 we give an assessment of the hurdles that have been overcome in this program and the problems that remain to be solved.

Kloosterman sums and the Rademacher expansion
We review the definitions of Kloosterman sums and their relation to the Rademacher Expansion.

The classical Kloosterman sum
The classical Kloosterman sum for integers n, m, c is defined by (2.1) It arises naturally in analytic number theory in the study of Fourier coefficients of modular forms of negative weight. A modular form of particular interest to us (see section 2.3) is which has weight −12: with Fourier expansion which can be proven easily by changing variables pd =d and d * = pd * . This property will be important later in section 4.3 to prove the duality invariance of the bulk answers.

The generalized Kloosterman sum
There is a natural generalization of the Rademacher expansion for Fourier coefficients of weak Jacobi forms, which suggests the following definition for the generalized Kloosterman sum. For a review of weak Jacobi forms see, for example, [8] or [9]. Consider the standard weight-half index-k theta functions defined by 3 ϑ k,µ (τ, z) = l∈Z l=µ mod 2k q l 2 /4k y l , q := e 2πiτ , y := e 2πiz (2.8) for a positive integer k. Under modular transformation they transform among each other as 10) and the square root is defined by choosing the principal branch of the logarithm log z = log |z|+arg z, −π < arg z ≤ π. The matrix M (γ) is called the multiplier system. To obtain an explicit analytic expression for the representation M (γ) is a subtle problem in number theory. In section 5.1, we review a representation obtained in [10] that is particularly well-suited for our physical computations in section 5.2 because it affords a natural path integral interpretation [11]. For a given k, the generalized Kloosterman sum [12][13][14] is then defined by where ∆ := 4kn − ν 2 and∆ := 4km − µ 2 . The summand depends only on the equivalence class [γ] ∈ Γ ∞ \SL(2, Z)/Γ ∞ where Γ ∞ is the subgroup of translations generated by T . This can be checked using the definition (2.9) of M −1 (γ) µν . Practically, this means that by the left and the right coset action we can choose a representative of the class [γ] such that −c < a, d ≤ 0. The generalized Kloosterman sum appears naturally in the Rademacher expansion of Fourier coefficients of weak Jacobi forms. Consider a weak Jacobi form φ(τ, z) of nonpositive weight w and index k. Elliptic properties of the Jacobi form imply a theta expansion: where h ν (τ ) is periodic in ν with period 2k. Modular properties of the Jacobi form imply that the components of the vector transform under a modular transformation as where the sum is over the discriminants ∆ = 4kn − ν 2 for nonnegative integers n. The terms in this expansion for which ∆ is negative are called the polar terms. The Rademacher expansion for the coefficients C ν (∆) is given [13,14] by which is determined essentially by the polar terms. A weak Jacobi form of particular interest to us (see section 2.3) is where ϑ 1 is the odd Jacobi theta function and η is the Dedekind function. It has index k = 1 and weight w = −2 with the theta expansion which gives a 2-component vector-valued modular form {h µ } with weight w − 1/2 = −5/2 and µ = 0, 1. Note that µ is determined completely by ∆ as µ = ∆ mod 2, and there is only a single polar term (µ = 1, ∆ = −1). As a result, the Rademacher expansion simplifies to: where we have defined the Kloosterman sum Kl c (D) by with ν = ∆ mod 2 and ad = 1 mod c.

Kloosterman sums and quantum degeneracies of black holes
Consider Type-IIA compactified on X × T 2 where X is either T 4 or K3. We use N = 2 truncation of these theories to label the charges [3,15]. Consider a state with charge (q 0 , q 1 , q a |p 0 , p 1 , p a ). Here q 0 is the number of D0-branes, q 1 is the number of D2-branes wrapping T 2 , and q a is the number of D2-branes wrapping the two cycles Σ a in X. Similarly, p 0 is the number of D6-branes wrapping X × T 2 , p 1 is the number of D4-branes wrapping X, and p a is the number of D4-branes wrapping 4-cyclesΣ a × T 2 whereΣ a are the dual 2-cycles in X withΣ a ∩ Σ b = δ b a . We see that a = 2, . . . n v where n v − 1 is the number of JHEP03(2015)074 2-cycles on X; thus n v = 7 for T 4 and n v = 23 for K3. The electric and magnetic charge vectors Q and P are given by Let C ab be the intersection matrix for the 2-cycles of X. Then the T-duality invariants for these charge vectors (in the heterotic-like frame by analogy with the N = 4 theory) are defined by 1. One-half BPS states: when X = K3 we obtain a theory with N = 4 supersymmetry in four dimensions. We consider half-BPS states in this theory. The simplest realization of such a state has only two nonzero charges q 0 , p 1 . The degeneracies d(N ) depend only on the invariant 4 and are given [16,17] in terms of the Fourier coefficients c(N ) of F (τ ) in (2.2): One-eighth BPS states: when X = T 4 we obtain a theory with N = 8 supersymmetry in four dimensions. We consider one-eighth BPS states in this theory. The simplest realization of such a state has only five nonzero charges q 0 , q 1 , p 1 , p 2 , p 3 . The degeneracies d(∆) depend only on the quartic U-duality invariant of charges and are given [18][19][20] in terms of the Fourier coefficients C(D) of F (τ, z) in (2.16): The near horizon geometry of the black holes corresponding to these BPS states has an AdS 2 factor and the quantum entropy of these black holes is defined via a functional integral of supergravity in the framework of AdS 2 /CF T 1 holography. In the next section we turn to the evaluation of this functional integral. The Rademacher expansions (2.5) and (2.19) of the Fourier coefficients are particularly suited to compare the microscopic degeneracies with the quantum entropy obtained from this supergravity functional integral in AdS 2 . The terms with c > 1 are the nonperturbative corrections which in particular involve the Kloosterman sums and our main goal is to see how the path integral can capture this information.
The structure of the Kloosterman sums (2.5) and (2.19) is substantially different in the two cases. Remarkably, the Chern-Simons terms in the N = 8 and N = 4 theories are sufficiently different to correctly reproduce these two very different Kloosterman sums. The duality invariance of the degeneracy is not immediately obvious from the functional integral because individual terms depend on various charges and not only on the duality invariants. Fortunately, properties of Kloosterman sums make it possible to assemble the final answer into a duality invariant form as we discuss briefly in section 5.3.

JHEP03(2015)074 3 Localization and nonperturbative contributions
The supersymmetry of the formal functional integral makes it possible to apply localization techniques [3,5] to evaluate it. For this purpose we use the N = 2 truncation of the massless sector and consider only F-type chiral terms of the action for the vector multiplets coupled to the gravity multiplet. It is convenient to use the off-shell formalism for N = 2 supergravity developed in [21][22][23] in which the vielbein and its superpartners reside in the Weyl multiplet. In addition, we consider n v + 1 vector multiplets with the field content For each I, the multiplet contains eight bosonic and eight fermionic degrees of freedom: X I is a complex scalar, the gaugini Ω I i are an SU(2) doublet of chiral fermions, A I µ is a vector field, and Y I ij are an SU(2) triplet of auxiliary scalars. The N = 2 truncation of the N = 8 theory has n v = 7. 5 The chiral F-type action for these fields is described by the prepotential This prepotential describes the effective action obtained from the dimensional reduction of the two-derivative classical action. Because of N = 8 supersymmetry, there are no quantum corrections of these F-type terms. The N = 2 truncation of the N = 4 theory has n v = 23. The generalized prepotential [24,25] in this case takes the form The first term is the classical prepotential as above but now there is a one-loop correction captured by the second term. There are additional contributions at one loop level from world-sheet instantons but these can be ignored as they vanish in the background of small black holes because of additional fermionic zero modes. Near the horizon, the metric is AdS 2 ×S 2 and the values of the scalar fields are given by where e I * are the attractor value of the electric fields determined in terms of the charges (q, p). The AdS 2 functional integral is defined by summing over all field configurations which asymptote to the these attractor values with the fall-off conditions [1,2,26]: , (3.5) (3.6) 5 We use the truncation described in [4]. We first reduce N = 8 to N = 4 by dropping 4 gravitini of N = 4. This amounts to keeping only the NS-NS charges of the theory that belong to the 12 of the T-duality group SO (6,6). We then reduce further to N = 2 by dropping two gravitini of N = 2 which leaves behind 8 vector fields or nv = 7.

JHEP03(2015)074
To make the classical variational problem well-defined, it is necessary to add a boundary term to the action so the equations of motion for the gauge field are satisfied everywhere. With this boundary term, the quantum bulk partition can be naturally interpreted as an expectation value of a Wilson line inserted at the boundary The superscript refers to a finite piece obtained by a holographic renormalization procedure to remove a divergence coming from the infinite volume of the AdS 2 [2].

Localization in supergravity
It was shown in [3] from the analysis of the vector multiplets that the functional integral (3.7) localizes on a solution parametrized by (n v + 1) real parameters {C I }, I = 0, . . . , n v , and is given by the field configurations with other fields fixed to their attractor values. Note that the auxiliary fields Y I ij have a nontrivial profile indicating that the localizing saddle point is far away from the physical minimum. It was shown later in [27] that this is the most general solution even after including the Weyl multiplet. 6 The real parameters {C I } are the collective coordinates of the localizing instantons. The functional integral of supergravity thus reduces to a finite dimensional ordinary bosonic integral over {C I } with integrand the exponential of a renormalized action, thus leading to an enormous simplification [3]. Using new variables with e I * defined by (3.4), we can express the renormalized action as which has the same form conjectured in [28]. Note that, in this expression, the prepotential is evaluated precisely for values of the scalar fields at the origin of AdS 2 for the localizing solution and not at the boundary of AdS 2 . At the boundary, the fields remain pinned to their attractor values and in particular the electric field remains fixed as required by the microcanonical boundary conditions of the functional integral. The collective coordinates φ I in (3.9) fluctuate in the functional integral because C I , the parameters of the off-shell solutions, take values over the real line.

JHEP03(2015)074
For the one-eighth BPS black holes in the N = 8 theory, the horizon area is large. Moreover, the classical prepotential (3.2) is quantum-exact. The effective action involves only two-derivatives and the measure on the localizing submanifold is determined by this action. 7 Evaluating the integral over the parameters φ I with n v = 7, we obtain the Bessel function I 7/2 π √ ∆ which is precisely the c = 1 term of the corresponding microscopic degeneracy (2.18) [4].

An SL(2, Z) family of localizing solutions
The four-dimensional AdS 2 × S 2 geometry in the Type-IIA frame corresponds to a fivedimensional AdS 2 × S 1 × S 2 geometry in the M-theory frame. It can be shown [29] using localization that the entropy functional in five dimensions reduces exactly to four dimensions 8 to give the quantum entropy function (3.10). We reduce the five-dimensional theory on the S 2 to obtain 9 a three-dimensional theory. This three-dimensional point of view will be particularly useful especially when we discuss the contributions from the Chern-Simons terms.
We now describe a family of supersymmetric orbifolds which all satisfy the AdS 2 boundary conditions and admit localizing solutions. Contributions from these additional localizing saddle points precisely give rise to the nonperturbative corrections to the quantum entropy.
Let J be a generator of rotations of the round sphere S 2 and L be the generator of rotations of Euclidean AdS 2 which is a disk with Poincaré metric. Consider a Z c action generated by exp 2πi c (L − J). This preservers supersymmetry. One can accompany this twist by a shift along the coordinate of the S 1 by 2πd/c for d relatively prime to c to obtain a freely acting orbifold. 10 This gives a family of supersymmetry preserving smooth orbifolds labeled by two integers (d, c). The geometry of the AdS 2 × S 1 part of the orbifold is crucially important for our purposes which we now discuss. The action on the S 2 contributes to a phase which we discuss later in section 4.
Before taking any orbifold, the metric for AdS 2 × S 1 is where R is the attractor value of the M-theory circle near the black hole horizon. We see that the M-circle is fibered over AdS 2 because the Kaluza-Klein gauge field couples to the M-momentum which in the Type-IIA frame is the D0-brane charge q 0 .
7 There are subtleties in gauge fixing to Poincaré gravity which can affect the measure. See section 6. 8 The results of [29] are in the context of AdS2 × S 3 but extend easily to AdS2 × S 1 × S 2 . 9 The reduction on the S 2 requires care because of Dirac string singularities [30]. 10 It may appear that one can have more general shifts along the T 6 . However, we are considering an orbifold not in flat space but in the presence of the black string from the 5-dimensional point of view. If the magnetic charges of the black hole are relatively prime then the identifications along the internal torus will violate the flux quantization and hence are not allowed [31].

JHEP03(2015)074
The orbifolds must preserve the AdS 2 boundary conditions (3.5) of the functional integral. Such orbifolds are labeled by two integers (c, d). For every positive integer c, the generator for the orbifold symmetry is a supersymmetry preserving Z c twist on AdS 2 × S 2 together with a shift of d units along the M-circle S 1 . Hence d is defined only mod c. If c and d are relatively prime then the orbifold symmetry is freely acting without fixed points and one obtains a smooth manifold M(c, d). In the coordinates used in (3.12), the metric for the orbifold M(c, d) has the same form as for the unorbifolded manifold M(1, 0) but the identifications are different: 14) The family of distinct extremal solutions given by (3.12) with periodicities (3.14) all have the same asymptotics as in (3.5). To see this explicitly, it is convenient to use new coordinates so that the identifications of the new coordinates θ and y are the same as (3.13) for the unorbifolded theory. The metric now takes the form Thus, the KK gauge field has the form where A (0) is the KK gauge field when there is no shift along the M-circle. It is clear that the large r behavior of the metric and the gauge fields is the same for all M(c, d).
Hence all these orbifold geometries will contribute to the functional integral defined with the boundary conditions (3.5). The integers (c, d) are naturally identified [6,7] with the integers appearing in the microscopic degeneracy (2.1) and (2.11). It is convenient to use a particular representation of these orbifolds [7] obtained as a limit of orbifolds of global AdS 3 . There is a well-known SL(2, Z) family of configurations labelled by (c, d), that all have the same AdS 3 asymptotics [32]. These configurations are crucial in the "Farey Tail" interpretation of AdS 3 /CF T 2 [13,14,33]. We now briefly review this construction.
A cover of global AdS 3 has the metric

JHEP03(2015)074
and −∞ < t < ∞, 0 ≤ η < ∞ and 0 ≤ χ ≤ 2π. The Euclidean section is obtained by the usual Wick rotation t → it E with −∞ < t E < ∞. Thermal AdS 3 is obtained by further identifications on the cylinder with τ a complex number in the upper half plane. Topologically this is a solid torus is an open disc parametrized by (r, χ). The boundary is a torus with complex structure parameter τ and holomorphic 1-form ω := dχ + idt E . The cycle C 2 parametrized by χ is contractible and the noncontractible cycle C 1 is such 11 that C 2 ω = 2π and C 1 ω = 2πτ . The SL(2, Z) family of solutions is obtained from this basic solution by choosing a different homology class for the boundary cycle that becomes contractible in the full geometry [32,34]. To do so , consider a 'Dehn twist' on the boundary torus which relabels the cycles and takes the complex structure parameter to One would now like to fill in a smooth manifold inside this 'Dehn-twisted' boundary torus. Topologically, this operation is called 'Dehn-filling' and in fact it is possible to write a smooth hyperbolic metric on this manifold [32]. In this Dehn-filled geometry now the cycle C c becomes contractible instead of the cycle C 2 of the original thermal AdS 3 . In particular, for (c, d) = (1, 0) the contractible cycle is now C 1 which is along the time direction and hence it represents a Euclidean continuation of nonextremal BTZ black hole [35]. In the coordinates (3.16) the cycle C 1 is parametrized by −θ and C 2 is parametrized by y.
The geometries M(c, d) of interest are orbifolds of supersymmetric extremal BTZ black hole. The extremal limit of the geometries above is obtained by taking τ → ∞, keeping τ fixed [36]. This corresponds heuristically to taking the right-moving temperature in the boundary thermal CFT to zero so that the right-moving super symmetries are preserved. This is possible in the Lorentzian section in which τ and τ are no longer complex conjugates. In contrast to the AdS 3 Farey tail, the charge of the BTZ black hole and hence R is fixed while the parameter τ of the boundary AdS 3 varies. To obtain the M(c, d) geometry (3.17) with given parameters R, c, d, one must choose [7] the complex structure τ of the thermal AdS 3 such that One can now examine the localization solutions in the orbiold geometry. Because the space is still locally AdS 2 ×S 1 ×S 2 , the localization equations are not changed and therefore 11 We choose orientation such that C2 ∩ C1 = 1.

JHEP03(2015)074
we obtain the same solutions (3.8) for the orbifolds. However, the renormalized bulk action gets reduced by a factor of 1/c. As a result the Bessel functions in the Rademacher expansions (2.18) and (2.5) with an argument reduced by c are correctly reproduced for all c. The question that we now would like to address is the origin of the Kloosterman sums.

Boundary terms for the Chern-Simons action
The analysis in section 3.1 is local and is insensitive to the global properties of the orbifolds. However, the Wilson lines and the Chern-Simons terms for various gauge fields in the action are sensitive to global properties of the space M(c, d) that depend on c and d. These lead to additional contribution to the renormalized action and additional localizing saddle points specified by the holonomies of flat connections of these gauge fields. These lead to additional phases.
The gauge group in the bulk supergravity has many factors. There are several U(1) factors corresponding to the n v vector multiplets. In addition there is an SU(2) L × SU(2) R factor corresponding to the R-symmetry (after an appropriate dimensional uplift). To discuss the contributions from the higher derivative terms, it is also useful to consider the Chern-Simons formulation of gravity in AdS 3 in section 4.3 with an SL(2) L × SL(2) R gauge group. Remarkably various phases in (2.1) and (2.11) arise from intricate combinations of the boundary terms and Chern-Simons terms of these various gauge groups in the bulk supergravity. The contribution to the phases from the U(1) factors, the SU(2) R factor, and the SL(2) L ×SL(2) R factor is discussed in section 4. The contribution from the SU(2) L is discussed in section 5. In this subsection we discuss the general structure of the Chern-Simons action and the associated boundary terms for these gauge groups of interest.
Consider the Chern-Simons action for a gauge field A on the manifold M(c, d) For abelian gauge fields the trace is trivial and the cubic term is absent. For nonabelian SL(2) and SU(2) gauge fields the trace is in the fundamental representation. Asymptotically all M(c, d) geometries are AdS 2 × S 1 and have a torus boundary. One must introduce appropriate boundary terms to obtain a well defined variational problem. We describe these boundary conditions in the reference geometry M(1, 0). In the basis of cycles (C 1 , C 2 ) in (3.21), the components of the gauge field at the boundary are A 1 or A 2 . Because the Chern-Simons action is first order, we can fix only one component at the boundary. To determine the correct boundary conditions we relate the 3d theory to the 2d theory in AdS 2 where the boundary conditions are specified by (3.5). The geometry M(1, 0) is the unorbifolded extremal BTZ black hole obtained from thermal AdS 3 by a Dehn-twist by the element S = 0 −1 1 0 of SL(2, Z). Hence, the contractible cycle is now C 1 and corresponds to the boundary of AdS 2 with coordinate θ in (3.17) whereas the noncontractible cycle is −C 2 .
Demanding invariance under all eight supercharges of the five dimensional supersymmetry implies that the three dimensional gauge fields, that is, the components "orthogonal"

JHEP03(2015)074
to the sphere, are flat [30]. 12 The component of the gauge field along C 2 gives the scalar field in AdS 2 . Hence, the three-dimensional gauge field takes the form For Kaluza-Klein reduction we reexpress this field in terms of gauge invariant one-forms: and read off the two dimensional field A I (2) = −iφ I * (r − 1)dθ. This is consistent with the normalization used in [3] In AdS 2 , the constant mode of the scalar field (coming from the reduction of the 3d gauge field on the non-contractible KK circle) is nonnormalizable and hence is held fixed at the boundary to its attractor value. On the other hand, the constant mode of the 2d gauge field which is the chemical potential is normalizable and hence is allowed to fluctuate [2]. For the 3d gauge field this implies that in the quantum problem its component along the cycle C 2 is held fixed to set the boundary condition of the functional integral and the component along the cycle C 1 is allowed to fluctuate: using the fact that y is the coordinate of C 2 . In the classical problem, the component C 1 A I gets determined by physical requirements on the gauge fields in the interior which are different for different gauge fields. From this 2d analysis we conclude following [37] that the correct boundary terms for the 3d theory are given by Note that A 1 instead of A 2 were fixed, then the boundary term would be − T 2 TrA 1 A 2 d 2 x . The same reasoning applies to nonabelian gauge fields. For example, for the SU(2) R gauge field, the Wilson line along the boundary cycle C 2 of AdS 2 is the angular momentum J R . The AdS 2 boundary conditions imply that J R = 0 so that index equals degeneracy [38] Tr(−1) J R = Tr(1). (3.29) In other words, we fix the Wilson line The phases that assemble into the Kloosterman sum arise essentially from the boundary Wilson lines and the Chern-Simons action evaluated for the flat connections of various 12 After localization the configuration needs to be invariant under one supercharge. This allows for a non-flat profile for the gauge field, as we discuss later.

JHEP03(2015)074
gauge fields. We now explain the general philosophy behind these computations. For this purpose, it is useful to parametrize the Wilson lines along the basis cycles C 1 and C 2 by For a given manifold M(c, d) we will need to know also the Wilson lines around the contractible cycle C c and noncontractible cycle C n . We parametrize these by two real numbers α and β as It follows from (3.21) that The boundary action (3.28) can be readily evaluated given γ and δ. Evaluation of the bulk action (3.24) is more nontrivial but using a result (4.28) from the work of [39], it can be computed easily knowing α and β. Our problem thus reduces to computing γ and δ because α and β are determined using (3.33). In the physical problem at hand, δ is specified by the boundary condition (3.27) but γ is not specified directly. It has to be determined from physical considerations as we discuss in the next section.

Phases from Wilson lines and Chern-Simons terms
In this section we will evaluate the phases in the Kloosterman sums by two different methods. In section 4.1 and section 4.2 we use the metric formulation of supergravity which admits an off-shell completion to evaluate the phases. The computation is then justified by localization of the path integral on M(c, d). In section 4.3 we use the on-shell Chern-Simons formulation of gravity to give a simpler rederivation of the same result. The on-shell computation is justified heuristically by the fact that the phases are essentially topological in origin.

Phases from boundary Wilson lines and abelian Chern-Simons terms
To understand the possible phase contributions arising from the abelian sector, we need to first work out the different boundary terms in five dimensions. This construction is similar to the one presented in [29]. Supersymmetry requires that the abelian gauge field be flat at infinity [30]. As a result, variations of the Maxwell terms do not generate any boundary terms. 13 On the other hand, the Chern-Simons terms require a careful treatment, as explained in section 3.3. These terms after a circle reduction to four dimensions lead to the Wilson lines on the AdS 2 boundary (3.7). Since the metric gives rise to a Kaluza-Klein gauge field in two dimensions with a non-zero electric field, normalizable fluctuations 14 of this metric component lead to an additional boundary term. 13 In the previous version of the paper these were treated incorrectly. 14 By normalizable we mean the fluctuations which leave the electric field fixed as required in AdS2.

JHEP03(2015)074
Consider the five dimensional abelian Chern-Simons action. To simplify the analysis, we reduce it on an ungauged S 2 and "diagonalize" the Chern-Simons couplings using the intersection matrix C ab introduced in section 2.3: with a, b = 2, . . . , n v . This rewriting simplifies the computation of on-shell values of the fields. The boundary terms for the resulting 3d Chern-Simons action are as in section 3.3: As explained before (3.27) the component A I 2 is fixed 15 to its attractor value A I 2 = 2φ I * /φ 0 * . Let us first consider how to obtain the two dimensional Wilson lines from the Chern-Simons terms in the unorbifolded theory. To perform localization as in [29] we need to rewrite the Chern-Simons action in terms of two dimensional quantities, that is, we write the three dimensional gauge field as where A 2I is the gauge field living on AdS 2 . In rewriting this way we generate non gaugeinvariant terms in two dimensions. Integrating by parts solves the problem but gives additional boundary terms via total derivatives. For instance in the simple example of only one gauge field we obtain Integrating the total derivative gives an additional boundary contribution. To compute the boundary terms we take the off-shell solution allowed by localization. The two dimensional electric fields are fixed to their on-shell values but the scalars χ I have a non-trivial profile [3,29], that is, with C I , C 0 constants. The total boundary term in two dimensions coming from the treatment of the Chern-Simons terms thus has two parts: 15 We use R = −2/φ 0 * which follows from the 4d-5d dictionary [29]. See section 4.3 for a simpler derivation.

JHEP03(2015)074
where we denote the combinationχ a = χ a + p a /p 1 χ 1 and similarly forφ a = φ a + p a /p 1 φ 1 , and "finite" stands for the finite piece as r → ∞. We have to be careful in taking the limit because χ has subleading terms in 1/r. We find that the final result is independent of these subleading terms and we obtain where q J , with J = 1 . . . n v , are the two dimensional charges. It is interesting to observe that these boundary contributions do not depend on the value of the gauge field along the cycle C 1 . To appreciate this, note that for very large r we have where C I are the constant modes allowed by localization. We will argue that this is also true in the orbifolded theory so that only the KK Wilson line boundary term gives a non-trivial phase. We now consider the boundary term for the Kaluza-Klein gauge field. After reducing the five dimensional Ricci scalar down to AdS 2 we obtain a Maxwell term where R is the Ricci scalar (not to be confused with the fiber radius R), and F KK is the Kaluza-Klein gauge field strength. The Maxwell term gives rise to a boundary Wilson line as explained in [1,29] (4.11) We have used the on-shell value of R (4.51). Putting this boundary term together with (4.8) we obtain, at the on-shell level, the two dimensional Wilson lines on AdS 2 as indicated in (3.7): where the index on the r.h.s. of the expression now runs in the interval I = 0 . . . n v and we have used the on-shell values of the fields obtained via a saddle point of the entropy function (3.10). The bulk gauge-invariant action living in AdS 2 is the same as considered originally in [3] and therefore the action on 16 There is an overall charge dependent factor multiplying the five dimensional Ricci scalar. This factor is proportional to CIJK σ I σ J σ K , where σ I is the five dimensional vector multiplet scalar which has on-shell value σ I = p I , the magnetic charge [30]. The coefficient of the Ricci scalar is proportional to p 1 P 2 with the correct normalization fixed by the value of the central charge computed in three dimensions.

JHEP03(2015)074
the localization locus including the boundary terms gives precisely the Bessel function as derived in [4]. Let us now consider the orbifolded theory. From a ten dimensional point of view, the geometry is locally AdS 2 × S 2 × T 6 . Instead of taking the ten dimensional geometric point of view, we need to consider the reduced five dimensional theory for which we have an offshell representation. Orbifold action of shifts can be equivalently interpreted as turning on a constant mode for the abelian fields living in five dimensions. Localization fixes the two dimensional gauge fields to their on-shell values [3,29] and since these equations only allow for smooth field configurations living on AdS 2 the 3-dimensional gauge field is completely determined to be 17 where both φ I and φ 0 have the localization profile andθ has periodicity 2π/c. Note that A 3I asymptotes for large r to (4.9) and therefore we see that, from a three dimensional point of view, we are in fact integrating over the constant mode. The computation is similar to the one in the unorbifolded theory except that now the volume gets divided by a factor of c.
On the other hand, the boundary Wilson line (4.11) for the KK gauge field gives a non-trivial phase via the shift (3.14) Note that in this case there is no bulk singularity. The orbifold is freely acting and as a consequence the curvature is smooth everywhere. The KK reduction is always of the form (4.10) with the field strength F KK smooth on AdS 2 with the volume reduced by a factor of c. We will present a different derivation of this result in section 4.3 where we show that this phase comes precisely from the boundary terms in the SL(2, R) Chern-Simons formulation. For the black hole under consideration we have P 2 = 2 and p 1 = 1 so that the SU(2) R level becomes k R = 1. At the on-shell level the three dimensional gauge field is given simply by A 3I = 2φ I * /φ 0 * dy and the holonomy along the contractible cycle cC 1 +dC 2 becomes trivial as required exp i where we have used the on-shell values of the fields. In this case, under a electric-magnetic duality transformation In the previous version of the paper the two dimensional gauge fields had delta function singularities at the origin which however is forbidden by localization.

Phases from SU(2) R Chern-Simons terms
The Killing spinor ξ on AdS 2 × S 2 associated with the supercharge used for localization has the schematic form where φ is the azimuthal coordinate on the S 2 and η is a Dirac spinor independent of both θ, φ. Under the orbifold identification (3.14) this spinor picks a non-trivial phase and would not be invariant [5]. To preserve the supercharge we turn on an SU(2) flat connection on S 2 so that its holonomy along the cycle C 1 parametrized byθ gives a compensating phase. This together with (3.30) implies where A R = i 2 A a σ a is in the fundamental of SU(2). The boundary contribution to the action (3.28) vanishes because Wilson line along C 2 is fixed to zero. The bulk Chern-Simons action for the SU(2) gauge field is then of the form with k R = p 1 P 2 /2 which can be obtained from the Kaluza-Klein reduction of fivedimensional action of M-theory [40]. We thus need to compute the Chern-Simons integral (3.24) for flat connections subject to the boundary conditions (4.22). This requires some mathematical machinery, which fortunately has been developed earlier in [39] for computing Chern-Simons invariants of Lens spaces. We review this computation, especially theorems 4.2 and 5.1 in [39]. Our manifold of interest M(c, d) is topologically a solid torus D 2 × S 1 . We parametrize the solid torus using the coordinates (r, x c , x n ) and orientation (∂ r , ∂ c , ∂ n ). Here x c , x n ∈ [0, 2π] are the meridian and longitude directions, that is, they parametrize the contractible and non-contractible cycles respectively, while r ∈ [0, 1] parametrizes a radial direction. A flat connection is always pure gauge In [39] it is shown that we can always bring the gauge transformation g to a form Using the flatness condition dA + A ∧ A = 0 one then obtains Integrating over x n yields precisely dω and by Stokes' theorem we get the desired result which enables us to evaluate the bulk actions given α and β. Given (3.29) and (4.22), it is easy to compute α and β for the SU(2) R gauge field: and We thus conclude α = −1 and β = −a/c. Note that α must be an integer because the holonomy exp ( Cc A) around the contractible cycle must be trivial for A in the vector representation. On the other hand, β can be real. The total contribution from the SU(2) R action is (4.31)

Phases from gravitational Chern-Simons terms
We have seen that the SU(2) R Chern-Simons terms contribute a phase with k R the SU(2) R Chern-Simons level. On the other hand, the microscopic counting formulae for half-BPS and quarter-BPS states in N = 4 string theory [41], imply that the Kloosterman sums should carry a phase proportional to the left-moving central charge c L in the sector where supersymmetry is broken: In the boundary theory, we have an affine SU(2) R current algebra with level k R which is related by supersymmetry to the right-moving central charge as c R = 6k R . However, in general, c R = c L which leads to a puzzle of explaining this discrepancy between the boundary and the bulk.

JHEP03(2015)074
For the N = 8 theory, c L = c R and one does not encounter this puzzle. However, N = 4 actions contain gravitational Chern-Simons terms in three dimensions [42] that are responsible for the difference between c L and c R . We now show that these terms contribute with additional phases that precisely resolve this discrepancy between the bulk and the boundary. For computing the phases using (4.28) we need the holonomies along the contractible and non-contractible cycles. Their computation is considerably simpler [43] if we use the Chern-Simons formulation of the three dimensional gravity which we now describe. 18 It is well known that the Einstein-Hilbert action 19 with negative cosmological constant plus gauge and gravitational Chern-Simons terms can be written only in terms of the SL(2, R) L × SL(2, R) R connectionsÃ L,R and SU(2) R connections A R as withk L = c L /6 andk R = c R /6. As discussed in section 3.3 we need to add appropriate boundary terms. The analysis is similar to the SU(2) case except that for SL(2, R) the Wilson lines can be complex instead of imaginary. At the on-shell level both A L,R are flat and therefore we need to compute the Chern-Simons integral of an SL(2, R) flat connection. We view AdS 3 as the group manifold SO(2, 2)/SO(2, 1) so that thermal AdS 3 corresponds to the identification where X is an element of SO (2,2)  Similarly we could have considered Euclidean AdS 3 under the indentification X ∼ ρ(τ )Xρ † (τ ) with ρ(τ ) a diagonal subgroup of SL(2, C) and take τ and τ independent. The first element in (4.36) corresponds precisely to the holonomy ofÃ L around the noncontractible cycle whereas the second element corresponds to the holonomy ofÃ L around the contractible cycle [44]. In the Euclidean case the right quotient is generated by elements that are just hermitiean conjugates g R = g † L and correspond similarly to the holonomies ofÃ R around the non-contractible and contractible cycles. We can read off easily the corresponding Wilson lines in the extremal limit τ → ∞ CnÃ L = 2πi (4.38) 18 The usual metric formulation requires a suitable choice of coordinates which complicates the computation. 19 We weight the Euclidean functional integral by e S .

JHEP03(2015)074
Given these Wilson lines it is easy to determine the Wilson lines along the cycles (C 1 , C 2 ): As explained before, the boundary conditions fix the Wilson lines along the C 2 cycle. Note that first condition in (4.39) is nothing but the requirement that the radius R in the metric (3.12) is held fixed. As discussed in section 4.1 the Wilson lines along the C 1 cycle in the classical problem are determined by regularity. Given the Wilson lines we can use the result (4.28) to compute together with the boundary terms Putting it together, we compute the total action (4.34) including the boundary terms. The SL(2) R and SU(2) R terms cancel because by supersymmetryk R = k R and we obtain (4.43) where we have used c L = 6k L . Using the equalities we write (4.43) as (4.45) Using (3.23) we can reexpress it in terms of the radius R The term in the first bracket is real and can be identified with classical entropy of the black hole reduced by a factor of c if This gives the correct entropy S BH for these black holes from the real term in (4.46). We can therefore rewrite (4.45) as S = 1 c S BH + 2πi(phase) .

JHEP03(2015)074
where S BH is the on-shell classical black hole entropy. Our analysis in this section is for the on-shell theory. We believe that this result can be extended to the off-shell theory in which case we would replace S BH by the off-shell renormalized action (3.10) whose extremum value gives S BH . Since the phase of our interest is topological coming from terms supported only at the boundary we expect that it will be the same also in the off-shell extension of our results. We see now that the coefficient multiplying a/c in (4.46) is in fact proportional to c L /24 which resolves the puzzle posed in the beginning. For half-BPS states in N = 4 theory we have 20 Hence, the total phase from this sector by exponentiating the imaginary part in (4.46) is For the one-eighth BPS states in the N = 8 theory, we have where we have used p 1 = 1 so that 21 Recalling that k L = k R in the N = 8 theory, we see that the phase (4.53) reproduces the product of the phases (4.31) and (4.16) derived previously.

The multiplier system and duality invariance
The phases that we have worked out thus far are common to all known models with at least eight supercharges. We now turn to the computation of the multiplier matrix M (γ) µν which is crucial for invariance of the Rademacher sum under the elements Γ ∞ ∈ SL(2, Z). This ensures that we are not overcounting geometries.
To set up the computation we first describe an explicit representation the multiplier matrix in section 5.1 following the work of [10]. In section 5.2 we give a physical interpretation of this representation in terms of SU(2) L Chern-Simons path integral. Recall that the degeneracy of one-eighth BPS black holes in 4d is the same as the degeneracy of one-quarter BPS black holes in 5d. By the 4d-5d lift the charge q 1 in the presence of a KK-monopole with charge p 1 = 1 can be identified with the spin of this 5d black hole. This

JHEP03(2015)074
black hole is an excited state of the D1D5P Strominger-Vafa black string in six dimensions with near horizon AdS 3 ×S 3 . As a result, the near horizon theory has (4, 4) supersymmetry and SU(2) R × SU(2) L R-symmetry to start with. This is a geometric symmetry of the S 3 which is broken to SU(2) R × U(1) L by the spin of the black hole.
While localization fixes the holonomy of the SU(2) R flat connection on both contractible and non-contractible cycles, for the SU(2) L sector there is no such restriction and we have to sum over the holonomies. The Chern-Simons action with boundary terms for these flat connections combines to reproduce the multiplier matrix M (γ) up to a non-trivial phase which can be related to a choice of framing as we discuss in section 5.4.

An explicit expression for the multiplier system
The matrix M (γ) realizes a representation of SL(2, Z) in the space of vector-valued modular forms. It appears in the generalized Kloosterman sum via its inverse. It is easy to determine the matrix M −1 (γ) for the S, T generators of SL(2, Z) from the definition (2.9) and the transformation properties of the theta functions: To find M −1 for a general element γ, we can use its continued fraction expansion and iteratively compute the matrix M −1 via the images (5.1) Even though this is conceptually straightforward, it is nontrivial to obtain a useful explicit expression from this formula. Fortunately, this problem has already been addressed by Jeffrey [10] in the context of knot theory to construct the Chern-Simons partition function using the surgery formula of Witten [11]. In the following we use her results to construct an explicit representation for the multiplier matrix which is particularly amenable to a simple physical interpretation. This connection to knot invariants via Chern-Simons theory is not accidental as we explain in section 5.4. Jeffrey uses the representations of S, T ∈ SL(2, Z) given by with the basis j, l running from 1 to r − 1, and r is the "renormalized" Chern-Simons level, that is, r = k + 2 for SU(2) gauge group. Since we have k = 1 then r = 3, and therefore the representation is two dimensional with j, l = 1, 2. Identifying the basis j, l with our basis ν, µ in (5.1) as j = ν + 1 we observe that S jl and T jl in (5.4) are the same as M −1 (S, T ) in (5.1) up to an overall phase, that is,

JHEP03(2015)074
Our general representation for (5.3) has an additional phase relative to the result in [10]: whereŨ is given by proposition 2.7 in [10] with Φ(γ) the Rademacher phi function defined as This phase is reminiscent of the framing correction in knot theory. We discuss this connection in section 5.4. The final result for the multiplier matrix is then where the prefactor is It can be shown from this expression that the generalized Kloosterman sum depends only on the equivalence class Γ ∞ \γ/Γ ∞ where we need the matrix elements M −1 (γ) ν1 for ν = 0, 1.

A physical interpretation from SU(2) L Chern-Simons theory
To compute the boundary contribution (3.28) for the SU(2) L gauge field, we need the Wilson lines along the cycles C 1 and C 2 . These in turn determine the Wilson lines along the cycles C n and C c parametrized by α and β in (3.32) which can be used to compute the bulk action (3.24) using the theorem (4.28). As explained in section 3.3, the Wilson line δ around the cycle C 2 is fixed by the boundary condition. Because Q.P is the spin J L of the black hole in 5d under SU(2) L , this implies The Wilson line γ around the cycle C 1 is determined by demanding that the holonomy around the around the contractible cycle in the vector representation must be trivial. Since we are working in the fundamental representation and since C c = cC 1 + dC 2 we require exp c Therefore, using (5.15) and defining ν by we get To determine the conditions n ∈ Z/cZ and λ = 0, ±1, we need to examine the symmetries of the exponential of the Chern-Simons action. As a matter of fact it would be enough to consider λ = 0, 1 so that (5.16) is satisfied. However, as we see next, the exponential of the Chern-Simons action is different for λ = ±1 and therefore we should consider this other possibility. The Wilson lines are computed to give Given γ and δ, the boundary action (3.28) becomes and given α and β, the bulk Chern-Simons action (3.24) becomes

JHEP03(2015)074
Putting both terms together we arrive at where we define λ = µ/k L and = ±1. When we exponentiate this expression and sum over sectors we get precisely the Kloosterman phase under the sums in (5.13) except that there the constants k and ν, µ are renormalized to k + 2, ν + 1, µ + 1 respectively. It is well known that the Chern-Simons level k L gets renormalized. In our computation ν, µ could possibly get renormalized if the boundary conditions on the holonomies get shifted appropriately. The prefactor C of the multiplier matrix (5.13) does not follow from our classical evaluation but it could possibly arise from one-loop corrections of the localization action. Indeed, in the context of localization of Chern-Simons theory on Lens spaces, such a phase proportional to the Rademacher phi function is known to arise precisely in this manner [45,46]. There is a natural connection of our computation to knot theory on Lens space and Witten's surgery formula which we elaborate in section 5.4. An extension of the results (5.30) and (5.31) from knot theory could explain both the renormalization of k L , ν, µ and the prefactor C.
There is one puzzle that we do not fully understand. The U(1) part of the SU(2) L gauge field can be identified with the U(1) abelian gauge fields that couples to the charge q 1 . This can be seen using for example by using 4d-5d lift in which electric charge q 1 in 4d in the presence of a KK monopole of charge p 1 = 1 gets identified with the spin J L . For charge configurations with q 1 = 0 there seems to be a puzzle because this U(1) gauge field is apparently counted twice in computing both the phase in section 4.1 as well as the multiplier system in this subsection. However, note that the action used in this subsection is obtained by truncating a 6d theory on an S 3 , whereas the action used in section 4.1 is obtained by first reducing on a circle and then truncating on an S 2 . It would be necessary to understand the precise map between these truncations to resolve this puzzle.

Duality invariance and Kloosterman sums
We now analyze the total phase after summing over sectors assembling all terms. Duality invariance of the resulting answer is not immediately obvious and requires nontrivial identities for the Kloosterman sum.
For the half-BPS black holes 22 there is no multiplier system and duality invariance is relatively easy to prove. The total phase is For p 1 = 1 this is in perfect agreement with (2.5) with N = −q 0 . 22 These black holes are 'small' [47] in that their horizon area is of order one in string units. As a result, one does not really have a geometric picture. However, the localization solutions depend essentially on the symmetries of AdS2 and the Kloosterman sum is topological which can partially justify our supergravity reasoning which in any case seems to lead to a striking agreement. Similar phases are expected to be relevant for large black holes.

JHEP03(2015)074
For general p 1 , we get the classical Kloosterman sum Kl(−q 0 , −p 1 , c) defined in (2.1). At first sight it does not seem duality-invariant. However, using the fact that q 0 and p 1 are relatively prime, and choosing p = p 1 , n = −q 0 , m = −1 in (2.7) we get in perfect agreement with the duality invariant formula (2.5).
For the one-eighth BPS black holes we choose k L = 1 and the total phase is Considerations of duality invariance thus suggest interesting identities for the Kloosterman sum. For example, for a general k L , it should be possible to obtain the duality invariant answer as above. However, it would require a generalization of the identity (5.25) for the generalized Kloosterman sum which to our knowledge is not known in the mathematics literature. Another important classical identity is the Selberg identity A generalization of this identity could play a role in the context of black holes with nonprimitive charge vectors [18,[48][49][50][51].

Relation to knot theory
Several ingredients that we have encountered in our computation of the Kloosterman sums are reminiscent of knot theory in Lens space L(c, d). This is not a coincidence and follows from the fact that Chern-Simons theory on the Dehn-filled solid torus can be related to the surgery formula of Witten [11] for the unknot in the Lens space. Let us recall a few facts about the surgery formula. Any three manifold M without boundary can be obtained by Dehn surgery on a link L on another manifold M . This procedure consists in removing a tubular neighborhood Tub(L) in M and glueing it back, after an SL(2, Z) diffeomorphism of the boundary of Tub(L).
As an example, consider Lens space which can be constructed as follows. Consider M = S 2 × S 1 which is the union of two solid tori X 1 = D 2 × S 1 and X 2 = D 2 × S 1 glued at the boundary by the identity element. This means that we identify the boundary cycle of the first disk with the boundary cycle of the second disk and the same for S 1 . On the other hand, if we glue the boundary of the first disk with the circle S 1 of the second solid torus and vice-versa, then we obtain the manifold M = S 3 . This corresponds to a Dehn twist by the element S of SL(2, Z). The Lens space L(c, d) is obtained as a union of the two tori after a general Dehn twist by an element γ. To make contact with the surgery described earlier, we see that M = S 2 × S 1 , M = L(c, d), X 1 = Tub(L) for the unknot L which is glued back to X 2 = M \X 1 after an SL(2, Z) twist. In this case, X 2 is also a solid torus and to be consistent with our notation in the rest of the paper, we perform the Dehn twist on the boundary of X 2 . To be more precise take C 1 to be cycle on ∂X 2 that becomes JHEP03(2015)074 By computing explicitly this matrix element in [10], Jeffrey was able to obtain exact result for the path integral (5.28) for Lens space. Moreover, (5.30) implies that the Chern-Simons integral on M(c, d) with the boundary conditions (5.29) must equal e iφ f r V (c,d) 1j . This makes contact with the black hole problem if the matrix V (c,d) can be identified withŨ (c,d) . We see that up to the sign( d c + ν) in (5.32), our multiplier system is precisely the matrix in (5.31). It seems though that in the black hole context more general boundary conditions are relevant because we need the matrix elementsŨ (c,d) 21 andŨ (c,d) 22 . We have seen in section 4.3 that the phases in the Kloosterman sum can be computed from the on-shell SL(2) Chern-Simons theory whereas the multiplier matrix comes from the SU(2) L Chern-Simons theory. It raises the intriguing possibility that the entire Kloosterman sum, which has deep connections in number theory, can perhaps be related to a topological computation in knot theory for SL(2) × SU(2) and appropriate Wilson lines, even in the general case (2.11).

An assessment
The program of computing the fully quantum corrected entropy of supersymmetric black holes has evolved considerably over the past few years. A number of difficult hurdles have been overcome and there has been some important progress that brings us very close to this goal. We now give an assessment of the status.

Solved problems
• Choice of the ensemble: even though the Bekenstein-Hawking entropy is independent of the choice of the ensemble, the finite size subleading corrections to the entropy depend sensitively on the choice of the ensemble. The AdS 2 boundary conditions imply that the microcanonical ensemble is a natural choice [1,2]. As we have seen, the boundary conditions set by this ensemble play an important role in our computations of the Kloosterman sums.
• Relation between index and degeneracy: black hole entropy must correspond to the total degeneracy by Boltzmann relation. On the other hand, the microscopic degeneracies are usually computed using a spacetime index. It is not clear a priori why the two should agree. There has been considerable confusion on this issue. The AdS 2 boundary conditions explain that the index equals the degeneracy near the horizon of a single black hole [38]. In general there are additional contributions to the spacetime index from degrees of freedom outside a single horizon [53,54] which can complicate the comparison [41,55]. However, for the two examples considered in this paper such 'hair' degrees of freedom are absent which allows for a direct comparison.
• Localization in supergravity: the formal supergravity functional integral could be evaluated only because localization reduces it to a finite-dimensional integral. The localizing instantons have simple analytic expressions for supergravity coupled to vector multiplets [3]. They are universal because they depend only on the off-shell supersymmetry transformations that are independent of compactification and the JHEP03(2015)074 physical action. It has been shown subsequently that other modes of the supergravity multiplet do not play a role in localization [27] and hence these are the most general solutions. To our knowledge this is the first application of localization in a gravitational context. It may appear that the metric does not play any role in localization however that is because in the superconformal formalism, we have chosen a gauge that trades off the conformal factor of the metric for a compensating scalar field. Thus, the conformal mode of the physical metric does have a nontrivial profile for the localizing solution.
• Contribution from D-type terms: in the physical action we only considered chiral superspace integrals governed by a prepotential (F-type terms) and ignored full superspace integrals (D-type terms). It was shown in [56] using the enhanced supersymmetry of the near horizon geometry that the on-shell classical entropy of BPS black holes in N = 2 theories does not receive any contributions from a large class of D-terms. However, in the context of localization, one must show that D-terms do not contribute to the off-shell renormalized action evaluated on the universal localizing solutions. This was shown in [57] for the class of D-terms considered in [56], thus providing a justification for our analysis that ignores the D-type terms.
• Origin of nonperturbative corrections and phases: the results of this paper make clear that the supergravity functional integral is fully capable of reproducing not only the perturbative corrections to the Bekenstein-Hawking entropy but also the nonperturbative corrections including all intricate details of the Kloosterman Sum. In the broader context of quantum holography, the finite charge corrections considered here correspond to finite N corrections that are perturbative (expansion in 1/N 2 ) and nonperturbative (expansion in e −N 2 ). It is remarkable that the quantum gravity functional integral in this case can capture all these corrections.

Open problems
• Contribution from hypermultiplets and gravitini : we have analyzed the N = 8, 4 theories in their N = 2 truncation. The near horizon geometry of these black holes only has N = 2 symmetry so for the purposes of the finding the localizing solutions such a truncation is justified. However, this is a truncation and not a reduction because the masses of the gravitini multiplets that are ignored are of the same order as the scale of the black hole horizon. As a result these multiplets can make a contribution to the the one-loop determinants. Similarly, the hypermultiplets are known not to contribute to the classical entropy but could in principle contribute at the quantum level. The striking agreement with the microscopic answers, as well as the macroscopic one-loop determinants [58] does suggest that the combined effects of the fields that are not kept in the truncation is not significant for our problem at hand. To settle this issue definitively one would require an off-shell realization of the two supercharges used for localization but for all fields including the additional gravitini and hypermultiplets. This is an interesting problem in supergravity.

JHEP03(2015)074
• Localization in supergravity: implementing localization in a theory of gravity is subtle because the choice of the localizing supercharge requires a background metric. We have treated the metric as any other field in a fiducial background. This introduces an arbitrary background dependence. It should be possible to implement localization in a background independent way.
• A puzzle: The gauge fields in our problem are all abelian. Consequently, the offshell supersymmetry transformations are quadratic and as a result the quadratic fluctuation determinant of the localizing action around the localizing saddle point would seem to not depend on the collective coordinates {C I } of these instantons. Thus, unlike in analogous problems in nonabelian gauge theories [59], the one-loop determinants appears to be independent of the {C I }. This raises a puzzle. The logarithmic correction to the entropy of a black hole of horizon area A H in N = 2 supergravity coupled to n v vector multiplets has been found to be 23−nv 12 log A H from the one-loop contribution the on-shell effective action. In our off-shell analysis, we find, instead − nv+1 2 log A H . A possible source of this discrepancy is our gauge-choice which trades the conformal factor of the metric for a scalar field in the superconformal gravity which can lead to area dependent overall normalization of the degeneracy and thus to a logarithmic contribution to the entropy. Investigations on this front, which also addresses the first puzzle about the truncation, are currently underway [60,61].