Let $\hat p$, $\xi$, $\xi'$ and $1\le n\le d$ be as in Lemma <ref>. We can then find an element $\widehat K\in T_{\hat J}\clJ(X,\omega) \subset \normalfont\overline{\text{End}}_{\hat J}(T_X)$ such that it and its first $n$ derivatives vanish along $C$ and its $\normalfont(n+1)^\text{st}$ derivative, in the directions normal to $C$, projects to a smooth $\bR$-linear bundle homomorphism

\begin{align}\label{normal-derivative}
\normalfont\widehat K_{n+1}:\text{Sym}^{n+1}_\bR N_C\to\overline{\text{Hom}}_{\hat J}(T_C,N_C) = \Lambda^{0,1}T^*_C\otimes_\bC N_C
\end{align}

\begin{align}\label{normal-taylor-variation}
\int_{C'}\langle\hat\varphi^*(i\widehat K_{n+1}),\xi^{\otimes n+1}\otimes\xi'\rangle \ne 0
\end{align}

where $i$ denotes multiplication by $\sqrt{-1}$ on the fibers of $N_C$.

It suffices to construct a bundle homomorphism $L$ of the type (<ref>) satisfying (<ref>) with $L$ in place of $\widehat K_{n+1}$. Indeed, in this case, we can then construct $\widehat K\in T_{\hat J}\clJ(X,\omega)$ with $L = \widehat K_{n+1}$ (using a tubular neighborhood of $C\subset X$ and the argument from <cit.> to ensure $\omega$-compatibility). Choose a smooth bundle homomorphism

\begin{align}
L':\text{Sym}_\bR^{n+1}N_C\to\Lambda^{0,1}T^*_C\otimes_\bC N_C
\end{align}

which has positive pairing with (<ref>) at the point $q\in C$ yielded by Lemma <ref>. Multiplying $L'$ by a non-negative cutoff function on $C$ supported near $q$, we can assume that its pairing with (<ref>) is $\ge 0$ at all points of $C$ and $>0$ at $q$. Taking $L = iL'$ completes the construction. We refer the reader to <cit.> for comparison and further details.

We can now state our main technical result.

The inclusion (<ref>) has codimension $\ge 1$.

Near any point $\clM^d_{{\bf b},G}(\clM^*_g(X,A);{\bf k},{\bf c})_\spadesuit$, we can choosing auxiliary data (i.e., $\{D_{[z]}\}_{[z]\in M/\Gamma}$, (1), (2) and (4) as in §<ref>) and define Kuranishi models $F_{\hat p}$ as in (<ref>) for all points $\hat p\in\clM^d_{{\bf b},G}(\clM_g^*(X,A);{\bf k},{\bf c})$ in this neighborhood. Thus, in this neighborhood, the inclusion (<ref>) is defined by the equations

\begin{align}\label{local-def-eqns}
T^{(2)}_{\hat p} = \cdots = T^{(d+1)}_{\hat p} = 0.
\end{align}

Given any point $\hat p$ satisfying (<ref>), we show that the linearization of this system of $d$ equations has rank $\ge 1$. This will suffice to show that (<ref>) is the inclusion of a $C^\infty$ subvariety of codimension $\ge 1$ (in the sense of <cit.>).

Having fixed a point $\hat p\in\clM^d_{{\bf b},G}(\clM^*_g(X,A);{\bf k},{\bf c})_\spadesuit$ satisfying (<ref>), pick a section $0\ne\xi\in\ker\hat\varphi^*\hat D$. By condition (1) of Definition <ref>, we can also pick a section, unique up to scaling, $0\ne\xi'\in\ker\hat\varphi^*\hat D^\dagger = (\coker\hat\varphi^*\hat D)^*$ which annihilates $W_{\hat\varphi}$. Lemmas <ref> and <ref> then produce $1\le n\le d$ and $\widehat K$ satisfying (<ref>). We can now find a smooth path $\hat\gamma:[-1,1]\to\clJ(X,\omega)$ such with the following properties.

* $\hat\gamma(0) = \hat J$ and $\frac{d}{ds}|_{s=0}\hat\gamma(s) = \widehat K$.

* The path $\hat\gamma$ fixes the $n$-jet of $\hat J$ along $C$. More precisely, $|\hat\gamma(s) - \hat J| = O(|\nu_C|^{n+1})$ for all $s$, where $\nu_C = \text{dist}(C,\cdot)$ denotes the distance to $C$ induced by the given Riemannian metric.

* $\hat p(s) = (\hat\gamma(s),C,\hat\varphi:C'\to C,\hat\iota)\in\clM^d_{{\bf b},G}(\clM^*_g(X,A);{\bf k},{\bf c})$ for all $s$.

Note that (3) actually follows from (1) and (2). Also observe that (2) implies that $T^{(i)}_{\hat p(s)}\equiv 0$ for $2\le i\le n$. Thus, we have a well-defined element

\begin{align}
DT^{(n+1)}|_{\hat p}\cdot\widehat K = \textstyle\frac d{ds} T^{(n+1)}_{\hat p(s)}|_{s=0}
\end{align}

which can be computed by covariantly differentiating the non-linear Cauchy–Riemann operator and then pairing the result with $\xi'\in(\coker(\hat\varphi^*\hat D)/W_{\hat\varphi})^*$.
The computation in Lemma <ref> now shows that $DT^{(n+1)}|_{\hat p}\cdot\widehat K\ne 0$ and thus, we have proved that the rank in question is $\ge 1$.

[Variation of Taylor coefficient]
Using the notation from the proof Lemma <ref>, we have the following identity:

\begin{align}\label{taylor-identity}
\langle (DT^{(n+1)}|_{\hat p}\cdot\widehat K)\cdot\xi^{\otimes n+1},\xi'\rangle = -\frac12\int_{C'}\langle\hat\varphi^*(i\widehat K_{n+1}),\xi^{\otimes n+1}\otimes\xi'\rangle.
\end{align}

To get (<ref>), we inspect the expression for the non-linear Cauchy–Riemann operator

\begin{align}
(J',\varphi',j')\mapsto\bar\partial_{J',j'}(\varphi') = \textstyle\frac12(d\varphi' + J'(\varphi')\cdot d\varphi'\cdot j')
\end{align}

and differentiate it at $(\hat J,\hat\varphi,j_{C'})$ once with respect to the $J'$ (in the direction $\widehat K$) and covariantly differentiate it $n+1$ times with respect to $(\varphi',j')$ (in the direction $(\tilde\xi_\text{vf},\tilde\xi_\text{acs})\in\ker D(\bar\partial_{\hat J})|_{(\hat\varphi,j_{C'})}$, which is a lift of $\xi\in\ker\hat\varphi^*\hat D$) and use the fact that $\widehat K(\hat\varphi)\cdot d\hat\varphi\cdot j_{C'} = -\hat J(\hat\varphi)\cdot \widehat K(\hat\varphi)\cdot d\hat\varphi$. By assumption, $\widehat K$ and its first $n$ derivatives vanish along $C$ and thus, the only term which can survive the pairing with $\xi'$ is the one from (<ref>).

§ AN EXTENSION OF TAUBES' GROMOV INVARIANT TO DIMENSION $6$

In this section, we will apply the results of the last two sections to prove Theorem <ref>. This invariant can be viewed as a partial extension of Taubes' Gromov invariant (defined in <cit.>) to symplectic Calabi–Yau $3$-folds.

§.§ Linear wall crossing

The purpose of this subsection is to introduce the linear wall-crossing invariant (Definition <ref>), which will serve as a “correction term" in the definition of virtual count of embedded curves of class $2A$ in equation (<ref>).

Fix a smooth closed oriented $2$-manifold $\Sigma$ of genus $g$ and a $\bC$-vector bundle $\pi:N\to\Sigma$ of rank $2$ such that $c_1(N)\cdot[\Sigma] = 2g-2$. Such pairs $(\Sigma,N)$ arise by considering the normal bundle of any embedded pseudo-holomorphic curve of genus $g$ in a symplectic Calabi–Yau $3$-fold.
[Space of operators]
Let $\clJ(\Sigma)$ denote the space of almost complex structures on $\Sigma$ inducing the given orientation on $\Sigma$. For $\bK\in\{\bR,\bC\}$, define the space

\begin{align}\label{space-of-CR-on-N-eq}
\clC\clR_\bK(N)
\end{align}

to consist of pairs $(j,D)$, where $j\in\clJ(\Sigma)$ and $D$ is a $\bK$-linear Cauchy–Riemann operator on $N$ with respect to $j$, i.e.,

\begin{align}
\end{align}

is a linear first order differential operator such that for all $s\in\Omega^0(\Sigma,N)$ and $f\in C^\infty(\Sigma,\bK)$, we have $D(fs) = (\delbar_jf)s + fDs$. This is a bundle of affine spaces over the contractible space $\clJ(\Sigma)$ and therefore is also contractible. Every $(j,D)\in\clC\clR_\bK(N)$ satisfies $\ind D = 0$.

[Ordinary Brill–Noether loci]
For $\bK\in\{\bR,\bC\}$ and any integer $k\ge 1$, define the subspace

\begin{align}
\clW^k_\bK(N)\subset\clC\clR_\bK(N)
\end{align}

to consist of those pairs $(j,D)$ for which $\dim_\bK\ker D = k$. Also define

\begin{align}
\clW_\bK(N) = \bigcup_{k\ge 1}\clW^k_\bK(N).
\end{align}

Finally, also define $\clW'(N)\subset\clC\clR_\bR(N)$ to be the set of pairs $(j,D)$ such that there exists a section $0\ne\sigma\in\ker D$ and a point $z\in\Sigma$ such that $\sigma(z) = 0$.

We have the following codimension estimates on $\clW^k_\bK(N)$ and $\clW'(N)$.

* $\clW^1_\bR(N)$ is a submanifold of $\clC\clR_\bR(N)$ of codimension $1$.

* For each $k\ge 2$, $\clW^k_\bR(N)$ is of codimension $\ge 4$ in $\clC\clR_\bR(N)$.

* For each $k\ge 1$, $\clW^k_\bC(N)$ is of codimension $\ge 2$ in $\clC\clR_\bC(N)$.

Given any element $(j,D)\in\clW^k_\bK(N)$, there exists (using <cit.> for example) a smooth function

\begin{align}
\clC\clR_\bK(N)\supset\clU\xrightarrow{\clS}\text{Hom}_\bK(\ker D,\coker D)
\end{align}

defined in a neighborhood $\clU$ of $(j,D)$ such that $\clU\cap\clW_\bK^k(N) = \clS^{-1}(0)$. Moreover, its linearization $d\clS|_{(j,D)}$ restricted to $\Omega^{0,1}_j(\Sigma,\text{Hom}_\bK(N,N))$, i.e. the space of variations of $D$ with $j$ held fixed, is given by

\begin{align}\label{linearize-triv-wall}
A\mapsto(\kappa\mapsto A\kappa\pmod{\text{im }D})
\end{align}

where $\kappa \in \ker D$.
The statements (i)–(iii) will therefore follow by proving suitable rank estimates on this map. By duality, it suffices to prove rank estimates for the “Petri map" (recall that $D^\dagger$ is the Serre dual of $D$ as from Definition <ref>)

\begin{align}\label{triv-petri}
\ker D\otimes_\bK\ker D^\dagger\to\Omega^0(C,N\otimes_\bK N^\dagger) \\
s\otimes_\bK s'\mapsto(z\mapsto s(z)\otimes_\bK s'(z)).
\end{align}

By taking a $0\ne s\in\ker D$ and $0\ne s'\in\ker D^\dagger$ and using unique continuation for solutions of Cauchy–Riemann equations, it follows that the Petri map always has $\bK$-rank $\ge 1$. This proves (i) and (iii). Statement (ii) follows by using <cit.> (which is itself based on <cit.>) to conclude that the rank of the Petri map is $\ge 2k$ whenever $k\ge 2$ and $\bK = \bR$.

$\clW'(N)$ is of codimension $\ge 3$ in $\clC\clR_\bR(N)$.

Since $\clW'(N)\subset\clW_\bR(N)$, Lemma <ref>(ii) implies that it is enough to show that $\clW'(N)\cap\clW^1_\bR(N)$ is of codimension $\ge 3$ in $\clC\clR_\bR(N)$.
To prove this, we argue as follows. Define

\begin{align}
\widehat\clW'(N)\subset\clC\clR_\bR(N)\times\Sigma
\end{align}

to consist of $(j,D,z)$ such that $(j,D)\in\clW^1_\bR(N)$ and the elements of $\ker D$ vanish at $z$. It will be enough to show that $\widehat \clW'(N)$ is a submanifold of codimension $4$ in $\clW^1_\bR(N)\times\Sigma$. Fix any point $(j,D,z)\in\widehat\clW'(N)$. Choose metrics on $\Sigma$, $N$ – this yields an $L^2$ inner product on the space of sections of $N$. Fix a section $\sigma\in\ker D$ with $\|\sigma\|_{L^2} = 1$ (note that $\sigma$ is unique up to multiplication by $\pm 1$). Then, for every $(j',D')$ in a sufficiently small neighborhood $\clU$ of $(j,D)$ in $\clW^1_\bR(N)$, there is a unique element $\sigma_{(j',D')}\in\ker D'$ such that its $L^2$ inner product with $\sigma$ is $1$. We now have the smooth map

\begin{align}
\clU\times\Sigma&\xrightarrow{\mathcal{E}} N \\
\end{align}

which is compatible with the projection to $\Sigma$ and satisfies $\widehat\clW'(N)\cap(\clU\times\Sigma) = \mathcal{E}^{-1}(0)$. It will now suffice to show that the linearization

\begin{align}
d\mathcal{E}|_{(j,D,z)}:T_{(j,D)}\clW^1_\bR(N)\oplus T_z\Sigma\to N_z
\end{align}

is surjective. We will show the stronger statement that variations in $D$ with $j$ and $z$ held constant suffice to surject onto $N_z$. First, we need to find an explicit expression for this linearization. To this end, let $\Pi:\Omega^{0,1}_j(\Sigma,N)\to\coker D$ be the natural projection and let $Q:\text{im }D\to(\ker D)^\perp$ be the right inverse of $D$ which we extend to $\Omega^{0,1}_j(\Sigma,N)$ by declaring $Q|_{(\text{im }D)^\perp} \equiv 0$.

Let $A\in\Omega^{0,1}_j(\Sigma,\text{Hom}_\bR(N,N))$ be such that $A\in T_{(j,D)}\clW^1_\bR(N)$ (from the proof of Lemma <ref>(i), this means that $\Pi A\sigma = 0$). Then, there exists a smooth path $t\mapsto D_t\in\clW^1_\bR(N)$ such that $\dot D_0 = A$. Denoting $\sigma_t = \sigma_{(j,D_t)} = \sigma + \xi_t$ with $\xi_t\perp\sigma$ and differentiating the identity $D_t\sigma_t \equiv 0$, we find

\begin{align}
0 = A\sigma + D\dot\xi_0
\end{align}

which gives $\dot\xi_0 = -QA\sigma$. To summarize, we need to show that the map

\begin{align}
L:\Omega^{0,1}_j(\Sigma,\text{Hom}_\bR(N,N))\to N_z\oplus\coker D \\
L(A):= (-(QA\sigma)(z),\Pi A\sigma)
\end{align}

is surjective.

Now, if we let $D_z:\Omega^{0,1}_z(\Sigma,N)\to\Omega^{0,1}_j(\Sigma,N)$ be the restriction of $D$ to the space of sections of $N$ vanishing at $z$ and $\Pi':\Omega^{0,1}_j(\Sigma,N)\to\coker D_z$ be the corresponding projection, we see that we have an injective map

\begin{align}
\coker D_z\to N_z\oplus\coker D \\
\Pi'\eta\mapsto(-(Q\eta)(z),\Pi\eta)
\end{align}

which is an isomorphism by counting dimensions. Under this isomorphism, the map $L$ is simply $A\mapsto\Pi'A\sigma$.

Suppose for the sake of contradiction that $L$ is not surjective. Then, there is a nonzero distributional section $\tau$ of $N^\dagger$ such that $\langle A\sigma,\tau\rangle = 0$ for all smooth $A$ (i.e., $\sigma\otimes\tau\equiv 0$ as a distributional section of $N\otimes_\bR N^\dagger$) and $\tau|_{\text{im }D_z}\equiv 0$. The second condition implies that $D^\dagger\tau$, viewed as a functional on $\Omega^0(\Sigma,N)$, vanishes on the subspace $\Omega^0_z(\Sigma,N)$. As a result, there is a linear functional $\Lambda_\tau:N_z\to\bR$ such that for any $\sigma\in\Omega^0(\Sigma,N)$, we have $\langle D^\dagger\tau,\sigma\rangle = \Lambda_\tau(\sigma(z))$. Thus, $D^\dagger\tau$ is of class $(L_1^p)^*$ for any $2<p<\infty$ (where $L_1^p$ is the space of $L^p$ functions with one derivative in $L^p$ and we are using the Sobolev embedding $L_1^p\subset C^0$). By elliptic regularity, $\tau$ must be of class $(L^p)^* = L^q$ (where $\frac1p+\frac1q=1$) and smooth in the complement of $z$ (since it satisfies $D^\dagger\tau = 0$ here). But now $\sigma\otimes\tau\equiv 0$ with $\sigma\not\equiv 0$ and $\tau\not\equiv 0$ on the complement of $z$ contradicts the fact that $\sigma$ and $\tau$ satisfy unique continuation on the complement of $z$.

Now, let $h\ge g$ be an integer such that $r:=2h-2-2(2g-2)\ge 0$. Then, for any $j\in\clJ(\Sigma)$, the complex orbifold $\clM_h(\Sigma,j,2)$ of genus $h$ holomorphic double covers of $(\Sigma,j)$ branched at $r$ points is non-empty. In fact, the underlying coarse moduli spaces are canonically identified for all $j$ (since the isomorphism class of a cover is determined by purely topological data once $j$ is specified). Call this common coarse moduli space $M_h(\Sigma,2)$; it is naturally a smooth manifold of dimension $2r$.

Now, given $(j,D,[\varphi:\Sigma'\to\Sigma])\in\clC\clR_\bK(N)\times M_h(\Sigma,2)$, the operator $D_\varphi = \varphi^*D$ on $\varphi^*N$ admits a splitting $D_\varphi = D_\varphi^+\oplus D_\varphi^-$ into a direct sum of Cauchy–Riemann operators on isotypic subspaces corresponding to the trivial and sign representations of $\bZ/2\bZ = \text{Aut}(\varphi)$. We have $\ind D_\varphi^+ = \ind D = 0$ and $\ind D_\varphi^- = \ind D_\varphi = -2r$.
[Equivariant Brill–Noether loci]
Given $\bK\in\{\bR,\bC\}$, an integer $k\ge 1$ and integers $h$ and $r$ as above, define the subset

\begin{align}
\clW^k_{2,h,\bK}(N)\subset\clC\clR_\bK(N)\times M_h(\Sigma,2)
\end{align}

to consist of those $(j,D,[\varphi:\Sigma'\to\Sigma])$ for which $\dim_\bK\ker D_\varphi^- = k$. Also define

\begin{align}
\clW_{2,h,\bK}(N) = \bigcup_{k\ge 1}\clW^k_{2,h,\bK}(N).
\end{align}

We have the following codimension estimates on $\clW^k_{2,h,\bK}(N)$.

* $\clW^1_{2,h,\bR}$ is a submanifold of $\clC\clR_\bR(N)\times M_h(\Sigma,2)$ of codimension $2r+1$.

* For each $k \ge 2$, $\clW^k_{2,h,\bR}$ has codimension $\ge 4r + 4$ in $\clC\clR_\bR(N)\times M_h(\Sigma,2)$.

* For each $k\ge 1$, $\clW^k_{2,h,\bC}$ has codimension $\ge 2r+2$ in $\clC\clR_\bC(N)\times M_h(\Sigma,2)$.

The proof is a slight variation of the argument from Lemma <ref>. As in that argument, given any point $(j,D,[\varphi:\Sigma'\to\Sigma])\in\clW^k_{2,h,\bK}$, we can find a smooth function

\begin{align}
\clC\clR_\bK(N)\times M_h(\Sigma,2)\supset\clU\xrightarrow{\clS}\text{Hom}_\bK(\ker D_\varphi^-,\coker D_\varphi^-)
\end{align}

defined on a neighborhood $\clU$ of $(j,D,[\varphi:\Sigma'\to\Sigma])$ such that $\clU\cap\clW^k_{2,h,\bK} = \clS^{-1}(0)$. Moreover, the linearization $d\clS|_{(j,D,[\varphi])}$ restricted to $\Omega^{0,1}_j(\Sigma,\text{Hom}_\bK(N,N))$, i.e. the space of variations of $D$ with $j$ and $[\varphi]$ held fixed, is given by

\begin{align}
A\mapsto (\kappa\mapsto(\varphi^*A)\kappa \pmod{\text{im }D_\varphi^-})
\end{align}

where $\kappa \in \ker D_\varphi^-$. Thus, exactly as in Lemma <ref>, the proofs of (i)–(iii) will follow from suitable rank estimates on this map. By duality, it is enough to prove rank estimates for the “Petri map"

\begin{align}\label{double-petri}
\ker D_\varphi^-\otimes_\bK\ker(D^\dagger)_\varphi^-&\to\Omega^0(\Sigma',\varphi^*N\otimes_\bK \varphi^*N^\dagger)^{\bZ/2\bZ} \\
\sigma\otimes_\bK\sigma'&\mapsto(\zeta\mapsto\sigma(\zeta)\otimes_\bK\sigma'(\zeta))
\end{align}

where $(\cdot)^{\bZ/2\bZ}$ denotes the $\bZ/2\bZ = \text{Aut}(\varphi)$-invariant part.
The key observation is that $\ker D_\varphi^-\otimes_\bK\ker(D^\dagger)_\varphi^-$ already consists of $(\bZ/2\bZ)$-invariant elements – indeed, $\bZ/2\bZ$ acts by the sign representation on both $\ker D_\varphi^-$ and $\ker (D^\dagger)_\varphi^-$ – and so, the map (<ref>) is well-defined. Thus, we are reduced again to the argument of Lemma <ref>(i)–(iii). More precisely, we can show by unique continuation that the Petri map has $\bR$-rank $= 2r+1$ in case of (i) and $\bC$-rank $\ge r+1$ in case of (ii). For statement (iii), we invoke <cit.> (or <cit.>) to conclude that the rank of the Petri map is $\ge 2(2 + 2r)$ in case of (ii).

The injectivity of Petri maps in the proofs of both Lemma <ref> and Lemma <ref> follows without appealing to Wendl's work on generic injectivity of Petri maps <cit.> because the degrees of the corresponding covers are small enough.

[Co-orientation on $\clW^1_{2,h,\bR}(N)$]
Given a tuple $(j,D,[\varphi:\Sigma'\to\Sigma])$ lying in $\clW^1_{2,h,\bR}(N)$, its normal space in $\clC\clR_\bR(N)\times M_h(\Sigma,2)$ is canonically identified with

\begin{align}\label{double-wall-normal}
\normalfont\text{Hom}(\ker D_\varphi^-,\coker D_\varphi^-).
\end{align}

We define an orientation on (<ref>) in the usual fashion, i.e., we deform $D$ in a $1$-parameter family to a $\bC$-linear operator and use the spectral flow. This assignment of orientations to the normal spaces of $\clW^1_{2,h,\bR}(N)\subset\clC\clR_\bR(N)$ is called the natural co-orientation on $\clW^1_{2,h,\bR}(N)$.

In order to make the next definition, we will need the following well-known fact which is implicit in <cit.> and <cit.>.

Given a complex curve $C$ (not necessarily compact) and a complex vector bundle $\pi:N\to C$ on it, there is a natural bijection $D\mapsto J_D$ between

* $\bR$-linear Cauchy–Riemann operators $D:\Omega^0(C,N)\to\Omega^{0,1}(C,N)$ and,

* almost complex structures $J$ on the total space of $N$ which

* restrict to the standard complex structure on each fiber of $\pi$,

* restrict to the given complex structure on $C$ along the zero section,

* are invariant under the $\bR^\times$ action $\lambda\cdot(z,v) = (z,\lambda v)$ on $N$ and,

* such that the projection $\pi$ is $J$-holomorphic.

Under this bijection, if $C'$ is another complex curve (not necessarily compact), then a smooth map $\hat s: C'\to N$ is $J_D$-holomorphic if and only if $\varphi:=\pi\circ\hat s:C'\to C$ is holomorphic and the corresponding section $s\in\Omega^0(C',\varphi^*N)$ given by

\begin{align}\label{eqn:curve-section}
z\in C'\mapsto \hat s(z)\in N_{\varphi(z)}
\end{align}

satisfies $(\varphi^*D)s = 0$.

It is enough to consider the case of the trivial bundle $U\times\bC^r\to U$ where $U\subset\bC$ is an open subset with complex coordinate $z$ and $\bC^r$ is endowed with the complex coordinates $w = (w_1,\ldots,w_r)$. Let $J$ be any almost complex structure on $U\times\bC^r$ which satisfies conditions (a)–(d). Using (a), (b) and (d), we find that the bundle $\Omega^{1,0}_J$ near $U\times 0\subset U\times\bC^r$ has a local frame consisting of $dz$ and

\begin{align}\label{acs-frame}
dw_i + A_i(z,w)d\bar z
\end{align}

for $1\le i\le r$ where the $A_i$ are smooth functions vanishing when $w_i=0$ for all $1 \leq i \leq r$. Now, (c) implies that the $A_i$ are actually $\bR$-linear in $w$, i.e., they are of the form

\begin{align}\label{acs-frame-2}
A_i(z,w) = \hat A_i(z)[w]
\end{align}

where $\hat A = (\hat A_i)_{i=1}^r:U\to\text{End}_\bR(\bC^r)$ is a smooth function. Moreover, the expression (<ref>) for a frame of $\Omega^{1,0}_J$ is valid on the whole of $U\times\bC^r$. To this almost complex structure, we can associate the $\bR$-linear Cauchy–Riemann operator $D = \delbar + \hat A[\cdot]$ on the bundle $U\times\bC^r\to U$. Conversely, any $\bR$-linear Cauchy–Riemann operator $D$ on $U\times\bC^r$ can be written as $\delbar + \hat A[\cdot]$ for some smooth function $\hat A:U\to\text{End}_\bR(\bC^r)$ and thus, defines an almost complex structure $J_D$ on $N$, satisfying (a)–(d), by taking the $(1,0)$ forms to be spanned by $dz$ along with $dw_i + \hat A_i(z)[w]d\bar z$ for $1\le i\le r$.

It is easy to see that this gives a bijective correspondence $D\mapsto J_D$ and that the bijection is preserved under the natural action of the group $C^\infty(U,GL_r(\bC))$ on both sides. Finally, for any open subset $U'\subset\bC$ and smooth map $\hat s:U'\to U\times\bC^r$ given by $\zeta\mapsto(\varphi(\zeta),s(\zeta))$ is $J_D$-holomorphic if and only if we have

\begin{align}\label{eqn_redtext}
\delbar\varphi = 0, \quad\delbar s + \hat A(\varphi)[s]\delbar\bar\varphi = 0
\end{align}

as desired. Now, the lemma extends to the general case by naturality.

Let us now observe that for any $(j,D,[\varphi:\Sigma'\to\Sigma]) \in \clW^1_{2,h,\bR}(N)$, all non-zero elements of $\ker D_\varphi^-$ are non-zero scalar multiples of each other. Thus, for any $0 \neq \sigma \in \ker D_\varphi^-$, the corresponding $J_D$-holomorphic map $\hat\sigma:\Sigma'\to N$ is immersed/injective if and only if the same property holds for $a\cdot\sigma$ where $0\neq a\in \bR$. Therefore, we can make sense of the locus within $\clW^1_{2,h,\bR}$ where this immersion/injectivity property fails. The discussion which follows constructs Baire sets which avoid this locus (i.e. the immersion and injectivity property hold). These Baire sets will be used in the definition of linear wall crossing invariant (Definition <ref>).

Define the subsets

\begin{align}
&\normalfont\clW^1_{2,h,\bR}(N)_\text{imm}, \\
\end{align}

of $\clW^1_{2,h,\bR}(N)$ to consist of exactly those $(j,D,[\varphi:\Sigma'\to\Sigma])$ for which the $J_D$-holomorphic map $\hat\sigma:\Sigma'\to N$ corresponding to a nonzero $\sigma\in\ker D_\varphi^-$ fails to be immersed or injective respectively. Also define

\begin{align}
\normalfont\clW^1_{2,h,\bR}(N)_\text{emb} = \normalfont\clW^1_{2,h,\bR}(N)_\text{imm}\cup \normalfont\clW^1_{2,h,\bR}(N)_\text{inj}.
\end{align}

We have the following codimension estimates.

* $\normalfont\clW^1_{2,h,\bR}(N)_\text{imm}$ has codimension $\ge 2r + 5$ in $\clC\clR_\bR(N)\times M_h(\Sigma,2)$.

* $\normalfont\clW^1_{2,h,\bR}(N)_\text{inj}$ has codimension $\ge 2r + 3$ in $\clC\clR_\bR(N)\times M_h(\Sigma,2)$.

In particular, $\normalfont\clW^1_{2,h,\bR}(N)_\text{emb}$ has codimension $\ge 2r+3$ in $\clC\clR_\bR(N)\times M_h(\Sigma,2)$.

The proof is just a combination of the ideas from Lemmas <ref> and <ref>. More precisely, the proof of (ii) exactly mirrors the proof of Lemma <ref> while (i) requires a slightly more involved argument.

* Consider the finite cover $\tilde \clC_\text{imm}\to\clC\clR_\bR(N)\times M_h(\Sigma,2)$ which consists of tuples $(j,D,[\varphi:\Sigma'\to\Sigma])$ along with the choice of a point $\zeta\in\text{Crit }\varphi$. Within $\tilde\clC_\text{imm}$, we can consider the subset $\tilde\clW^1_{2,h,\bR}(N)_\text{imm}$ consisting of $(j,D,[\varphi:\Sigma'\to\Sigma],\zeta)$ such that $(j,D,[\varphi:\Sigma'\to\Sigma])\in\clW^1_{2,h,\bR}(N)$ and $d\hat\sigma|_\zeta = 0$ for all $0\ne\sigma\in\ker D_\varphi^-$ (where $\hat\sigma$ is the $J_D$-holomorphic map corresponding to $\sigma$).

It will suffice to show that $\tilde\clW^1_{2,h,\bR}(N)_\text{imm}$ is a submanifold of $\tilde\clC_\text{imm}$ of codimension $2r+5$. To this end, fix a point $(j,D,[\varphi:\Sigma'\to\Sigma],\zeta)\in\tilde\clW^1_{2,h,\bR}(N)_\text{imm}$. Arguing exactly as in the proof of Lemma <ref> (with Lemma <ref> playing a role analogous to Lemma <ref> in that proof), we are reduced to showing that

\begin{align}
L:\Omega^{0,1}_j(\Sigma,\text{Hom}_\bR(N,N))\to\coker (D_\varphi^-)_\zeta \\
\end{align}

is surjective. Here, $\sigma$ is some nonzero element of the $1$-dimensional vector space $\ker D^-_\varphi$, the operator $(D_\varphi^-)_\zeta$ is the restriction of $D_\varphi^-:\Omega^0(\Sigma',\varphi^*N)^-\to\Omega^{0,1}_j(\Sigma',\varphi^*N)^-$ to the subspace of sections $s$ for whose derivative at $\zeta$ (well-defined and independent of choice of connection on $N$ since $\zeta\in\text{Crit }\varphi$) is $\bC$-anti-linear and $\Pi'$ is the projection from $\Omega^{0,1}_j(\Sigma',\varphi^*N)^-$ to $\coker (D_\varphi^-)_\zeta$.

Assume, for the sake of contradiction, that $L$ is not surjective. Then, arguing as in the proof of Lemma <ref>, we deduce the existence of a nonzero distributional section $\tau$ of $(\varphi^*N)^\dagger$ which

* is $\bZ/2\bZ = \text{Aut}(\varphi)$-anti-invariant,

* vanishes on the image of $(D_\varphi^-)_\zeta$ and,

* is such that $\sigma\otimes\tau\equiv 0$ as a distributional section of $\varphi^*N\otimes_\bR(\varphi^*N)^\dagger$ (for this last condition, we are using the observation that $\sigma\otimes\tau$ is invariant under $\bZ/2\bZ$ –  see the parallel argument in the proof of Lemma <ref>).

Now, note that (a) and (b) imply that $(D_\varphi)^\dagger\tau$, viewed as a functional on $\Omega^0(\Sigma',\varphi^*N)$, factors through the projection

\begin{align}\label{c-linear-derivative}
\Omega^0(\Sigma',\varphi^*N)\to\text{Hom}_\bC(T_\zeta\Sigma',N_{\varphi(\zeta)})\\
\end{align}

and thus, it is of class $(L_2^p)^*$ for any $2<p<\infty$ (where $L_2^p$ is the space of $L^p$ functions with two derivatives in $L^p$ and we are using the Sobolev embedding $L_2^p\subset C^1$). By elliptic regularity it now follows that $\tau$ is of class $(L_1^p)^*$ and smooth in the complement of $\zeta$ (since it satisfies $(D_\varphi)^\dagger\tau = 0$ here). Now, if support of $\tau$ is not just the point $\zeta$, then by unique continuation for $\sigma$ and $\tau$ (on the complement of $\zeta$), we must have $\sigma\otimes\tau\not\equiv 0$. Thus, we must have $\text{supp }\tau = \{\zeta\}$. It follows that there is an integer $m\ge 0$ such that $\tau$ applied to any element of $\Omega^{0,1}_j(\Sigma',\varphi^*N)$ depends only on the $m$-jet of this element at $\zeta$. Since $\tau$ is known to be of class $(L_1^p)^*$ and $L_1^p\not\subset C^1$, it follows that $m=0$ and as a result $\tau$ acts on the space $\Omega^{0,1}_j(\Sigma',\varphi^*N)$ via a linear functional

\begin{align}
\end{align}

But now, it is easy to produce a smooth section $s$ of $\varphi^*N$ such that

\begin{align}
-\langle (D_\varphi)^\dagger\tau,s\rangle = \langle\tau,D_\varphi s\rangle = M(D_\varphi s|_\zeta) = M((\varphi^*\nabla)^{0,1}s|_\zeta)\ne 0
\end{align}

and $(\varphi^*\nabla)^{1,0}s|_\zeta = 0$. This contradicts the fact that $(D_\varphi)^\dagger\tau$ factors through the map (<ref>).

* The proof is similar to (i) but easier and so, we only indicate the setup. Define $\tilde\clC_\text{inj}$ to be the subset of $\clC\clR_\bR(N)\times M_h(\Sigma,2)\times\Sigma$ consisting of tuples $(j,D,[\varphi:\Sigma'\to\Sigma],z)$ such that $z\not\in\varphi(\text{Crit }\varphi)$. We can then define the subset $\tilde\clW^1_{2,h,\bR}(N)_\text{inj}\subset\tilde\clC_\text{inj}$ to consist of those elements $(j,D,[\varphi:\Sigma'\to\Sigma],z)$ for which $(j,D,[\varphi])\in\clW^1_{2,h,\bR}(N)$ and $\sigma|_{\varphi^{-1}(z)}\equiv 0$ for all $0\ne\sigma\in\ker D_\varphi^-$. It can now be shown as in (i) that $\tilde\clW^1_{2,h,\bR}(N)_\text{inj}\subset\tilde\clC_\text{inj}$ is a submanifold of codimension $2r+5$. Noting that $\clW^1_{2,h,\bR}(N)_\text{inj}$ is the image of $\tilde\clW^1_{2,h,\bR}(N)_\text{inj}$ under the obvious projection gives the desired result.

The statement concerning $\clW^1_{2,h,\bR}(N)_\text{emb}$ follows immediately from (i) and (ii).

The codimension estimates from Lemma <ref> assert that the holomorphic curve associated to the kernel of a generic element in $\normalfont\clW^1_{2,h,\bR}(N)$ is embedded. The injectivity of the relevant Petri map is not hard to establish because our discussion just involves $(\bZ/2\bZ)$-equivariant Cauchy–Riemann operators from $2$-fold covers. In fact, it is possible to extend the statements in Lemma <ref> to elementary walls as in Definition <ref>. The fact that $\dim_{\bR} \mathbf{k}^H = 1$, which follows from the definition of elementary wall type, is necessary in order to define the holomorphic sections uniquely up to rescaling. However, one needs to adapt the proof of genetric injectivity of Petri maps from <cit.> to this context.

Any element $0 \neq \sigma \in \ker D_\varphi^-$ defines a multi-valued section of the bundle $N \to \Sigma$. The conclusion of Lemma <ref> can therefore be phrased as the “generic embeddedness" of multi-valued sections. As pointed out in Remark <ref>, it may be possible to use similar arguments to establish similar generic behavior for $2$-valued harmonic forms relevant to special Lagrangian geometry.

The next definition introduces the notion of “$2$-rigid" operators, paths between them and fixed endpoint homotopies between such paths. Such operators arise naturally as normal deformation operators of embedded pseudo-holomorphic curves with respect to any super-rigid almost complex structure.

* We say that $\alpha = (j,D)\in\clC\clR_\bR(N)$ is $2$-pre-rigid if it misses the images of $\clW'(N),\clW^k_{2,h,\bR}(N)$ and $\normalfont\clW^1_{2,h,\bR}(N)_\text{emb}$ in $\clC\clR_\bR(N)$ for all $h\ge g$ and $k\ge 2$. We say that $\alpha$ is $2$-rigid if, in addition, it also misses the image of the map

\begin{align}\label{double-wall-to-ops}
\clW^1_{2,h,\bR}(N)\to\clC\clR_\bR(N)
\end{align}

for all $h\ge g$. Denote the set of $2$-rigid elements by $\clC\clR_\bR(N)_2$ and its intersection with $\clC\clR_\bC(N)\setminus\clW_\bC(N)$ by $\clC\clR_\bC(N)_2$.

* Given $\alpha_\pm\in\clC\clR_\bR(N)_2$, define $\clP(\alpha_-,\alpha_+)$ to be the space of smooth paths in $\clC\clR_\bR(N)$ from $\alpha_-$ to $\alpha_+$. Define

\begin{align}
\clP^\pitchfork(\alpha_-,\alpha_+)\subset\clP(\alpha_-,\alpha_+)
\end{align}

to be the set of paths which consist entirely of $2$-pre-rigid elements and are transverse to (<ref>).

* Given $\gamma_\pm\in \clP^\pitchfork(\alpha_-,\alpha_+)$, define $\clP(\gamma_-,\gamma_+)$ to be the space of smooth paths in $\clP(\alpha_-,\alpha_+)$ from $\gamma_-$ to $\gamma_+$, i.e., smooth homotopies from $\gamma_-$ to $\gamma_+$. Define

\begin{align}
\clP^\pitchfork(\gamma_-,\gamma_+)\subset\clP(\gamma_-,\gamma_+)
\end{align}

to be the set of homotopies which consist entirely of $2$-pre-rigid elements and are transverse to (<ref>).

For the convenience of the reader, we now summarize the consequences of Lemmas <ref>, <ref> and <ref> which are relevant for the next lemma: $\clW'(N)$ has codimension $\ge 3$ in $\clC\clR_\bR(N)$, the image of $\clW^k_{2,h,\bR}(N)$ in $\clC\clR_\bR(N)$ has codimension $\ge 4$ for $k\ge 2$ and the image of $\clW^1_{2,h,\bR}$ has codimension $\ge 3$ in $\clC\clR_\bR(N)$. Moreover, both $\clW^k_\bC(N)$ and the image of $\clW^k_{2,h,\bC}$ in $\clC\clR_\bC(N)$ have codimension $\ge 2$ for all $k\ge 1$.

We have the following genericity statements.

* $\clC\clR_\bR(N)_2\subset\clC\clR_\bR(N)$ is a Baire subset.

* $\clC\clR_\bC(N)_2\subset\clC\clR_\bC(N)$ is a path connected Baire subset.

* For $\alpha_\pm\in\clC\clR_\bR(N)_2$, $\clP^\pitchfork(\alpha_-,\alpha_+)\subset\clP(\alpha_-,\alpha_+)$ is a Baire subset.

* For $\gamma_\pm\in P^\pitchfork(\alpha_-,\alpha_+)$, $\clP^\pitchfork(\gamma_-,\gamma_+)\subset\clP(\gamma_-,\gamma_+)$ is a Baire subset.

This is a straightforward consequence of the Sard–Smale theorem combined with the codimension formulas/estimates from Lemmas <ref>, <ref> and <ref>.

Fix $\alpha_\pm\in\clC\clR_\bR(N)_2$, $\gamma_\pm\in\clP^\pitchfork(\alpha_-,\alpha_+)$ and $\tilde\gamma\in\clP^\pitchfork(\gamma_-,\gamma_+)$. Consider $\tilde\gamma$ as smooth map

\begin{align}\label{generic-homotopy}
\end{align}

such that $\tilde\gamma(\cdot,\pm1)\equiv\gamma_\pm(\cdot)$ and $\tilde\gamma(\pm1,\cdot)\equiv\alpha_\pm$. Then, for any fixed $h\ge g$, the fiber product of (<ref>) and (<ref>) is a naturally oriented smooth $1$-manifold with boundary which is proper over $[-1,1]\times[-1,1]$ and has boundary exactly over $[-1,1]\times\pm1$.

The fact that the fiber product in question is a manifold with boundary (with boundary only over $[-1,1]\times\pm 1$) is obvious from the transversality assumption in the definition of $\clP^\pitchfork(\gamma_-,\gamma_+)$. The orientation comes the standard orientation on $[-1,1]\times[-1,1]$ and the natural co-orientation from Definition <ref>. Thus, what remains to be proved is properness over $[-1,1]\times[-1,1]$ and this will be a consequence of the fact that all elements in the image of $\tilde\gamma$ are $2$-pre-rigid. To establish properness, let $p_n\to p$ be a convergent sequence in $[-1,1]\times[-1,1]$ and let $\tilde\alpha_n = (j_n,D_n,[\varphi_n:\Sigma'_n\to\Sigma])\in\clW^1_{2,h,\bR}(N)$ be a sequence such that we have $\tilde\gamma(p_n) = \alpha_n:= (j_n,D_n)$ for all $n\ge 1$, with limit $\tilde\gamma(p) = \alpha := (j,D)$. We will show that $\tilde\alpha_n$ has a subsequence converging to an element $\tilde\alpha\in\clW^1_{2,h,\bR}(N)$.
In other words, we will use the assumption $\tilde\gamma\in\clP^\pitchfork(\gamma_-,\gamma_+)$ to argue that there is a limiting $(\bZ/2\bZ)$-anti-invariant multi-valued section associated to $\alpha = (j,D)$ which is defined over a branched cover of $\Sigma$ with smooth domain.

Fix a Hermitian inner product on $N$ and let $\omega_0$ be a symplectic form on the unit ball $B_1(N)$ taming the almost complex structure $J_D$ (this exists by <cit.>). Since $\alpha_n\to\alpha$, it follows that $\omega_0$ tames $J_{D_n}$ also for $n\gg 1$.

Let $\hat\sigma_n:\Sigma'_n\to N$ be the simple $J_{D_n}$-holomorphic map representing the class $2[\Sigma]$ corresponding to a section $\sigma_n\in\ker(D_n)_{\varphi_n}^-$ with $\|\sigma_n\|_{L^\infty} = \frac12$. By Gromov compactness, we can pass to a subsequence to assume that we have a limiting $J_D$-holomorphic stable map $\hat\sigma:\Sigma'\to N$ representing class $2[\Sigma]$ with $\Sigma'$ being of arithmetic genus $h$. Note that the image of each $\hat\sigma_n$ (and therefore of $\hat\sigma$) is invariant under the automorphism $\clI:(z,v)\mapsto(z,-v)$ of $N$. Define $\varphi = \pi\circ\hat\sigma:\Sigma'\to\Sigma$ and note that the corresponding section $\sigma\in\ker\varphi^*D$ satisfies $\|\sigma\|_{L^\infty} = \frac12$. Each effective component of $\Sigma'$ (i.e. an irreducible component on which $\hat\sigma$ is non-constant) must map with positive degree onto $\Sigma$ via $\varphi$. Thus, there are at most two effective components in $\Sigma'$. We now consider two cases.

* (There are two effective components $C_1,C_2\subset\Sigma$.) Since $\varphi|_{C_i}:C_i\to\Sigma$ are both of degree $1$, they must be isomorphisms. Thus, $\hat s_1 := \hat\sigma|_{C_1}$ and $\hat s_2:=\hat\sigma|_{C_2}$ give us two sections $s_1,s_2\in\ker D$ at least one of which must be nonzero. If $\hat s_1\not\equiv 0$, then since the image of $\hat\sigma$ is connected invariant under $\clI$, it follows that $s_1$ must vanish at a point $z\in C$. This contradicts the $2$-pre-rigidity of $\alpha = (j,D)$.

* (There is a unique effective component $C\subset\Sigma'$.) Let $\psi:\tilde C\to C$ be the normalization. Since the image of $\hat\sigma\circ\varphi:\tilde C\to N$ is invariant under $\clI$, it follows that $0\ne\psi^*\sigma\in\ker D_{\varphi\circ\psi}^-$. Since $\alpha = (j,D)$ is $2$-pre-rigid, it follows that $\dim\ker D^-_{\varphi\circ\psi} = 1$ and the $J_D$-holomorphic map $\hat\sigma\circ\psi$ is an embedding because $\alpha$ necessarily lies in the complement of $\normalfont\clW^1_{2,h,\bR}(N)_\text{emb}$. This implies that $\psi$ is an isomorphism, $C$ is smooth and $\hat\sigma|_C$ is an embedding representing class $2[\Sigma]$. Since $\hat\sigma:\Sigma'\to N$ is the Gromov limit of the simple (in fact, embedded by $2$-pre-rigidity) $J_{D_n}$-curves $\hat\sigma_n:\Sigma'_n\to N$, Remark <ref>(b) shows that $\Sigma'$ cannot have any ghost components. Thus, $\Sigma'$ is smooth and coincides with $C$. Moreover, $0\ne\sigma\in\ker D_\varphi^-$ and $\dim\ker D_\varphi^- = 1$.

We have now shown that $\Sigma'$ is necessarily smooth. We conclude that the limit $\tilde\alpha = (j,D,[\varphi:\Sigma'\to\Sigma])$ lies in $\clW^1_{2,h,\bR}(N)$ as desired.

[Linear wall crossing invariant]
Let $\alpha\in\clC\clR_\bR(N)_2$ be $2$-rigid and let $h\ge g$ be given. We then define the invariant

\begin{align}
\normalfont\text{w}_{2,h}(\alpha)\in\bZ
\end{align}

as follows. Set $r = (2h-2) - 2(2g-2)$. If $r<0$, we define $\normalfont\text{w}_{2,h}(\alpha) = 0$.

If $r\ge 0$, choose a point $\beta\in\clC\clR_\bC(N)_2$ and choose a path $\gamma\in\clP^\pitchfork(\alpha,\beta)$. Then, using Lemma <ref> and the natural co-orientation from Definition <ref>, the fiber product of $\gamma$ with (<ref>) is a compact oriented $0$-manifold and we define $\normalfont\text{w}_{2,h}(\alpha)$ to be the signed number points in this fiber product.

The following lemma shows that $\normalfont\text{w}_{2,h}(\alpha)$ does not depend on the auxiliary data therefore it is well-defined.

$\normalfont\text{w}_{2,h}(\alpha)$ in Definition <ref> is independent of the choice of $\beta$ and $\gamma$.

It is enough to consider the case $r\ge 0$. Let us temporarily denote the quantity from Definition <ref> as $\text{w}_{2,h}(\alpha,\beta,\gamma)$ to emphasize the dependence on the choices $\beta$ and $\gamma$.

* Fix the choice of $\beta$ and consider $\gamma,\gamma'\in\clP^\pitchfork(\alpha,\beta)$. Choose $\tilde\gamma\in\clP^\pitchfork(\gamma,\gamma')$ and apply Lemma <ref> (combined with the fact that an oriented $1$-manifold with boundary has $0$ boundary points when counted with sign) to get

\begin{align}
\text{w}_{2,h}(\alpha,\beta,\gamma) = \text{w}_{2,h}(\alpha,\beta,\gamma').
\end{align}

Thus, we may write $\text{w}_{2,h}(\alpha,\beta,\gamma) = \text{w}_{2,h}(\alpha,\beta)$.

* Now, suppose $\beta,\beta'\in\clC\clR_\bC(N)_2$ are given. Choose a path $\delta$ in $\clC\clR_\bC(N)_2$ from $\beta$ to $\beta'$ – such a path exists by Lemma <ref> and it is, moreover, automatically in $\clP^\pitchfork(\beta,\beta')$. Now, given any $\gamma\in\clP^\pitchfork(\alpha,\beta)$, we can set $\gamma'\in\clP^\pitchfork(\alpha,\beta')$ to be the concatenation of $\gamma$ and $\delta$. Since there are no intersections of $\delta$ with (<ref>), it follows that

\begin{align}
\text{w}_{2,h}(\alpha,\beta) = \text{w}_{2,h}(\alpha,\beta,\gamma) = \text{w}_{2,h}(\alpha,\beta',\gamma') = \text{w}_{2,h}(\alpha,\beta').
\end{align}

Combining (i) and (ii), we conclude that $\text{w}_{2,h}(\alpha,\beta,\gamma)$ is independent of the choices of $\beta$ and $\gamma$.

§.§ Proof of Theorem <ref>

The proof of Theorem <ref> is an application of the arguments of §<ref> combined with Theorems <ref> and <ref>.

We fix the primitive class $A\in H_2(X,\bZ)$ for the whole argument. Let $J_\pm\in\clJ(X,\omega)$ be super-rigid almost complex structures. We need to show that for all $h\ge 0$ we have

\begin{align}
\text{Gr}_{2A,h}(X,\omega,J_-) = \text{Gr}_{2A,h}(X,\omega,J_+)
\end{align}

where $\text{Gr}_{2A,h}(X,\omega,J_\pm)$ is the right side of (<ref>) for $J = J_\pm$. We will accomplish this by studying the bifurcations that occur along a suitably chosen path $\gamma:[-1,1]\to\clP(J_-,J_+)$. Before this, we need some preparatory facts analogous to Lemmas <ref>, <ref>, <ref> and <ref>.

Let $h\ge g\ge 0$ be integers.

* Define $\clJ'_{A,g}\subset\clJ(X,\omega)$ to be the set of all $\omega$-compatible almost complex structures $J$ on $X$ for which there exists an embedded $J$-curve $C\subset X$ of genus $g$ in class $A$, a point $z\in C$ and $0\ne\sigma\in\ker D^N_{C,J}$ with $\sigma(z)= 0$.

* Define $\clW_{2,h}(\clJ_{A,g})\subset\clJ(X,\omega)$ to be the set of all $\omega$-compatible almost complex structures $J$ on $X$ for which there exists an embedded $J$-curve $C\subset X$ of genus $g$ in class $A$, a holomorphic branched double cover $\varphi:C'\to C$ with $C'$ being smooth of genus $h$ and $0\ne\sigma\in\ker(D^N_{C,J})^-_{\varphi}$ such that the corresponding $J_{D^N_{C,J}}$-holomorphic map $\hat\sigma:C'\to N_C$ defined using (<ref>) is not an embedding.

[Analogue of Lemmas <ref> and <ref>]
We have the following codimension estimates.

* $\clJ'_{A,g}\subset\clJ(X,\omega)$ has codimension $\ge 3$ for all $g\ge 0$.

* $\clW_{2,h}(\clJ_{A,g})\subset\clJ(X,\omega)$ has codimension $\ge 3$ for all $h\ge g\ge 0$.

We first define the relevant universal moduli spaces and reduce the problem of estimating the codimension to proving a rank lower bound for the linearization of the defining equations of these universal moduli spaces. The proofs of the rank estimates from Lemmas <ref> and <ref> (which prove the analogous results for Cauchy–Riemann operators) apply verbatim once we combine them with <cit.> which shows that deformations in the space of Cauchy–Riemann operators can be realized by deformations in the space of $\omega$-compatible almost complex structures.

[Analogue of Lemma <ref>]
The subset $\clB^*\subset\clP(J_-,J_+)$ of paths $\gamma:[-1,1]\to\clJ(X,\omega)$ with $\gamma(\pm1) = J_\pm$ which are disjoint from $\clJ'_{A,g}$ and $\clW_{2,h}(\clJ_{A,g})$ for all $A \in H_2(X, \bZ)$ and $h\ge g\ge 0$ is a Baire subset.

This is a direct consequence of a Sard–Smale argument applied to the codimension estimates from Lemma <ref>.

For the statement of the next lemma, recall the Baire set $\clB'$ from Lemma <ref>.
[Analogue of Lemma <ref>]
Fix a path $\gamma\in\clB^*\cap\clB'\subset\clP(J_-,J_+)$ and integers $0\le g\le h$.

* Consider all tuples of the form $(t,\Sigma,\varphi:\Sigma'\to\Sigma)$ where $t\in[-1,1]$,  $\Sigma\subset X$ is an embedded $\gamma(t)$-curve of genus $g$ in class $A$ and $(\Sigma',\varphi)\in\overline\clM_h(\Sigma,2)$ with $\Sigma'$ being smooth. Among these, the tuples satisfying

\begin{align}
\dim\ker D^N_{\Sigma,\gamma(t)} = 0,\quad\dim\ker\varphi^*D^N_{\Sigma,\gamma(t)} = 1
\end{align}

form a finite set.

* Let $t_n\to t$ in $[-1,1]$ be a convergent sequence and suppose $\Sigma'_n\subset X$ is a sequence of embedded $\gamma(t_n)$-curves of genus $h$ in class $2A$ which converge to a $\gamma(t)$-holomorphic stable map $\varphi:\Sigma'\to\Sigma\subset X$ in the Gromov topology with $\Sigma$ being an embedded $\gamma(t)$-curve of genus $g$ in class $2A/d$ for some $d\in\{1,2\}$ and $(\Sigma',\varphi)\in\overline\clM_h(\Sigma,d)$.

Then, $\Sigma'$ is necessarily smooth. If $d=1$, then $\varphi$ is an isomorphism. If $d=2$, then the operator $D^N_{\Sigma,\gamma(t)}$ is an isomorphism and we have

\begin{align}
\dim\ker \varphi^*D^N_{\Sigma,\gamma(t)} = 1.
\end{align}

The key ingredients of the proof are Theorem <ref> and Remark <ref>(b).

* Since $\gamma\in\clB'$, it follows that this set is discrete. It will therefore suffice to prove compactness. To this end, suppose that $(t_n,\Sigma_n,\varphi_n:\Sigma'_n\to\Sigma_n)$ is a sequence of points in this set with $t_n\to t$. By Remark <ref>(b), the sequence $\Sigma_n$ has, after passing to a subsequence, a Gromov limit $\Sigma$ which is an embedded $\gamma(t)$-curve of the same genus $g$. Now, by identifying the normal bundles $N_{\Sigma_n}\to\Sigma_n$ for $n\gg 1$ with the fixed smooth vector bundle on $N_\Sigma\to\Sigma$, we can repeat the argument of Lemma <ref> to conclude (the condition $\gamma\in\clB'\cap\clB^*$ is the analogue of the $2$-pre-rigidity condition used in that proof).

* First, suppose $\Sigma$ itself is of class $2A$. Then, Remark <ref>(b) shows that $d=1$, $\varphi$ is an isomorphism and, in particular, that $\Sigma'$ is smooth. For the remainder suppose that $\Sigma$ is of class $A$ and $d = 2$. Theorem <ref> now yields a section $s\in\ker\varphi^*D^N_{\Sigma,\gamma(t)}$ which is not pulled back from $\Sigma$. Let $\hat s:\Sigma'\to N_\Sigma$ be the associated $J_{D^N_{\Sigma,\gamma(t)}}$-holomorphic map.

Since $(\Sigma',\varphi)\in\overline\clM_h(\Sigma,2)$, it follows that $\Sigma'$ has at most two effective components (i.e. irreducible components of $\Sigma'$ on which $\varphi$ is non-constant). We now split into two cases.

* (There are two effective components $C_1,C_2\subset\Sigma'$.) Since $\varphi|_{C_i}$ has degree $1$, it must be an isomorphism for $i=1,2$. Thus, $s|_{C_i}$ yields a section $s_i\in\ker D^N_{\Sigma,\gamma(t)}$ for $i=1,2$. Since $s$ is not pulled back from $\Sigma$, it follows that $s_1\not\equiv s_2$. Since $C_1$ can be connected to $C_2$ within $\Sigma'$ by a (possibly empty) chain of ghost components, it also follows that there must be a point $z\in\Sigma$ such that $s_1(z) = s_2(z)$. The section $s_1-s_2\in\ker D^N_{\Sigma,\gamma(t)}$ now shows that $\gamma(t)\in\clJ'_{A,g}$. This contradicts $\gamma\in\clB^*$.

* (There is a unique effective component $C\subset\Sigma$.) Let $\psi:\tilde C\to C$ be the normalization and set $\varphi' = \varphi\circ\psi:\tilde C\to\Sigma$. Since $\gamma(t)\not\in\clW_{2,h}(\clJ_{A,g'})$ for $g' = \text{genus}(\tilde C)$, we deduce that $\hat s\circ\psi:\tilde C\to N_\Sigma$ is an embedding. This implies that $\psi$ must be injective and therefore an isomorphism. Thus, $C$ is smooth and $\hat s|_C$ is an embedding. Since $\ker (D^N_{\Sigma,\gamma(t)})_{\varphi'}^-\ne 0$, it follows from $\gamma\in\clB'$ that this vector space must in fact be $1$-dimensional and that $\ker D^N_{\Sigma,\gamma(t)}$ is an isomorphism. Using the inverse function theorem, we can now obtain a sequence $\Sigma_n\subset X$ of $\gamma(t_n)$-curves of genus $g$ in class $A$ converging to $\Sigma$. Arguing as in <cit.>, we can now identify tubular neighborhoods of $\Sigma_n$ for $n\gg 1$ with the normal bundle of $\Sigma$ equipped with the pullback of the almost complex structure $\gamma(t_n)$. Rescaling the images of the embedded curves $\Sigma'_n$ in $N_\Sigma$ to have distance $\frac12$ from the zero section gives a new sequence of embedded curves which are holomorphic with respect to the rescaled versions of $\gamma(t_n)$. The rescalings of the $\gamma(t_n)$ converge to $J_{D^N_{\Sigma,\gamma(t)}}$ and moreover, all these almost complex structures are tamed by a symplectic form for $n\gg 1$ (<cit.>). Therefore, after passing to a subsequence, we can extract a Gromov limit given by a $J_{D^N_{\Sigma,\gamma(t)}}$-holomorphic map $\hat s':\Sigma'\to N_\Sigma$ whose image doesn't lie in the zero section. Since $C$ is the only effective component of $\hat s'$ (since a holomorphic mapping into any normal fiber must be constant), it follows that $\hat s'$ a scalar multiple of $\hat s$. We have therefore exhibited $\hat s$ as a limit of embedded pseudo-holomorphic curves of genus $h$ and class $2[\Sigma]$. Recalling that $\hat s|_C$ is an embedding and applying Remark <ref>(b) shows that we must have $C = \Sigma'$.

We have now succeeded in showing that $\Sigma'$ is smooth. The remaining facts concerning the operator $D^N_{\Sigma,\gamma(t)}$ have already been proved during the course of (b) above.

Although the proof of Lemma <ref> is formally parallel to the proof of Lemma <ref>, it is crucial to note that we use Theorem <ref> to construct the multi-section $s$ over $\Sigma$ because the rescaling argument from <cit.> or Remark <ref>(a) cannot be used unless we already know that $D^N_{\Sigma,\gamma(t)}$ is an isomorphism.

We can now complete the proof of Theorem <ref>. Choose a path $\gamma$ from the Baire subset $\clB^*\cap\clB'\cap\clB''\subset\clP(J_-,J_+)$. (Recall the definition of the Baire set $\clB''$ from Lemma <ref>.) Define the moduli space

\begin{align}\label{2A-h-mod}
\clM_h^*(X,\gamma,2A)\to[-1,1]
\end{align}

consisting of pairs $(t,\Sigma')$, where $t\in[-1,1]$ and $\Sigma'\subset X$ is an embedded $\gamma(t)$-curve of genus $h$ in class $2A$. For each $0\le g\le h$, also consider the moduli spaces

\begin{align}\label{A-g-mod}
\clM_g(X,\gamma,A)\to[-1,1]
\end{align}

consisting of pairs $(t,\Sigma)$, where $t\in[-1,1]$ and $\Sigma\subset X$ is an embedded $\gamma(t)$-curve curve of genus $g$ in class $A$. Both $\clM_h^*(X,\gamma,2A)$ and $\clM_g(X,\gamma,A)$ are oriented $1$-manifolds with boundary over $t = \pm 1$ since $\gamma\in\clB'$. Moreover, $\clM_g(X,\gamma,A)$ is compact by Remark <ref>(b). Since $\gamma\in\clB'\cap\clB^*$, Lemma <ref> shows that the set of points in $(t,\Sigma,\varphi:\Sigma'\to\Sigma)$ with $(t,\Sigma)\in\clM_g(X,\gamma,A)$ for some $g\le h$, $(\Sigma',\varphi)\in\clM_h(\Sigma,2)$ with $\Sigma'$ smooth and

\begin{align}\label{wall-points-along-path}
\ker D^N_{\Sigma,\gamma(t)} = 0,\quad \ker\varphi^*D^N_{\Sigma,\gamma(t)} = 1
\end{align}

forms a finite set. Moreover, $\gamma$ is transverse to the map

\begin{align}\label{relevant-wall}
\clM^2_{{\bf b}^r,\bZ/2\bZ}(\clM_0^*(X,A);\theta,\theta^{\oplus 1+2r})\to\clJ(X,\omega)
\end{align}

at any such point $(t,\Sigma,\varphi:\Sigma'\to\Sigma)$, where we have set $r = 2h-2-2(2g-2)\ge 0$, ${\bf b}^r = ((2),\ldots,(2))$ and $\theta = $ the sign representation of $\bZ/2\bZ$.

Enumerate the times $t$ for which there exists $\varphi:\Sigma'\to\Sigma$ satisfying (<ref>) as

\begin{align}
-1 < t_1 < \cdots < t_k < 1
\end{align}

and, for each $1\le i\le k$, enumerate the intersections with the maps (<ref>) as

\begin{align}
p_{i,j} = (t_i,\Sigma_{i,j}\subset X,\varphi_{i,j}:\Sigma'_{i,j}\to\Sigma_{i,j})
\end{align}

for $1\le j\le \ell_i$, where $\ell_i$ is a positive integer depending on $i$. Theorem <ref> now provides numbers $\epsilon_i>0$ and neighborhoods $\clO_{i,j}$ of $\varphi_{i,j}:\Sigma'_{i,j}\to\Sigma_{i,j}\subset X$ and by shrinking these further we can assume that the products

\begin{align}
\clU_{i,j} = (t_i-\epsilon_i,t_i+\epsilon_i)\times\clO_{i,j}
\end{align}

are all pairwise disjoint. We now make a series of claims.

* The $\bZ$-valued function

\begin{align}
\end{align}

defined on $\clM_g(X,\gamma,A)$ away from $t = t_1,\ldots,t_k$ is locally constant.

Indeed, fix any point $(t,\Sigma)$ such that $t\ne t_i$ for all $1\le i\le k$. Then, $D^N_{\Sigma,\gamma(t)}$ is $2$-rigid and the same is true for all nearby points $(t',\Sigma')$. Thus, any nearby $(t',\Sigma')$ can be connected to $(t,\Sigma)$ by a path of curves with $2$-rigid normal deformation operators and so, $\text{w}_{2,h}(D^N_{\Sigma,\gamma(t)}) = \text{w}_{2,h}(D^N_{\Sigma',\gamma(t')})$.

* The moduli space $\clM_h^*(X,\gamma,2A)\setminus\bigcup_{i,j}\clU_{i,j}$ is compact. Moreover, the restriction of (<ref>) over the complement of $\{t_i\}_{1\le i\le k}$ is proper.

Both assertions follow directly from Lemma <ref>.

* The expression (<ref>) is well-defined with $J = \gamma(t)$ provided $t\in[-1,1]\setminus\{t_1,\ldots,t_k\}$ is a regular value of (<ref>) and each of the maps (<ref>). If $t_i<t'\le t''< t_{i+1}$ are two such regular values (for some $1\le i<k$), then we have the equality

\begin{align}\label{loc-const-Gr}
\text{Gr}_{2A,h}(X,\omega,\gamma(t')) = \text{Gr}_{2A,h}(X,\omega,\gamma(t'')).
\end{align}

Claim (2) shows that the first sum in the expression (<ref>) is well-defined for such a $t$. The remaining sums in (<ref>) are well-defined by Claim (1). For regular values $t'<t''$ in $(t_i,t_{i+1})$, we can now use the cobordisms given by restricting (<ref>) and (<ref>) to $[t',t'']$ and the local constancy statement from Claim (1) to deduce (<ref>).

* In the previous claim, if we instead have $t_i-\epsilon_i<t'<t_i<t''<t_i+\epsilon_i$ for some $1\le i\le k$, then (<ref>) still holds.

By Claim (3), we can assume $t',t''$ are arbitrarily close to $t_i$. For small $|t-t_i|$ and $\Sigma\in\{\Sigma_{i,j}:1\le j\le \ell_i\}$, define $\Sigma(t)$ to be the unique embedded $\gamma(t)$-curve close to $\Sigma$ (obtained by noting that $\ker D^N_{\Sigma,\gamma(t_i)} = 0$ and applying the inverse function theorem). For such a $\Sigma$, define the set $I_\Sigma(i) = \{1\le j\le\ell_i:\Sigma = \Sigma_{i,j}\}$, and note that we have

\begin{align}\label{net-change}
\sum_{j\in I_\Sigma(i)}\text{sgn}(\gamma,t_i;p_{i,j})
=\text{sgn}(D^N_{\Sigma,\gamma(t_i)})\cdot(\text{w}_{2,h}(D^N_{\Sigma(t''),\gamma(t'')}) - \text{w}_{2,h}(D^N_{\Sigma(t'),\gamma(t')}))
\end{align}

where we check orientations by using the identification

\begin{align}
\det(D^N_{\Sigma,\gamma(t_i)})\otimes\det(D^N_{\Sigma,\gamma(t_i)})_{\varphi_{i,j}}^- = \det(\varphi_{i,j}^*D^N_{\Sigma,\gamma(t_i)})
\end{align}

for each $j\in I_\Sigma(i)$. The quantities $\text{sgn}(\gamma,t_i;p_{i,j})$ are as in Definition <ref>. Now recall that the neighborhoods $\clU_{i,j}$ were constructed by applying Theorem <ref> to each point $p_{i,j}\in\clU_{i,j}$ and note that the isotropy group $\Gamma$ is $\bZ/2\bZ$ in all cases. Restrict (<ref>) to $[t',t'']$ and note that this gives a compact $1$-manifold with boundary over the complement of $\bigcup_{i,j}\clU_{i,j}$ by Claim (2). Thus, as in Claim (3), this portion contributes equally to both sides of (<ref>).

For the remaining contribution (coming from $\bigcup_{i,j}\clU_{i,j}$), we see from Theorem <ref> that the first sum in the definition of $\text{Gr}_{2A,h}$ changes by the negative of the left side of (<ref>) as we go from $t'$ to $t''$, while the second sum in the definition of $\text{Gr}_{2A,h}$ changes by the right side of (<ref>) when we go from $t'$ to $t''$. These two changes cancel each other out and so, we again have (<ref>) as desired.

Combining claims (3) and (4) and noting that $\pm1$ are regular values of (<ref>) as well as each of the maps (<ref>) completes the proof of Theorem <ref>.

§ APPLICATION TO THE GOPAKUMAR–VAFA INVARIANTS

In this section, we will show that the invariant from Theorem <ref> coincides with the Gopakumar–Vafa invariant for genus $0$. The comparison is carried out in §<ref> and is an application of the discussion of obstruction bundles in §<ref>. The main result of §<ref> (Theorem <ref>) is stated in greater generality than is needed for the application in §<ref> as it may be of independent interest.

§.§ Obstruction bundles and their Euler classes

Let $C$ be a smooth curve of genus $g$ and let $h\ge g$ and $d\ge 2$ be integers such that the integer

\begin{align}
r = (2h-2)-d(2g-2)
\end{align}

is non-negative.
The moduli stack $\overline\clM_h(C,d)$, consisting of stable holomorphic maps $f:C'\to C$ with the arithmetic genus of $C'$ being $h$ and $f_*[C'] = d[C]$, has complex virtual dimension given by $r$. Moreover, the non-empty open substack $\clM_h(C,d)\subset\overline\clM_h(C,d)$, consisting of those $[f:C'\to C]$ for which the domain $C'$ is smooth, is a complex orbifold of complex dimension $r$.
[Virtual fundamental class]
Define the class

\begin{align}
\normalfont[\overline\clM_h(C,d)]^\text{vir} \in \check{H}_{2r}(\overline\clM_h(C,d),\bQ)
\end{align}

to be the virtual fundamental class of this moduli space as in <cit.>. Note that $\overline\clM_h(C,d)$ is algebraic and so, we do not actually need to distinguish between its Čech and singular (co)homologies.

Now, let $N$ be a rank $2$ complex vector bundle on $C$ with $\deg(N) = 2g - 2$. We are interested in $\bR$-linear Cauchy–Riemann operators on $N$ because $N$ naturally arises as the normal bundle of $J$-curves of genus $g$ in a symplectic Calabi–Yau $3$-fold. Then, for any $\bR$-linear Cauchy–Riemann operator $D$ on $N$, we have

\begin{align}
\text{ind}(D) =2\deg(N) + (2-2g)\cdot\text{rank}(N) = 0
\end{align}

by the Riemann–Roch theorem. For the Cauchy–Riemann operator $D$ and a point $[f:C'\to C]\in\overline\clM_h(C,d)$, we can consider the vector spaces

\begin{align}
\label{new-ker}\ker(f^*D)' &:= \coker(\ker D\xrightarrow{f^*}\ker(f^*D)) \\
\label{new-coker}\coker(f^*D)' &:= \coker(\coker D\xrightarrow{f^*}\coker(f^*D)).
\end{align}

Note that these spaces can also be defined as subspaces of $\ker(f^*D)$ and $\coker(f^*D)$, when $C'$ is smooth, using Remark <ref> and Lemma <ref>.

[Cokernel/obstruction bundle]
The operator $D$ is said to be $(d,h)$-rigid if and only if for all $[f:C'\to C]\in\overline\clM_h(C,d)$, we have

\begin{align}\label{no-new-ker}
\ker(f^*D)' = 0.
\end{align}

In this case, the assignment

\begin{align}\label{new-coker-bundle}
[f:C'\to C]\mapsto (\clN^{d,h}_{C,D})_f := \coker(f^*D)'
\end{align}

defines a rank $2r$ vector bundle $\clN_{C,D}^{d,h}\to\overline\clM_h(C,d)$, which is called the cokernel/obstruction bundle.

Next, define the canonically oriented determinant line of $(f^*D)'$ to be

\begin{align}
\det(f^*D)' &= \det\ker(f^*D)'\otimes\left(\det\coker(f^*D)'\right)^*\\
\end{align}

where $\det(D)$ and $\det(f^*D)$ are the determinant lines of the Cauchy–Riemann operators $D$ and $f^*D$, which are canonically oriented by considering the spectral flow of a homotopy between $D$ and a $\bC$-linear Cauchy–Riemann operator. If $D$ is $(d,h)$–rigid, this gives rise to an orientation of the corresponding cokernel bundle. Accordingly, we have a well-defined virtual Euler number of the cokernel bundle

\begin{align}\label{virt-eu-num}
e_{d,h}(C,D) = \langle \normalfont[\overline\clM_h(C,d)]^\text{vir}, e(\clN^{d,h}_{C,D})\rangle\in\bQ.
\end{align}

More generally, suppose $P$ is a topological space and $\clD = \{D_p\}_{p\in P}$ is a family of real Cauchy–Riemann operators

\begin{equation}
D_p: \Omega^0(C, N) \to \Omega^{0,1}(C, N)
\end{equation}

parametrized by $P$. The family $\clD = \{D_p\}_{p\in P}$ is called continuous if the coefficients of $\{D_p\}_{p\in P}$ (and all their derivatives in the $C$ direction) are continuous as functions on $P\times C$ once we identify the space of real Cauchy–Riemann operators with $\Omega^{0,1}(C, \hom_{\mathbb{R}}(N,N))$ by choosing a reference operator. The notion of smooth family $\clD = \{D_p\}_{p\in P}$ is defined similarly when $P$ is a smooth manifold. It is easy to see that this notion of continuity/smoothness is well-defined.
Let $\hat{\Delta}\subset\overline\clM_h(C,d)\times P$ be the closed substack over which (<ref>) fails, with $\clD$ in place of $D$. Then, the assignment (<ref>), with $\clD$ in place of $D$, gives a well-defined oriented rank $2r$ vector bundle

\begin{align}
\clN^{d,h}_{C,\clD}\to(\overline\clM_h(C,d)\times P)\setminus\hat{\Delta}
\end{align}

which has an Euler class $e(\clN^{d,h}_{C,\clD})\in \check{H}^{2r}((\overline\clM_h(C,d)\times P)\setminus\hat{\Delta},\bQ)$.

[Simple wall crossing]
Let $\clD = \{D_t\}_{t\in [-1,1]}$ be a smooth family of real Cauchy–Riemann operators on $N$. We say that $\clD$ is a simple wall crossing of type $(d,h)$ at $t = 0$ if $\ker D_0 = 0$ and there is a finite set $\Delta\subset\clM_h(C,d)$ such that

* Equation $\eqref{no-new-ker}$ holds on $(\overline\clM_h(C,d)\times[-1,1])\setminus(\Delta\times 0)$ and the vector bundle $\clN^{d,h}_{C,\clD}$ is well-defined here;

* for each $[f:C'\to C]\in\Delta$, the linearized map

\begin{align}\label{linear-wc-iso}
\end{align}

defined in Definition <ref> is an isomorphism.

Note that the set $\Delta$ is assumed to be a subset of the locus $\clM_h(C,d)$ parametrizing holomorphic maps with smooth domains. This is consistent with the Equation (<ref>) in Theorem <ref>. This assumption is sufficient for the application in Section <ref>.

By counting dimensions and indices, it follows that we have

\begin{align}
\dim_\bR\ker(f^*D)' &= 1 \\
\dim_\bR\coker(f^*D)' &= 1 + 2r
\end{align}

over the finite set $\Delta$.
Both sides of (<ref>) are canonically oriented by combining the discussion surrounding equation (<ref>) with the orientation on $\det(f^*D)'$. Thus, to each $[f:C'\to C]\in\Delta$, we can assign a well-defined number

\begin{align}
\normalfont\text{sgn}(\clD,[f:C'\to C])\in\{+1,-1\}.
\end{align}

which is the sign of the isomorphism (<ref>).

We want to compute the change in the virtual Euler number $e_{d,h}(C,D_t)$ as we go from $t<0$ to $t>0$ for a simple wall crossing $\clD$ in terms of isotropy groups of the points in $\Delta$ and the signs $\{\text{sgn}(\clD,p)\}_{p\in\Delta}$. Our main result is the following.
[Change in Euler number]
In the situation of Definition <ref>,

\begin{align}
[-1,1]\setminus\{0\}&\to\bQ \\
t&\mapsto e_{d,h}(C,D_t)
\end{align}

is a locally constant function. Let $e_{d,h}(C,D_\pm)$ denote the value $e_{d,h}(C,D_t)$ for $\pm t>0$. Then, we have the identity

\begin{align}\label{euler-change-formula}
\normalfont e_{d,h}(C,D_+) - e_{d,h}(C,D_-) = \sum_{p\in\Delta}\frac{2\cdot\text{sgn}(\clD,p)}{|\text{Aut}(p)|}.
\end{align}

The local constancy assertion is obvious. The remaining assertion will be proved in the next two lemmas. We continue to use the notation from Definition <ref>.
[Local to global]
For each point $p\in\Delta$, choose an open neighborhood
\begin{align}
\end{align}

whose closure has smooth orbifold boundary $\partial V_p$. Endowing $\partial V_p$ with the boundary orientation from $V_p$ and assuming that the closures of $\{V_p\}_{p\in\Delta}$ are pairwise disjoint, we have the identity

\begin{align}
e_{d,h}(C,D_+) - e_{d,h}(C,D_-) = \sum_{p\in\Delta}\langle[\partial V_p], e(\clN^{d,h}_{C,\clD})\rangle
\end{align}

where $[\partial V_p]$ denotes the standard orbifold fundamental class for each $p\in\Delta$.

Introduce the notation $\clM_{I} := \overline\clM_h(C,d)\times[-1,1]$. It will be enough to show that the identity

\begin{align}
[\overline\clM_h(C,d)]^\text{vir}\times\{+1\} - [\overline\clM_h(C,d)]^\text{vir}\times\{-1\} = \sum_{p\in\Delta}[\partial V_p]
\end{align}

holds in $H_*(\clM_{I}\setminus\bigcup_{p\in\Delta}V_p;\bQ)$. This will follow from <cit.> applied to the space

\begin{align}\label{aux-cobordism}
\clM_{I}\setminus\bigcup_{p\in\Delta}V_p
\end{align}

provided we show that it has an implicit atlas with boundary which, when restricted to the boundary, gives (a) the usual atlas (from section <cit.>) on $[\overline\clM_h(C,d)]^\text{vir}\times\{\pm1\}$ and (b) the standard orbifold atlas on each $V_p$. Constructing such an atlas is straightforward. Indeed, choose open neighborhoods

\begin{align}
V_p\Subset W_p \Subset W'_p\Subset \clM_h(C,d)\times(-1,1)
\end{align}

with $\{W'_p\}_{p\in\Delta}$ still being pairwise disjoint. Endow each $W'_p\setminus V_p$ with the obvious orbifold-with-boundary atlas (with trivial obstruction spaces) as in <cit.> and endow the open subset

\begin{align}
\clM_{I}\setminus\bigcup_{p\in\Delta}\overline W_p
\end{align}

with the restriction of the product atlas (see <cit.>) on $\clM_{I}$. These $1+|\Delta|$ open sets cover the moduli space in question. Over the open overlaps $W'_p\setminus\overline W_p\subset\clM_h(C,d)\times(-1,1)$ – note that there are no triple overlaps – both implicit atlases are equivalent (in the sense of <cit.>). This is because the standard orbifold atlas on $\clM_h(C,d)$ is equivalent to the restriction of the implicit atlas on $\overline\clM_h(C,d)$. Thus, we can combine this cover into an implicit atlas on the space (<ref>) with the desired properties.

[Local contribution]
In the situation of Lemma <ref>, the neighborhoods $V_p$ can be chosen such that their closures are pairwise disjoint and we have

\begin{align}
\normalfont\langle[\partial V_p], e(\clN^{d,h}_{C,\clD})\rangle = \frac{2\cdot\text{sgn}(\clD,p)}{|\text{Aut}(p)|}
\end{align}

for each $p\in\Delta$.

Fix $p = [f:C'\to C]\in\Delta\subset\clM_h(C,d)$. Since $\clM_h(C,d)$ is a smooth orbifold, we can identify a neighborhood $U_p$ of $p$ diffeomorphically with the orbifold $[\bV/\Gamma]$, where $\Gamma = \text{Aut}(C,f)$ is the isotropy group of $p$ with its natural complex representation on $\bV = T_f\clM_h(C,d)$ and the point $p$ is identified with $[0]$. Without loss of generality, we can assume that this neighborhood meets no other points of $\Delta$.

Assume, for the sake of concreteness, that $\text{sgn}(\clD,p) = +1$. This can be achieved by reparametrizing the interval $[-1,1]$ in reverse if necessary. The local chart $[\bV/\Gamma]$ gives a map $\bV\xrightarrow{\nu}\clM_h(C,d)$ which, in turn, yields the following $\Gamma$-equivariant commutative diagram (with the square being a fiber square).

C' [d] [r, hook, "j"] [rr, bend left, "f"]     ' [d, "π"] [r, "ev"]     C
[r, hook, "0"]

Here, $\pi$ is a $\Gamma$-equivariant smooth family of curves and $\text{ev}$ is a $\Gamma$-invariant smooth map which is holomorphic on each fibre of $\pi$. The maps $\pi$ and $\text{ev}$ together with the $\Gamma$-action realize the open embedding $[\bV/\Gamma]\hookrightarrow\clM_h(C,d)$.  We can then define $V_p = [B_\bV/\Gamma]$, where $B_\bV$ is the ball bounded by $S_\bV$, and conclude by Lemma <ref> and noting that $\langle[S_\bV],e(TS_\bV)\rangle = \chi(S_\bV) = 2$. It is useful to note that, for this last argument to work, we do not require the isomorphism (<ref>) to be $\Gamma$-equivariant.

Use the same notations as in Lemma <ref>. For any sufficiently small sphere $S_\bV\subset\bV\times[-1,1]$ centered at $0$ (defined with respect to the orthogonal direct sum of a $\Gamma$-invariant Hermitian inner product on $\bV$ and the standard inner product on $\bR$), we have an isomorphism

\begin{align}\label{tgt-bundle-iso}
(\tilde\nu^*\clN^{d,h}_{C,\clD})|_{S_\bV}\simeq TS_\bV
\end{align}

of oriented vector bundles on $S_\bV$, where $\tilde\nu:\bV\times[-1,1]\to\clM_h(C,d)\times[-1,1]$ is given by $\tilde\nu = \nu\times\text{id}$.

Let us first make the following auxiliary choices.

* A Hermitian metric $(\cdot,\cdot)$ and a compatible $\bC$-linear connection $\nabla$ on $N$.

* A Riemannian metric (and therefore, an area form) on $C'$ whose conformal class coincides with the one on $C'$ induced by $j$.

* A smooth trivialization $\clC' = C'\times\bV$ of the bundle $\pi$. Let $\tilde f:C'\times\bV\to C$ denote the map induced by $\text{ev}$, and set $f_v:=\tilde f(\cdot,v):C'\to C$ for $v\in\bV$. Also, let $\tilde j = (j_v)_{v\in V}$ denote the induced family of almost complex structures on $C'$.

* A smooth family of isomorphisms

\begin{align}
\end{align}

We now have the following smooth family of Cauchy–Riemann operators on $N$ parametrized by $(v,t)\in\bV\times[-1,1]$

\begin{align}
D_{v,t}:L^2_1(C',f^*N)\to L^2(C',\Lambda^{0,1}T^*_{C',j_0}\otimes_\bC f^*N)
\end{align}

defined by pulling back the operator $D_t$ on $f_v^*N$ to an operator on $f^*N$ by using the $\nabla$-parallel transport along the paths $\tau\in[0,1]\mapsto f_{\tau v}(z)\in C$ for each $z\in C'$ and the isomorphism $I_v^{-1}$. Obviously, we have $D_{0,0} = f^*D_0$ on smooth sections. Since $\ker D_0 = \coker D_0 = 0$ (and this will continue to hold for small $t$), we have an obvious isomorphism

\begin{align}
\coker D_{v,t}\simeq (\tilde\nu^*\clN^{d,h}_{C,\clD})_{v,t}
\end{align}

for small $(v,t)\ne (0,0)$. Orient $A = \ker(f^*D_0)'$ and $B = \coker(f^*D_0)'$ so that the induced orientation on $\det(f^*D_0)'$ is the canonical one from Definition <ref>. Define the bounded linear map

\begin{align}
R:\text{im}\,D_{0,0}\to(\ker D_{0,0})^\perp
\end{align}

to be the inverse of $D_{0,0}|_{(\ker D_{0,0})^\perp}$, with $(\ker D_{0,0})^\perp\subset L^2_1$ denoting the $L^2$ orthogonal complement of $\ker D_{0,0}$. Let $\Pi_\text{im}:L^2\to\text{im}\,D_{0,0}$ be the orthogonal projection and let $\Pi_\coker$ be the quotient projection onto the cokernel. For small $(v,t)$, the quantity $\|1 - \Pi_\text{im}D_{v,t}R\|$ is small on $\text{im}\,D_{0,0}$ and so, we can define the map

\begin{align}
R_{v,t} = R(\Pi_\text{im}D_{v,t}R)^{-1}:\text{im}\,D_{0,0}\to(\ker D_{0,0})^\perp
\end{align}

which is the inverse of $\Pi_\text{im}D_{v,t}|_{(\ker D_{0,0})^\perp}$. It is immediate that $\ker( \Pi_\text{im}D_{v,t})$ is given by the graph of the map $- R_{v,t}\Pi_\text{im}D_{v,t}:\ker D_{0,0}\to(\ker D_{0,0})^\perp$. Define the smooth family of linear maps

\begin{align}
L_{v,t}&:\ker D_{0,0}\to \coker D_{0,0}\\
L_{v,t} &= \Pi_\coker D_{v,t}(1 - R_{v,t}\Pi_\text{im}D_{v,t})
\end{align}

for small $(v,t)$. We now observe that that the natural maps $\ker L_{v,t} \xrightarrow{\simeq} \ker D_{v,t}$ and $\coker L_{v,t} \xrightarrow{\simeq} \coker D_{v,t}$ are isomorphisms. It follows (using the identifications $A = \ker D_{0,0}$ and $B = \coker D_{0,0}$) that the oriented vector bundle $\tilde\nu^*\clN^{d,h}_{C,\clD}$ is given, on a punctured neighborhood of $(0,0)$, by the assignment

\begin{align}
(v,t)\mapsto\coker(L_{v,t}:A\to B)
\end{align}

with the bundle orientation derived from the orientations already chosen on $A$ and $B$. Note that $L_{0,0} = 0$ and that the first order Taylor expansion of $L_{v,t}$ about $(0,0)$ is given by the positively oriented linear isomorphism

\begin{align}
\bV\oplus\bR_t\xrightarrow{\simeq}\text{Hom}(A,B)
\end{align}

from (<ref>). Fixing a unitary $\Gamma$-invariant metric on $\bV$ and restricting to any sufficiently small sphere $S_\bV\subset\bV\times[-1,1]$ centred at the origin, we can discard (i.e. homotope away) the higher order terms from the Taylor expansion of $L_{v,t}$. It follows that the fiber of the vector bundle at a point $(v_0,t_0)\in S_\bV$ is identified with the quotient of the oriented vector space $\bV\oplus\bR_t$ by the oriented $1$-dimensional space spanned by $(v_0,t_0)$. But this is simply the standard description of the (oriented) tangent bundle of the sphere $S_\bV\subset\bV\oplus\bR_t$, once we replace “quotient" by “orthogonal complement" and (<ref>) now follows.

Note that Lemma <ref> holds for any $d$ and $h$. It is ultimately a consequence of the isomorphism (<ref>) via the finite dimensional reduction argument presented above.

A coordinate invariant way of summarizing the above proof is the following. The bundle $\clN^{d,h}_{C,\clD}$, initially defined on $(\overline\clM_h(C,d)\times[-1,1])\setminus(\Delta\times 0)$, extends to the real oriented blow-up of $\overline\clM_h(C,d)\times[-1,1]$ along the smooth points $\Delta\times 0$ as a vector bundle $\overline\clN^{d,h}_{C,\clD}$. Moreover, for each point $p\in\Delta$, we have a natural vector bundle isomorphism with orientation $\normalfont\text{sgn}(\clD,p)$

\begin{align}
\overline\clN^{d,h}_{C,\clD}|_{\bS_p} = T\bS_p
\end{align}

over $\bS_p$, the exceptional boundary component created by blowing up at $p$. Now, a direct cobordism argument as in Lemma <ref>, applied to the real oriented blow-up $\normalfont\text{Bl}^{+}_{\Delta\times 0}(\overline\clM_h(C,d)\times[-1,1])$ gives (<ref>).

§.§ Comparision to Gopakumar–Vafa invariants

In this subsection, we identify Taubes' Gromov invariant in dimension $6$ (Equation (<ref>)) with the Gopakumar–Vafa invariants in the case of genus $0$ and class $2A$ for $A\in H_2(X,\bZ)$ primitive. We omit the underlying Calabi–Yau $3$-fold $(X,\omega)$ from the notation.

The invariant $\normalfont\text{Gr}_{2A,0}$ satisfies the Gopakumar–Vafa formula. More precisely, define, for super-rigid $J$,

\begin{align}
\normalfont\text{GW}_{A,0} &:= \normalfont\text{Gr}_{A,0} := \sum_{C :\,A,0} \text{sgn}(D^N_{C,J}) \\
\normalfont \text{GW}_{2A,0} &:= \normalfont \sum_{C':\,2A,0}\text{sgn}(D^N_{C',J}) + \sum_{C:\,A,0}\text{sgn}(D^N_{C,J})e_{2,0}(C,D^N_{C,J})
\end{align}

where $e_{2,0}$ denotes the virtual Euler number as defined in (<ref>) and the summations follow the notation of (<ref>). Then, we have the following relation between $\normalfont\text{GW}$ and $\normalfont\text{Gr}$.

\begin{align}
\normalfont \text{GW}_{2A,0} =  \text{Gr}_{2A,0} + \frac1{2^3}\cdot\normalfont \text{Gr}_{A,0}.
\end{align}

From the definitions, it is clear that it will suffice to prove that

\begin{align}
e_{2,0}(C,D^N_{C,J}) - \frac1{2^3} = \text{w}_{2,0}(D^N_{C,J}).
\end{align}

Let $\bar\partial$ denote an operator on $N_C$ which is conjugate to the standard operator on $\clO(-1)^{\oplus2}\to\bP^1$. The Aspinwall–Morrison formula (see, for example <cit.>) shows that we have the identity

\begin{align}
e_{2,0}(C,\bar\partial) = \frac1{2^3}.
\end{align}

Thus, we are left to prove that the difference of Euler numbers is given by the linear wall crossing invariant $\text{w}_{2,0}$. But this is immediate from the Definition <ref> and Theorem <ref> once we choose a path $\gamma\in\clP^\pitchfork(D^N_{C,J},\delbar)$ in $\clC\clR_\bR(N_C)$ to compute $\text{w}_{2,0}$.

author=Boden, Hans U,
author=Herald, Christopher M,
title=The $\SU(3)$ Casson invariant for integral homology
journal=Journal of Differential Geometry,

author=Bryan, Jim,
author=Pandharipande, Rahul,
title=BPS states of curves in Calabi-Yau 3-folds,
journal=Geom. Topol.,

author=Cox, David A,
author=Katz, Sheldon,
title=Mirror symmetry and algebraic geometry,
publisher=American Mathematical Soc.,

author=Doan, Aleksander,
author=Ionel, Eleny-Nicoleta,
author=Walpuski, Thomas,
title=The Gopakumar-Vafa finiteness conjecture,
journal=arXiv preprint arXiv:2103.08221,

author=Donaldson, Simon,
title=Deformations of multivalued harmonic functions,
journal=arXiv preprint arXiv:1912.08274,

author=Doan, Aleksander,
author=Walpuski, Thomas,
title=Counting embedded curves in symplectic 6-manifolds,
journal=arXiv preprint arXiv:1910.12338,

author=Doan, Aleksander,
author=Walpuski, Thomas,
title=On counting associative submanifolds and Seiberg-Witten
journal=Pure Appl. Math. Q.,

author=Doan, Aleksander,
author=Walpuski, Thomas,
title=Equivariant Brill-Noether theory for elliptic operators and
super-rigidity of $J$-holomorphic maps,

author=Doan, Aleksander,
author=Walpuski, Thomas,
title=Castelnuovo's bound and rigidity in almost complex geometry,
journal=Advances in Mathematics,

author=Eftekhary, Eaman,
title=On finiteness and rigidity of J-holomorphic curves in
symplectic three-folds,
journal=Advances in Mathematics,

author=Eftekhary, Eaman,
title=Counting periodic orbits of vector fields over smooth closed
journal=arXiv preprint arXiv:2012.01808,

author=Gopakumar, Rajesh,
author=Vafa, Cumrun,
title=M-theory and topological strings–II,
journal=arXiv preprint hep-th,

author=Hatcher, Allen,
title=Algebraic topology,
publisher=Cambridge University Press, Cambridge,
ISBN=0-521-79160-X; 0-521-79540-0,

author=Hosono, Shinobu,
author=Saito, Masa-Hiko,
author=Takahashi, Atsushi,
title=Relative Lefschetz action and BPS state counting,
journal=International Mathematics Research Notices,

author=Ionel, Eleny-Nicoleta,
author=Parker, Thomas H.,
title=The Gopakumar-Vafa formula for symplectic manifolds,
journal=Ann. of Math. (2),

author=Katz, Sheldon,
title=Genus zero Gopakumar-Vafa invariants of contractible curves,
journal=Journal of Differential Geometry,

author=Kiem, Young-Hoon,
author=Li, Jun,
title=Categorification of Donaldson-Thomas invariants via perverse
journal=arXiv preprint arXiv:1212.6444,

author=Mrowka, Tomasz,
author=Ruberman, Daniel,
author=Saveliev, Nikolai,
title=Seiberg–Witten equations, end-periodic Dirac operators, and
a lift of Rohlin's invariant,
journal=Journal of Differential Geometry,

author=McDuff, Dusa,
author=Salamon, Dietmar,
title=$J$-holomorphic curves and symplectic topology,
series=American Mathematical Society Colloquium Publications,
publisher=American Mathematical Society, Providence, RI,

author=Maulik, Davesh,
author=Toda, Yukinobu,
title=Gopakumar–Vafa invariants via vanishing cycles,
journal=Inventiones mathematicae,

author=Pardon, John,
title=An algebraic approach to virtual fundamental cycles on moduli
spaces of pseudo-holomorphic curves,
journal=Geom. Topol.,

author=Swaminathan, Mohan,
title=Rel–${C}^\infty$ structures on Gromov–Witten moduli
journal=Journal of Symplectic Geometry,

author=Taubes, Clifford Henry,
title=Counting pseudo-holomorphic submanifolds in dimension 4 [
MR1438194 (97k:58029)],
booktitle=Seiberg Witten and Gromov invariants for symplectic
series=First Int. Press Lect. Ser.,
publisher=Int. Press, Somerville, MA,

author=Voisin, Claire,
title=A mathematical proof of a formula of Aspinwall and Morrison,
journal=Compositio Math.,

author=Walker, Kevin,
title=An extension of Casson's invariant,
series=Annals of Mathematics Studies,
publisher=Princeton University Press, Princeton, NJ,

author=Wendl, Chris,
title=Transversality and super-rigidity for multiply covered
holomorphic curves,

author=Zinger, Aleksey,
title=A comparison theorem for Gromov–Witten invariants in the
symplectic category,
journal=Advances in Mathematics,