{'fraction_non_alphanumeric': 0.045144086021505374, 'fraction_numerical': 0.017686021505376345, 'mean_word_length': 4.349838932351588, 'pattern_counts': {'":': 0, '<': 2, '<?xml version=': 0, '>': 8, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 11, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
Duality in twisted N=4 supersymmetric gauge theories in four dimensions

We consider a twisted version of the four-dimensional N=4 supersymmetric Yang-Mills theory with gauge groups SU(2) and SO(3), and bare masses for two of its chiral multiplets, thereby breaking N=4 down to N=2. Using the wall-crossing technique introduced by Moore and Witten within the u-plane approach to twisted topological field theories, we compute the partition function and all the topological correlation functions for the case of simply-connected spin four-manifolds of simple type. By including 't Hooft fluxes, we analyse the properties of the resulting formulae under duality transformations. The partition function transforms in the same way as the one first presented by Vafa and Witten for another twist of the N=4 supersymmetric theory in their strong coupling test of S-duality. Both partition functions coincide on K3. The topological correlation functions turn out to transform covariantly under duality, following a simple pattern which seems to be inherent in a general type of topological quantum field theories.


Introduction
During the last few years we have witnessed an important development of topological quantum field theory in four dimensions. The use, in the context of the Donaldson-Witten theory [1], of exact results on supersymmetric gauge theories [2,3] led to the discovery of an important new set of topological invariants: the Seiberg-Witten invariants [4]. It turned out that the Donaldson invariants for fourmanifolds, among other topological invariants, can be written in terms of these.
The discovery of the Seiberg-Witten invariants triggered the study of new types of topological quantum field theories. For some years now, there has been considerable interest in studying the twisted counterparts of several extended supersymmetric gauge theories, from which many astonishing links between the topology of lowdimensional manifolds and the dynamics of strongly-coupled supersymmetric gauge theories have been unveiled.
Last year, important progress on the formulation of some topological quantum field theories in terms of effective actions associated to supersymmetric gauge theories was achieved by Moore and Witten [5]. They studied the problem of integrating over effective theories (u-plane integration) and introduced the technique of wall crossing to fix some of the unknown quantities which are present in the procedure. In their work they rediscovered known results for manifolds of simple type, and provided a general formulation for general manifolds and for a wide variety of topological quantum field theories related to twisted supersymmetric gauge theories with and without matter multiplets. The aim of this paper is to apply their techniques to compute all the topological correlation functions of a topological quantum field theory based on twisted N = 4 supersymmetric gauge theory with gauge groups SU(2) and SO(3) for the case of simply-connected spin four-manifolds of simple type. N = 4 supersymmetric gauge theories are conformal field theories for which it is believed that the duality symmetry proposed by Montonen and Olive [10] holds exactly. This feature is also believed to be shared by other finite field theories as, for example, the one which originates after introducing equal masses for two of the chiral multiplets of the N = 4 supersymmetric gauge theory, thus breaking the N = 4 supersymmetry down to N = 2. Upon twisting, all these theories have their topological counterparts. Actually, theories with N = 4 supersymmetry lead to three different topological quantum field theories [6][7][8]. It is natural to expect that the topological quantum field theories which result from the twist of a theory having the duality symmetry also possess such a symmetry. This was tested by Vafa and Witten [9] for one of the twisted theories arising from N = 4 supersymmetric gauge theories, for the case of gauge groups of rank 1 and a wide varity of four-manifolds. In their work they used known mathematical results to verify that the partition function of the theory does indeed transform as expected under duality transformations.
In this paper we do not attempt to rediscover the partition function computed by Vafa and Witten using wall-crossing techniques within the u-plane approach.
We will apply these techniques to compute topological correlation functions of a topological theory for which one expects the same type of duality properties as the ones found in the theory considered by Vafa and Witten. The theory is based on another twist of the N = 4 supersymmetric gauge theories, also known as the half-twist, or twist leading to adjoint non-Abelian monopoles [6,8]. Actually, we will be considering a more general theory in which equal masses are introduced for two of the chiral multiplets. The model possesses an important feature, which makes it more attractive than the one considered in [9]: topological correlation functions different from the partition function are non-trivial. Explicit formulae for these correlation functions will teach us how correlators transform under duality in theories for which the duality symmetry holds exactly.
The main goal of this paper is to compute the generating function of all the topological correlation functions of the topological quantum field theory under consideration, for the case of simply-connected spin manifolds of simple type. We find that the partition function possesses, for any value of the mass parameter, the same type of duality transformation properties as the one considered by Vafa and Witten, and that on K3 both actions coincide. Since our analysis is based on wall-crossing techniques and u-plane integration, the partition function, as well as the topological correlation functions, are expressed in terms of the Seiberg-Witten invariants. The duality transformations of the correlation functions turn out to be very natural. As we show below, they are the same as those inherent in a simple Abelian topological model. The paper is organized as follows. In sect. 2 we review the structure of the moduli space of N = 4 supersymmetric gauge theories in four dimensions. In sect.
3 we describe the topological quantum field theory involving adjoint non-Abelian monopoles, which results from one of the twists of the N = 4 supersymmetric gauge theory. In sect. 4 we introduce the u-plane integral and use wall-crossing techniques to derive the contributions from the twisted effective theories at the singularities of the low-energy effective description, and we present the explicit form of the generating function for the topological correlation functions. In sect. 5 we study its transformation properties under duality. In sect. 6 we analyse the massless limit and the N = 2 limit, which leads to Donaldson invariants. In addition, we also show in this section that the partition function coincides on K3 with the one found by Vafa and Witten in [9], and we extend their results by presenting the full generating function of topological correlators for the massive theory. Finally, in sect. 7 we state our conclusions. An appendix deals with a set of useful identities and definitions used in the paper.

The moduli space of N = 4 supersymmetric gauge theories in four dimensions
In this section we review some aspects of the Seiberg-Witten solution for the low-energy effective description of the four-dimensional N = 4 supersymmetric gauge theory. The N = 4 supersymmetry algebra has the automorphism group SU(4) I , under which the gauge bosons are scalars, while the gauginos and the scalar fields are arranged into a pair of spinors λ uα ⊕λ uα transforming in the 4 ⊕4, and a selfconjugate antisymmetric tensor φ uv in the 6. All the above fields take values in the adjoint representation of some compact Lie group G. In this paper we will work with G = SU(2) or SO (3), which are equivalent as long as we stay on IR 4 .
The action takes the following form in N = 1 superspace: is the microscopic complexified ⋆ We follow the same conventions as in [8]. coupling.
The theory is invariant under four independent supersymmetries which transform under SU(4) I , but only one of these is manifest in the N = 1 superspace formulation (2.1). The global symmetry group of N = 4 supersymmetric theories . The fermionic generators of the four supersymmetries are Q u α andQ uα . They transform as (2, 1,4) ⊕ (1, 2, 4) under H.

The mass-deformed theory and the Seiberg-Witten solution
The massless N = 4 supersymmetric theory has zero beta function, and it is believed to be exactly finite and conformally invariant, even non-perturbatively. It is in fact the most promising candidate for the explicit realization of the strongweak coupling duality symmetry conjectured some twenty years ago by Montonen and Olive [10]. This theory has a moduli space of vacua in the Coulomb phase consisting of several equivalent copies which are interchanged by the SU(4) I symmetry. Each of these copies corresponds to one of the scalar fields φ uv developing a non-zero vacuum expectation value. There is a classical singularity at the origin of the moduli space, which is very likely to survive even in the quantum regime.
A more interesting theory is the one which results after deforming the N = 4 supersymmetric theory by giving bare masses, m d 4 xd 2 θTr(Φ 1 Φ 2 ) + h.c. , to two of the chiral multiplets. This mass-deformed theory still retains N = 2 supersymmetry: the massive superfields build up an N = 2 hypermultiplet, while the remaining chiral superfield, together with the vector superfield, build up an N = 2 vector multiplet. The low-energy effective description of this theory was worked out, for the SU(2) gauge group, by Seiberg and Witten in [3]. Their results were subsequently extended to SU(N) by Donagi and Witten in [11], where a link to integrable systems was established. Some quantitative discrepancies between the proposed solution and explicit instanton calculations have been pointed out in [12].
The explicit structure of the effective theory for gauge group SU(2) has been much clarified by Ferrari [13], who has also given a detailed account of the BPS spectrum.
For gauge group SU(2) and for generic values of the mass parameter, the moduli space of physically inequivalent vacua forms a one complex-dimensional compact manifold (the u-plane). This manifold parametrizes a family of elliptic curves, which encodes all the relevant information about the low-energy effective description of the theory. The explicit solution is given by the curve: and ϑ 2 (τ ), ϑ 3 (τ ), ϑ 4 (τ ) are the Jacobi theta functions -see the appendix for more details.
The parameter z in (2.2) is a global gauge-invariant coordinate on the moduli space and it is a modular form of weight 2 under the microscopic duality group.
It differs from the physical order parameter Tr φ 2 by instanton corrections [12], which are not predicted by the Seiberg-Witten solution. The precise relation is given by: Notice that the instanton corrections c n are invisible in the double-scaling limit , under which the mass-deformed theory flows towards the pure gauge theory and z → u = Tr φ 2 . Here Λ 0 is the dynamically generated scale of the N = 2, N f = 0 theory.
The low-energy description breaks down at certain points z i where the elliptic curve degenerates. This happens whenever any two of the roots of the cubic polynomial 3 j=1 X − e j z − (1/4)e 2 j m 2 coincide. These singularities, which from the physical point of view are interpreted as due to BPS-saturated multiplets becoming massless, are located at the points [3]: Following Ferrari [13], we choose q 0 small, m large, with m 4 q 0 ∼ Λ 0 4 . Under these circumstances, at strong (effective) coupling, there are two singularities at z 2 , , which flow to the singularities of the pure gauge theory in the double-scaling limit. At weak (effective) coupling, there is a third singularity, located at z 1 , due to an electrically charged (adjoint) quark becoming massless.
For this choice of parameters, we have the explicit formulas: relating the coordinate z to the modulus k of the associated elliptic curve (2.2).
Here τ is the complexified effective coupling of the low-energy theory, and enters the formalism as the ratio of the two basic periods of the elliptic curve. The first period of the curve is given by the formula: where is the complete elliptic integral of the first kind. The second period can be computed from (2.7) as daD dz = τ da dz . Owing to the cuts and non-trivial monodromies present on the u-plane ⋆ , daD dz is not globally defined, and the actual formulas are somewhat more complicated [13]. In any case, the final expression for the u-plane integral will be invariant under monodromy transformations, so the above naive expression is sufficient for our purposes.
⋆ "z-plane" would be more accurate here, but the former terminology is by now so widespread that we prefer to stick to it.
Around each of the singularities we have the following series expansion: where q j = e 2πiτj is the good local coordinate at each singularity: τ 1 = τ for the semiclassical singularity at z 1 , τ 2 = τ D = − 1 τ for the monopole singularity at z 2 , and τ 3 = τ d = − 1 (τ −1) for the dyon singularity at z 3 .
Using (2.6), one can readily compute: . (2.10) At the singularities, each of the periods has a finite limit when expressed in terms of the appropriate local coordinate: While in N = 2 supersymmetric gauge theories the R-symmetry group is at most U(2) and thus the twist is essentially unique (up to an exchange of left and right), in the N = 4 supersymmetric gauge theory the R-symmetry group is SU(4) and there are three different possibilities, each corresponding to a different non-equivalent embedding of the rotation group into the R-symmetry group [6,8,9].
Two of these possibilities give rise to topological field theories with two independent BRST-like topological symmetries. One of these was considered by Vafa and Witten [9] in order to carry out an explicit test of S-duality on several four-manifolds.
The key point of their calculation was that the partition function of this theory computes, on certain four-manifolds, the Euler characteristic of instanton moduli spaces, making it possible to fix, by comparing with known mathematical results, several unknown modular functions which could not be determined otherwise. The final computation required the introduction of a clever mass perturbation which, while breaking down the N = 4 supersymmetry of the physical theory down to N = 1, still preserves one of the topological symmetries of the theory. This procedure, first introduced by Witten in [14] and commonly referred to as the abstract approach, is restricted to Kähler manifolds with b + 2 > 1. Vafa and Witten conjectured that, in the case of the theory they were considering, the perturbation did not affect the final result for the partition function. Their conjecture has been recently confirmed by a careful analysis in [15]. Recently, Dijkgraaf et al. [16] have shown that, on Kähler four-manifolds with b + 2 > 1, Vafa and Witten's partition function can be explicitly rewritten in terms of the Seiberg-Witten invariants, thereby establishing an interesting link to four-dimensional N = 2 supersymmetric theories, which would be worthwhile to explore in the future.
The second possibility was first addressed by Marcus [7], and his analysis was extended in [8,17]. It describes essentially intersection theory on the moduli space of complexified flat gauge connections. This theory was shown in [8] to be amphicheiral, which in this context means that the twisting with either SU(2) L or SU(2) R leads to the same result.
The remaining possibility leads to the half-twisted theory, a topological theory with only one BRST symmetry [6,8]. This theory is, in essence, the so-called non-Abelian monopole theory [18][19][20][21], the non-Abelian generalization of Witten's monopole theory [4], in the particular case in which the matter fields are in the adjoint representation of the gauge group. This close relation to twisted N = 2 supersymmetric theories is not an accident, since the half-twisted theory is precisely the twisted counterpart of the mass-deformed N = 4 supersymmetric theory. In what follows, we will analyse this theory in great detail.

Adjoint non-Abelian monopoles
The theory we wish to study can be formulated in several different -but equivalent -ways, which we now recall. It can be obtained by twisting the N = 4 supersymmetric theory in a certain fashion first discussed by Yamron [6]. The details are as follows. First break SU(4) I down to SU(2) A ⊗ SU(2) B ⊗ U(1), then replace SU(2) L by its diagonal sum SU(2) ′ L with SU(2) A . After the twisting, the symmetry group of the theory becomes H ′ = SU(2) ′ L ⊗ SU(2) R ⊗ SU(2) B ⊗ U(1), where the last factor is the Abelian ghost number symmetry of the topological theory. Under H ′ , the supercharges split up as where i is an SU(2) B index. The twist gives rise to a scalar supercharge Q, which is a certain linear combination of the original supercharges.
The fields of the N = 4 supersymmetry multiplet transform under H ′ as follows -in the notation of [6]: The superscript stands for the ghost number carried by each of the fields. Notice that the field χ αβ is symmetric in its spinor indices and can therefore be regarded as a self-dual two-form. As explained in [8], the isospin group is not manifest in the field-theory realization we are interested in. Instead, we reorganize the SU(2) B doublets in (3.2) into three pairs of complex-conjugate spinors: λ iα → µ α ,μ α ; with n = 1 16π 2 X Tr (F ∧ F ) = 1 32π 2 X √ gTr ( * F µν F µν ), the instanton number, which is an integer for SU(2) bundles but a half-integer for non-trivial SO (3) bundles on spin four-manifolds. Therefore, as pointed out in [9], one would expect the SU(2) theory to be invariant under τ 0 → τ 0 + 1, while the SO(3) theory should be only invariant under τ 0 → τ 0 + 2 on spin manifolds. Notice that, owing to (3.3), the partition function depends on the microscopic couplings e 0 and θ 0 only through the combination 2πinτ 0 , and in particular this dependence is a priori holomorphic (if we reversed the orientation of the manifold X, the partition function would depend anti-holomorphically on τ 0 ). However there could be manifolds in which, because of some sort of holomorphic anomaly, the partition function would acquire an explicit anomalous dependence onτ 0 . This seems to be the case, for example, for the partition function of the Vafa-Witten twist on CIP 2 [9].
In the twisting procedure, one couples the twisted action (3.3) to arbitrary gravitational backgrounds, so as to deal with its formulation for a wide variety of manifolds. In general, the procedure involves the covariantization of the flat-space action, as well as the addition of curvature terms to render the new action as a Qexact piece plus a topological term as in (3.3). Actually, on curved space one might think of additional topological terms -such as R ∧ R or R ∧ * R, with R the curvature two-form of the manifold -besides the one already present in (3.3). Thus, the action which comes out of the twisting procedure is not unique (even modulo Q-exact terms), since it is always possible to add c-number terms, which vanish on flat space but are nevertheless topological. In a topological field theory in four dimensions, those terms are proportional to the Euler number χ and the signature σ of the manifold X. In order to keep the holomorphicity in τ 0 , the proportionality constants must be functions of τ 0 . At this stage one does not know which particular functions to take, but clearly good transformation properties under duality could be spoiled if one does not make the right choice. It seems therefore that there exists a preferred choice of those terms, which is compatible with duality. This issue was treated in detail in [9], where it was shown that a c-number of the form −iπτ 0 χ/6 was needed in the topological action in order to have a theory with good transformation properties under duality. For the theory considered in this paper, it turns out that the c-number which must be present in the action has the form −iπτ 0 (χ + σ)/2 if 2χ + 3σ = 0 mod 32, and iπ(2χ + 3σ)/8 otherwise. This will be shown in section 4.
The significance of the above field spectrum, as well as the underlying geometric structure of the topological theory, can be most transparently understood within the framework of the Mathai-Quillen formalism [27] (for a review of the Mathai-Quillen formalism in the context of topological field theories, see [22][23][24][25][26]). From this viewpoint, the theory is defined in terms of the monopole equations: Notice that the twisted theory contains several spinor fields. This means that the theory is not well defined on those manifolds that do not admit a spin structure.
As explained in [18,19,28] -see [4] for a related discussion -, one could try to avoid this problem by coupling the spinor fields to a fixed (background) Spin c structure.
We will not follow this path here, and therefore we will take X to be an -otherwise arbitrary -spin four-manifold.
It would be interesting to know whether the mass-deformed theory has an analogue twisted version which is also a topological quantum field theory, but now with massive fields. It turns out that this is indeed the case (it was shown for the N = 2 supersymmetric theory with one hypermultiplet in the fundamental representation in [29,30], and it is straightforward to extend their result to the present situation). As shown in [31], where the map C : Ω 0 (X, adP ) −→ T M is given by: The index of the complex (3.5) gives the virtual dimension of the moduli space.
One can show in this way that, for gauge group SU (2): where χ is the Euler characteristic of the four-manifold X and σ its signature.
Notice that the dimension of the moduli space does not depend on the instanton number of the gauge configuration.
Topological invariants are obtained by considering the vacuum expectation value of arbitrary products of observables, which are operators that are Q-invariant but not Q-exact. As discussed in [8,20], the relevant observables for this theory and gauge group SU(2) or SO (3), are precisely the same as in the Donaldson-Witten theory [1]: The operators W i have positive ghost numbers given by 4−i and satisfy the descent which imply that  [9]. Below we will show that this is indeed the case. Notice that this assertion does not apply to the twist first considered by Marcus, as it actually involves two independent twists, one on each of the SU(2) factors of the holonomy group of the manifold [6][7][8].
The selection rule on the topological invariants that we have just discussed does not apply of course to the massive theory, as the mass terms explicitly break the ghost number symmetry. However, the following is a useful constraint. The can be twisted as well, and provides Lorentz-invariant mass terms for the monopoles M α and their partners µ α and να. These mass terms break up into a Q-exact piece (which can therefore be discarded when computing vevs of Q-invariant operators), and a second piece, m∆L, which is linear in m and does not depend on m -see eqs. (4.39)-(40) in [31]. Here ∆L is a polynomial function in the fields with net ghost number −2.
The partition function of the massive theory can be interpreted as the vev of the operator e m∆L in the massless theory. This vev must be understood as a series expansion in powers of m, Each term in the above expansion has successively lower ghost number −2ℓ. As explained above, the only non-vanishing correlator will be that for which the net ghost number of the operator insertion (−2ℓ for the ℓ-th term) equals the anomaly of the theory, −(3/4)(2χ+3σ). This forces the dependence of the partition function on m to be of the form: where F is a certain function to be determined below.
A simple check to test that (3.13) leads to the correct dependence on the mass is the following. The action (3.3), perturbed by mass terms as above, is invariant under a U(1) chiral transformation -that is, a ghost number transformation -if the field transformations are accompanied by an appropriate rescaling of the mass parameter. However, the partition function, as well as the correlation functions, is not invariant -unless the appropriate selection rule is satisfied -due to a contribution from the measure that is proportional to the chiral anomaly, which is given precisely by (3.7). Thus, these quantities should transform into themselves times a term proportional to the exponential of the chiral anomaly. This is in fact the behaviour of (3.13) under a rescaling of m.

Integrating over the u-plane
The functional-integral (or microscopic) approach to twisted supersymmetric quantum field theories gives great insight into their geometric structure, but it does not allow us to make explicit calculations. Once the relevant set of field configurations (moduli space) on which the functional-integral is supported has been identified, the computation of the partition function or, more generally, of the topological correlation functions, is reduced to a finite-dimensional integration over the quantum fluctuations (zero modes) tangent to the moduli space. For this to produce sensible topological information, it is necessary to give a suitable prescription for the integration, and a convenient compactification of the moduli space is usually needed as well. This requires an extra input of information which, in most of the cases is at the heart of the subtle topological information expected to capture with the invariants themselves.
The strategy to circumvent these problems and extract concrete predictions rests in taking advantage of the crucial fact that, by construction, the generating functional for topological correlation functions in a topological quantum field theory is independent of the metric on the manifold. This implies that, in principle, these correlation functions can be computed in either the ultraviolet (shortdistance) or infrared (long-distance) limits. The naive functional-integral approach focuses on the short-distance regime, while long-distance computations require a precise knowledge of the vacuum structure and low-energy dynamics of the physical theory. incorporate the coupling to gravity -these measure factors were derived in [35] by demanding that they reproduce the gravitational anomalies of the massive fields -, and in contact terms among the observables -the contact term for the twoobservable for the SU(2) theory was derived in [5] and was subsequently extended to more general observables and other gauge groups in [32,34,36].
The total contribution to the generating function thus consists of an integration over the moduli space with the singularities removed -which is non-vanishing for b + 2 (X) = 1 [5] only -plus a discrete sum over the contributions of the twisted effective theories at each of the singularities. The effective theory at a given singularity should contain, together with the appropriate dual photon multiplet, several charged hypermultiplets, which correspond to the states becoming massless at the singularity. The complete effective action for these massless states contains as well certain measure factors and contact terms among the observables, which reproduce the effect of the massive states which have been integrated out. However, it is not possible to fix these a priori unknown functions by anomaly considerations only.
As first proposed in [5] -see [32,33,36] for more details and further extensions -, the alternative strategy takes advantage of the wall-crossing properties of the u-plane integral. It was shown in [5] that at those points on the u-plane where the (imaginary part of the) effective coupling diverges, the integral has a discontinuous variation when the self-dual two-form ω, which gives a basis for H 2,+ (X), is such that, for a given gauge configuration λ ∈ H 2 (X; Z Z), the period ω · λ changes sign. This is commonly referred to as "wall crossing". The points where wall crossing can take place are the singularities of the moduli space due to charged matter multiplets becoming massless -the appropriate local effective coupling τ diverges there -and, in the case of the asymptotically free theories, the point at infinity, u → ∞, where also the effective electric coupling diverges owing to asymptotic freedom.
On the other hand, the final expression for the invariants can exhibit a wallcrossing behaviour at most at u → ∞, so the contribution to wall crossing from the integral at the singularities at finite values of u must cancel against the contributions coming from the effective theories there, which also display wall-crossing discontinuities. As shown in [5], this cancellation fixes almost completely the unknown functions in the contributions to the topological correlation functions from the singularities.

The integral for N = 4 supersymmetry
The complete expression for the u-plane integral for the gauge group SU (2) and N f ≤ 4 was worked out in [5]. The appropriate general formulas for the contact terms can be found in [32,34,36]. These formulas follow the conventions in [3], according to which, for N f = 0, the u-plane is the modular curve of Γ 0 (4). In this formalism, the monodromy associated to a single matter multiplet becoming massless is conjugated to T . As for the N = 4 supersymmetric theory, it is more convenient to use instead a formalism related to Γ(2), in which the basic monodromies are conjugated to T 2 . Our formulas follow straightforwardly from those in [5,32,36], with some minor changes to conform to our conventions. The integral in the N = 4 supersymmetric case, for gauge groups SU(2) or SO(3) and on simply-connected four-manifolds, is given by the formula:  Here, S is a two-cycle on X given by the formal sum S = a α a S a , where {S a } a=1,...,b2(X) are two-cycles representing a basis of H 2 (X), and S 2 ≡ a,b α a α b ♯(S a ∩ S b ), where ♯(S a ∩ S b ) is the intersection number of S a and S b . Notice that since we are restricting ourselves to simply-connected four-manifolds, there is no non-trivial contribution from the one-and three-observables W 1 and W 3 in (3.10). The generalization to the non-simply-connected case was outlined in [5], and it has been recently put on a more rigorous basis in [33].
The measure factor µ(τ ) is given by the expression: where ∆ is the square root of the discriminant of the Seiberg-Witten curve (2.2): where η(τ ) is the Dedekind function and f (m, χ, σ, τ 0 ) is a universal normalization factor which cannot be fixed a priori. It can be fixed in the N f = 0 case by comparing with known results for the Donaldson invariants [5], but a first-principle derivation from the microscopic theory in the general case is still lacking -see however [35], where some steps in this direction have already been taken.
In eq. (4.1)T (z) is the monodromy-invariant combination: where the contact term T (z) is given by the general formula [32,36]: Here F is the prepotential governing the low-energy dynamics of the theory.
For the asymptotically free theories, τ 0 is defined in terms of the dynamically generated scale Λ N f of the theory by [36]: -see also [37] for further details and extensions: where E 2 and E 4 are the Eisenstein functions of weight 2 and 4, respectively -see the appendix for further details.
Under a monodromy transformation acting on τ (holding τ 0 fixed), τ → (aτ + b)/(cτ + d), the contact term (4.6) transforms into itself plus a shift: Under a microscopic duality transformation τ 0 → (aτ 0 + b)/(cτ 0 + d), the situation is slightly more involved. As these duality transformations interchange the singularities, they induce a non-trivial monodromy transformation τ → (âτ +b)/(ĉτ +d) on the effective low-energy theory [13]. Under these combined duality transformations one has, for example, z → (cτ 0 + d) 2 z, 2 cτ +d (dz/da), so that [37]: The factor Ψ in (4.1) is essentially the photon partition function, but it contains, apart from the sum over the Abelian line bundles of the effective low-energy theory, certain additional terms which carry information about the 2-observable insertions. In the electric frame it takes the form: where the lattice Γ is H 2 (X, Z Z) shifted by a half-integral class 1 2 ξ = 1 2 w 2 (E) representing a 't Hooft flux for the SO(3) theory, that is, λ ∈ H 2 (X, Z Z) + 1 2 w 2 (E). As explained in detail in [35], this shift takes into account the fact that in the SO (3) theory, while the rank-3 SO(3) bundle E (which at a generic vacuum is broken O being a trivial bundle) is always globally defined -and therefore L 2 is represented by an integral class c 1 (L 2 ) = 2λ ∈ 2H 2 (X, Z Z)+w 2 (E) -, it is not necessarily true that the corresponding SU(2) bundle F (which we can somewhat loosely represent at low energies by F = L⊕L −1 ) exists, the obstruction being precisely w 2 (E): the line bundle L is represented by a class c 1 (L) = λ ∈ H 2 (X, Z Z) + 1 2 w 2 (E), which is not integral unless w 2 (E) = 0 (mod 2). If w 2 (E) = 0 mod 2, the SO(3) bundle can be lifted to an SU(2) bundle and one has F ⊗ F = E ⊕ O, where now F is a globally defined rank-2 SU(2) bundle.
From the above formulas it can be readily checked, along the lines explained in detail in [32,36], that the integral (4.1) is well defined and, in particular, is invariant under the monodromy group of the low-energy theory (for example, this can be seen almost immediately for the semiclassical monodromy, which at large z ≃ u takes z → e 2πi z and a → −a, a D → −a D , while leaving τ ≃ τ 0 unchanged.

Wall crossing at the singular points
At each of the three singularities, the corresponding local effective coupling diverges: y j = Im τ j → +∞, q j → 0. The first step to analyse the behaviour of the integral around the singular points is to make a duality transformation (in τ ) to rewrite the integrand in terms of the appropriate variables: τ → −1/τ near the monopole point, etc. Due to the divergence of Im τ j , one finds a discontinuity in Z u when λ · ω changes sign. We begin by considering the behaviour near the semiclassical singularity at z 1 . As the BPS state responsible for the singularity is electrically charged, it is not necessary to perform a duality transformation in this case: the theory is weakly coupled in terms of the original effective coupling τ . Let us consider the integral (4.1). Fix λ and define ℓ(q) as follows:  The integration over x ≡ Re τ imposes n = λ 2 ; the remaining y integral can be easily evaluated with the result: (we have set y min = 0, as the discontinuity comes from the y → ∞ part of the integral). The result of the integral (4.12) is discontinuous as λ + = ω · λ → 0: Therefore, the wall-crossing discontinuity of Z u at z 1 is: (4.14) We have now to evaluate the wall-crossing discontinuities at the other two singularities. At the monopole point (z = z 2 ), we have to perform a duality transformation to express the integral in terms of τ D = −1/τ , which is the appropriate variable there. This duality transformation involves a Poisson resummation in (4.9), which exchanges the electric class λ ∈ H 2 (X; Z Z) + 1 2 w 2 (E) with the magnetic class λ * ∈ H 2 (X; Z Z) ⋆ , and inverts the coupling constant τ . The details are not terribly important, so we just give the final result for the integral: ⋆ Notice that, as the manifold X is spin, the magnetic class is an integral class, not a Spin c structure as in [4].
where noŵ The functions ∆ and z are exactly the same as before, but expressed in terms of τ D . The crucial point here is that the modular weight of the lattice sum cancels against that of the measure.
From (4.15) we can easily derive the wall-crossing discontinuity at z 2 along the lines explained above -see eqs. (4.10)-(4.14). The final result differs from (4.14) in several extra numerical factors: (4.17) The corresponding expression at the dyon point z 3 , is exactly the same as

Contributions from the singularities
At each of the singularities, the complete effective theory contains a dual Abelian vector multiplet † (weakly) coupled to a massless charged hypermultiplet representing the BPS configuration responsible for the singularity. This effective theory can be twisted in the standard way, and the resulting topological theory is the celebrated Witten's Abelian monopole theory. Its moduli space is defined † This is so for the monopole and dyon singularities; at the semiclassical singularity, the distinguished vector multiplet is the original electric one. whereφ is the (twisted) scalar field in the Abelian N = 2 vector multiplet. For a four-manifold X with b + 2 > 1, the u-plane integral vanishes and the only contributions to the topological correlation functions come from the effective theories at the singularities. Those manifolds with b + 2 > 1 for which the only non-trivial contributions come from the zero-dimensional Abelian monopole moduli spaces are called of simple type. No four-manifold with b + 2 > 1 is known which is not of simple type. We will restrict ourselves to manifolds of simple type. The generalization to positive-dimensional monopole moduli spaces should be straightforward from the explicit formulas in [5] and our own results.
The general form of the contribution to the generating function e pO+I(S) ξ from the twisted Abelian monopole theory at a given singularity was presented in [5]. It contains certain effective gravitational couplings as well as contact terms among the observables. We just adapt here eq. (7.12) of [5]: functions, which can be determined by wall crossing as follows [5]. For b + 2 = 1 and fixedλ j , (4.20) exhibits a wall-crossing behaviour when ω ·λ j changes sign.
At such points, the only discontinuity comes from SW n (λ), which jumps by ±1.
Therefore, the discontinuity in (4.20) is: (We have set χ + σ = 4, which is equivalent to b + 2 = 1 for b 0 (X) = 1, b 1 (X) = 0.) The crucial point now is that the complete expression for the generating function cannot have wall-crossing discontinuities at finite values of z. This is not difficult to understand if one realizes that nothing physically (or mathematically) special occurs at the singular points: when expressed in terms of the appropriate variables, and once all the relevant degrees of freedom are taken into account, the low-energy effective description is perfectly smooth there. The conclusion is therefore that the discontinuity in the u-plane integral has to cancel against the discontinuity in the contribution from the effective theory at the singularity. As shown in [5], this suffices to fix the unknown functions C j , P j , L j in (4.20).  (4.22) which are even classes since the manifold X is spin ⋆ . Notice that, because of (4.22), not all the basic classes of X will contribute to the computation at z 1 . Rather, only those basic classes x satisfying with x 2 the mod 2 reduction of x 2 , can give a non-zero contribution.
Taking this into account, we can rewrite (4.21) at z 1 as follows: near z = z 1 , a 1 = a − a(z 1 ) = a 0 q 1/2 + · · ·. By comparing (4.24) with the wallcrossing formula for the integral at z 1 , (4.14), we can determine the unknown ⋆ If the manifold is not spin, the basic classes are shifted from being even classes by the second Stieffel-Whitney class of the manifold, w 2 (X) [4].
functions in (4.20). We find, for example, (4.25) Putting everything together, the final form for the contribution to the generating function at z 1 is given by the following formula: (4.26) We can now specialize to the simple-type case, for which 4λ 2 = (2χ + 3σ)/4.
We use the following series expansions around z 1 : (4.27) The final formula is the following: e pO+I(S) x,z1,ξ where ν = (χ + σ)/4. The delta function δ [ x 2 ],ξ in (4.28) enforces the constraint (4.23), and T (z 1 ) is given by: The corresponding expressions at the monopole and dyon singularities can be determined along the same lines. One has to take into account the relative factors in each case, and the fact that, at these singularities, the basic classes are given by where λ * is the appropriate dual class. One finds in this way, for the monopole singularity at z 2 , the following expression: e pO+I(S) x,z2,ξ while for the dyon singularity at z 3 one finds: where T (z 2 ) and T (z 3 ) are given by expressions analogous to (4.29): (4.32)

The formula for the generating function
The complete formula for the generating function of the half-twisted theory on simply-connected spin four-manifolds of simple type is given by the combination of (4.28), (4.30) and (4.31), summed over the basic classes (we do not sum over 't Hooft fluxes, though). The contribution from the u-plane integral is absent, since it vanishes for manifolds with b + 2 > 1. As for the as yet unknown function f (m, χ, σ, τ 0 ), it is not possible to determine it completely in the context of the u-plane approach. However, we will propose an ansatz for this function, which is motivated by a series of natural conditions that it has to satisfy. We will discuss later how modifications of the proposed form for f (m, χ, σ, τ 0 ) violate those conditions. As we will show, our ansatz leads to the right mass dependence according to our previous arguments, which led to (3.13), and makes the partition function display two properties of the partition function of the twisted N = 4 supersymmetric theory considered by Vafa and Witten [9]: it is a modular form of weight −χ/2 and contains the Donaldson invariants in the form shown in [16]. In addition, its final expression reduces to the Vafa-Witten partition function on K3.
Our ansatz for f (m, χ, σ, τ 0 ), which turns out to satisfy the properties stated above, is: Taking (4.28), (4.30) and (4.31), the formula that one obtains for the generating function of all the topological correlation functions for simply-connected spin manifolds is the following: where the sum x is over all the Seiberg-Witten basic classes. This formula can be written in terms of modular forms by substituting the explicit expressions (2.10) for κ j and (2.11) for the periods. Notice that there is no need to resolve the square roots in (2.11). Indeed, the periods in (4.34) are raised to the power −(ν + σ/4).
one can take advantage of the following property of the Seiberg-Witten invariants n x -see [4] for a quick proof: Upon summing over x and −x using (4.35), the factors e i 2 (dz/da)jx·S average to a cosine when ν is even, and to a sine when ν is odd. Therefore, no odd powers of (dz/da) j appear in (4.34). Note that as x is an even class on spin manifolds, ξ · x/2 is always an integer, and therefore the phase (−1) ξ· x 2 does not spoil the argument. Likewise, if x + 2ξ = 0 mod 4, it is also true that −x + 2ξ = 0 mod 4 (x is an even class), so if a given basic class x contributes to the first term in (4.34), so does −x.
We will now work out a more explicit formula for the partition function (setting p = 0 and S = 0 in (4.34)). Notice that, since the partition function does not care about whether the manifold is simply-connected or not, at least in the simpletype case (in any case, we are not computing correlation functions of observables), we can easily extend our result to the non simply-connected case. As in [9] this extension involves the introduction of a factor 2 −b1 in two of the three contributions.
Notice also that, because of (4.35), the partition function is zero when ν is odd, since n x +n −x = n x (1+(−1) ν ). Therefore, in the following formula for the partition function we assume that ν is even. Upon substituting eqs. (2.10) and (2.11) in (4.34), and taking into account the identities (A10), the partition function for a fixed 't Hooft flux ξ is given by: (4.36) The partition function for gauge groups SU(2) and SO(3) is easily obtained from this expression. One finds: (4.37) The constraint x = 4y in the first term in (4.37) means that one has to consider only those basic classes x ∈ 4H 2 (X; Z Z). Notice that this constraint implies that the corresponding contribution vanishes unless x 2 = 2χ + 3σ = 8ν + σ = 16y 2 = 0 mod 32. But since ν is even, this requires σ = 0 mod 16. Therefore, when σ ∈ 16Z Z, the first singularity contributes to the SU(2) partition function, and the leading behaviour of the partition function is: As in [9], the leading contribution could be interpreted as the contribution of the trivial connection, shifted from (q 0 ) 0 to q 0 −ν by the c-number we referred to in sect. 3. But notice that the next power in the series expansion is q 0 −ν+1 . The gap between the trivial connection contribution and the first non-trivial instanton contribution which was noted in [9] for the Vafa-Witten partition function is not present here: all instanton configurations contribute to Z SU (2) .
On the other hand, when σ = 8(2k + 1), k ∈ Z Z, the first singularity does not contribute to the partition function and the leading behaviour comes from the strong coupling singularities. Then Z 0 has an expansion: again with no gap between the contribution of the trivial connection (shifted from (q 0 ) 0 by the c-number q 0 2χ+3σ 16 ) and higher-order instanton contributions.

Duality transformations of the generating function
In this section we will study the properties under duality transformations of the generating function (4.34). We will start by checking the modular properties of Z ξ (τ 0 ) as given in (4.36). As explained in [9], one should expect the following behaviour under the modular group. Under a T transformation, taking τ 0 → τ 0 + 1, the partition function for fixed ξ must transform into itself with a possible anomalous ξ-dependent phase. Indeed, (4.36) behaves under T in the expected fashion: Checking (5.1) involves some tricky steps that we now explain. Let us rewrite (4.36) as: (ϑ 2 ϑ 3 /2) (2χ+3σ)/2 , and so on.
Likewise, under an S transformation, taking τ 0 → −1/τ 0 , one should expect the following behaviour: It turns out that the partition function (4.36) indeed satisfies (5.7). In fact, In order to check (5.8), one has to use the modular properties of the different functions in (4.36), which are compiled in the appendix, and handle with care the summation over fluxes in (5.8). The following identities are useful: To prove these identities, we borrow from eq. (5.40) of [9] the following formulas: (5.10) In addition to this, we have to take into account that, since the manifold is spin, haviour under an S transformation: This model contains an Abelian gauge field A, whose field strength is defined as F = dA, two neutral scalar fields φ, λ, a Grassmann-odd neutral one-form ψ and a Grassmann-odd neutral two-form χ. The Lagrangian is simply the topological plus conventional kinetic terms for the rest of the fields: where To deal with the other fields, we augment the quintet {F, ψ, φ, λ, χ} with a dual Abelian field strength F D , a dual neutral Grassmann-odd one-form ψ D , dual neutral scalars φ D , λ D , a dual neutral Grassmann-odd two-form χ D , bosonic four-form multipliers b,b, a Grassmann-odd three-form multiplier ρ and a Grassmann-odd two-form multiplier ω, and consider the extended Lagrangian: By integrating out the dual fields F D , φ D , ψ D , χ D and λ D , and the multipliers b, b, ρ, ω, it is straightforward to verify that the generating functional: where now the integration over F is unrestricted, represents the same theory as (5.20). The dual formulation can be achieved by integrating out instead the original fields F , φ, λ, χ and ψ, together with the multipliers b,b, ρ and ω. One obtains in this way the dual Lagrangian: which, as promised, faithfully reproduces the modular properties (5.13) of the corresponding topological correlation functions of the full, non-Abelian theory.

More properties of the generating function
In this section we will analyse more properties of the generating function (4.34).
First, we will study its behaviour in the massless limit m → 0, then we will show that the Donaldson invariants are contained in the partition function by studying the N = 2 limit (m → ∞) and, finally, we will show that on K3 it reduces to the one obtained by Vafa and Witten for another twist of the N = 4 supersymmetric theory.

Massless limit
We wish to analyse the behaviour of (4.34) and (4.36) in the limit m → 0. We would like to point out that there is no reason why this limit should make sense at all. In the massless limit, the three singularities of the low-energy description of the physical N = 4 theory collapse to a unique singularity at u = 0. This new singularity is a super-conformal point, whose contribution to the topological generating function is not straightforward to analyse -see [32] for a related analysis -and need not be given by the naive limit of the contributions of the three singularities of the mass-deformed theory. What we find is that this limit is meaningful provided that 2χ + 3σ ≥ 0, but the corresponding expressions are non-trivial only when 2χ + 3σ = 0. When 2χ + 3σ < 0, however, the partition function diverges as m −3|2χ+3σ|/8 , but it is still possible to extract finite predictions for certain correlation functions. It would be interesting to compare these results with explicit computations from the twisted super-conformal N = 4 theory at u = 0. Therefore, there are three different possible behaviours to be considered, depending on whether 2χ + 3σ is positive, negative or zero. If 2χ + 3σ is positive, both the generating function and the partition function vanish in the massless limit. This can be understood as follows: the twisted (massless) theory has the anomaly −3(2χ+3σ)/4, which is strictly negative if 2χ+3σ > 0; as the observables all have positive ghost number, there is no way to soak up the unbalanced fermion zero modes (whose net number is given by minus the anomaly) in the functional measure, and therefore the generating function -and the partition function -vanishes. If, on the other hand, 2χ + 3σ is negative, the situation is the following.
Consider a certain correlation function O (1) · · · O (r) . The observable insertions in (4.34) all carry an explicit mass dependence dictated by their ghost number, in such a way that: with g n the ghost number of the observable O (n) . If 3(2χ+3σ)/8+ r n=1 g n /2 < 0, the corresponding correlation function diverges in the massless limit. If, on the other hand, 3(2χ + 3σ)/8 + r n=1 g n /2 > 0, the correlation function vanishes as m → 0. Finally, if 3(2χ + 3σ)/8 + r n=1 g n /2 = 0, which is just the anomalymatching condition for the massless theory, the correlator is perfectly finite anda priori -non-trivial in the massless limit.
So as to complete the discussion, we have to study the case in which 2χ+3σ = 0.
In this situation the partition function is independent of m (and therefore nonvanishing in the m → 0 limit), but all the correlation functions vanish in this limit. This is consistent with the anomaly-matching condition, since when 2χ + 3σ = 0 the massless theory is anomaly-free and therefore any correlation function involving observables with non-zero ghost number must vanish.

The N = 2 limit and the Donaldson-Witten invariants
We would like to analyse the fate of our formulas for the generating function under the decoupling limit m → ∞, q 0 → 0, holding Λ 0 , the scale of the N f = 0 theory, fixed: 4m 4 q 0 = Λ 0 4 . In this limit, the singularities at strong coupling evolve to the singularities of the N f = 0 SU(2) theory, while the semiclassical singularity goes to infinity and disappears. While this limit is perfectly well-defined for the Seiberg-Witten curve, it is not clear whether the corresponding explicit expressions for the prepotentials and the periods should remain non-singular as well. In fact, one would be tempted to think that this is not the case, since this naive decoupling limit is highly singular as far as quantities such as the effective action are concerned. The question therefore arises as to whether taking this naive limit in the twisted theory could give a non-singular result, that is whether, starting from (4.34) or (4.36), one could recover the corresponding expressions for the twisted (pure) SU(2) N = 2 supersymmetric theory. This limit has been studied by Dijkgraaf et al. [16] for the Vafa-Witten partition function, and they were able to single out a piece which corresponds to the partition function of the twisted N = 2 supersymmetric theory as first computed by Witten [4]. We will go a step further and recover, in the same limit, the full generating function for the Donaldson-Witten invariants.
We will focus on the generating function (4.34). We will keep the leading terms in the series expansion of the different modular functions in powers of q 0 . We will use the explicit formulas: G(q 0 2 ) = 1/q 0 2 + · · · , −ν e pm 2 /3 . . . , (6.6) the contributions from the strong coupling singularities give the following result:

Partition function on K3
We now specialize to K3. This is a compact hyper-Kähler manifold, and as such one would expect [14] the physical and the twisted theories to coincide. Therefore, our formulas are to be considered as true predictions for the partition function and a selected set of correlation functions of the physical N = 4 SO(3) gauge theory on K3.
Only the zero class x = 0 contributes on K3, and n x=0 = 1. Moreover, χ = 24 and σ = −16, so ν = 2 and 2χ + 3σ = 0. Notice that because of the latter identity, the mass parameter drops out from the formula on K3, a nice check. The answer for K3 is therefore: which happily coincides with the formula given by Vafa and Witten [9]. We can go even further and present the full generating function on K3:  (6.10) The corresponding expression for SO(3) bundles is given by the sum of (6.9) over all 't Hooft fluxes. As explained in [9], the allowed 't Hooft fluxes on K3 can be grouped into different diffeomorphism classes, which are classified by the value of ξ 2 modulo 4 (K3 is spin, so ξ 2 is always even). There are three different possibilities and, correspondingly, three different generating functions to be computed: ξ = 0, with multiplicity n 0 = 1, gives just the SU(2) partition function; ξ = 0, ξ 2 ∈ 4Z Z, with multiplicity n even = (2 22 + 2 11 )/2 − 1; and ξ 2 = 2 mod 4, with multiplicity and (5.13). In particular, the S transformation exchanges the SU(2) and SO (3) generating functions according to (5.11) and (5.13).

Conclusions and final remarks
In this paper we have computed the generating function of all the topological correlation functions of one of the twisted N = 4 supersymmetric theories, perturbed by a mass term, for simply-connected four-manifolds of simple type. The result provides, for the first time, a framework to analyse duality transformations of correlation functions in a theory in which the duality symmetry holds exactly.
The transformation properties of the topological correlation functions which have been obtained turn out to be very simple. Actually, these transformation seem to belong to a general class of duality transformations. They are the same as those of a simple Abelian topological model, in which the duality transformation can be carried out explicitly by performing standard manipulations in its functional integral formulation.
In obtaining the final expressions for the generating function, we made the ansatz (4.33) for the unknown function f (m, χ, σ, τ 0 ) in the measure (4.3). This ansatz is consistent with some natural properties, which one expects for the generating function. However, other choices are possible. We assumed that the partition function should transform under duality as a modular form with weight −χ/2, as is the case for the theory considered by Vafa and Witten. A different hypothesis would have led to a different exponent for η(τ 0 ) in (4.33). For the mass dependence on (4.33), we can be confident that it is correct, as it is the only possibility which leads to the structure dictated by the anomaly. Finally, the numerical factor could also be modified and still obtain the same results for K3 (as long as it remains the same when 2χ + 3σ = 0), and an equivalent behaviour in the N = 2 limit. Thus, in the main result (4.34), a global factor involving a modular form g(τ 0 , χ, σ) such that g(τ 0 , χ, −2χ/3) = 1, could be missing. We believe, however, that our ansatz is correct but, certainly, it would be reassuring to have an independent argument to fix global factors in the u-plane approach, which could justify our choice.
We have restricted our analysis to the case of simply-connected manifolds of simple type. The generalization of (4.34) to the non-simple type case can be easily done within the framework of the u-plane approach, by using the general formula (4.20). It would be very interesting to find out if the modular properties found in the simple-type case hold in general or, conversely, if they do not hold, which implications can be inferred for the higher-order Seiberg-Witten invariants.
Our work shows, following [5,32,33,36], how wall-crossing techniques within the u-plane approach can be implemented to obtain explicit expressions for topological quantities. It would be very interesting to study if the same methods can be applied to the twist considered by Vafa and Witten to reobtain their results, and to extend them to more general types of manifolds. Another important issue that should be considered is the extension of our results, as well as those obtained by Vafa and Witten, to the case of SU(N) for arbitrary N. We expect to address some of these issues in future work.

APPENDIX
Here we collect some useful formulas which should help the reader follow the computations in the paper. A more detailed account can be found in appendices A and B of [5]. A very useful review containing definitions and properties of many modular forms can be found in appendices A and F of [41].