Self-dual Maxwell equations, the second homology group, and topological invariants of a four manifold In Witten's paper Quantum Field Theory and the Jones Polynomial, he mentioned that:

Geometers have long known that (via de Rham theory) the self-dual and anti-self-dual Maxwell equations are related to natural topological invariants of a four manifold, namely the second homology group and its intersection form. 

Q: can someone illuminate this more explicitly?
I suppose that self-dual and anti-self-dual Maxwell equations is source-free vacuum Equation of motions of $U(1)$ E&M in 3+1 dimensional spacetime. How do the topological invariants of a four manifold, namely the second homology group and its intersection form come into the story? How does de Rham theory help to understand this? 
Thanks for any comment or answer!
 A: I'm not an expert in algebraic topology by the stretch of anyones imagination, but hopefully I can shed some light on this.
The starting point is, as you mention, the Maxwell equations themselves. Cast into a geometric language the curvature 2-form $\bf{F}$, which you can think of as the Faraday tensor for $U(1)$-Maxwell theory (there are generalisations for Yang-Mills theory), can be written $\mathbf{F}$ $= E \wedge d \sigma + B$ and we have the equations:
$d \bf{F} = 0$ $\,\,\,\,\,\, ; \,\,\,\,\,\,$ $d^{\star} \bf{F} = \bf{J}$
The 'self-dual' here is referring to Hodge duality apearing in the above, since in vacuum we have an obvious symmetry here. A good physical description can be found here (Hodge star operator on curvature?).
So, we have a space-time manifold $\mathcal{M}$ that has a curvature 2-form satisfying some properties (Maxwell equations). What can this tell us about the topological structure on $\mathcal{M}$? 
The theory of de-Rham cohomology is essentially the study of differential forms on manifolds. The idea is that by analysing the way in which $p$-forms behave one can deduce some global structure properties. This makes physical sense to me, since if certain classes of functions are behaving in very specific ways it must say something regarding the curvature of the manifold, right? Herein the link lies and why things can be said regarding the $\it{second}$ homology group, since $\bf{F}$ is a 2-form.
A little more mathematical:
If a $k$-form $\omega$ satisfies $d \omega = 0$ it is called closed. If one can write $\omega = d \lambda$ for some $(k-1)$-form $\lambda$, $\omega$ is called exact. Cohomology is the study of whether or not these two notions are interchangeable. The idea is analogous to gauge potentials for Maxwell's equations in $\mathbb{R}^{4}$ wherein we have the identity $\nabla \times (\nabla A) = 0$ for any function $A$, which we of course know as the vector potential associated with $\bf{F}$. 
Consider the space of closed $k$-forms:
$Z^{k}(\mathcal{M}) = \{ \omega \in C^{k}(\mathcal{M}) : d \omega = 0 \}$
So if $\omega$ is closed then so is $\omega + d \tau$. So, we have a very natural equivalence relation on $Z^{k}: \omega \sim \omega'$ iff their difference is exact. The $k$-th de-Rham cohomology $H^{k}(\mathcal{M})$ is defined as a quotient of $Z^{k}$  by the space of exact forms:
$B^{k}(\mathcal{M}) = \{d \lambda : \lambda \in C^{k-1}(\mathcal{M}) \}$
as $H^{k}(\mathcal{M}) = Z^{k}(\mathcal{M}) /B^{k} (\mathcal{M})$
The dimensions of $H^{k}$ are called the Betti numbers $b_{k} = \dim H^{k}(\mathcal{M})$. Which are a topological invariant of the space. The Euler characteristic is defined in terms of them also: $\chi = \sum (-1)^{k} b_{k}$, which is an important curvature invariant. On Manifolds it tells you whether your space is compact if it vanishes, for example, and relates to the hodge dual contracted Riemann tensor.
Edit (Some more): In essence, this means we have a specific way to test the homological structures since, by definition of the Maxwell equations, we have $\bf{F}$ $\in Z^{2}(\mathcal{M})$.
As a last note, the Hodge dual gives a canonical way to associate (using Poincaré duality) $H^{k}(\mathcal{M})$ with its dual space. So the Maxwell equations really give some deep insight into both (co)-homological groups in vacuum.
A good reference is this paper by Dotti and Kozameh (http://www.famaf.unc.edu.ar/~gdotti/1.pdf).
A: Let $M$ be a $4$-dim manifold. Here we consider source-free Maxwell equation:
$$dF=0,\,d*F=0$$, we study the space of solutions.
Then if $F$ is a solution, it is a harmonic form. Thus the space of solutions is real vector space of dimension $b_2$.
Now add another constraint, we require $F$ to be self-dual or anti self-dual. Here the index of intersection form take effect: The the space of self-dual harmonic form is real vector space of dimension $b_2^+$ and the space of anti self-dual harmonic form is real vector space of dimension $b_2^-$. For a proof one can refer to https://link.springer.com/chapter/10.1007/978-3-540-74311-8_14 at 13.7
The Donaldson theory is the study of moduli space of (anti)self-dual solutions replacing maxwell equation with $SU(2)$ Yang-Mills theory, which is nonlinear and the space of solutions is not a vector space. This moduli space carries more information about topology of $M$, say diagonalization theorem.
