Six-dimensional Origin of $\mathcal{N}=4$ SYM with Duality Defects

We study the topologically twisted compactification of the 6d $(2,0)$ M5-brane theory on an elliptically fibered K\"ahler three-fold preserving two supercharges. We show that upon reducing on the elliptic fiber, the 4d theory is $\mathcal{N}=4$ Super-Yang Mills, with varying complexified coupling $\tau$, in the presence of defects. For abelian gauge group this agrees with the so-called duality twisted theory, and we determine a non-abelian generalization to $U(N)$. When the elliptic fibration is singular, the 4d theory contains 3d walls (along the branch-cuts of $\tau$) and 2d surface defects, around which the 4d theory undergoes $SL(2,\mathbb{Z})$ duality transformations. Such duality defects carry chiral fields, which from the 6d point of view arise as modes of the two-form $B$ in the tensor multiplet. Each duality defect has a flavor symmetry associated to it, which is encoded in the structure of the singular elliptic fiber above the defect. Generically 2d surface defects will intersect in points in 4d, where there is an enhanced flavor symmetry. The 6d point of view provides a complete characterization of this 4d-3d-2d-0d `Matroshka'-defect configuration.

, and in the context of N = 4 SYM, much evidence exists in its favor, in particular the seminal work [3], and, more recently, its relation to the geometric Langlands program in [4]. For the theory with a U (N ) gauge group, the conjectured duality states that the theory, with the complexified coupling constant τ defined in terms of the θ-angle and gauge coupling g as is self-dual under τ → γτ , with γ ∈ SL(2, Z).
The SL(2, Z) duality group of N = 4 SYM with gauge group U (N ) has a geometric realization in terms of the 6d (2, 0) superconformal theory of type A N −1 , i.e. the theory on a stack of M5-branes in M-theory, by compactification on an elliptic curve with complex structure given by the modular parameter τ . By shrinking the torus fiber, the 6d (2, 0) theory reduces at low energies to 4d N = 4 SYM. S-duality is then identified with SL(2, Z) modular transformations acting on τ [5].
In string theory, a closely related duality is the S-duality of Type IIB string theory, acting on the axio-dilaton τ IIB = C 0 + ie −φ , which when acted upon on a D3-brane in Type IIB results precisely in the S-duality of the effective N = 4 SYM on its world-volume. In this case, a formulation, which allows for a manifest realization of SL(2, Z)-duality is provided by F-theory [6], which allows the study of string theory vacua, where the axio-dilaton varies.
Our goal here is to determine a formulation of N = 4 SYM with varying complexified coupling constant in analogy to the F-theoretic approach to IIB string theory. We find that this setup arises naturally from the 6d (2, 0) theory on an elliptically fibered complex threefold, by dimensional reduction along the elliptic fiber.
Supersymmetry can be preserved, if no topological twist is applied to the 6d theory, if the elliptic three-fold is Calabi-Yau. More generally, supersymmetry can be preserved for an This elliptic three-fold is embedded into an elliptically fibered Calabi-Yau four-fold X 4 , with base M , which contains B 2 . The elliptic fibration of X 4 restricts to that of Y 3 . We assume that the fibration has a section, i.e. there is a map from the base to a marked point in the fiber, which is origin of the fiber elliptic curve.
arbitrary elliptically fibered Kähler three-fold if the theory is topologically twisted. We will study both situations in detail. We will find that imposing Kählerity is tied to τ being a holomorphic function on the base B 2 . This setup is of particular interest, when the fibration becomes singular, i.e. whenever the complex structure degenerates. Singularities in the fiber happen generically over 2d loci, which are complex curves in the base of the fibration. We will find that there are additional chiral degrees of freedom localized at these 2d defects.
The complete M-theory setup corresponds to the geometry X 4 × R 1,2 , where X 4 = CY 4 is an elliptically fibered Calabi-Yau four-fold, with base three-fold M 3 . M5-branes wrap an elliptic Kähler three-fold Y 3 , that is a Kähler surface B 2 ⊂ M 3 and the elliptic fiber restricted to this subspace -see figure 1 for a depiction of the setup.
An alternative approach to studying this N = 4 SYM theory with varying coupling is directly in terms of D3-instantons in F-theory, which was pursued in [7]. This 4d point of view is restricted to the abelian N = 4 theory, which once twisted by the so-called topological duality twist, defines the theory with varying τ on a Kähler surface. This duality twist is a combination of a standard topological twist, combined with a non-trivial background connection for the gauge field associated to a U (1) D action on the abelian N = 4 SYM theory, which is called "bonus symmetry" [8,4]. One of the main results in this paper is the derivation of this duality twisted theory from τ γτ W γ B 2 Figure 2: Setup of 4d theory on B 2 with local coordinates z 1 and z 2 . The curve C is given by z 1 = 0, and the wall W γ by θ 1 = 0, where θ 1 is the angular coordinate of z 1 . As one crosses the branch-cut W γ , the coupling undergoes an SL(2, Z) monodromy γ.
6d, by performing a standard topological twist of the 6d (2, 0) theory on an elliptic three-fold and reducing along the elliptic fiber. An advantage of taking the 6d point of view is that it predicts a generalization of the U (1) model in [7] to a non-abelian 4d theory with varying coupling, which is the reduction of the type A N −1 6d (2, 0) theory on the elliptic fibration.
We will present the non-abelian extension of the 4d theory with varying coupling.
One of the salient features of these theories is the presence of 2d defects. Geometrically these correspond to complex one dimensional subspace in B 2 above which the fiber degenerates. Taking a varying holomorphic coupling τ over a base manifold B 2 , can result in singularities in the fiber, above 2 real-dimensional surfaces/complex curves C ⊂ B, along which τ degenerates. Locally around each such curve C, the function τ has a monodromy τ → τ given by an SL(2, Z) modular transformation γ of the elliptic curve There are branch-cuts emanating from the curve C, which are real codimension one in the 4d theory on B 2 and thus appear as 3d walls W , across which the coupling jumps by an SL(2, Z) duality transformation. We will sometimes refer to these as duality walls. This setup is shown in figure 2.
In IIB/F-theory, the 2d singular loci are the intersections of the D3-branes, on which the 4d SYM theory is realized, with 7-branes, and the chiral modes arise from 3-7 strings. Thus one way to study the defects is in terms of the spectrum of [p, q] strings between the D3-and 7-branes. From the 6d (2, 0) theory point of view, we will see that these modes arise naturally from the reduction of the two-form field B µν along the P 1 s associated to the singular fibers.
On the other hand, the 3d walls carry no physical degrees of freedom, and only guarantee continuity of the theory across the entire 4d spacetime.
The surface defects are labeled by elements γ of SL(2, Z). For γ = T n , i.e. τ → τ + n, a complete Lagrangian description is possible for the non-abelian theory [9]. The 3d walls in this case carry a level n Chern-Simons term, n W Tr[A ∧ dA + 2 3 A ∧ A ∧ A]. On the defect itself, the theory is a chiral WZW model, which cancels the gauge anomaly of the 3d coupling. Alternatively the defect theory can be described in term of n chiral fermions or n chiral bosons.
An interesting property that we notice is that the 2d defects generically intersect in points. From the point of view of the 2d chiral theories, this corresponds to loci of enhanced flavor symmetries, which can be determined by studying the mechanics of the singular fibers which have an enhanced singularity above these points [10][11][12][13][14][15].
In summary, the complete setup could be termed a 4d-3d-2d-0d Matroshka-defect configuration: starting in 6d we reduce on an elliptic fiber to 4d SYM with varying coupling constant.
There are 3d walls, which end on a network of 2d surface defects, on which chiral modes are localized, and have a flavor symmetry that is dictated by the singularities in the elliptic fiber.
These 2d defects, in turn, intersect at points, which enjoy an enhanced flavor symmetry.
We should mention some related compactifications of the 6d (2, 0) theory. The dimensional reduction of the 6d theory on a circle gives rise to maximally supersymmetric 5d Yang-Mills.
The case of circle-fibration was discussed in [5] and in more detail in [16,17] including the Taub-NUT geometry, where the circle-fiber can degenerate. The Taub-NUT reduction will play an important role in our analysis of the 6d reduction.
In F-theory, a related configuration are D3-branes compactified on a curve in the base of a Calabi-Yau three-fold including the duality twist [18]. A comprehensive analysis of D3-branes on curves in the base of Calabi-Yau compactifications to dimension 6, 4, and 2, respectively, in F-theory, will appear in [19]. Unlike the case studied here, which could be understood in terms of D3-instantons with duality surface defects, in those cases, the theories are 2d chiral supersymmetric theories, with point-like defects on the compactification curve, where the D3branes intersect 7-branes in F-theory. More recently a discussion of supergravity backgrounds for 4d N = 4 SYM appeared in [20]. Also, some duality defects for N = 2 theories were proposed in [21]. Furthermore, there are related configurations in the D3-instanton literature in F-theory: our setup can be viewed from the bulk F-theory or M-theory theory point of view as studying D3-or M5-instantons, for instance in [22][23][24][25][26][27], see [28] for a review. The plan of this paper is as follows. In section 2 we provide the setup for studying the 6d (2, 0) theory on an elliptically fibered three-fold. We carry out the reduction to 4d of the abelian 6d theory defined on an elliptically fibered Calabi-Yau three-fold and extend it to the non-abelian theory. We also review the so-called bonus-symmetry in N = 4 SYM. In section 3 we construct the twisted 6d (2, 0) abelian theory on an elliptic Kähler three-fold and perform the reduction along the elliptic fiber to 4d. We find a twisted 4d N = 4 SYM theory with varying coupling, matching the topological duality twisted theory. Furthermore, we determine the non-abelianization of this 4d SYM theory with varying coupling. In section 4 we discuss the 3d walls and 2d defects and explain how the defect degrees of freedom arise from 6d. We also discuss the flavor symmetry enhancement at the point defects localized at the intersections of the 2d defects, in relation to the singularity enhancement of the elliptic fiber. We summarize various topological twists of the 6d theory, present conventions and spinor manipulations, and provide details on computations in the appendices A to D.
2 Elliptic fibrations, M5-branes and 4d N = 4 SYM We begin with some background for studying the 6d (2, 0) super-conformal theory on an elliptic fibration, by reviewing some basic facts about such geometries, the relation of the 6d theory to N = 4 SYM in 4d, as well as the bonus symmetry of the abelian 4d N = 4 theory.
All these parts will come together in the following sections.

Elliptic Three-folds
We consider the abelian 6d (2, 0) theory on an elliptically fibered variety Y (≡ Y 3 ) of complex is the four-dimensional base of the fibration. Denote by τ = τ 1 + iτ 2 the complex structure of the elliptic fiber and by V its volume. Given this setup we consider the Euclidean 6d theory. In the case of trivial fibrations, the space is endowed with the direct product metric where ds 2 B is line element on the base. Here, (x, y) are periodic coordinates on the elliptic curve with periodicity 1. To obtain a generic fibration, we let τ = τ (b µ ) and V = V (b µ ) depend on the coordinates b µ on the base B, and introduce two connections η = η µ db µ and ρ = ρ µ db µ , which are 1-forms on B, with metric given by Here g B is the metric on the base. When the elliptic fibration has a (holomorphic zero-) section, as we shall assume, the off-diagonal terms in the metric vanish, which is equivalent to requiring that ρ = η = 0 [22,29]. Furthermore, we set the volume V to be constant. Later on, taking the limit V → 0 corresponds to the F-theory limit, where the M5-brane reduces to the theory on the D3-brane. A convenient frame for this specialization is e a , a = 0, 1, 2, 3 , where e a is the frame on the base, associated to g B . The inverse frame is given by where µ and µ are curved Lorentz indices on the total space and on the base respectively.
The spin connection Ω AB , A, B = 0, 1, · · · , 5, is given by where ω ab is the spin connection on B.
In order to preserve some supersymmetries, we will topologically twist the theory, which requires Y to be Kähler manifold, with reduced U (3) L ⊂ SO(6) L holonomy. From the results in [30] it is known that all allowed base surfaces, that support (minimal) elliptic fibrations are Hirzebruch surfaces F m for m = 0, 2, 3, · · · , 7, 8, 12, projective space P 2 , the Enriques surface, or blow ups thereof. We assume that this fibration has a section, which is precisely given by a copy of the base B, and can be represented thereby by a Weierstrass model with f and g sections K , respectively. Furthermore, we allow for singularities along a complex codimension one locus Σ in the case B, characterized by which we will characterize in terms of the vanishing of a local coordinate in B. Locally around each singularity, the function τ has a monodromy τ → τ given by an SL(2, Z) modular transformation γ as in (1.3).
To obtain a Kähler metric we start by introducing complex coordinates z i , i = 1, 2, on the base B, which has to be Kähler, and w = x + τ y on the torus, and pick τ = τ (z i ) holomorphic in z 1 , z 2 . The metric now takes the form with g B ij a hermitian metric on B. If K B is the Kähler potential of the base, the Kähler potential for Y is given by We introduce the complex frame, which we refer to as canonical frame with real components (2.4). The holomorphicity of τ ,∂τ = 0, can be recast into The Kähler condition for the base manifold B implies that the four-dimensional spin connection Ω ab has also two vanishing components, which in this frame are Ω 02 −Ω 13 = Ω 03 +Ω 12 = 0.
This makes six components of the spin connection vanish, signaling the reduction of the holonomy SU (4) L SO(6) L → U (3) L of the six-manifold, as it should be for a Kähler space. More precisely the embedding of U (3) L inside SO(6) L can be described as follows (see e.g. [31], chap. 15.3): consider a 3 × 3 unitary matrix U = (u ij ) and replace each component by a 2 × 2 real matrix u ij →Re(u ij )1 2 +Im(u ij ) , where 1 2 is the 2 × 2 identity matrix and is the antisymmetric matrix with component 12 = − 21 = 1. The resulting matrix is a 6d orthogonal matrix. The same operation maps an anti-hermitian 3 × 3 matrix to an anti-symmetric 6 × 6 matrix and describes an embedding of the u(3) algebra into the so(6) algebra. The so(6) matrices in the image of this map obey precisely the six relations above, showing that Ω belongs to this u(3) subalgebra.

Abelian 6d (2, 0) Theory
We consider the abelian 6d (2, 0) theory, which describes the theory on a single M5-brane, in Euclidean signature. The symmetry group is the 6d Lorentz group and the R-symmetry, The theory consists of a free tensor multiplet with fields (H 3 , λ m , Φ mn ), where H 3 is a self-dual three-form, λ m , m = 1, · · · , 4 are Weyl spinors of positive chirality transforming in the (4, 4) of SU (4) L × Sp(4) R and Φ mn are scalars transforming in the (1,5). They obey Φ mn = −Φ nm and Ω mn Φ mn = 0, where Ω mn is the anti-symmetric Sp(4) invariant tensor. Our conventions on spinors are provided in appendix A.
In Lorentzian signature the bosonic fields H 3 and Φ mn are real and the fermions λ m obey a Symplectic-Majorana condition. In Euclidean signature, which is the case of interest here, we cannot enforce self-duality on a real three-form 1 . Instead we can consider the modified self-duality condition where R is the 6d Ricci scalar. The equation on H 3 tells us that it can be written locally as the differential of a two-form H 3 = dB 2 . These equations are invariant under Weyl transformations with Weyl weights w(H 3 ) = 0, w(λ m ) = 5 2 and w(Φ mn ) = 2. The equations of motion of the spinor and scalar fields can be derived from the actions We will also label the five scalars Φ i , i = 1, · · · , 5 corresponding to the vector representation  17) and are given by (2.18) The theory, defined in this way, preserves supersymmetries only when the six-dimensional geometry admits solutions to (2.17). We note that the Killing spinor equations imply the relation The supersymmetry transformations leave the equation of motions (2.14) invariant and the super-algebra closes on-shell.

M5-branes on an elliptic Calabi-Yau
In this section we consider the abelian (2, 0) theory on an elliptic fibration admiting Killing spinors and we perform the reduction to four dimensions. We will show that, without any additional twisting of the 6d (2, 0) theory, this implies that the three-fold has to be a Calabi-Yau variety. In four dimensions the reduced theory will be the abelian N = 4 Super-Yang-Mills theory on a Kähler space with varying complex coupling. Having obtained the abelian theory we will promote it to the non-abelian theory with U (N ) gauge group and comment on issues related to monodromies of the coupling.
We wish to reduce the six-dimensional theory on E τ → Y → B to a four-dimensional theory on the base B, by shrinking the elliptic fiber E τ . This corresponds to taking the constant volume V of E τ very small compared to the size of B (or considering the theory at energies small compared to V −1/2 if B is non-compact). We start by studying the constraints imposed by supersymmetry on the geometry. We assume the existence of a 6d Killing spinor E independent on the fiber coordinates x, y, with negative chirality. Such a spinor can be decomposed, as explained in appendix A.2, into where E + , E − are 4d spinors of positive and negative 4d chirality respectively and η ± are constant 2d chiral spinors which serve as a basis for the decomposition. The 6d Killing spinor equations (2.17) then reduce to the 4d Killing spinor equations, (2.21) These equations, written back in 6d language, imply that the 6d Killing spinor E is covariantly constant, ∇ A E = 0, so that the six-dimensional geometry has to be Calabi-Yau. We find therefore that elliptic fibrations with a section, which admit a Killing spinor constant along the elliptic fiber, correspond exclusively to Calabi-Yau three-folds. The equations on the second line of (2.21) imply that τ is holomorphic in appropriate complex coordinates on the base B. We will come back to this when we discuss the twisted theory.
On a generic Calabi-Yau manifold the reduced holonomy group is SU (3) L ⊂ SU (4) L and a Weyl spinor in the 4 of SU (4) L decompose into 3⊕1 of SU (3) L (see appendix B.2). Therefore a generic Calabi-Yau three-fold has a single covariantly constant spinor E, which reduces in four dimensions to a single pair of Killing spinors of opposite chirality (E + , E − ) satisfying (2.21). Since the Killing spinor equations for E + and E − are decoupled, it must be that, for a generic Calabi-Yau, either E + = 0 or E − = 0, otherwise we could consider these spinors as independent and they would generate more supersymmetry in 4d than we had in 6d. We can argue about this point as follows. If we have both E + and E − non-zero, we can construct E − = B(E − ) * 2 which satisfies the same equations as E + , but which has negative chirality 3 . In particular we have ∂ aτ γ a E + = 0 and ∂ aτ γ a E − = 0, which together imply ∂ aτ = 0 and therefore ∂ a τ = 0. The coupling τ is then constant, corresponding to the Calabi-Yau being a direct product E τ × K 3 . This is a non-generic Calabi-Yau, with further reduced holonomy.
The supersymmetries of the six-dimensional theory are parametrized by the four spinors E m , each one being a copy of the Killing spinor. The supersymmetries of the four-dimensional theory are similarly parametrized by the four spinors E m + or E m − . In the following we will assume E m − = 0 and parametrize the supersymmetry transformations with E m + . In order to reduce to a four-dimensional theory on the base manifold B, we decompose the three-form H 3 into where E 3 , F 2 , G 2 , D 1 are forms on B, taken independent of the fiber coordinates x, y. The equations of motions for H 3 (2.14) are The latter equation can be used to solve for E 3 and G 2 in terms of F 2 and D 1 . Some useful properties to work this out are θ ∧ e 4 ∧ e 5 = ( 4 θ) , with ω a 2-form and θ a 1-form on B. We obtain The closeness relation dH 3 = 0 becomes The equations on the first line remain in the reduced theory and allow to write locally F 2 = dA and D 1 = dC, with A a one-form and C a scalar, which is periodic C → C + 2πn with n ∈ Z, It is now desirous to integrate the equations of motion for F 2 to find a Lagrangian description of that sector of the 4d theory. The theory is that of an abelian connection A with action where F ≡ F 2 is the curvature of A and τ varies over the base B, which we assumed to be without boundary.
The equations of motion for the scalar field C defined by D 1 = dC reduces simply to It integrates to the action Next we consider the scalar fields and take them independent of the x and y coordinates, where the rescaling by √ V is convenient to simplify later formulas. It also gives the scalars φ mn the canonical 4d scalar scaling dimension one. The equations of motion (2.14) reduce to where we used the relation between 6d and 4d Ricci scalars This equation simplifies with the assumption that the six-dimensional geometry is Calabi-Yau.
We have R (6d) = 0 and the equations of motions are simply This equation integrates to the action where we have changed the scalar index φ i = 1 4 (Γ i ) mn φ mn , with i = 1, · · · , 5 the index of the 5 of SO(5) R Sp(4) R 4 . The index i is implicitly summed over in the action.
Finally we consider the fermions λ m . Following the analysis of appendix A.2 λ m can be decomposed into where λ m + is a positive chirality spinor, λ m − is a negative chirality spinor in four dimensions, and The equations of motion (2.14) reduce to and can be derived from the action The supersymmetry transformations, obtained from six-dimensions, are generated by four Killing spinors E m + or E m − , each one of them being equal to the solutions to the Killing spinor equation (2.21) where we replace the scalar C by φ 6 ≡ C  The scalar field φ 6 is in the trivial representation of the Sp(4) R R-symmetry, inherited from the three-form. The five scalars φ i , which transform in the 5 of Sp(4) R combine with φ 6 and transform in the 6 of SU (4) r . Note that in the limit V → 0 (i.e. the F-theory limit), the compact scalar φ 6 = C/ √ V decompactifies and is therefore on the same footing as the noncompact scalars φ i . The fermions λ m − , λ m + transform in the 4 of Sp(4) R . Under the enhanced R-symmetry, they transform as the 4 and4 of SU (4) r . More precisely λṁ + and λ m − transform in the (2, 1,4) ⊕ (1, 2, 4) of the 4d flat space symmetry group SU (2) 1 × SU (2) 2 × SU (4) r .
The complete action takes the SU (4) r invariant form with the SU (4) r covariant supersymmetry transformations (2.41) The index i now goes from 1 to 6, labeling the representation 6 of SU (4) r , and we have definedΓ i ≡ −Γ i , for i = 1, · · · , 5, and (Γ6) mṅ = (Γ6)ṁ n ≡ iδ m n . Indices are now raised and lowered with Ω mṅ and Ωṁ n .

Non-abelian Generalization
The four-dimensional action can be promoted to a non-abelian theory by letting the fields take value in the u(N ), or su(N ) algebra, with A µ the non-abelian gauge potential and F = dA + A ∧ A, and taking the action to be The non-abelian theory with gauge algebra su(N ) is then interpreted as the dimensional reduction of the 6d (2, 0) theory of type A N −1 on an elliptic Calabi-Yau three-fold.
We have derived a Euclidean action with complex fields in four-dimensions. We could impose reality conditions, demanding that the bosonic fields are hermitian and the fermions obey a Symplectic-Majorana condition (see appendix A.1).
In the flat space and constant τ limit, namely the 6d flat space limit where the elliptic fibration is a direct product E τ ×R 4 , we recover the standard abelian N = 4 Super-Yang-Mills action as expected [32].
Finally we must comment on the fact that such Calabi-Yau elliptic fibrations have singular loci where the modular parameter τ degenerates, as mentioned in Section 2.1. In the fourdimensional theory the profile of the holomorphic coupling τ has surface defects, where τ degenerates, from which emanate branch cuts. These branch cuts appear as domain-walls across which the coupling jumps by an SL(2, Z) duality transformation, which we may call duality walls. We will discuss these duality walls and the surface defects in section 4. For now, we only notice that, due to the presence of these walls, the supersymmetry variation of the action is not vanishing, but instead picks boundary terms for each duality wall W where W + − W − computes the difference of the integrals with the fields and coupling τ evaluated on one side of the wall (at W + ) and the fields and coupling τ evaluated across the wall (at W − ). Here, n µ denotes a unit vector normal to the 3d wall.

N = 4 SYM and Bonus Symmetry
The abelian N = 4 SYM theory has an additional transformation, which we refer to as U (1) D , also known as "bonus symmetry" in [8]. It arises when we consider SL(2, Z) electric-magnetic duality transformations in N = 4 SYM. Such a transformation is parametrized by an SL(2, Z) As found in [8] and [4] (using different approaches), the supercharges transform under the transformation γ. The bosonic symmetries of the theory are the Lorentz group SO(4) l SU (2) 1 × SU (2) 2 and the R-symmetry group SU (4) r . The supercharges of N = 4 SYM are Under an SL(2, Z) duality the supercharges transform by a phase rotation, which is identified The fields of the SYM theory transform under this U (1) D as The gauge field A µ does not have a definite transformation under U (1) D . In the abelian theory the field strength components do have definite U (1) D transformations, In [8] this U (1) D transformation was described as a symmetry of the equations of motion and of the supersymmetry variations of the abelian theory and the charges of the fields under U (1) D were given. However it is not a symmetry of the SYM action. In the non-abelian case the symmetry does not survive, even at the level of the equations of motion, however it still acts on the sector of protected operators.
In [7] this U (1) D action was used to perform the so-called "topological duality twist" in the abelian SYM theory, allowing U (1) D to mix with the Lorentz symmetry, leading to a theory with varying coupling constant and duality defects. The approach that we will take, starting in 6d, will allow for a definition of the twisted theory even in the absence of a clear definition of a 4d U (1) D for non-abelian gauge groups.

Duality Twist of 4d N = 4 SYM from 6d
We consider now the dimensional reduction on an elliptic Kähler three-fold Y 3 (which is notnecessarily a Calabi-Yau). In order to preserve some supersymmetries, we need to topologically twist the six-dimensional theory, which means turning on an appropriate R-symmetry gauge field background. 5 This is achieved by twisting the U (1) L =diag(U (3) L ) residual holonomy with a U (1) R subgroup of the R-symmetry group. In this section we describe the sixdimensional abelian twisted theory on a Kähler three-fold. We then carry out the reduction on the elliptic fiber and obtain a twisted version of N = 4 SYM theory with varying coupling constant. In particular, we identify in this way the topologically twist of the M5-brane theory with the duality twist of N = 4 SYM described in [7].
Interestingly we show that the bonus symmetry, or rather "non-symmetry", of N = 4 SYM in 4d, has its origin in terms of the geometric SO(2) 45 rotation symmetry in the (x, y) plane in the flat space M5-brane theory.
We also provide the non-abelian version of the topologically twisted 4d theory and point out difficulties related to the description of the walls and surface defects associated to the inherent coupling constant monodromies.

Twist in 6d, Duality Twist and Bonus Symmetry
We first explain the twist in the six-dimensional theory and work out its relation to the duality twist in four dimensions, which was studied in [7]. In the process we identify the six-dimensional origin of the bonus symmetry.
A generic Kähler six-manifold has reduced holonomy U (3) L SU (3) L × U (1) L ⊂ SU (4) L and the twisting consists in mixing the U (1) L transformation with a U (1) R R-symmetry transformation, to obtain supercharges transforming trivially under the new Lorentz symmetry. In appendix B we detail the various inequivalent twistings, which correspond to different choices In the following we consider the topological twisting, which preserves the maximal amount of supersymmetries, namely the twisting described in appendix B as "Twist 1", which preserves two supercharges on an arbitrary Kähler manifold. It can be described as follows.
Consider the SU (2) R × U (1) R R-symmetry subgroup associated to the following decomposition of the representation 4 of Sp(4) R The supercharges decompose under the Lorentz and R-symmetry subgroups as We now choose an alternate Lorentz group by redefining the U (1) L generator as where T L and T R are the generators of the Lorentz and R-symmetry U (1)s. The decomposition of the supercharges under the twisted symmetry group is then The last term corresponds to supercharges that are trivial under the twisted Lorentz group and transform in the 2 −1 under the residual SU (2) R × U (1) R R-symmetry group. These correspond to two scalar supercharges in the twisted theory.
Anticipating the result of the reduction, we would like to make immediately the connection with the duality twist in 4d. For this purpose it is useful to understand more precisely which component of the spin connection will be affected by the twisting. At the end of section 2.1, and following [31], we explained how the reduced holonomy algebra u(3) L is embedded into so(6) L . Under this embedding, the generator of the U (1) L subgroup is given, up to normalization, by the so(6) matrix T L ≡ J = −diag( , , ). 6 The spin connection component which gauges U (1) L is given by with a normalization chosen such that supercharges have have the U (1) L charges given above.
The twist of the 6d theory (3.3) is then implemented by turning on a U (1) R connection We can now see what is effect of this twist from the four-dimensional point of view. The base B is Kähler, so its holonomy group is also reduced The SO(2) 45 rotation symmetry in the (xy) plane of the 6d theory is broken when we place the theory on the torus. In standard dimensional reduction, such a symmetry is restored in the infrared theory where it appears as an R-symmetry. In our case the 4d theory does have an enlarged R-symmetry, but it does not come from the SO(2) 45 rotation, which does not survive as a genuine symmetry of the 4d theory. We will come back to this point shortly.
We propose to identify it with the U (1) D bonus symmetry reviewed in section 2.5, which, similarly to R-symmetries, acts on the supercharges of N = 4 SYM, i.e.
The SU (2) R × U (1) R R-symmetry subgroup can be identified with a subgroup of the 4d SU (4) r enhanced R-symmetry as follows: we consider the subgroup 4d R-symmetry : and Having found the origin of all the relevant symmetries in 4d, we find that the sixdimensional twisting (3.3), which corresponds to turning on the U (1) R connection (3.6), is expressed in 4d by turning on the corresponding U (1) r connection with ω U (1) D ≡ 1 2 Ω 45 . This corresponds to the four-dimensional twisting described by the generator redefinitions where T , T r and T D = −2T 45 are the generators or U (1) , U (1) r and U (1) D , respectively. We which we reduce becomes a U (1) R-symmetry of the reduced theory. This follows from the fact that the SO(2) Lorentz rotation becomes a global symmetry in the lower-dimensional theory, which acts on the supercharges. It then becomes an R-symmetry. When we define the theory on the torus, we break this rotation symmetry, but in the low-energy limit, or zero size limit of the torus, it is recovered, so we still naively expect it to become a U (1) R-symmetry in the lower-dimensional theory. However this cannot be the case in our setup since, if it were true, the 4d theory would have a least a Sp(4) R × U (1) R-symmetry, but N = 4 SYM has SU (4) r R-symmetry which does not contain Sp(4) R × U (1) as a subgroup. This means that the SO(2) 45 Lorentz symmetry, broken by the torus geometry, is not recovered in the lowenergy limit as an R-symmetry in 4d. How is this possible? This is possible if the 6d theory does not have a local Lorentz invariant action. In this way we avoid the contradiction since the 4d theory does not inherit the symmetry by dimensional reduction of a 6d action. The non-existence of this U (1) R-symmetry in N = 4 SYM can actually be seen as an argument for ruling out the existence of a 6d Lorentz invariant action for the (2, 0) theory. The R-symmetry enhances instead from Sp(4) R in 6d to SU (4) r in 4d as explained around (2.39). We can identify the SO(2) 45 rotations with the U (1) D transformations by using the interpretation of the SL(2, Z) dualities in 4d as diffeomorphisms of the elliptic fiber in 6d, which act the complex structure parameter τ . The diffeomorphisms are labeled by an SL(2, Z) element γ and are explicitly given by preserving the coordinate periodicities (x , y ) ∼ (x + 1, y + 1). The metric (2.9) transforms to which is the same as the initial metric with τ replaced by γ.τ . The new complex coordinate w = x + τ y is related to the initial complex coordinate w = x + τ y by a rescaling The canonical complex frame in the new coordinates (e 0 , e 1 , e 2 ) is related to the initial complex frame (2.11) by namely the new frame is obtained by an SO(2) 45 Lorentz rotation with rotation parameter α(γ). This means that the SL(2, Z) diffeomorphism contains an SO(2) 45 rotation with parameter α(γ) 8 . This corresponds to a U (1) D rotation with parameter − α(γ) 2 . The six-dimensional supercharges transform under the representation (4, 4) of SU (4) L × Sp(4) R . Under dimensional reduction, they are mapped to supercharges Qṁ α ,Q ṁ α of N = 4 SYM, transforming as ( the SL(2, Z) elliptic fiber diffeomorphisms in 6d acts on the 4d supercharges precisely as in (2.46). We conclude that the uncanny 4d duality twist, is nicely explained from the 6d perspective by identifying the "bonus symmetry" U (1) D in 4d with the SO(2) 45 Lorentz rotation in 6d. Moreover the so-called duality twist is simply expressed as a standard topological twist of the (2, 0) theory.
Finally we would like to provide the U (1) D charges of the 4d fields. These are inherited from the SO (2)

Twisted 6d theory
We now describe the six-dimensional theory on a Kähler three-fold Y 3 with the topological twist described above. The twisting can be done on any Kähler three-fold, so the theory that we describe in this section does not require the Kähler manifold to be elliptically fibered. We will restrict to this case in the next section when we study the reduction to four-dimensions.
In the twisted theory the fields transform in representations of the twisted symmetry group SU (3) L × U (1) L × SU (2) R 9 corresponding to (anti)holomorphic forms. To work out the decomposition of the various fields into form components, it is useful to introduce several geometric objects. The twisted theory possesses a covariantly constant spinor of positive chirality, that we denote η, where M = 0, 1, · · · , 5 is the spacetime index and the background U (1) R connection is fixed by the twisting (3.6). From bilinears of this covariantly constant spinor, we can construct a Kähler form J (1,1) , a holomorphic three-form Ω (3,0) and an anti-holomorphic three-formΩ (0, 3) on Y 3 . The details are presented in appendix D.
The imaginary self-dual 3-form H 3 is in the representation 10 of SU (4) L and is not charged under the R-symmetry group. Under the twisted symmetry group it decomposes to the sum of irreducible representations 20) corresponding to an imaginary self-dual (1, 2)-form h (1,2) , a holomorphic one-form h (1,0) and a holomorphic three-form h (3,0) . The twist charge q L /2 indicates the difference in the holomorphic and anti-holomorphic degree: The transformation under the SU (3) L furthermore fixes the actual form degrees: in the case of 6 with charge q L /2 = 1, the form is of type Λ (p,p+1) with p = 1. Likewise 3 −2 is a Λ p+1,p form with p = 0. Indeed, we can decompose the three-form H 3 as where J is the Kähler form of Y 3 , defined in appendix D. Each component is imaginary selfdual (see appendix C) and corresponds to one of the irreducible pieces in the decomposition (3.20). The equations of motion dH 3 = 0 become These equations can be solved locally by expressing the three-forms in terms of the two-form and demanding that∂b (0,2) = 0, J ∧ (∂b (1,1) + ∂b (0,2) ) = 0 and ∂b (1,1) +∂b (2,0) is imaginary self-dual. h (1,0) can be expressed directly in terms of the form-potentials, using the relation Next we consider the fermions. The positive chirality spinors λ m transform as the supercharges, in the (4,4), and decompose as follows We can identify these irreducible representations with the holomorphic one-and three-forms Λ α (1,0) , Λ α (3,0) , the anti-holomorphic two-form Λ α (0,2) and the scalar Λ α (0,0) , respectively. Here α ∈ {1, 2} denotes the index for the 2 of the SU (2) R R-symmetry. This follows directly from the twist charges: q L /2 gives the degree of the form, and the sign(q L ) = ± determines whether the form is holomorphic or anti-holomorphic. The equations of motion for the twisted fermions are determined in appendix D, using the explicit decomposition of the spinors into form components, to be∂ These equations of motion can be integrated to the action up to total derivatives. Note that the forms Λ α (n,m) are fermionic (Grassmann-odd). We now turn to the scalar fields Φ i which transform in the 5 of Sp(4) R . Under the subgroup SU (2) R × U (1) R they decompose into (3.27) In the twisted theory these fields transform in the representation where the twist charges again identify these in terms of the forms as follows: an SU (2) Rtriplet of scalars ϕ αβ (0,0) (with ϕ αβ = ϕ βα ), a holomorphic three-form σ (3,0) for q L /2 = −3 and an anti-holomorphic three-formσ (0,3) for q L /2 = 3. The scalars ϕ αβ (0,0) can be identified with Φ k , k = 1, 2, 3, via where Ω (3,0) andΩ (0,3) are holomorphic and anti-holomorphic three-forms respectively, which can be constructed in the twisted theory, as explained in appendix D. The inverted relations In the 6d Euclidean theory we are considering a doubled number of fields and Φ i are complex scalars. Then ϕ αβ are again complex scalars, while σ,σ are independent (anti-)holomorphic three-forms.
The equations of motion for the scalars in flat space are ∂ M ∂ M Φ i = 0. In the twisted theory on curved space we need to covariantize the derivatives and possibly to add curvature terms, including terms involving the field strength of the background connection A U (1) R . We will simply guess the form of these curvature terms, requiring some cancellations, and verify that the supersymmetries are preserved. 10 So the equations of motion for the scalars are generically where "curv" denotes extra curvature terms. The equations of motion for the scalars ϕ αβ are found to be ∇ 2 ϕ αβ = 0, without extra curvature terms. It can be re-written The equations of motion for σ (3,0) are With the curvature terms canceling in this equation, this leaves us with These equations of motion can be integrated to the six-dimensional action which can also be derived from (2.15) after adding extra appropriate curvature terms.
The full set of equations of motion of the twisted theory is then In the twisted theory two supersymmetries are preserved. They are generated by two covariantly constant spinors of negative chirality and thus are proportional to η c , which is the charge conjugate of η (see appendix D). These correspond to two specific spinors out of the four spinors E m parametrizing the flat space supersymmetry, The transformation of the three-form field strength are

Reduction to 4d
We now specialize to the case when the Kähler three-fold is elliptically fibered. This allows us to dimensionally reduce the twisted six-dimensional theory on the elliptic fiber to a topologically twisted four-dimensional theory with varying complexified coupling τ . In section 3 we already showed that the six-dimensional R-symmetry twist descends to the Topological Duality Twist of [7]. We show now that the theory in four dimensions obtained by reducing on the elliptic fiber coincides with topologically duality twisted N = 4 SYM theory described in [7].
To reduce the theory on the torus we first decompose the six-dimensional Kähler form J The three-forms field of the twisted theory decompose into a collection of forms on the base with the constraint f (1,1) ∧ j = 0, following from h (1,2) ∧ J = 0. We used here the complex frame components e 2 = e 4 + ie 5 ,ē 2 = e 4 − ie 5 on the torus. The subscripts (m, n) refer to the (anti-)holomorphic indices in four dimensions. In particular j ≡ j (1,1) . The equations of motion reduce to where we denoted ∂ A ,∂ A the four-dimensional (anti)holomorphic differentials covariantized with respect to the U (1) D SO(2) 45 connection A. Explicitly we have which follow from the the frame definition (2.4). 12 The equations of motion can be expressed more compactly using the (anti)self-dual two form F (±) 2 and the one-form D 1 , The equations of motion are then Defining F 2 in terms of F (±) 2 as in (3.18), we obtain The closedness relations dF 2 = 0 and dD 1 = 0 are solved by introducing local potentials 49) and the remaining equations of motion can be integrated to the actions (3.50) We recover the standard Yang-Mills action, up to the fact that τ 1 and τ 2 vary along the base B in the present case. This part of the reduction is actually identical to the reduction on a Calabi-Yau three-fold presented in section 2.3.
Finally the scalars of the twisted theory decompose as The dimensional reduction of the 6d scalar action (3.36) yields The four-dimensional theory has an enlarged R-symmetry SU (2) A ×SU (2) B and we denote doublets of SU (2) A , resp. SU (2) B , with the indices α, β, resp.α,β. The scalar field C can be combined with the three scalars ϕ αβ into the four scalars ϕ αα with the explicit relations The total action is (3.56) The relative coefficients between the terms were fixed by requiring invariance under the supersymmetry transformations inherited from six dimensions, which are given by where q D denotes the U (1) D charge of Φ.
As observed for the theory on the elliptic Calabi-Yau in section 2.3, the action (3.56) is locally invariant under the supersymmetry transformations given above, but not globally.

Rather the variation of the Lagrangian δL
This is important since, as we already explained, the holomorphic function τ has monodromies around (real) codimension two surfaces, implying that τ jumps across three-dimensional walls.
The supersymmetry variation of the action is not vanishing, but instead picks boundary terms for each duality wall W We will discuss how to cure the remaining non-invariance in section 4.

Non-abelian theory
Despite the lack of a Lagrangian formulation, it is believed that non-abelian 6d (2, 0) theories exist, with gauge algebras of ADE type. These non-abelian theories can in principle be defined on a Kähler elliptic fibration with the topological twist that we have described, and reduced to four-dimensions on the elliptic fiber, as we did for the abelian theory. We expect therefore that the four-dimensional twisted theory that we found can be promoted to a non-abelian (interacting) theory, with all fields valued in a Lie algebra g of ADE type. Since the profile of the coupling τ has monodromies/duality walls, the theory only makes sense if for each defect, that is labeled by an SL(2, Z) element γ, that corresponds to the total monodromy, the gauge group in the local patch is self-dual under γ. This is satisfied, for instance, for the where, for Lie algebra valued p-form and q-form ω (p) ,ω (q) , we define with κ = 1 if both forms are Grassmann-odd and κ = 0 otherwise.
The supersymmetry transformations receive non-abelian contributions as follows (3.65) The topological twist relies solely on the symmetries of the theory and can be defined for the non-abelian theories as well. However, since there is no field theoretic description of the non-abelian theory, we do not know how the fields transform under SL(2, Z). In particular it is not known how the gauge field, or the field strength, transforms under SL(2, Z), therefore we are not able to describe the transformations of the fields across the duality walls, with the exception of the T k duality wall, for which the fields are continuous across the wall, as we shall see in section 4.
The supersymmetry transformation of the action produces the non-abelian total derivative term δL (4d)

(3.66)
This term leads to a non-invariance of the action in the presence of 2d surface defects and associated SL(2, Z) duality walls, as in the abelian theory. We will see in the next section how to restore full supersymmetry invariance in the abelian theory. However the discussion will not apply for the non-abelian theory in the presence of SL(2, Z) surface defects, except for the T k duality defect. It is not obvious how to tackle this issue for the non-abelian theory in general and we leave this for future work.

Duality and Point-Defects
So far we have shown how starting with the twisted 6d (2, 0) theory on a Kähler elliptic threefold, we obtain by dimensional reduction on the elliptic fiber, the 4d N = 4 SYM theory with varying coupling τ on the base four-manifold B. The key ingredient in this construction is the topological twist, which as we have seen, is from the 6d point of view a standard topological twist, and descends in the 4d theory to the duality twist [7], which uses the so-called bonus symmetry of [8].
The elliptic fibers can become singular along complex codimension one loci in the base B.
Such singular loci C are characterized in terms of the Weierstrass equation of the fibration, as the discriminant locus ∆ = 0 (see (2.8)) intersecting B. The axio-dilaton, or N = 4 SYM coupling, diverges at these loci. The branch-cuts associated to these singularities, which are 3d duality walls, have no direct physical meaning, however, they ensure continuity equations on the fields of the 4d theory. More precisely, as one crosses these cuts, the fields of the 4d theory undergo an SL(2, Z) duality transformation.
Moreover, the 2d duality defects generically intersect at points in the base, corresponding to singularity enhancement in the fiber of the elliptic three-fold. We will now discuss how this network of 4d-3d-2d bulk, wall and defect systems arises, first in a gauge theoretic description in 4d, and then from the M5-brane point of view. This setup is depicted in figure 2. We finally discuss the point defects and describe the local flavor symmetry enhancements associated to them.

Gauge-theoretic Description of Walls and Defects
First we summarize what is known about the gauge theoretic description of 3d walls and 2d defects in the N = 4 SYM with varying coupling in the abelian theory in [23,34,7].

3d Duality Walls
The 3d walls in the elliptic fibration correspond to the branch-cuts of τ , and should not carry any physical degrees of freedom. These branch-cuts end at the points where τ has a log singularity. The base can be written as B = ∪B i , with W ij a 3d duality wall separating the regions B i and B j . 14 The gluing conditions of the fields across a duality wall are described by their U (1) D transformation (3.59). For the gauge field, the gluing condition can be described in terms of F and F D (instead of F (±) ), where Note that we can write the gauge-part of the 4d action as This agrees with the transformations of F (±) under the U (1) D action (3.59), as expected from our analysis.
The simplest walls are the T k walls, which correspond to the case a = d = 1, c = 0 and b = k ∈ Z and are associated with shifts of τ 1 by k (i.e. shifts of the theta angle by 2πk). The identification of field strengths is resulting in the identification of the two gauge fields along the wall Requiring the bulk equations of motion to hold at the location of the wall requires the presence of an additional Chern-Simons term along the wall More generally, the 3d term canceling the difference between the variations of the two actions on either sides of the wall is easily obtained from (4.2) 15 , (4.6) The relative minus sign is related to the fact that the wall W ij is the boundary of both B i and B j regions, but with opposite orientations. Inserting the expression for F D , for c = 0, this is precisely the expression for the wall obtained in [23] Moreover, a straighforward calculation reveals that the presence of the 3d duality wall term (4.6) is necessary for supersymmetry. Indeed the supersymmetry variation of (4.6) precisely cancels the 3d term on W ij induced by the supersymmetry variation of the bulk action (3.60), with the identification (A (i) , τ (i) ) = (A, τ ), (A (j) , τ (j) ) = (A , τ ), and τ (j) = aτ (i) +b cτ (i) +d . In the presence of a T k wall (c = 0), the supersymmetry invariance is also restored by the addition of the 3d term (4.5).
We can generalize to the non-abelian theory in the presence of a T k wall. To enforce the bulk equations of motion at the location of the wall and restore supersymmetry we must add the non-abelian Chern-Simons term For other duality walls in the non-abelian theory, it is not clear how to restore supersymmetry by adding 3d terms to the action. Indeed, in the supersymmetry variation of the action (3.66), 15 To see it, one can think of F = dA and F D = dA D as independent field strengths.
the commutator terms involve the coupling τ 2 , which jumps across the wall, and the gauge field A, whose transformation across the wall is not understood. Only for the T k -wall, when τ 2 and A are continuous across the wall, do these commutator terms cancel. It is not obvious that the other duality walls in the non-abelian theory can have a Lagrangian description, since they always involve configurations of large gauge coupling (τ 2 < 1).

Surface Defects
The 3d walls end of 2d surface defects, which are curves in B (see figure 2). In the elliptic fibration, these will be the loci above which the fiber becomes singular, i.e. these curves C are components of ∆ ∩ B. As we move around these defects, the theory undergoes an SL(2, Z) monodromy. This means that the fields charged under U (1) D have twisted periodicity conditions around the defect C γ described by the transformation (3.59).
The 3d duality wall term (4.6) is neither gauge invariant nor supersymmetric, when the wall has a boundary. This implies that additional degrees of freedom have to be added to the theory along the surface defect C = ∂W . The 2d surface theory on the boundary of a T k duality wall was studied in [9,7]. In this case the gauge field A is continuous across the wall and well-defined at the position of the surface defect. The defect theory is described by a WZW model at level k, which can be obtained by integrating chiral fermions living on the surface defect [9]. For k > 0, this is equivalent to coupling the theory to k chiral bosons living on the surface defect, namely bosonic fields β i , i = 1, · · · , k, with 2 dβ i = idβ i , with action [35] 16 which can equivalently be written in terms of The surface term S C is not gauge invariant. Under a gauge transformation A → A + dΛ, the chiral bosons transform as β i → β i + Λ and S C transforms as This precisely cancels the gauge transformation of the Chern-Simons term (4.5) defined on the T k duality wall W whose boundary is C. So the total action of the theory is gauge invariant after the addition of the surface action S C .
The 2d theory on a single defect long C has two chiral, topological supercharges, corresponding to a type of half-twist of a (0,8) theory 17 . The supersymmetry variations of the chiral modes is trivial, δβ = 0, and they form Fermi multiplets.

Duality Defects from M5-branes
We will now derive the 2d defect theory from the M5-brane -or 6d (2, 0) theory -point of view, which will require us to be a bit more specific about the geometry of the fibration. We begin by discussing the geometry of the singular fibers in the M-theory setup and its relation to the F-theory setup, through M/F duality. We then identify the chiral modes living on the 2d duality defects as components of the tensor multiplet B field reduced on the curves of the resolved fiber.

M/F-duality and Singular Fibers
Consider M-theory on with base M 3 , given in terms of a Weierstrass model (2.7). The abelian twisted (2, 0) theory, that we defined and studied in this paper, can be described as the low-energy world-volume theory of one M5-brane wrapping a vertical divisor inside X 4 , i.e. the elliptic three-fold Y , which is the world-volume of the M5-brane, is embedded into X 4 by restriction of the elliptic fibration to a surface B 2 ⊂ M 3 . The dual F-theoretic setup is that of a D3-brane (instanton) wrapped on B.
The singularities in the fiber are above a complex codimension one locus in M 3 , given by ∆ = 0, and, intersected with B, give a collection of complex curves in the base. In the F-theory picture this is the intersection of the D3-instanton with the 7-branes that wrap the discriminant locus and the transverse R 1,3 , which is a collection of curves (4.12) Along the curves C n there are localized defect degrees of freedom, which in an F-theory realization correspond to open string modes between the D3-branes and 7-branes. The setup is shown in figure 3. From the M5-brane point of view the 3-7 modes arise from studying the reduction of the self-dual three-form H + 3 along harmonic (1, 1) forms. In an elliptic Calabi-Yau four-fold, the set of (1, 1) forms can either arise from the base M 3 , the elliptic fiber, and rational sections (corresponding to rational points on the elliptic curve). For our considerations, of dimensional reduction of the M5-brane world-volume on the elliptic fiber to a 4d theory with defects, the fibral contributions are of particular interest. For a smooth elliptic fiber, there is one (1, 1) form, which was already discusssed in the bulk reduction to 4d. Above C n ⊂ [∆], however, there are additional (1, 1) forms, which we will now describe. In the next section we use these to define the chiral defect theory localized on the curves C n .
Above the singular loci, the elliptic fibers degenerate, and the so-called singular fibers have been classified by Kodaira [36]. The singularities are best understood by resolution (which retain the Calabi-Yau property of X 4 , so-called crepant resolutions). Above ∆ = 0 the resolved fibers are collections of rational curves P 1 intersecting for instance in affine ADE type Dynkin diagrams, possibly with multiplicities. Each rational curve is associated to a simple root of an affine Lie algebra. Fibering these P 1 s over the dicriminant components, gives divisors in the Calabi-Yau four-fold, which are dual to (1, 1) forms. In this way each fibral curve arising in singular fibers has associated a (1,1) form, with a harmonic representative.
The simplest example is the I k fiber, whose intersection graph is that of affine SU (k). Let F i , i = 0, 1, · · · , k − 1 be the rational curves in the fiber, which intersect as in figure 3. These curves obey the relation where F is the fiber class. Fibering each of these F i over the discriminant locus ∆ gives a complex three-fold, the so-called Cartan divisors D i . These intersect with the curves F i in the negative Cartan matrix −C ij = δ i−1,j − 2δ i,j + δ i+1,j , and are Poincaré dual to (1,1) forms (4.14) We can identify the F i with roots and ω i with the co-roots of the gauge algebra. Furthermore we introduce which is dual to the zero-section Z (the copy of the base in the fiber, which passes through each of the origins of the elliptic curves). These forms are not all independent: the form ω 0 can be expressed as a certain linear combination of ω i , i = 1, · · · , k − 1, and ω Z .
There is an important difference between the reduction of the 11d supergravity modes, including C 3 , and the reduction of the M5-brane world-volume theory. The expansion has also a component of C 3 that is obtained by reducing along ω (1,1) 0 (which is dual to the zero-section) which in 3d (M-theory on the Calabi-Yau four-fold X 4 ) gives rise to a gauge field, that lifts in F-theory to a component of the metric in 4d -for an in depth analysis of the F/M duality effective action see [37]. We only obtain rank(G) many Cartan gauge fields on the 7-brane, for instance k − 1 for I k . However, for the M5-brane theory what is important is the distinct number of cycles in the fiber, and independent (1, 1) forms, which is k for I k fibers.
Finally, it will be important to discuss the self-duality of the (1, 1) forms. For this, consider the local description of the elliptic fibration, which above a component of the discriminant is given in terms of an ALE-fibration [38][39][40], that can be directly constructed from a given elliptic fibration in Weierstrass form [11]: Locally, the Calabi-Yau above a component of the discriminant, S, is given by a Higgs bundle spectral cover, which arises as the BPS equations of 8d SYM on S. This defines an ALE-fibration. The rational curves F i in this case correspond to a basis of H 2 (ALE) curves, and are dual to harmonic representatives of H 2 (ALE). For A-type singularities (that describe the local model for an I k fiber), the local ALE is a kcentered Taub-NUT geometry, which has k harmonic (1, 1)-forms, which are all anti-self-dual 18 [41-43, 5, 44]. Note, as emphasized in [5,45], the k (1,1)-forms are square-integrable, and the holonomy of the associated line bundles is trivial at the boundary of the Taub-NUT space.

3-7 Modes from M5-branes
Our main interest is now the sector of 3-7 strings and resulting 2d defect modes. In the case of a D3-D7-brane intersection, the 3-7 strings give rise at low energies to chiral fermions, which, upon dualization, are mapped to the chiral bosons discussed in section 4.1.2. The supergravity background corresponding to this type IIB brane setup, with the defects supporting chiral fermions, has been studied in [9]. We will now provide a description of the chiral modes from the reduction of the abelian M5-brane theory.
In the last section we have seen that an I k singularity, corresponding to k 7-branes, gives rise to k harmonic (1, 1) forms which are anti-self-dual in the local 4d ALE fiber defined via the spectral data above C The local 6d geometry near a generic point in C is the direct product of a local patch in C times the ALE, which is the k-centered Taub-NUT space. We identify locally the k − 1 (1,1) forms ω i , i = 1, · · · , k − 1, of the elliptic fibration with k − 1 Taub-NUT (1,1) forms Ω i , therefore we have The remaining independent (1,1) form ω 0 , or ω Z , being related to the fiber class, has no self-dual property. We can then expand the (1,1) component of the two-form potential B (1,1) into, where B (1,1) denotes components purely along the base (and not along the fiber). The new (1, 1) forms from the singular fiber give rise to components of H that are (1, 2) or (2, 1) forms From the self-duality of the ω i we obtain the relations The self-duality condition 6 H = iH then implies that i.e. the b i are k − 1 chiral bosons, each associated to a component of B dual to a P 1 in the singular fiber. The modes arising from B by integrating over the various fiber components The modes β i defined in this way, β i = F i B, i = 1, · · · , k − 1, are naturally chiral. This is however not true for the integral over F 0 , as b Z is not chiral. To get a consistent picture with the 4d approach reviewed in section 4.1.2 and with the fact that the local Taub-NUT space has k anti-self-dual (1,1) forms Ω i (1,1) , we need to identify an additional chiral mode from the b Z ω Z component. We can rewrite the decomposition (4.18) with J ± = j ± e 4 ∧ e 5 . Note that J − = J is the Kähler form of the elliptic fibration, and B (1,1) denotes again components along the base. We have the relation Requiring that the component db + Z ∧ J + ⊂ dB is imaginary self-dual, independently of the other components of B, leads to ∂ z b + Z = 0 19 , so that b + Z is a chiral boson. We then define the scalar β 0 by the relation where β 0 is now chiral, satisfying ∂ z β 0 = 0. We thus obtain k chiral modes β 0 , · · · , β k−1 from B. The relation on the fiber classes (4.13) translates into The supersymmetry variations of all the β i is trivial, δβ i = 0, since the supersymmetry transformation of B (1,1) is along J − (3.39).
In the description in terms of chiral fermions coming from open strings stretched between the D3-and 7-branes, the chiral modes transform in bi-fundamentals of the D3 and 7-brane gauge groups, respectively. As we decouple the 7-brane gauge degrees of freedom, this symmetry group becomes an SU (k) flavor group. To see this flavor symmetry, note that the 2d action for the chiral bosons β i along C (4.10) contains the coupling 20 where F is the 4d bulk gauge field evaluated on the defect. All chiral modes couple in the same way to F . Their transformation under the abelian bulk gauge symmetry was described in section 4.1.2: β i → β i + Λ for all i, with Λ the gauge parameter. In addition this 2d action admits a U (1) k−1 abelian flavor symmetry acting by where the Λ i are constants. These must be understood as the Cartan part of the SU (k) global symmetry. The action on the β i of the full SU (k) global symmetry is non-linear and complicated to describe. In order to see it, one must use the description in terms of chiral fermions, which transform in the fundamental representation of SU (k) 21 .
An alternative point of view, which allows understanding all these aspects is to describe the singularity in terms of a k-centered Taub-NUT geometry. In [5] it was analyzed that this indeed gives k self-dual harmonic (1, 1) forms, which were shown to agree with chiral modes.
Finally, let us consider the non-abelian theory, living on a stack of N M5-branes. In the tensor branch, when the M5s are separated, each one of the tensor multiplets gives rise to k chiral bosons, localized on C. As we move to the origin of the tensor branch, we expect this theory to become a non-abelian 2d chiral SCFT.

Point-defects
Two 2d surface defects intersect generically in a point in the base of the elliptic fibration.
Such point-defects have had relatively little attention in the literature. Here we will see, that the geometry dictates precisely how the chiral modes on each of the 2d defects are related, such that the intersection is consistent with an enhanced global symmetry which is induced by the 7-branes. 20 The rest of the chiral bosons action is trivially invariant under the symmetries we describe. 21 The fermionization maps the bosons and fermions as χ i =: e iβi :. The term i β i ∼ log( i χ i ) is then an SU (k) invariant. The anti-commutation of fermions is crucial to show that i χ i is a symmetry invariant.

Fiber Splittings
A complex codimension one singularity in the base is a component of ∆ = 0 given locally by z 1 = 0. In addition there can be codimension two enhancements of the singularities. This is the locus where z 1 = z 2 = 0, which in a three-fold base M 3 is a complex curve. This codimension two locus intersects B 2 ⊂ M 3 in a point. Above this curve, the discriminant of the elliptic fiber vanishes to a higher order than along a generic locus in z 1 = 0 Again, resolving the fiber, gives insight into what type of singularities can happen. This problem has been studied extensively over the last few years [10][11][12][13][14], and the possible codimension two fibers were systematically characterized in [15].
For clarity, we consider the case of a singularity associated to an I k fiber (corresponding to an SU (k) gauge group on the 7-branes), which enhances to an I k+m fiber. Let us again denote by F i , i = 0, · · · , k − 1 the rational curves in the fiber that are one-to-one with the simple roots of SU (k), and F 0 , the affine node. This is the generic fiber above z 1 = 0. As we pass to z 1 = z 2 = 0, the fiber becomes singular. A useful way to think about this is in terms of the intersection of the loci z 1 = 0 and z 2 = 0, above each of which there is a collection of fibral curves F i andF i . At z 1 = z 2 = 0 these 'merge' with relations between these two sets of rational curves.
As the singularity z 1 = z 2 = 0 is codimension two, it is resolved by so-called small resolutions. There is not a unique way to resolve the singularities, but the (relative) Kähler cone of the fiber develops a cone structure, with walls along which rational curves can be floppedthus passing from one resolution to another topologically inequivalent one. This is precisely the structure of the Coulomb branch of the 3d N = 2 gauge theory with matter that one obtains by compactifying M-theory on this Calabi-Yau four-fold, and can be systematically described by box graphs [15]. These provide a succinct way of determining the basis of the relative Kähler cone of the fiber.
We consider the simplest case of m = 1 first and discuss an example for m > 1 in section 4.3.3. Locally, there is an enhancement of SU (k) and U (1) to SU (k + 1), which from the point of view of the SU (k) symmetry, corresponds to adding the fundamental k representation.
Above z 1 = 0 there is a collection of rational fibral curves F (1) i , i = 0, · · · , k − 1 and above z 2 = 0 there is a single curve component F (the I 1 fiber is in fact a nodal curve). Along z 1 = z 2 = 0 one of the curves F i becomes reducible and splits into two curves C ± where C ± are associated to weights of the fundamental representation 22 . The intersection graph of the set of rational fibral curves F (1) j and C ± turns out to be simply the affine Dynkin diagram of SU (k + 1).

Point-interactions of 2d Defects
We can now ask how this splitting of the fibral curves affects the dimensional reduction of the M5-brane on the three-fold Y 3 . For concreteness let z = 0 be the local equation of B, which is wrapped by the M5-brane, inside the base three-fold M . Reducing the self-dual three-form along ω i we have seen that this gives rise to a chiral boson β (α) i along the curve where the surface ∆ α is the component of the discriminant given by z α = 0.
In the above example of an I k singularity colliding with an I 1 , where say F the components of B above P decompose as follows where the chiral fields β ± are obtained from the (1, 1) forms associated 23 to the curves C ± .
This results in a constraint at the points where the two 2d defects along C α and C β intersect, which relates the chiral fields in the two theories with the f i , e j dependent on the specific choice of Kähler cone, or resolution. In the above case we obtain k + 1 chiral bosons, and the basis of effective curves above this point is which from the splitting (4.30) implies the constraints (4.35) 22 If L i are the fundamental weights, then the simple roots are α i = L i − L i+1 , and in this sense F (1) i splits into two rational curves: C + associated to the weight L i and C − associated to the negative weight −L i+1 . 23 We can locally think of the transverse space above the codimension two singularity as an ALE space associated to SU (k + 1), a k + 1 centered Taub-NUT.
Which of these curves F (and also the D-type flavor symmetries that are realized by I * n fibers), is the fiber type, and thus the complete set of rational curves, above the intersection point. This determines the flavor symmetry, which gets enhanced at the intersection point. E.g. in the above case of I k colliding with I 1 , the coupling (4.27) along C 1 where the I k fiber is located, restricts at the intersection point P 12 to (4.37) where F C 1 denote the components of the bulk field strength along the defect C 1 . Similarly, along the second defect C 2 where the I 1 fiber is located, the coupling (4.27) restricts at the intersection point P 12 to (4. 38) We observe that at the point P 12 , the combination j =i β (1) j + β + + β − appears in the action, signaling an SU (k+1) flavor symmetry acting on the β j =i and β ± at the point P 12 , as explained in section 4.2.2.
The point-like defects arising at the intersection of 2d duality defects are thus characterized by the presence of extra localized modes, with continuity relations to the defect fields dictated by the fiber type above these points, and associated to local flavor symmetry enhancements.

An Example
As another example consider the setup of D3s with the intersection of two 7-brane stacks with SU (n) and SU (m) gauge groups, respectively. The local enhancement of the 7-brane gauge symmetry at the intersection locus is SU (n + m). Let F i , i = 0, 1, · · · , n − 1 ,F j , j = 0, 1, · · · , m − 1 . in terms of a Coulomb phase or equivalently box graph (see [46] for the discussion of collisions of two non-abelian singularities). An example is shown in figure 4 for n = 5 and m = 3, where the graph implies the following splitting C : Here, C ± ji corresponds to a curve, which carries the fundamental weight ±L i and ±L j of SU (5) and SU (3) respectively. Also, the non-effective affine nodes split into F 0 = C + 35 =F 0 . From the point of view of the chiral 2d theories we have modes C : Each of these couple to the bulk D3-gauge field as in (4.27), and along each curve there is an enhanced SU (5) and SU (3) flavor symmetry, respectively. At the intersection point P = C ∩C, the splitting of the curves dictates that the coupling (4.27) on C evaluates to where F C is the bulk 4d gauge field along C and the coupling (4.27) onC evaluates to where the β ± ji are the scalars obtained by reducing the B field along the (1,1) forms dual to the cycles C ± ji at the ponit intersection. We obtain that the flavor symmetry is enhanced at the point P to SU (8) acting on the eight scalars β + 35 , β − 31 , β 1 , β + 22 , β − 23 , β 3 , β − 15 , β + 14 . We have focused our attention on defects with SU (k) flavor symmetries. It would of course be interesting to extend this to defects supporting general ADE type flavor symmetries, making use of the known results on elliptic fibrations.

Conclusions and Outlook
The relation between 6d (2, 0) theory or M5-branes on an elliptic curve and 4d N = 4 SYM for fixed coupling constant τ , parametrized by the complex structure of the elliptic curve, makes the SL(2, Z) duality of the 4d theory manifest in the modular action on τ . In this paper we studied what happens as we allow the elliptic curve to be fibered non-trivially over a 4d base manifold -much like the generalization of IIB to F-theory by allowing the axio-dilaton to vary. A concrete setup where this M5-brane configuration can be studied is indeed in the context of M/F-duality, for an elliptic Calabi-Yau four-fold X 4 , which contains an elliptic three-fold, that is wrapped by the M5-brane.
The interesting physics appears along singularities in the fiber, when the complex structure τ diverges, and we defined a suitable topological twist of the 6d theory, which allows for supersymmetry in 4d, including along 3d walls, 2d duality surface defects and 0d point defects.
The resulting 4d theory for an abelian gauge group agrees with the duality twisted 4d SYM theory of [7], including the walls and surface defects determined therein. In the latter case, this theory was obtained from a D3-D7-brane setup, where the 3-7 string sector gives rise to the surface modes. The advantage of the M5-brane approach is that it allows to formulate the theory more generally for non-abelian gauge groups, where the duality U (1) D symmetry is absent.
The 2d duality defects are labeled by elements of SL(2, Z), which determine the monodromy that τ undergoes upon encircling the defect. The consistency of the theory is ensured by 3d walls, along which the fields of the 4d theory are glued according to the duality transformations, which are known only for the abelian theory. We determined the spectrum of the 2d theory starting from the M5-brane, by dimensional reduction on singular fibers, which are a source of additional harmonic (1, 1) forms. The self-duality of the 3-form on the M5-brane world-volume implies that the localized modes are chiral. The 2d theory preserves two supercharges, couples to the 4d gauge field, and enjoys a flavor symmetry. Furthermore the surface defects generically will intersect at points, which result in local enhancements of the flavor symmetry. We determined these properties of the 2d and 0d defects from the singular fibers, in codimension one and two in the base of the elliptic Calabi-Yau four-fold X 4 in which the M5-brane world-volume Y 3 is embedded.
There are various directions in which to extend and generalize our analysis: 1. Defects in non-abelian theories: We provided the non-abelian generalization of the 4d bulk theory in section 3.4, however we studied the walls/defects in 3d, 2d and 0d only in the abelian theory, where the SL(2, Z) action on the fields in known. It would be extremely interesting to understand the 3d walls, 2d duality defects, and point defects in the non-abelian theory. This could provide some more insights into the electro-magnetic duality of the N = 4 SYM theory.

3-7 strings:
The present focus has been on the M5-brane theory point of view. The modes arising at the singular fibers were determined using insights into the geometry of the singular fibers. In a IIB/F-theory dual point of view, these insights should be derivable from studying [p, q] strings between the D3 and 7-branes.

Lefschetz-fibrations:
Another interesting avenue is to consider instead of elliptic curves, a fibration by a higher genus curve. Such Lefschetz-fibrations were mentioned in [21] and it would be interesting to perform a reduction similar to the one in the present paper 24

A Spinor conventions
We need to consider spinors in six dimensions and their reduction to four dimensions. We work in Euclidean signature, however we will present the Lorentzian case as well. We follow the conventions of [49].
We denote Γ A , A = 0, · · · , 5, and γ a , a = 0, · · · , 3, the gamma matrices in six and four dimensions respectively. We use the specific basis with t = 0 in Euclidean signature and t = 1 in Lorentzian signature. σ 1,2,3 are the usual Pauli matrices The chirality matrices in six and four dimensions are of positive/negative chirality obey We provide some useful identities: We define . When we need to use spinor bilinears, we use matrix notations, for instance χ T 1 CΓ A χ 2 and we defineχ Spinors λ m in six dimensions transform in the fundamental representation 4 of Sp(4) R , with m = 1, · · · , 4. We denote Ω mn the invariant anti-symmetric tensor of Sp(4) R . It satisfies the relations with Ω mn ≡ (Ω mn ) * . Indices are raised and lowered as In four dimension the same Ω mn (= Ωṁ n ) plays the role of the SU (4) R invariant tensor, raising and lowering indices, with spinors λ m transforming in the 4 and spinors λṁ in the4 of SU (4) R .

A.1 Irreducible spinors
To enforce reality conditions on spinors one also need to define the matrices The matrix B is also used to define the charge conjugate of a spinor χ: which has the opposite chirality compared to χ.
We also note the relation The last term is the single and only scalar supercharge of the twisted theory. Twist 3: There is a final distinct decomposition of Sp(4) containing U (1), which comes from the special embedding of SU (2) inside Sp(4). The decomposition is It is clear that after this decomposition there are two different twistings, up to symmetry, that will create scalar supercharges. These are After the twist (i) the supercharges will transform as and after the twist (ii) they will transform as 3 −8 ⊕ 3 −2 ⊕ 3 4 ⊕ 3 10 ⊕ 1 −12 ⊕ 1 −6 ⊕ 1 0 ⊕ 1 6 . (B.14) These twists are equivalent to the first two twists above when the remaining SU (2) R symmetry in those theories is further reduced to a U (1) and that U (1) is twisted with.
As there is not an embedding of SU (3) inside Sp(4) we argue that these are all of the possible twistings that can be done without assuming that the SU (3) L Lorentz group component is further reduced.

C Differential Geometry and useful Relations
In this appendix we provide some basic identities in differential geometry and some useful self-duality relations on (m, n) forms in 6d and 4d, involving the Kähler potentials J and j, respectively.

D Topological Twist and Form-Fields
We provide some details on the construction of the topologically twisted 6d theory on a Kähler three-fold Y 3 . It is useful in particular to understand the decomposition of the spinors. To write the spinors in terms of forms on Y 3 , we make use of the existence in the twisted theory of a covariantly constant spinor of positive chirality that we denote η which is covariantized with respect to the non-trivial R-symmetry connection A R in U (1) R .
Here µ is the curved Lorentz index in 6d, while A, B are the flat Lorentz indices. The spinor η has charge q R = 1. We take η to be Grassmann-even (commuting spinor) and we normalize it with η † η = 1. The complex structure J which satisfies J i j = iδ i j , J¯ij = −iδ¯ij, can be built (by raising an index) from the Kähler (1, 1)-form Importantly the spinor η is annihilated by the gamma matrices with holomorphic indices Γ i η = 0, i = 1, 2, 3, while the charge conjugate spinor η c = C −1 η * , which has negative We can also define the holomorphic and anti-holomorphic three-forms: 25 The three-forms Ω,Ω transform under U (1) R with R-charges 2 and −2 respectively, and therefore are globally defined (anti-)holomorphic three-forms only when the U (1) R bundle is trival, namely when Y 3 is Calabi-Yau (since in the twisted theory the U (1) R connection is 25 In our conventions a holomorphic vector X satisfies P A B X B = X A ,P A B X B = 0 and a holomorphic one-form ω (1,0)   To deal with the spinors λ m we split them into two sets of spinors λ α 1 , λ α −1 corresponding to the decomposition 4 → 2 1 ⊕2 −1 of the R-symmetry group (see appendix A.3), and expand each spinor in the twisted theory in the basis of spinors which is appropriate for the identification of the (anti-)holomorphic forms where we have suppressed the (anti-)holomorphic indices (1, 0), (3, 0), · · · . In real indices, with some convenient normalization of the forms, we have with the second equalities obtained by making use of the holomorphicity of the forms.