Twisted 6d $(2,0)$ SCFTs on a Circle

We study twisted circle compactification of 6d $(2,0)$ SCFTs to 5d $\mathcal{N} = 2$ supersymmetric gauge theories with non-simply-laced gauge groups. We provide two complementary approaches towards the BPS partition functions, reflecting the 5d and 6d point of view respectively. The first is based on the blowup equations for the instanton partition function, from which in particular we determine explicitly the one-instanton contribution for all simple Lie groups. The second is based on the modular bootstrap program, and we propose a novel modular ansatz for the twisted elliptic genera that transform under the congruence subgroups $\Gamma_0(N)$ of $\text{SL}(2,\mathbb{Z})$. We conjecture a vanishing bound for the refined Gopakumar-Vafa invariants of the genus one fibered Calabi-Yau threefolds, upon which one can determine the twisted elliptic genera recursively. We use our results to obtain the 6d Cardy formulas and find universal behaviour for all simple Lie groups. In addition, the Cardy formulas remain invariant under the twist once the normalization of the compact circle is taken into account.


Introduction
Interacting conformal field theories in dimensions larger than four is one of the most remarkable discoveries in string theory. Many of them do not have a Lagrangian description, and to study their dynamics we have to make full use of our knowledge on string theory accumulated in the past few decades. Six is known to be the maximal dimension allowing for their presence [1], so one naturally starts from theories in six dimensions. In particular, 6d N = (2, 0) superconformal field theories (SCFTs) can arise from type IIB string theory on the ALE spaces C 2 /Γ ADE [2,3]. Theories of A and D types can also be engineered on parallel M5 branes without or with OM5 plane. These theories in the tensor branch have 1/2 BPS self-dual strings and 1/2 BPS massless tensor multiplets [4]. Furthermore, these 6d (2, 0) SCFTs can be compactified on a circle S 1 and the resulting low energy 5d theories are 5d N = 2 supersymmetric gauge theories with simply-laced ADE type gauge groups. The instantons of these 5d theories play the role of Kaluza-Klein (KK) modes of the compactification [5]. The massless tensor multiplet becomes either 1/2 BPS instantons without electric charge or massless vector multiplet in the Coulomb branch. The winding self-dual strings become 1/2 BPS W-bosons and the unwound self-dual strings become magnetic monopole strings in the Coulomb phase.
A further compactification of the 5d theory of ADE type on a circleS 1 with outerautomorphism twist leads to the 4d KK theories with twisted affine algebra G (n) [6]. The exchange of ordering of two compactifications is the 4d S-duality and provides the 5d N = 2 supersymmetric gauge theory with non-simply-laced group. This 4d S-dual, or Langlands dual, of the twisted affine Dynkin diagram is the untwisted affine Dynkin diagram of non-simple-laced group. Thus 5d N = 2 gauge theory can be obtained by the twisted compactification of the 6d (2, 0) SCFTs of A, D and E 6 types. This will be explained in more detail in section 2. The low energy dynamics of these twisted theories are the 5d N = 2 theories with the non-simply-laced group B r = SO(2r + 1), C r = U Sp(2r) 0 , (C r ) π = U Sp(2r) π , G 2 and F 4 [6]. There are two kinds of 5d U Sp(2r) gauge theories with adjoint flavor, depending on the discrete theta parameter being 0 or π, which is sensitive to the homotopy group π 4 (G). The exact correspondence between the 6d (2, 0) theories and the 5d N = 2 theories of non-simply-laced groups and the corresponding insertion of orientifold planes are given in table 1.
In this work, we also want to explore the physics of these 5d theories directly from twisting the 6d theory. A very partial list of this approach can be found in [7][8][9][10][11][12][13][14][15][16] and references therein. For us, one of the main interests is the elliptic genus of the BPS strings in the 6d (2, 0) theories with twisted circle compactification. The 6d partition function for the counting of BPS states of BPS strings with KK momenta would be equivalent to the 5d partition functions for dyonic instantons. From the 4d S-dual perspective, magnetic monopole strings in the twisted compactification of the 5d ADE theory with KK momentum but without electric charge and instanton number would correspond to these self-dual strings.
6d theory twist 5d theory Γ 0 (n G ) orientifold First of all, we analyze the BPS objects of these twisted theories from the 5d point of view by studying the blowup equations of the 5d instanton partition function. The original blowup equations were derived by Nakajima and Yoshioka, in order to prove that the Nekrasov's instanton partition function gives a deformation of the Seiberg-Witten prepotential for four dimensional N = 2 supersymmetric gauge theory on C 2 . Later on, they generalised them to five dimensional gauge theories and obtained K-theoretic blowup equations [17], which count K-theoretic Donaldson invariants as discussed in a paper with Göttsche [18]. Based on [19,20], in [21], a geometric description was proposed, which makes it possible to define blowup equations for non-Lagrangian theories like local P 2 . In [22], the geometric description was generalised to all KK theories of 6d SCFTs, and was used to bootstrap the BPS invariants of the KK theories. The blowup equations are functional equations, which turn out to be very powerful tool to bootstrap the BPS invariants, instanton partition functions/elliptic genera for various 5d/6d SCFTs [21][22][23][24][25][26][27][28]. In particular, the elliptic blowup equations for 6d (2, 0) ADE M-strings were proposed in [27]. However, the number of the equations is not enough to solve the elliptic genera recursively. Thanks to the 5d KK theory description of the 6d theory, we develop novel methods to bootstrap the instanton partition functions and the BPS invariants, which helps to recover the information of the elliptic genera. Utilizing our method, we manage to compute the exact one-instanton partition functions for all exceptional Lie groups with adjoint matters, when turning off gauge fugacities. We also study the (elliptic) blowup equations for the 6d (2, 0) KK theory with twisted circle compactifications.
Secondly, as mentioned before, from the 6d point of view we should study the elliptic genus of effective strings. The elliptic genus is known to transform as a Jacobi modular form of weight zero, which imposes very strong constraints on its structure. To make full use of it, we come up with a physically motivated ansatz compatible with the modular property, and we are left with a finite number of undetermined coefficients. If one can find sufficiently many extra constraints either from gauge theory or geometry, one is able to fix all the unknowns and hence the elliptic genus itself. This approach is often dubbed modular bootstrap [29][30][31][32][33][34][35][36], and was successfully applied to compute the elliptic genera of various (1, 0) and (2, 0) SCFTs in 6d. This method is also applicable to compact elliptically fibered Calabi-Yau (CY) threefolds [37,38], leading to interesting results on Heterotic/Type II string duality [39,40], black hole physics [41] and swampland conjectures [40,[42][43][44], to name a few.
In this paper, we find a lot of evidence that after twisted compactification of (2, 0) SCFTs to 5d, there exists a twisted version of the elliptic genera that are covariant under congruence subgroups Γ 0 (N ) of SL(2, Z), which is shown in table 1. Geometrically, this should correspond to the topological string partition function on genus one fibered CY threefolds upon which M-theory compactifies [10]. We develop novel modular ansatz for 6d twisted (2, 0) theories and determine the elliptic genera at low base degrees using conjectural vanishing conditions for the corresponding genus one fibered CY threefolds, extending the previous work [35]. We emphasize that although the twisted elliptic genera are not related to the 6d elliptic genera in an apparent way, the choice of subgroups indeed coincides nicely with one's expectation from twisting the theory, which is not at all obvious from the perspective of 5d instanton dynamics.
This paper is organized as follows. In section 2, we analyze in detail the procedure of twisted circle compactification of (2, 0) SCFTs to 5d N = 2 gauge theories. We also discuss the effect of twisting on the self-dual strings. Then we move on to determining the partition functions. In section 3, we tackle this problem from the perspective of instanton counting. In particular, we show how to bootstrap the instanton partition function using the blowup equations with adjoint matters. In section 4, our starting point becomes twisted self-dual strings instead. We propose a novel ansatz for the twisted elliptic genera, which, combined with conjectural vanishing conditions of refined BPS invariants, can also bootstrap the twisted elliptic genera recursively. In section 5, we consider the Cardy limit of the twisted elliptic genera and find universal asymptotic behavior of the 6d free energy for all simple Lie algebras. In section 6, we end this paper with concluding remarks and possible future directions.
2 Twisted circle compactification of 6d (2, 0) SCFTs In this section, we discuss some basic results about the twisted circle compactification of (2, 0) theories. Section 2.1 is devoted to a field theoretic derivation of the twisted compatification. It not only reviews previous works in the literature, but also contains some new discussions useful for later sections. In section 2.2, we analyze the effect of the twisting on the ADE M-strings. Finally in section 2.3, we re-examine the results from the geometric engineering perspective.

Outer-automorphism twist
In this subsection, we discuss the compactification of 6d (2, 0) theories on a circle with the outer-automorphism twist. From the classification 6d (2, 0) SCFTs only allow the simplylaced chain of M-strings, engineered from IIB string theory on ADE orbifold C 2 /Γ ADE . After the circle compactification, the 6d (2, 0) ADE SCFTs become 5d N = 2 gauge with ADE gauge group, whose instantons carry KK modes on the circle [5]. However, one can still consider a 5d N = 2 SYM with a non-simply-laced gauge group. For those theories, their UV completions are given by the 6d (2, 0) ADE theories on a circle with outer-automorphism twist [6,45].
Since the 6d theory is non-Lagrangian and also G is not its gauge group, it is hard to pin down the twisted circle compactification directly. To circumvent this, we revisit and refine the argument given by Tachikawa [6]. We compactify the 6d theory on a torus made of two distinct circles S 1 andS 1 . Now the order of compactification matters, so we shall consider the following two compactification chains, where the blue arrow denotes the untwisted compactification on S 1 , and the red arrow denotes the twisted compactification onS 1 . The change of the compactification, which is the origin of the 4d S-duality, provides the clues to the twisted compactification of the 6d (2,0) theories. The direct compactification along S 1 without twist, there is no change of the radius, R 6 =R 5 . We will see that in the convention where the long roots of the Lie algebra of the gauge groups take the square length two, the circle radius of the twisted circleS 1 changes such that n G R 5 =R 6 with n G = 1, 2, 3, 4, depending on the starting theory and also its twisting G (n) . Let us first consider the left chain. To begin with, we compactify these 6d theories on a circle of radius R 6 with periodic boundary condition x 6 ∼ x 6 + 2πR 6 , to get 5d N = 2 gauge theories of ADE type. As instantons represent the KK modes of mass 1/R 6 , the 5d gauge coupling constant g 5 is fixed to satisfy 8π 2 /g 2 5 = 1/R 6 . We further compactify this 5d theory on a circle of radius R 5 so that x 5 ∼ x 5 + 2πR 5 with twisted boundary condition φ(x 5 + 2πR 5 ) = σ(φ(x 5 )) , (2.2) where σ is an automorphism of order n G . The twisted 5d theory has the effective 4d coupling constant 4π/g 2 4 = 8π 2 R 5 /g 2 5 = R 5 /R 6 at the low energy. In the presence of twisting, the generators of the corresponding Lie algebra get split to the eigenstates under the corresponding automorphism σ. Each mode can have KK momentum of (Z + s/n G )/R 5 with n G being the order of the corresponding automorphism and s = 0, 1, · · · n G − 1. The adjoint field of the original 5d theory gets split into various fractional KK modes. The case for A 2r needs an additional consideration with automorphism including the Z 2 outer-automorphism [6,46]. With a matrix R = (1, iσ 2 ⊗ 1 r ), the automorphism for A 2r = SU (2r + 1) is the map σ(φ) = −Rφ T R −1 . As R 2 = diag(1, −1 2r ), this twisting is actually of order four. See the table 1 for the list of n G .
After carefully analyzing the decomposition of the adjoint representation into the representations of its invariant subalgebra as well as the fractional momentum dependence e (k+s/n G )x 5 /R 5 , we obtain the well-known result below: where adj s , fund s , and Λ 2 s denote the adjoint, fundamental and rank two anti-symmetric representations. It turns out that the extended weights on the right hand side of figure 2.3, including also the KK momentum, give rise to the twisted affine algebra G (n) [46]. The identification of the simple roots of the original Lie algebra G under the twist is shown on the leftmost of table 2. Under this identification, the invariant and non-invariant roots under the twist become long and short roots of G (n) , respectively.
The second column in table 2 gives the Dynkin diagrams for the twisted affine Lie algebras. They encode the simple roots of the 4d theory plus the affine root with minimally positive momentum. Ignoring the momentum dependence, the root vectors for the twisted affine algebra are given below: In the above table, {e 1 , e 2 , · · · e r } are r-dim orthonormal vectors and a = b . While there is no difference between C r and C r at the Lie algebra level, there is a difference in the 4d physics due to the range of the continuous 4d θ parameter. We will discuss the detail later on in this subsection. The upshot is that we can represent the equation (2.3) more succinctly, highlighting the length and the fractional momentum e ip 5 x 5 /R 5 : where the subscript indicates p 5 with k ∈ Z. For A (2) 2r , there are additional special roots with half the length of long roots, which carries non-vanishing KK momenta k ± 1 4 , k ∈ Z. There are only r independent Cartan elements at p 5 = 0 in the twisted theory G (n) . The higher momentum modes for the Cartan elements α long · H and α short · H for long and short simple roots are given exactly by E α long and E α short as shown in the equation (2.5).
The A (2) 2r theory is the intriguing case. Even for this case, the SU (2) generator elements for the long simple root carry integer momentum k ∈ Z while the short simple roots can carry integer or half-integer momenta, namely, p 5 = k 2 , k ∈ Z. In addition there is an identity element with only half-integer momentum, p 5 = k + 1 2 , k ∈ Z. Finally, the elements for special roots can carry only nontrivial momenta k ± 1 4 , k ∈ Z. The identity element of half-integer momentum is generated, for example, by the commutation relations of special generators with momentum k + 1 4 . Up to now we have looked at the x 5 dependence of all the modes in the 5d N = 2 gauge multiplet with twisting. If we have not turned on any scalar expectation value φ or gauge holonomy A 5 , then one can quantize each mode in the vanishing coupling limit with gauge fixing, and get the massless and massive modes with KK momentum p 5 /R 5 . The value of the KK momentum for adjoint vector multiplet for each root is identical to that given in the equation (2.5), and so the energy of the mode would be E ∼ = p 2 1 + p 2 2 + p 2 3 + p 2 5 /R 2 5 for the given 3d spatial momentum (p 1 , p 2 , p 3 ).
Let us now consider the BPS massive spectrum in the Coulomb phase. From the 6d perspective we have turned on the VEV of single scalar field Φ in the 6d (2,0) theory, which has the mass dimension two and decides the tension of self-dual strings. Reduced on S 1 , the 5d scalar vev φ = R 6 Φ has the mass dimension one and decides the W-boson mass, which is a self-dual string wrapping along the x 6 circle. Meanwhile the 5d gauge coupling constant is related to the instantons which are KK momentum states via 8π 2 /g 2 5 = 1/R 6 . A further reduction onS 1 gives 4d N = 4 KK theory with 4d gauge coupling constant which is related to the 5d one via 4π/g 2 4 = 8π 2 R 5 /g 2 5 = R 5 /R 6 . The scalar vev and the A 5 holonomy get combined into a complex Coulomb moduliφ = φ + iA 5 . In this 4d KK theory, there are 1/2 BPS W-bosons, magnetic monopoles, Kaluza-Klein modes for x 5 -compactification and instantons for x 6 -compactification. Both instantons and KK modes get fractionalized in the general Coulomb phase. Let us just consider the W-bosons and magnetic monopoles for the SU(2) of a root in adj 0 of the untwisted or twisted G (n) 4d KK theory. Their masses are respectively, The 4d magnetic monopoles arise from the 5d magnetic monopole strings wrapping the twisted circleS 1 . Since the 5d monopole strings are the 6d self-dual strings in the 5d theory, the physics of magnetic monopoles with KK momentum alongS 1 captures the twisted 5d theory on a circle. The magnetic monopoles for roots provide the massive dual W-bosons for the dual gauge theory in the Coulomb branch. The 4d dual magnetic group has the magnetic dual gauge group G ∨ with the dual roots α ∨ = 2α/α 2 made of the roots α of the zero momentum sector of the twisted affine algebra G (n) . Now, let us consider the second compactification chain in equation (2.1). First, we compactify the original 6d theory on the twisted circleS 1 . The resulting 5d theory is also an N = 2 gauge theory with some gauge group G ∨ , which is determined by self-dual strings with twisted compactification. Then, we further compactify the 5d theory on the untwisted circle S 1 to obtain the 4d N = 4 KK theory with gauge group G ∨(1) . Now let us look at the bottom line of equation (2.1). Exchanging the order of compactification amounts to the S-duality transformation of the 4d N = 4 KK theory with gauge group G (n) , which exchanges the W-bosons and magnetic monopoles and replaces G (n) with the Langlands dual gauge group G ∨(1) , constructed from the affine coroots. Surely, for simply-laced ADE cases (without actual twisting), their Langlands dual G ∨(1) are identical to the original groups G (n) . Then the S-duality in 4d is a self-duality 4π/g 2 4 = R 5 /R 6 ∼ =g 2 4 /4π =R 6 /R 5 and we set R 5 =R 6 , R 6 =R 5 .
For cases with twisting as in equation (2.1), the situation becomes more interesting. Note that we use the convention where the longest roots have the square length two, so we need to scale down the length of all affine coroots by √ n G , i.e., α G ∨(1) = α ∨ / √ n G .
From (2.6) for the magnetic monopole mass m M = n G R 5 | α G ∨(1) · Φ/ √ n G |, we find that the S-duality in these cases exchanges the coupling constant in the following way, which arises from the identification of the compactification radius as follows: Here there is a scaling of the tensor scalar VEV for W-bosons and magnetic monopoles by √ n G for the invariance of the mass. For the earlier works on the S-duality for 4d theories with non-simple-laced group, see, for example, [47][48][49].
The Dynkin diagram of Langlands dual algebra G (1) r is shown in the third column of the table 2. Except for the A (2) 2r case, the dual roots are simply the Dynkin diagram of the dual roots α ∨ / √ n G of simple roots α of G (n) algebra in the second column of the table 2. For A (2) 2r , its dual group turns out to be (C (1) r ) π which arise from the 5d (C r ) π = U Sp(2r) π theory with discrete theta parameter π. We will provide several evidences for this later in this subsection. The list of explicit expressions for roots of the Lie algebra G ∨(1) r with the zeroS 1 momentum are as follows: For all cases, the Langlands dual gauge group G ∨(1) in 4d actually becomes untwisted, meaning that all affine roots have the same KK mode. This can be seen from (2.5). Moreover, since descending from 5d to 4d involves no twisting, it is straightforward to find out what is G ∨ . The final result is listed in table 2. Note that G ∨ is not a subalgebra of G if G ∨ ∈ {B r , C r }, which is only possible if 6d (2,0) theory withG is not a gauge theory.
It is also productive to understand the above results from the brane systems. Recall that the 5d N = 2 theories with B r , (C r ) 0 , (C r ) π and D r gauge groups arise from multiple D4-branes on O4 − , O4 + , O4 + , and O4 − planes, respectively [6,50]. Note that after a circle compactification and T-duality, we get the interpretation in terms of O3-planes [51,52]. The S-dual of these O3-planes for the 5d theory on a circle without twist is exactly the O3-planes for the twisted G (n) shown in table 2. One important point is that in 4d, there are two kinds of C r = U Sp(2r) theories depending on the range of the 4d continuous θparameter. The standard 4d C r = U Sp(2r) theory on D3-branes with O3 + is S-dual to 4d B r = SO(2r + 1) theory on D3-branes with O3 − . Table 2. Dynkin diagrams for (affine) Lie algebras along the compactification chain (2.1). Brane interpretation is given when possible. Note that G (n) and G ∨(1) are related by the S-duality between 4d theories. The A 2r case is subtler and its S-duality is explained in the text.
Another 4d C r = U Sp(2r) theory on D3-branes with O3 + is self-dual. This C r theory has the continuous theta θ = 2π, such that the magnetic monopole for the long simple root has nontrivial electric charge due to additional Witten effect [53]. On the other hand, the dyonic bound state of two such monopoles, a.k.a. Sen's state [54] with unit electric charge, has no net electric charge when one includes also the Witten effect. Thus there exists a 1/2 BPS massive vector multiplet of zero electric charge and twice magnetic charge for the long simple root, making it self-dual under the S-transformations. 1/2 BPS single magnetic monopole states for short simple roots have zero electric charge sector when one considers both the dyonic BPS states and the Witten effect together. Thus this theory is S-duality invariant. Note that O3 + and O3 + are related by the T-transformation of the SL(2, Z). Some studies of the twisted theories and magnetic monopole spectrum were done before [6,49].
The S-duality of A (2) 2r is a bit complicated as its affine Dynkin diagram is self-dual under the α ↔ α ∨ = 2α/α 2 . Its S-dual theory is the 4d KK theory with affine (C (1) r ) π . From the brane perspective, the S-dual of A (2) 2r theory arising from D3 branes between O3 − and O3 + is the (C (1) r ) π theory arising from D3 branes between O3 + and O3 + . From it we learn that the A (2) 2r 4d KK theory cannot be self-dual. The Montonen-Olive duality is a quantum symmetry and so is sensitive to full quantum spectrum.
There is an additional subtlety in the S-duality. In the left-side line of the compactification (2.1) to 4d, we have 1/2 BPS W-bosons, instantons, magnetic monopoles and x 5 KK momentum. We are interested in the magnetic monopoles with x 5 KK momentum, which would correspond to the 5d W-bosons and instantons of the dual theory with nonsimple-laced group, obtained by the right-side line of the compactification (2.1). These 5d W-bosons and instantons are the wrapped self-dual strings with KK momentum of the twisted compactification of 6d (2,0) theories, which are of our primary interest.
In 4d N = 4 theories, in the Coulomb branch with only a single scalar field vev turned on φ , the simple roots of the Lie algebra appear naturally. While W-bosons of mass α · φ exist as 1/2 BPS elementary particle for all positive roots, classically only for each simple root there exists an elementary 1/2 BPS magnetic monopole with four zero modes, three for the 3d position and one for the internal phase. Once we quantize the moduli space of these elementary monopoles, the threshold bound states without electric charge appear for each positive roots, forming the W-boson of the dual gauge theory [55,56]. Along the left-side of the compactification to 4d, we want to consider these elementary BPS magnetic monopole for each simple roots with zero x 5 momentum and mass in (2.6). We want to add the x 5 momentum by simply combining the KK momentum carried by the Cartan for each simple roots as given in (2.5). Namely, one is imagining chargeless KK momentum combined with magnetic monopoles for each simple root α of G ∨ . This would generate a simple prescription for elementary monopoles with arbitrary x 5 KK momentum and without any electric and instanton charge. The full dynamics of these objects is at least as complicated as self-dual strings with KK momentum on the twisted circle.
In the right-side of the compactification chain, they correspond to 5d W-bosons with instantons for the twisted compactification, with the radiusR 6 = n G R 5 . This makes the x 6 momentum n G p 5 integer-valued. On the other hand, a single SU (2) instanton embedded in each simple root α carries the instanton number 2/α 2 . Both the 4d monopole and 5d instanton description give the same result for the allowed instanton number of a single Wboson or the KK momentum of an elementary string, corresponding to each simple root in 5d G ∨ as follows: where a = 1, 2, · · · r − 1. Before we move on to A 2r case, one would ask if any role is played by monopoles related to the affine simple root of G (n) . One could imagine an SU (2) generator (α · H, E α e ip 5 /R 5 , E −α e −ip 5 /R 5 ) and building up a magnetic monopole solution. It is static and has x 5 dependence, so it naturally has nontrivial F i5 component with an instanton number along the left-side compactification in (2.1). Thus they are not of our current interest.
Let us finally consider the 5d (C r ) π case arising from twisting A 2r . After the twisted compactification from 5d to 4d, the equation (2.5) shows that the possible KK momentum states are k, k/2, k ± 1/4, k + 1/2 with k ∈ Z, and the possible magnetic charges are long, short and special. When one combines them together and takes the S-dual picture with momentum factor n G = 4, The possible BPS states one gets in 5d turn out to be given in the equation (2.10) . Without KK momentum, there are states for each root of C r . Here we take the view from the 6d and so they appear as a composite of elementary strings for simple roots of C r . These elementary strings for simple roots can carry KK momentum 2k, k ∈ Z. In addition, there exist strings of half electric charge 1 2 α r of the long simple root. This string has to carry nontrivial KK momentum 4k ± 1, k ∈ Z so that it does not appear in the gauge multiplet spectrum of 5d theory. This is consistent with the known instanton dynamics. Single instanton for (C r ) π case carrying nontrivial electric charge belongs to fundamental representation of U Sp(2r) = C r . For the Cartan elements, the x 6 KK momentum is just 4 times of what is given in (2.5): the α r · H mode carries the KK momentum 4k, the α a · H, a = 1, ...r − 1 modes carry the KK momentum 2k, and finally the identity element carries the KK momentum 4k + 2 with integer k.

Elliptic genera of twisted ADE M-strings
Now, let us consider the partition function of the twisted 6d (2, 0) theories. More precisely, we will study the partition function of 6d (2, 0) theory on R 4 × T 2 where a spatial circle in T 2 gives the outer-automorphism twist. As we have discussed so far, it is equivalent to the partition function of 5d N = 2 gauge theory on R 4 × S 1 with a non-simply-laced gauge group. The full R 4 × T 2 partition function is defined schematically as follows, (2.11) Here, σ resembles the twisting operation, P is the KK momentum along the spatial circle in T 2 , J 1,2 are two angular momenta on R 4 , and R 1,2 are two charges of SO(5) R-symmetry. m can be regarded as a mass deformation, known as the M-string mass. Lastly, n is the charge of the twisted M-strings in 6d, which becomes the electric charge of W-bosons in 5d.
Henceforth, for simplicity we will omit σ in the subscript of Z, with the correct twisting understood from the context.
The 6d BPS partition function (2.11) admits two different descriptions: the instanton partition function and the elliptic genus. First, one can study a 6d (2, 0) theory from the 5d N = 2 gauge theory with KK instantons. Then, the 6d partition function admits the following expansion, Here, Z pert is the perturbative partition function which captures the perturbative W-bosons in 5d, and its form is given as follows, where ∆ + (G) is the positive root system of 5d gauge algebra g. Also, Z k is the k-instanton partition function, which captures the non-perturbative degrees in 5d with k-unit of KK momentum. For the classical gauge groups, the instanton partition functions are wellstudied with ADHM construction [57][58][59]. On the other hand, the exceptional gauge groups do not have ADHM construction, and their instanton partition functions are much less understood.
Instead of the 5d description, one can study the 6d partition function from the BPS spectra on the twisted M-strings on T 2 . Then, the 6d partition function admits the following expansion, (2.14) In (2.14), the expansion parameter is the string fugacity e −n·v , and the coefficient Z n is called the elliptic genus with charge n = (n 1 , n 2 , ..., n r ). Here, Z 0 is call the Abelian contribution which is the neutral part of the partition function independent of the tensor VEV v. The Abelian contribution of general gauge group takes the following form, (2.15) Note that Z 0 of non-simply-laced gauge group is made of U (1) partition functions with different momentum fugacities. In general, it can be read off from the decomposition rule (2.5). In this paper, we will mostly focus on the non-Abelian part Z/Z 0 and the elliptic genera E n . For 6d (2, 0) A-type theories, the elliptic genus can be computed from 2d quiver gauge theories on M-strings [4]. For other types of theories, such 2d gauge theory description has been yet unknown. Instead, SL(2, Z) modular property of the elliptic genera can be used to determine them. Such procedure is called the 'modular bootstrap', and it has been studied in various 6d theories [29][30][31][32][33][34][35][36], including (2, 0) D, E-type theories [30,35]. In this paper, we will focus on the twisted circle compactification of (2, 0) theories whose elliptic genera are unknown. Specifically, we will extend the modular bootstrap program to be applicable for non-simply-laced theories also.
As will be explained later, for the twisted M-strings of type G ∨ given by the Z n G twist of G, the elliptic genus is not the Jacobi form of SL(2, Z), but of the particular congruence subgroup of SL(2, Z). Such subgroup Γ 0 (n G ) 1 ⊂ SL(2, Z) is given as follows, Under the Γ 0 (n G ) action, as a Jacobi modular form the elliptic genus transforms as follows, where z collectively denotes the elliptic parameters ± and m. The elliptic genus is a modular form with index i n and weight 0. For the untwisted case with n G = 1, the index can be obtained from the 6d anomaly polynomial, through the anomaly inflow from 6d to 2d [60]. Then, the index of the untwisted M-strings are given as follows, n a , (n G = 1), (2.18) where Ω is the Cartan matrix of the simply-laced Lie algebra g.

(2.19)
See table 2 for our convention of the node enumeration. We claim that the index of the twisted M-strings of type G ∨ and chargen can be obtained from the index of the untwisted M-strings of type G and charge n as follows, Using (2.18) and (2.20), one can universally write down the index of the M-strings in any Lie algebra g in the following expression, Here, except for (C r ) π theories, Ω is the Cartan matrix of g and the matrix D is defined as follows, The above index will play an important role only in the section 4, and readers can see table  4 for the explicit values of ΩD. Lastly, the vector n is a usual string charge vector except for (C r ) π case where the string charge at the last node is halved.

Geometric engineering
In this section, we want to understand the physics from the point of view of geometry. To start with, the 6d (2, 0) SCFTs arise from F-theory on a elliptic-fibered CY threefold, where the base is the ALE space, i.e, the resolution of C 2 /Γ with Γ a finite subgroup of SU (2).
Since the base itself is a CY twofold, the resulting 6d theory has (2, 0) supersymmetry. 2 The resolution of the singularity in the base gives rise to a class of compact divisors S i and a class of compact curves Σ j , where the negative of the intersection matrix is exactly the Cartan matrix of ADE type.
In the geometric picture, BPS strings arise naturally from D3-branes wrapping on twocycles in the base, which also inherits the self-duality condition of the D3-branes in ten dimensions. The partition function under the 6d Ω-background localizes to the BPS strings wrapped on the T 2 in the spacetime, giving us an expansion in terms of elliptic genera (2.14). Through the F-theory/M-theory duality, the elliptic genus captures the essential part of the refined topological string partition function, i.e., Z GV in (2.25), for the elliptically-fibered CY threefold. 3 This brings us to another crucial ingredient of the story, i.e., topological strings. Given a CY threefold X, if one denotes the Kähler parameter of two cycles in H 2 (X, Z) as t with its exponential Q = exp(−t), we can associate the free energy as a formal power series in g s , where the genus g free energy F g can be expanded in terms of Q with coefficients the celebrated Gromov-Witten invariants. Furthermore, through lifting type IIA string theory to M-theory [61][62][63][64], for X non-compact, we are able to rewrite and refine topological string free energy in the following way, where 1 and 2 are two equivariant parameters related to the Cartan subalgebra of SO(4), originated from instanton counting under the Ω-background in five dimensional gauge theory with N = 1 supersymmetry [65,66]. F poly takes the structure, Moreover, for the second part in (2.25), the χ j is the character of an irreducible SU (2) highest-weight representation with spin j, and v = exp(− 1 + 2 2 ), u = exp(− 1 − 2 2 ). Last but not least, N α j − j + is the number of BPS states in 5d with spin j − and j + , arising from M2-branes wrapped on curves in X. They are integers known as the refined Gopakumar-Vafa (GV) or BPS invariants. 2 However, in order to turn on the M-string mass, one needs to modify this picture, rendering the fibration non-trivial. 3 For general N = (1, 0) SCFTs they are the same only up to overall factors [30,31].
For the type of CY threefold considered in this paper, we can divide the Kähler parameters t into three different categories: where they correspond to the volume of the elliptic fiber (instanton counting parameter in 5d), the compact curves in the base (Coulomb parameters associated to the simple roots of the gauge groups in 5d) and the M-string mass (mass of the adjoint matter in 5d) respectively. This also provides a unifying view on two types of expansion of Z(τ, 1,2 , m, v) in (2.11): If one sums up τ and m while expands in terms of v, this gives (2.14) which is an elliptic genus expansion and naturally fits the 6d perspective; If one sums up v and m while expands in terms of τ , this gives instead (2.12) which is an instanton expansion and arises from the 5d perspective. This is plausible since they are simply the UV/IR description of the same theory, and are supposed to share the same protected quantities.
To put it in another way, the upshot of the above discussion is that the elliptic genera or the instanton partition function enjoys a more constraining expansion (2.25), henceforth referred as the BPS or GV expansion.
Finally, we sketch a heuristic picture to understand the twisted compactification. We also consider the two compactification chains in figure 2.1, and let us first concentrate on the left one. 6d N = (2, 0) SCFTs compactified on S 1 is the same as M-theory compactification on the same Calabi-Yau due to F-theory/M-theory duality. Furthermore, When compactifying on a twisting circle, M-theory descends to type IIA theory, but the geometry gets modified according to the action σ depicted in section 2.1. The first step is to identify the curve Σ i and Σ σ(i) in the same orbit. Denote α, β the orbit of the action σ, we select one node i in the orbit α and the intersection matrix naturally becomes [10] (2.29) Remember that the elliptically fibered CY threefolds engineering 5d or 6d theories of ADE type have only one section. When we identify the curves, the section over them corresponds to different points in the fiber in general, hence the one section should be merged into an N -section in the terminology of [39]. As a result, the threefold is transformed to a genus one fibered CY manifold. This procedure is also explained, for example in [10]. Except for A 2l , the reduced intersection matrix becomes the Cartan matrix of the invariant subalgebra of the twisting. Interestingly, this gives a different result for A 2l group, where the negative of the intersection matrix becomes, 4 Notice that the last diagonal element is not two, so it cannot possibly be identified as a Cartan matrix.
In the terminology of [10], there is a self-edge attached to the last node in the graph.
Remember that this does not give the 5d theory after twisted compactification. Instead, as discussed in the section 2.1, they are S-dual to the real 5d theory with adjoint matters, which lives on the right compactification chain. Recall that S-duality includes exchanging the W-bosons and magnetic monopoles. Therefore, in the geometric language, it is equivalent to exchanging the role of divisors and curves, since D2-branes wrapping on compact curves give W-bosons while D4-branes on compact divisors give magnetic monopoles. With this in mind, after taking the S-dual the new intersection matrix becomes its transpose, giving the same matrix Ω in (2.21). Here we are embedding the intersection matrix into a larger intersection matrix of a putative genus one fibered CY threefold, such that the column corresponds to rational curves while the row represents toric divisors. For all cases except (C r ) π , this is nothing but a rewriting of the procedure in the section 2.1. Furthermore, for the (C r ) π theory it gives the precise matrix Ω that is identified quite indirectly in the sections 2.1 and 2.2.

Blowup equations
The twisted circle compactification of a 6d (2, 0) SCFT gives rise to a 5d N = 2 theory, as explained in detail in 2.1. In section 3.1, we first review the general setups for the 5d blowup equations. In section 3.2 we write down the blowup equations for 5d N = 2 theories of all ABCDEF G types, and discuss how to solve them in section 3.3. Then in section 3.3, we re-write them in the elliptic version, which also helps to fix/verify the index of elliptic genera for twisted theories.

Review of the blowup equations
The idea of blowup equation for instanton counting is to consider the equivariant localization onĈ 2 , which is constructed from C 2 by blowing up the origin to create a compact 2-cycle P 1 . One can regard the geometry as a total space of the tautological line bundle O(−1) over the P 1 , which can be parametrized by the homogeneous coordinates (z 0 , z 1 , z 2 ). We are interested in the U (1) 2 equivariant partition function, with the equivariant action on the homogeneous coordinates as (z 0 , z 1 , z 2 ) → (z 0 , e 1 z 1 , e 2 z 2 ). (3.1) In the blowup geometry, the instantons are located at two fix points, the north and south poles of P 1 , whose coordinates are (z 0 , z 1 , z 2 ) = (0, 1, 0) and (0, 0, 1). Around these fix points, they can be locally described by the C 2 coordinates (z 0 z 1 , z 2 /z 1 ) and (z 0 z 2 , z 1 /z 2 ) respectively, leading to the equivalent action near the north pole, The full partition functionẐĈ 2 onĈ 2 can be written as the product of the partition function Z N/S around these two fix points, by summing up all the fluxes n on the two-cycle P 1 . Here Q ∨ is the co-root lattice, v are the Coulomb parameters, m are masses of matters and q is the instanton counting parameter. Around the North/South poles, they can be locally treated as C 2 . In terms of C 2 partition functionẐ C 2 , we havê Note that the partition function should be invariant under Weyl transformation of its Lie algebra g, and n+ λ G is actually the co-weight lattice P ∨ . The number of nonequivalent choices λ G depends on the number of elements in the quotient |P ∨ /Q ∨ | = det Ω, where Ω is the Cartan matrix of g. For special cases, like (C r ) π , Ω should be interpreted as the intersection matrix of compact divisors and curves in the CY geometry.
Another remark here is that the partition functionẐ C 2 is not the usual partition function Z C 2 used in gauge theories. They are the same only up to a shift. As reviewed in section 2.3, a five dimensional gauge theory can be engineered from the M-theory compactification on a CY manifold, where the total partition function Z = exp F can be written as the product of the GV or BPS expansion Z GV (2.25) plus singular terms e F poly (2.26) at large volume limit. Then we defineẐ = e F polyẐ GV , with 5 where the second line comes from the checker-board pattern for the spin As a remark, the checkerboard pattern means that for a given curve class {d G , d F , d b }, if one enumerates all non-zero BPS invariants with two axes 2j + and 2j − , any two occupied blocks are either disconnected or connected through a diagonal. In other words, the combination (2j − + 2j + ) is always even or odd. Clearly this is necessary for the equation (3.6) to hold. This pattern was first noticed in [69] and holds true for all non-compact CY threefolds that the authors know of. Next, in order to get the blowup equation for ordinary gauge theory partition function, one has to shift back the extra fluxes. This will give rise to an extra phase (−1) |φ| , coming from rearranging the singular part e F poly in the blowup equation. The explicit expression is a bit complicated and for 6d SCFTs it can be found in [28]. Here we do not need the explicit form so we omit its expression. Now the blowup equation takes the form, (3.7) If one consider the limit where the size of blow-up P 1 is small, the resulting geometry is nothing but the original C 2 , so one concludes immediately that ZĈ 2 ∼ Z C 2 . In most cases, the two partition functions are exactly identical. However, in certain special cases, there could be an extra factor Λ coming from the perturbative part. It was further explained in [21] that Λ does not depend on Coulomb VEVs v, so we have If such an equation holds, we could define where Q i is the exponential of the Coulomb VEVs Q i = e −v i . For a 5d/6d SCFT that can be engineered from geometry, the instanton partition function admits a BPS expansion, counting the BPS states of M2-brane wrapping curves inside the CY such that the degree of Q i 's is always non-negative. This indicates that most of the instanton contributions in (3.9) vanish, leaving only the neutral part Z inst neutral = Z inst Q i →0 , times the contribution from e F poly .
It seems that one can use arbitrary λ G/F , r b in (3.4) to define an equation. Nevertheless, notice that the perturbative part is divergent in this limit, so one has to choose λ G/F , r b properly to cancel these divergences. The cancellation condition gives a strong constraint on λ G/F , r b , which turns out to give all the possible choices. Among them, we choose those that satisfy the aforementioned condition (3.6) for all BPS states.

Blowup equations for G + 1Adj
Now let us focus on 5d theories with an adjoint matter G + 1Adj. Recall that the adjoint representation is the same as the root system of its Lie algebra g. We denote m the mass of the adjoint matter, v α the Coulomb VEVs α · v, R + = {(v α , ±m)|α ∈ ∆ + } the positive weights where ∆ + is the set of positive roots. Following the gauge theory language, we separate the partition function into the classical, 1-loop and instanton part. We modify slightly the notations in [28] to adapt to our present convention, where PE stands for the plethystic exponential and h ij is the Killing form of g, . (3.13) One can easily recognize that Z inst is nothing but the Z GV defined in (2.25).
As discussed in the last section, the number of choices of λ G is determined by the determinant of the Cartan matrix or the negative of the intersection matrix. Therefore we can immediately get the number of flux λ G , summarized in table 3. Among all the cases except for (C r ) π , there is a common one: Together with the neutral part in (2.15), a short computation shows that the expression for Λ is One can easily verify from the expression that φ = 2πiλ F | n| cancels with the phase (−1) | n| . The prefactor f(τ ) comes from the neutral part of instanton partition function described in section 2.2, for classical Lie groups, Note that f(τ ) is not important in our current cases, so one can set it to be one if one does not care about the neutral part. Finally, for the (C r ) π theory, the negative of the intersection matrix is not the Cartan matrix of C r and λ G = 0 breaks the flux quantization condition (3.6). It turns out that there is only one blowup equation in this case. The correct choice is to simply replace the co-root lattice in (3.14) with another co-weight lattice by the shift, which gives the blowup equation for both (C r ) 0,π . As a summary, the blowup equation for 5d G + 1Adj theory is , For the (C r ) π theory, we should make the replacement as in (3.16). We verify (3.17) for A 1 + 1Adj up to 4-instantons with instanton partition function from ADHM description, and for (C r ) 0,π , r ≤ 4 at the one-instanton level.

Solving blowup equations
Here we give a description of our recipe to solve the blowup equation.

Solving BPS invariants
To solve the BPS invariants, one can expand the blowup equation with instanton counting parameter q and the Coulomb parameter v. With the ansatz on the BPS expansion with unknown BPS invariants, we can bootstrap all the BPS invariants, except for the spin (0, 0) and (0, 1/2) invariants. See [21,27] for the proof and [22] for a recent discussion on this approach. Following the definition in (3.13), define which is a Laurent polynomial of q 1 , q 2 . It is proved in [21,27] that for a fixed spin R, Bl (j − ,j + ,R) are mutually independent for all possible (j − , j + ), except for Bl (0,0,±1/2) (q 1 , q 2 ) = Bl (0,1/2,0) (q 1 , q 2 ) = 0. Then finding the BPS invariants becomes a problem of decomposing a Laurent polynomial into the basis Bl (j − ,j + ,R) (q 1 , q 2 ). In our case, we set λ G = 0, λ F = − 1 2 , r b = 0, so that the only unfixed BPS invariants are N dm=±1 and N dm=0 (0,1/2) . In principle, one can go to higher degrees to fix these invariants, but here we use another condition to fix them more conveniently.
It is known that if we set the mass of the adjoint matter to − , the partition function is trivially one. In this limit, which are linearly independent. This means that we can use the triviality condition to fix the remaining BPS invariants. In practice, we extract the BPS invariants up to 10instantons, at lower degree expansion of the Coulomb parameters, which are compatible with the results using the modular bootstrap in section 4. Part of the BPS invariants we solved can be found in appendix B.

Solving instanton partition functions
As reviewed in section 2.2, from the 5d point of view, the partition function can be expanded in terms of instanton sectors. To begin with, we expand the blowup equation at the kinstanton order and the resulting equation is Here f l is the l-th Fourier coefficient of f(τ ), which can be defined from the coefficients of the −r power of Dedekind eta function p −r (l) When r > 0, p −r (l) are always positive integers for l ≥ 0. For the first few terms, we have (3.23) (3.21) can be alternatively written as (3.24) where I k is the contribution from lower instanton numbers (3. 25) In order to solve the equation, we can first make the ansatz is a Laurent polynomial of Q i , Q m , q 1 , q 2 with unknown coefficients, and D k (Q i , q 1 , q 2 ) can be determined from the pole structure of I k . Then substituting the ansatz (3.26) into the k-instanton blowup equation (3.24), we can solve the coefficients in the N k (Q i , Q m , q 1 , q 2 ) with extra information. At one-instanton level, the problem becomes much simpler and easier to solve.
where f 1 coincides with the number of long simple roots according to (3.15). Here the sum in the first line can be understood as a sum over length-2 (co-)root. In our convention they correspond precisely to long roots, hence there are only poles at the long roots in the first line of (3.27). This analysis is enough to conjecture the denominator of Z inst 1 ( 1 , 2 , v i , m) for a simple Lie algebra g as where ∆ l is the set of long roots. Based on the zeros and properties of one-instanton partition function, one can further make an ansatz for the numerator (3.29) (1−q 1 )(1−q 2 )QmZ 1 and v = (q 1 q 2 ) − 1 2 , we solveZ 1 for gauge groups A 1 , A 2 and A 3 model with gauge fugacities turned off by setting Q i = 1, For all cases, they have the structurẽ with P (v, χ (n) ) always a Laurent polynomial in v, which is symmetric under v ↔ v −1 .
Here χ (n) := χ (n) (m) is the character of the spin n 2 representation of the SU (2) flavor group. Furthermore, the structure (3.30) still holds for other gauge groups, and in particular for ABCD type, we verified that the results agree with those computed from ADHM descriptions. For theories without an ADHM description, we listZ 1,G in appendix C.
Notice that for most cases, we turn off the gauge fugacities Q i = 1, but our method works also with all gauge fugacities turned on. For G 2 , we first compute the exact result and then expand it in terms of v, where χ (n 1 ,n 2 ) is the character of G 2 with highest weight (n 1 , n 2 ). As a remark, all the constant coefficients are ±1 in the expansion, which agrees with the conjecture in [28]. Similarly, for F 4 we havẽ (3.32) For E type gauge groups, the computation becomes too lengthy to reproduce here.

Elliptic blowup equations
In our 5d KK theory description, there is no cubic terms for the Coulomb branch parameter a i in the prepotential. According to a theorem in [70,71], geometrically, they are described by the genus one fibered CY three-folds on twisted ALE singularities. This already indicates that this is actually a 6d theory and the Coulomb branch becomes the tensor branch in 6d. One can then re-write the blowup equation to its elliptic version n +n =n n∈Z r e iπτ h ij n i n j +(m− + )| n|+n i Ω ij n j 1 +n i Ω ij n j 2 By comparing with the elliptic blowup equation in [27], one observes that for general simple groups the formula is the same if we do the replacement Ω ij → h ij = (ΩD −1 ) ij , k → k · D. We conclude that the index i n for Z n is agree with the results in section 2.2. For (C r ) π theory, the blowup equation is the same as the second blowup equation of (C r ) 0 , so they should have the same index. The only difference between them is that there are half-integer string charges, such that we need to normalize n → n 2 in the definition. Again, we recover the index for (C r ) π theories as described in section 2.2.
If we focus on a single node in the base, i.e., n I > 0 and n J = 0, J = I, (3.33) becomes n I +n I =n n∈Z e iπD II τ n 2 +(m− + )n−2n I n 1 −2n I n 2

Modular bootstrap
In this section, we will talk about the modular bootstrap approach towards the twisted elliptic genera. In section 4.1, we give a quick overview of the modular group of twisted elliptic genus. In section 4.2, we discuss in detail how to bootstrap all non-simply-laced cases except (C r ) π . Section 4.3 is devoted to the exceptional case (C r ) π .

Modular group of twisted elliptic genus
A 6d SCFT can be described by F-theory compactification on an elliptically fibered Calabi-Yau threefold. After twisted circle compactification, since the Z N automorphism should act on the fiber as well, the geometry becomes a geometry with N -sections. The geometry is expected to be a genus one fibered Calabi-Yau threefold [10]. The genus one fibration is a fibration with N -sections, which is defined by N points that can be identified with each other and are transformed to each other by monodromies in the base. As proved in [39,72], the monodromy is an element in Γ 1 (N ), which is a subgroup of Γ 0 (N ). Moreover, it is known that Although the minus of the identity matrix acts trivially on τ , its presence eliminates nontrivial modular forms of odd weights. In other words, if one considers modular forms invariant under Γ 1 (N ) for 3 ≤ N ≤ 4, in additional to those invariant under Γ 0 (N ) one in principle also has to include odd-weight modular forms. But since those are absent in the elliptic genera, we think it better to choose the modular group to be Γ 0 (N ) rather than Γ 1 (N ). This should be understood as applying only to particular CY threefolds considered in this paper. 7 In short, we expect the elliptic genus to be a Jacobi form in Γ 0 (N ), where N = 2 for B r , (C r ) 0 , F 4 algebras, N = 3 for G 2 algebra and N = 4 for (C r ) π .
In order to bootstrap the elliptic genera, one should use the ring of Γ 0 (N ), which is reviewed in appendix A. However, the full ring of Γ 0 (N ) modular forms contains object E (N ) 2 with smaller weight, which makes the number of generators growing too fast as we increase the string numbers. In order to simplify our computation, we treat the geometry after twisted circle compactification as a gluing of single nodes in the base, such that along each node the modular group is either Γ 0 (N ) or SL(2, Z). Another key observation from the end of last section is that, restricting to a single base node, the elliptic genera always resemble the elliptic genera of A 1 M-strings. If the node is a long simple root of the Lie algebra, then they are the same, while for a short simple root we simply make the replacement τ → N τ . Such an observation makes us conclude that along a single short node, the E (N ) 2 actually disappear and we could just use the modular forms arising from SL(2, Z) Jacobi forms instead. For general string numbers not necessarily restricted to a single node, except for (C r ) π , we further conjecture that the numerator of the elliptic genera can still be written in terms of the following set of elliptic modular forms and Jacobi forms, Recall that E 4 (τ ) and E 6 (τ ) are Eisenstein series with weight 4 and 6 under Γ 0 (1) = SL(2, Z). Second, A(τ |z) = ϕ 0,1 (τ, z) and B(τ |z) = ϕ −2,1 (τ, z) are weak Jacobi forms with weight 0, -2 and index 1. Those functions generate the ring of elliptic modular forms and weak Jacobi forms for Γ 0 (1) respectively. For more details, one can refer appendix A. In order to keep the expression simple, we will use the following notation from now on. Nevertheless, for the (C r ) π case, we propose a different modular ansatz, which will be discussed in section 4.3.
As a remark, notice that the generators in (4.3) are not independent. For all base degrees computed in this paper, we find that the unknown part of the elliptic genera indeed lies in the subring (4.3), and is completely fixed after imposing all the identities among them. For definiteness, we list those identities explicitly in appendix A for N = 2 and 3 which are used in this paper. We also indicate how to prove them for the case N = 2. Again the N = 4 case is very different and will be discussed separately in section 4.3.
Finally, we explain how the elliptic genus generated from (4.3) transforms under Γ 0 (N ). In general, one can express the elliptic genus in the following form, Here, we consider the monomial expansion of the elliptic genus such that the k'th monomial is given by N τ, z). The functions f (k) (τ, z) and f (k) (τ, z) are modular functions with weight w,ŵ and index i,î respectively. They transforms as follows under a b c d ∈ SL(2, Z), Then, under a b c d ∈ Γ 0 (N ), the elliptic genus (4.5) transforms as follows, Note that c ≡ 0 (mod N ) plays a critical role in the transformation above. As a result, the full elliptic genus has a weight w +ŵ and index i +ˆi N under Γ 0 (N ). This also shows that the index of the hatted Jacobi forms should be divided by N .

Bootstrap from the vanishing bound
Recall that from the end of section 2.2, the weight and index of the elliptic genus are where Ω is the Cartan matrix for the Lie algebra g and D is the matrix D ij = 2 δ i,j α i ,α i . For g simply-laced, D is the identity matrix and we are back to the case considered in [35], while for g non-simply-laced which is the focus of this paper, it is non-trivial such that the combined matrix Ω s = ΩD becomes which is manifestly symmetric. For reader's convenience, we give the explicit form of Ω s for B n , (C r ) 0 , F 4 and G 2 in table 4.2. For the (C r ) π theory, Ω is the negative of the intersection matrix (2.30), Table 4. Ω s for non-simply-laced g.
Before doing actual computation, we emphasize that our modular ansatz is motivated by the picture of twisting at the level of the elliptically fibered CY threefold, briefly explained in section 2.3. Note that the number N should coincide with the order of twisting mentioned in section 2.1.
Although we do not have a detailed understanding of how the geometry transforms, and for the cases we computed we actually do not need the full ring of Γ 0 (N ) modular forms, we believe that this geometric picture is supposed to support our modular ansatz for the twisted elliptic genera.
Without further ado, we claim that the modular ansatz takes the following form, and the numerator N n is an element in the ring of Γ 0 (N ) Jacobi modular forms, 11) where as before the overall hat means f (τ, ...) = f (N τ, ...) and z i represent the chemical potentials as (z 1 , z 2 , z 3 ) = ( + , − , m).
As promised above, further constraints can be imposed to reduce the number of terms in (4.11). The basic idea behind is that since we have roots of different length, the BPS string wrapping the corresponding curves should to some extent see the difference. For extreme cases, we learn from the last part of the section 3 that the N n with non-zero n only for roots dual to unfolded roots (corresponding to those with Ω s aa = 2) only depends on SL(2, Z) forms, while with only non-vanishing wrapping degrees for folded roots it only depends on hatted forms.
Although in general cases both forms are needed, we can still try to separate their contributions. Let us look again at (4.10). Note that the numerator N n has weight and index (4.12) The weight w Nn is naturally factorized, hence we can demand that the total weight for two types of roots should match the weight of the two products in (4.11) separately. The index i Nn is a bit more complicated. Since D is a diagonal matrix, the index for m is factorized, and we can ask for separation as above. However, because of the non-diagonal form of Ω s , the index for ± mixes n a for both types. The best we can demand is to separate the sum of indices i + + i − into roots different types. For all the cases computed in appendix B, this set of constraints is satisfied. To give a concrete example, let us consider the case g = F 4 (N = 2). From table 4.2 we learn that nodes 1 and 2 are long roots dual to the folded roots of E 6 , while nodes 3 and 4 correspond to short roots dual to the unfolded roots of E 6 . A potentially confused reader can look up the table 2 for clarification. We rewrite the weight and index polynomial in the following way, w Nn = −2 n 1 (n 1 + 1) 2 + n 2 (n 2 + 1) 2 − 2 n 3 (n 3 + 1) 2 + n 4 (n 4 + 1) 2 , i Nn = (m 2 − 2 + )(n 1 + n 2 ) + 1 2 (m 2 − 2 + )(n 3 + n 4 ) (4.13) Then we require the weight and index i m involving n 1 and n 2 to match the first parenthesis in (4.11), and those of n 3 and n 4 to match the second. Moreover, the sum of indices i + +i − containing n 1 and n 2 should match the sum in the first parenthesis in (4.11) while those of n 3 and n 4 should match the second one. Given the modified ansatz (4.11) and the weight and index polynomial (4.12), one can impose constraints to determine the coefficients which are finite. In earlier works [30,31,35], the authors successfully employed the vanishing conditions to fix them in many 6d SCFTs. To be more precise, the elliptic genus of BPS strings in 6d N = (2, 0) SCFTs can be identified with the topological string partition function on the elliptically fibered CY manifold, thanks to the M-theory/F-theory duality. The latter is known to have a GV expansion, encapsulating integral enumerative invariants known as the GV invariants. Those invariants turn out to satisfy vanishing conditions, which immediately give us infinitely many constraints on the coefficients. After twisted circle compactification, we expect the elliptically-fibered CY manifold to change to an N -section geometry, and the twisted elliptic genus should still be identified with the topological string partition function. Therefore, it's still legitimate to apply the vanishing condition to determine the elliptic genera. As a final remark, we stress that from the point of view of topological strings, the existence of the structure of Jacobi forms (4.10) is non-trivial and signals special Sp(n, Z) monodromies in the extended Kähler moduli space. The latter is demonstrated beautifully in [39] based on homological mirror symmetry.
Here we present a self-contained summary of the vanishing bound for GV invariants. For more details, the reader can refer [30,31,35]. First, recall that the refined free energy enjoys the GV expansion (2.25), with N α j − j + the refined GV invariants. They count the number of BPS states with spin j ± in five dimensions, so they are always non-negative integers. Mathematically they can be defined in terms of the motivic enumerative invariants [69,73], but they are quite complicated to understand. To argue for the vanishing property, we adopt the route taken in [35] which instead starts from the unrefined GV invariants I α g . The unrefined or self-dual limit sets v = 1, and we have where the symbol χ j (x) denotes the character of an irreducible SU (2) highest-weight representation with spin j ∈ N/2 (2.27). In mathematics, I α g is closely related to enumerative invariants known as stable pair or Pandharipande-Thomas (PT) invariants P n,α [74]. To define the latter, we start from a stable pair consisting of torsion sheaves F having dimension one support and a non-trivial holomorphic section s, which altogether captures the D6-D2-D0 bound states in physics. The moduli space of all possible stable pairs with a fixed holomorphic Euler characteristic n and a fixed class of support α carries a perfection obstruction theory [74], and the virtual fundamental cycle happens to be zero dimensional for a CY threefold. Hence the PT invariants P n,α just count the number of points inside the virtual fundamental cycle. For a fixed α, there exists an n small enough such that P m,α vanishes for any m ≤ n. This is simply because a curve with given homology class can not have arbitrarily small Euler characteristic, hence the moduli space is empty.
On the other hand, P n,α can be expressed in terms of I α g [74]. For simplicity, if we consider an irreducible class β ∈ H 2 (X, Z), they are related in the following way, n P n,β q n = g≥0 I β g q 1−g (q + 1) 2g−2 .
(4. 16) In order to satisfy the vanishing property of P n,β , I β g must vanish when g is sufficiently large. Inductively, we can extend the vanishing property for I β g to all curve classes in H 2 (X, Z).
Furthermore, we assume that the refined GV invariants satisfy the so-called checkerboard pattern [69]: for a given curve class α, the combination (2j − + 2j + ) is always even or odd. This pattern also plays an important role in the blowup equations, as explained in the section 3.1.
Let us look back at the equation (4.15). Decompose χ j − (u) into a polynomial with variable (u 1 2 + u − 1 2 ) 2 , based on the above assumption it is not hard to derive a generic vanishing bound for the refined GV invariants, However, the precise vanishing bound for j ± depends on the detailed knowledge of the geometry. At this stage, it is not clear to the authors how to construct a useful presentation of the genus-one fibered CY manifolds needed in this paper, let alone deriving the precise bound from the first principle. Therefore, we adopt the same strategy as in [35]. Namely, we make some guess on the bound by looking at the BPS data available from section 3. Moreover, since the CY threefolds consider here are obtained from certain twist of the geometries that engineer 6d N = (2, 0) SCFTs, we expect the vanishing conditions to be mostly unchanged. In fact, we essentially use the same ones found in [35], with only minor simplifications.
To fix our notation, we specialize the general formula (4.14), with Q m = e −m , q = e 2πiτ and Q = e −v formal exponential of Kähler parameters associated to two-cycle of the M-string mass, elliptic fiber and exceptional curves inside the base respectively. We choose the parametrization such that µ can be negative but with a Z 2 symmetry N n,k,µ j − j + = N n,k,−µ j − j + . Our conjecture for the vanishing bound of the refined GV invariants goes as follows: Conjecture. For genus one fibered CY threefolds that engineer 5d N = 2 gauge theories arising from twisted circle compactification of 6d N = (2, 0) ADE SCFTs, their refined GV invariants obey uniformly the vanishing bound 8 , N n,k,µ≥0 The function H(x) is the Heaviside step function, 20) and the last condition comes simply from the observation that the free energy F ref is always a power series in q N in that case. Then we explain how to use (4.19) to determine the elliptic genus recursively. This starts from the following obvious relation, with both sides regarded as power series in Q. Expand the logarithm in (4.21), we have where κ n 1 ,...,n j (nα) are some integers that can be computed order by order. Note that the second term in the right-hand side only involves Z n with base degree strictly smaller than n α .
It turns out that this equation is very constraining. We first supply a few refined GV invariants at the lowest base degrees as the input data, which e.g., can be obtained from the blowup equations in section 3. Then we impose simultaneously the vanishing bound in the left-hand side and the modular ansatz in the right-hand side. This already gives us enough constraints to completely fix F nα and hence E nα . Increasing the degree one step at each time, we are able to bootstrap the elliptic genus for any value of n α in principle.
As always, we need to clarify one issue: is the solution to the above bootstrap equation unique? Surely enough, the uniqueness of the solution is equivalent to determining all the unknowns in the ansatz. For the case of 6d N = (2, 0) SCFTs, we have the following powerful criterion, which is discussed in detail in [30].
Criterion. If either i + or i − is strictly smaller than −1, then the solution to (4.22) must be unique. Otherwise, the ambiguous term can be enumerated explicitly.
After looking at their proof carefully, it is not difficult to show that the above criterion still holds for the modified ansatz and the difference just lies in the set of ambiguous terms.
In our situation, the index of ε − can be written as where α ∨ i correspond to the coroots of g. Then the symmetric matrix Ω s defines a positivedefinite lattice and hence the exceptional cases are always finite. For them, the number of ambiguous terms is always very small after we further separate the contribution for different length of roots, explained earlier in this subsection. So we just need to supply a few BPS invariants if necessary.
Finally, it is worth emphasizing that finding the suitable ansatz to make the most of the vanishing bound is nontrivial. For example, if one uses the generators of the Γ 0 (N ) modular forms mentioned in section 4.1, at some low base degrees where we cannot invoke the above criterion, there appear to be many coefficients not determined by the vanishing condition (4.19). On the contrary, for cases listed in appendix B, we find that the ansatz used here can fix all the unknowns after imposing identities among them, although the number of terms in both ansatze are of roughly the same order.
In table 5, we list some useful information about the numerator of the elliptic genera at low base degrees for gauge groups G 2 , B 3 , (C 3 ) 0 and F 4 . The numerator is determined by the modular bootstrap whose explicitly form is shown in appendix B. As an independent check, the BPS invariants extracted from the elliptic genera is in perfect agreement with those obtained from the blowup equations.
Gauge group Base degree Index Weight Unknowns − + 4m 2 -10 550 Table 5. The index polynomial, weight and unknown coefficients for the numerator of the elliptic genera except (C r ) π case.

(C r ) π theories
For the last case (C r ) π , which is called non-geometric in [10], the situation becomes much subtler, which is the reason why we treat it in a separate subsection.
From (2.21) at the end of section 2.2, we learn that its weight and index can be written as where the Ω s takes the form, In this case, all the nodes come from Z 2 outer-automorphism of A 2r , we would expect that for all possible base degrees the τ variable in the ansatz will be multiplied by two. As a result, we propose its modular ansatz should be, It's interesting to remark that the D n does not follow the general rule in (4.10) which works perfectly for other cases. The structure of the numerator N n is different, which should enjoy the Γ 0 (4) modular group rather than the naive Γ 0 (2) from the Dynkin diagram. The main reason is that, as explained in section 2.1, the whole automorphism group is actually Z 4 , leading to the Jacobi form of Γ 0 (4). Following the above logic, we conjecture that the numerator N n is an element such that the total weight and index of Z n satisfy (4.24). Here z i ∈ ( + , − , m) .
Unlike other cases, this ansatz contains too many unfixed terms at low base degrees after imposing the previous vanishing conditions. Also, the number of coefficients in the ansatz is growing so fast that it is already quite hard to determine the case of base degree two. The main reason is due to the full generators we are using for Γ 0 (4) elliptic modular forms. In practice, we fix all of them consistently by further comparing them with the result obtained from the blowup equations. Below, we will explain this in more detail for the (C 1 ) π theory. Still, it serves as strong evidence for the existence of elliptic genera invariant under the Γ 0 (4) modular group. In table 6, we list some useful information about the (C r ) π elliptic genera at low base degrees, whose explicitly form is shown in appendix B.
As a non-trivial check of our ansatz, we fix the modular expression up to base degree two for the (C 1 ) π theory. In the rank one case, one would expect that the numerator is generated by the following Γ 0 (4) modular and Jacobi forms  Table 6. The index polynomial, weight and unknown coefficients for the numerator of the (C r ) π elliptic genera.
Indeed, as shown in table 13 of appendix B, the one-string elliptic genus 9 contains elements E 2 and E 2 of Γ 0 (4). We verify that this expression coincides with the instanton partition function from ADHM up to 5-instantons. And we verify further with the one-string elliptic blowup equation For base degree two, from table 6 we have 21707 possible generators, making it hard to fix the coefficients. From the gauge theoretic point of view, at the leading order the two strings contain the W-boson contribution, which is the same as a single string for (C 1 ) 0 theory. Further noticing that the index of the elliptic genus at two-strings of (C 1 ) π theory is the same as that of the single (C 1 ) 0 string, we may expect that the two-string elliptic genus contains the following contribution 10 The statement is indeed true, and we observe that the remaining part can be factorized as

(4.30)
We verify the structure of (4.30) by solving the two-string elliptic blowup equation 9 Here we use the notation Az i = ϕ−2,1(4τ, zi), Bz i = ϕ0,1(4τ, zi) 10 It is not difficult to show that this expression is invariant under the Γ0(4) modular group. and get the Fourier expansion of I(τ, 1 , 2 ) up to q 20 order. Now it is much easier to find the modular expression of I(τ, 1 , 2 ), which is expected to be a Γ 0 (4) Jacobi form with weight 0 and index 2 2 + + 2 − , with only 2221 generators. At the q 14 order, 11 we manage to fix all of the unknowns and find (4.31) Its expression is listed in appendix B. Interestingly, this does not depend on E 4 (τ ) and E 6 (τ ). We further check it up to q 20 order with the two-string elliptic blowup equation, and find a perfect agreement.

6d twisted theories in the Cardy limit
In this section, we explore the Cardy limit of 6d (2, 0) theories on R 4 × T 2 with an outerautomorphism twist. The Cardy limit is defined as a limit where momenta are much larger than the central charge of the CFT [75,76]. The free energy in the Cardy limit is usually called the Cardy formula, and it probes the high energy spectrum of the CFT. Furthermore, Cardy formulas have been used to account the Bekenstein-Hawking entropy of supersymmetric black holes in various dimensions [77,78]. In the case of 6d, the Cardy formulas of (2, 0) ADE theories on R 4 × T 2 were studied in [35,79]. The authors obtain the Cardy free energy by summing over the elliptic genera using continuum approximation and S-duality. The resulting asymptotic entropy in terms of the charges (J 1 , J 2 , P, Q L , Q R ) is By solving the saddle point equation from the Cardy formula, the entropy S can be written as a function of charges, and the result for A r -type is 12 where we define J ± = J 1 ± J 2 . Here, we shall extend their approach to all 6d (2, 0) theories, including twisted ones. In order to explore the large momenta limit of the BPS partition function (2.11), we need to set the momentum-conjugate chemical potentials to be small. On R 4 × T 2 , this can be achieved by setting First, | 1,2 | → 0 is the well-known Seiberg-Witten prepotential limit [65,80]. It is also called thermodynamic limit where the volume of R 4 becomes infinite. In this limit, the 11 The reason why we have to go to this order is that there exist a combination of the generators which contains a factor (E 2 ) 13 ∼ q 13 . 12 In [79], additional U (1) r+1 contribution is considered, here we only consider the non-abelian part. leading free energy on R 4 × T 2 is proportional to vol(R 4 ) ∼ 1 1 2 . Second, |τ | → 0 is the limit where KK momentum becomes large. Recall that τ = i R time R KK is inversely proportional to the KK circle radius. Therefore, the KK circle is effectively decompactified, and the full 6d physics is visible in |τ | → 0 limit. In this limit, the leading free energy on R 4 × T 2 is proportional to the volume of the spatial circle in T 2 , i.e. vol(R KK ) ∼ 1 τ [75]. Therefore, the leading free energy in the Cardy limit should be log Z ∼ O( 1 1 2 τ ). When taking the Cardy limit (5.3), we should decide the phase of the chemical potentials which can generically have complex values. Here, we shall consider the following regime of the chemical potentials, For simplicity, we set three fugacities Q 1 = e − 1 , Q 2 = e − 2 , and Q τ = e 2πiτ to be purely real. First, setting 2πiτ < 0 corresponds to setting Q τ < 1 which is needed for the convergence of KK expansion. Second, setting different signs for 1,2 might seem peculiar, but it is nothing but a slight deviation from the unrefined setting 1 = − 2 .
In order to investigate the Cardy limit, let us take τ → 0 limit first. Recall that, according to our ansatz (4.11), the elliptic genus of twisted M-string (except (C r ) π theory) can be written as follows, Here, unhatted parts have modular parameter τ , and hatted parts have modular parameter nτ , where n is the order of the outer-automorphism. Also, a is a monomial index which enumerates the monomials in the numerator. The asymptotic behavior of the elliptic genus at τ → 0 can be obtained by exploiting its property under the S-transformation. Unlike to the simply-laced case, we have to be careful about the S-transformation. The elliptic genus Z n is a modular form under Γ 0 (n G ) which is a congruence subgroup of SL(2, Z). If n G = 1, the S-transformation action ( 0 −1 1 0 ) is not an element of Γ 0 (n G ). Therefore, the twisted elliptic genus does not have the S-duality property.
However, one can still apply S-transformation to the elliptic genus and observe how it behaves. The elliptic genus (5.5) has two parts that depend on τ and n G τ respectively. Instead of the conventional S-transformation, we shall apply the following 'separate Stransformation' to our elliptic genus of the form (5.5), Recall that τ -dependent part and n G τ -dependent part both have zero weights. Let us assume that τ -part has index i, and n G τ -part has indexî. By applying the separate Sduality transformation above, the elliptic genus changes as follows, .

(5.7)
As we explained in (4.7), the sum of i andˆi n G yields the Γ 0 (n G ) index of the elliptic genus. Therefore, the above expression can be written as follows, .
(5.8) Now, the remaining task is to determine the asymptotics of the second line of (5.8) in the Cardy limit τ → i · 0 + . In the expression, the numerators and the denominators contain the following fugacities, . For simplicity, let us assume that m is purely imaginary and is in the 'canonical chamber' given as, Then, it is straightforward to obtain the asymptotics of (5.8). Our basis of the elliptic genus is given in (4.3). Among those functions, we shall only focus on the ones with m. After S-duality, their asymptotics are given as follows, For the index i n of the Z n , a single A(τ, m) or B(τ, m) contributes m 2 , and a single A(n G τ, m) or B(n G τ, m) contributes m 2 n G . Since the m-dependent part in i n is m 2 D · n, one can conclude the following asymptotics, Now, we plug the above result into (5.8). Then, one can obtain the following Cardy limit asymptotics of the elliptic genus, Next, let us consider the full 6d index. We shall focus on the non-Abelian part of the index given as follows, (5.14) The electric fugacity Q = e −v probes the tensor branch moduli space of 6d theory. We will focus on the origin of the tensor branch, where conformal symmetry is restored. In the conformal phase, we should set v = 0, i.e. Q = 1. By using (5.13), the 6d index can be written as follows in the Cardy limit, The summand has a Gaussian structure with respect to the string charge n. Furthermore, the sign of the quadratic term in the exponent is negative, which guarantees the convergence of the summation. The summation over n can be evaluated using the continuum approximation. Let us consider a new variable below, x ≡ − 1 2 Dn, (x a = − 1 2 D aa n a ). (5.16) Note that the minimal discrete distance ∆n = 1 while ∆x = − 1 2 1, and x can be though as an almost continuous variable. Then, the summation (5.15) can be approximated as the following integral, Here, we ignored the Jacobian factor which is subleading than 1 τ 1 2 terms in the exponent. Also, we introduced r-dimensional identity vector I = (1, 1, ..., 1). The free energy log Z can be computed by using the saddle point approximation of x. The saddle point equation and its solution are given by By plugging the saddle point value (5.18) to (5.17), one can obtain the following 6d free energy, which is valid in the Cardy limit. For all Lie algebras including (C r ) π , one can check that the overall coefficient is equivalent to the following group theoretic constant, where d G is the dimension and h ∨ G is the dual Coxeter number of G. The values are listed in table 7. As a conclusion, the Cardy free energy of 6d (2, 0) theory of type G is given as follows, where the 6d theory is twisted if G is non-simply-laced. Our derivation of (5.21) solely depends on the index of the theory, for C r theory with different theta angles, they have the same index up to a redefinition of the string charge n → 1 2 n. In the Cardy limit, the string charge is integrated out, such that at least at the leading order, the Cardy limit is the same for (C r ) 0 theory with different theta angles. Interestingly, one can observe that the 6d Cardy free energy (5.21) (without Abelian contribution) takes a universal form for all Lie algebras, even with the outer-automorphism twist. For the classical algebras A r , B r , C r , and D r , the free energy scales as log Z ∼ r 3 when r 1. This reiterates the fact that N M5-branes have N 3 degrees of freedom in the large N limit [81].
Furthermore, we can compare the Cardy free energy for theories before and after twisting. From the table 7, one can see that for all the Langlands dual pairs of Lie algebras (G (n) , G ∨(1) ) of the twisted compactification in the table 1, the following identity holds: Plugging it into (5.21), we find that the Cardy free energy remains unchanged after the twist, provided that we take the change of radius into account. This nicely shows that in the large radius limit, the effect of twisting is not visible and the physics should remain the same. In the computation above, the non-zero value of the saddle point (5.18) has a special importance. Physically, it indicates that the string charge n condensates to a non-zero expectation value in the Cardy limit [79]. From the saddle point of x in (5.18), the string charge n in (5.16) can be written as follows, where n a denotes the value of n a at the saddle point. The interesting fact is that the above expression is identical to the Weyl vector of the Lie algebra. To be specific, where α b is the root vector of the b'th node of the Dynkin diagram of G, and ∆ + (G) is the positive root system of G. For the (C r ) π theory, the last root vector should be replaced by half of the root vector, one can then verify that (5.24) still holds for the (C r ) π theory. The half of the sum over the positive root vectors ρ is called the Weyl vector of G. As a result, A r (r + 1) 2 − 1 r + 1 1 12 r 3 + 1 4 r 2 + 1 6 r B r 2r 2 + r 2r − 1 1 3 r 3 − 1 12 r C r 2r 2 + r r + 1 1 6 r 3 + 1 4 r 2 + 1 12 r D r 2r 2 − r 2r − 2 1 3 r 3 − 1 2 r 2 +  for all 6d (2,0) theory with or without twist, the string charge n has the following value at the saddle point, As well as the free energy, the sum of the string charges a n a ∼ | ρ| 2 also scales as r 3 when r 1. The Weyl vector sum precisely explains the free energy, i.e., | ρ| 2 = h ∨ G d G
With all the ingredients we have, we can now perform a similar computation for the asymptotic entropy as was done in [79]. The result is An interesting remark is that since h ∨ G d G P is a constant under twist operation, the entropy formula (5.26) is the same for twisted and untwisted theories.
Lastly, let us make a brief comment on the periodicity of m. The Cardy formula (5.21) is obtained in the canonical chamber (5.10) where 0 < Im[m] < 2π. One can do a similar computation outside of the canonical chamber, but it needs modification on the asymptotic behavior of (5.12). For ADE-type theories, such computation was performed in [35,79], and the result restores the periodicity m ∼ m + 2πi. We expect that the Cardy formulas for twisted (2, 0) theories are also periodic under m ∼ m + 2πi.

Conclusions
In this paper, we studied 6d (2, 0) SCFTs on a circle with outer-automorphism twist and their BPS partition functions. The twisted (2, 0) theories are the UV fixed points of 5d N = 2 SYM with non-simply-laced gauge groups: B r , C r , G 2 , and F 4 . We used blowup equations to obtain the BPS spectra and could determine the elliptic genera of twisted Mstrings with modular bootstrap. Our results for the elliptic genera of twisted M-strings are completely new since there has been no known method to compute them. Lastly, we obtain universal 6d Cardy formulas for the twisted (2, 0) theories, which yields log Z ∼ (rank) 3 when the tensor branch rank is large.
In this paper, we also determine the modular property of the elliptic genera of twisted M-strings. If we impose outer-automorphism twist Z n on M-strings, its elliptic genus is not a modular form under SL(2, Z), but its congruence subgroup. The modular index of the twisted M-string can be obtained by folding the original untwisted M-string, as described in (2.19). This modular index was double-checked by comparing with the elliptic blowup equation (3.33). As a result, we can bootstrap the twisted elliptic genus from the ring structure of Γ 0 (N ).
There are several interesting topics that worth pursuing in the near future. The first and most obvious one is to understand the 2d quiver theory living on the twisted BPS string. In particular, for the (2,0) SCFTs of A type one is supposed to perform certain twist or projection on the known 2d quiver [4]. However, at present it is not clear to the authors what are the correct rules, as the elliptic genera on two sides seem not related in a simple way.
Also, one may consider the generalization of our results to 6d little string theories (LSTs) [82]. The 6d LSTs are non-local quantum field theories and enjoy T-duality. Specifically, (2, 0) LSTs are T-dual to (1, 1) LSTs [32,83]. (2, 0) LSTs have well-known ADE classification, but one can impose an outer-automorphism twist on a T-dual circle. We speculate that the corresponding T-dual theory is a (1, 1) LST with a non-simply-laced gauge group. It would be interesting if one can check the duality by explicitly computing the elliptic genera of 6d twisted little strings. Similarly, we can start with (1,1) LST with ADE group and compactify with an automorphism twist on T-dual circle. The resulting (2,0) theories seem to lie beyond the ADE classification. It would be interesting whether these theories make any sense.
Another interesting direction is to explore the blowup equation for the little string theories, in particular, the blowup equation for 6d (1, 1) LSTs. The main difference between LSTs and SCFTs is that there is an additional non-shrinkable circle, which may lead to nonlocal objects in the blowup equations. However, notice that a 6d (1, 1) little string theory can be regarded as an elliptic version of the 5d N = 1 * theories, which means the blowup equation for (1, 1) little strings is simply an elliptic lift of (3.17). We hope to present it in the near future.
Twisted strings in 6d (1, 0) SCFTs are also interesting objects to study. Twisted compactification of 6d SCFTs yields 5d KK theories, which are parents of large class of 5d SCFTs [10]. It has been recently found that the blowup equations are strong methods to obtain the BPS spectra of those 5d theories on R 4 × S 1 [22]. However, non-critical strings in twisted 6d SCFTs have not been studied extensively so far. We expect that the modular property of twisted strings in (1, 0) SCFTs can be also obtained from folding procedure similar to (2.19), and the modular bootstrap would be a useful tool to explore the physics on those strings.

A Modular forms
In this appendix, we briefly summarize necessary results about the theory of modular forms [84][85][86].

Elliptic Modular Forms
Definition 1. A function f : H → C is called a modular form of integer weight k for a modular group Γ if f is holomorphic on H ∪ {∞} and satisfies the following equation For example, let us consider the full modular group SL(2, Z). We can choose the matrix T = 1 1 0 1 to find that f is periodic f (τ + 1) = f (τ ). It is standard to introduce q = exp(2πiτ ), such that f can be expanded as a power series in q, f being holomorphic yields n ≥ 0. If furthermore a 0 = 0, f is called a cusp form. Modular forms naturally form a ring M * (Γ), graded by the weight. The important result is that such space is always finitely generated. For the full modular group SL(2, Z), M * (SL(2, Z)) is freely generated by E 4 and E 6 [84,85], where E k is the famous Eisenstein series, with B k the k th Bernoulli number and σ i (n) the sum of the i th powers of the positive divisors of n. Moreover, in this paper it is equally important to consider congruence subgroups Γ 0 (N ) of SL(2, Z), defined as follows, As a special case, Γ 0 (1) = SL(2, Z). The ring of modular forms for Γ 0 (N ) will be denoted simply as M * (N ). Since the group is smaller, it is possible to have more generators. We introduce is an element of weight two in M * (N ). In the main text, we need to consider N = 2, 3, 4, for which we have the following result, However, in actual computations, we find it enough in mostly of the cases to use the modular forms E k (τ ) := E k (N τ ). It is not difficult to show that E k (τ ) indeed belongs to M * (N ).

Jacobi Modular Forms
Definition 2. A Jacobi modular form of weight k and index m for a modular group Γ is a function φ : H × C → C that depends on a modular parameter τ ∈ H and an elliptic parameter z ∈ C. It transforms under the action of Γ on H × C as Let us first consider Γ to be SL(2, Z). Choosing T = 1 1 0 1 and λ = 0, µ = 1 in equations (A.8) and (A.9) respectively we learn that the Jacobi form is invariant under both shifts τ → τ + 1 and z → z + 1, so it's legitimate to write down the expansion, φ(τ, z) k,m = n,r c(n, r)q n y r , with q = e 2πiτ , y = e 2πiz . (A.10) The coefficient c(n, r) actually only depends on r and an SL(2, Z) invariant combination 4nm − r 2 . We are interested in the so-called weak Jacobi modular forms, which satisfy c(n, r) = 0 unless n ≥ 0. We denote its ring as J w * , * (Γ). It is shown in [86] that the ring of weak Jacobi forms J w * , * (SL(2, Z)) with even weight and integral index is freely generated over M * (SL(2, Z)) by two generators ϕ −2,1 (τ, z) and ϕ 0,1 (τ, z). They can be defined in terms of Jacobi theta functions, (A.11) By the same token, we also need to consider the Jacobi modular forms for the congruence subgroups J w * , * (Γ 0 (N )). For us, the most important class of examples is the Jacobi forms φ k,m (N τ, z) where φ k,m (τ, z) belongs to J w * , * (SL(2, Z)). For brevity we just denote it by φ k,m , with N understood from the context. Also note that the actual index of φ k,m (τ, z) is reduced to m/N , as is shown explicitly in the section 4.1.
In the final part, let us show the identities among the generators that are used in our modular ansatz, for N = 2, 3. For modular forms involving τ and 2τ , we find the following relations, In order to prove them, we need to invoke the following known identities involving the Jacobi theta functions, As an example, we present here a proof of the last equality in (A.12).

RHS =
(A.14) For modular forms involving τ and 3τ , the situation becomes more complicated. Experimentally, we find the following identities which we verify up to very high orders in q, Table 8. Elliptic genera of B 2 . Here, A z = A z (τ ), A z = A z (2τ ), and same for B z .

B Elliptic genera and BPS invariants
In this section, we present the numerator of the elliptic genera for the following twisted M-strings: B 2 in table 8, G 2 in table 9, B 3 in table 10, (C 3 ) 0 in table 11, and F 4 in table 12. The elliptic genera of (C 1 ) π and (C 2 ) π theories is listed in table 13. We also list some refined GV invariants of geometries that engineer 5d N = 2 gauge theory of type G 2 and F 4 , obtained from the blowup equations or the elliptic genera, in table 14 and 15. Table 9. Elliptic genera of G 2 . Here, A z = A z (τ ), A z = A z (3τ ), and same for B z .
n N 1 1 1 1 Table 10. Elliptic genera of B 3 . Here, A z = A z (τ ), A z = A z (2τ ), and same for B z .

C One-instanton partition functions
In this appendix, we provide the one-instanton partition function Z inst 1 = ( √ q 1 Qm− √ q 2)( √ q 1 − √ q 2 Qm) (q 1 −1)(q 2 −1)QmZ 1 for G 2 , F 4 , E 6 , E 7 , E 8 with gauge fugacities turned off. With the notation v = (q 1 q 2 ) − 1 2 = e − + , we observe thatZ 1,G take the form with P n (v) = P n (v −1 ). In the massive limit m → ∞, only P h ∨ G −1 (v) survives, and the theory should become the pure gauge theory with gauge group G. We verify that our results here indeed are reduced to the Hilbert series for pure gauge theories studied in [87,88].