In Quantum Field Theory and Jones Polynomial (equation 2.16), Witten used a formula relating the APS eta-invariant to the Chern-Simons action. Witten claimed that it is derived from the Atiyah-Patodi-Singer index theorem. I cannot find any clue how one can derive that formula from APS index theorem.
In the following, I will briefly explain equation 2.19 in that paper, and will write the Atiyah-Patodi-Singer index theorem. Please help me figure out how one can derive that equation from APS index theorem.
Let $Y$ be a closed three dimensional manifold. Let $G$ be a compact simple gauge group, whose Lie algebra is denoted by $\mathfrak{g}$. Let $E$ be a $G$-bundle over $Y$, with connection $1$-form $A\in\Omega^{1}(Y,\mathfrak{g})$. The Chern-Simons action is given by
$$I[A]=\frac{1}{4\pi}\int_{Y}\mathrm{Tr}\left(A\wedge dA+\frac{2}{3}A\wedge A\wedge A\right).$$
Let $D_{A}$ be the covariant derivative. Then, one is interested in the operator
$$L=\bigg( \begin{matrix} \ast D_{A}&-D_{A}\ast\\D_{A}\ast&0 \end{matrix} \bigg).$$
To be specific, one is interested in $L_{-}$, the restriction of $L$ on odd forms, i.e.
$$L_{-}=L|_{\Omega^{1}(Y)\oplus\Omega^{3}(Y)}.$$
One defines its eta-invariant
$$\eta_{L_{-}}(A)=\lim_{s\rightarrow 0}\sum_{j}\frac{\mathrm{sign}(v_{j})}{|v_{j}|^{s}}$$
where $v_{j}$ are non-zero eigenvalues of the operator $L_{-}$.
Similarly, one defines the eta-invariant for the trivial gauge $A=0$, denoted by $\eta_{L_{-}}(0)$. With this trivial gauge, one is interested in the operator
$$L=\bigg( \begin{matrix} \ast d&-d\ast\\d\ast&0 \end{matrix} \bigg),$$
restricted on odd forms.
Equation 2.16 in Quantum Field Theory and Jones Polynomial:
$$\frac{1}{4}\left(\eta_{L_{-}}(A)-\eta_{L_{-}}(0)\right)=\frac{c_{2}(G)}{2\pi}I[A]$$
Witten claimed that this is a result from Atiyah-Patodi-Singer index theorem.
The original statement of APS index theorem is from Spectral Asymmetry and Riemannian Geometry I, which is very hard to read for physics students. In the following, I copy the statement of APS index theorem from Aspects of Boundary Problems in Analysis and Geometry, which is easier to read.
Let the closed three dimensional manifold $Y$ be the boundary of a compact, oriented, four dimensional Riemannian manifold $M$, i,e, $\partial M=Y$. Let $S(M)$ be a spin bundle over $M$, then one has the splitting $S(M)=S^{+}(M)\oplus S^{-}(M)$ into chiral halves. Let $E$ be a Hermitian vector bundles over $M$. The twisted Dirac operator on $M$ is defined as
$$\mathcal{D}=\bigg( \begin{matrix} 0&D^{+}\\D^{-}&0 \end{matrix} \bigg),$$
with
$$D^{+}:\Gamma(M,S^{+}(M)\otimes E)\rightarrow\Gamma(M,S^{-}(M)\otimes E)$$
$$D^{-}:\Gamma(M,S^{-}(M)\otimes E)\rightarrow\Gamma(M,S^{+}(M)\otimes E)$$
where $\Gamma(M,S^{\pm}(M)\otimes E)$ is the set of sections of the bundle $S^{\pm}(M)\otimes E$.
In addition, one assumes the following conditions:
$M$ has a collar neighborhood $N=[0,1)_{s}\times Y$ near $Y$, where the metric is a product
$$g=ds^{2}+h$$
with $h$ a metric on $Y$.
Denote the space of square-integrable spinors on $Y$ by $L^{2}(Y,S(Y))$. Near the boundary $Y$, the Dirac operator $\mathcal{D}$ is of product type on the collar of the following form:
$$\mathcal{D}=\Gamma^{s}(\partial_{s}+D_{Y})$$
where $\Gamma^{s}:S^{\pm}(N)\otimes E|_{N}\rightarrow S^{\mp}(N)\otimes E|_{N}$ is unitary mapping
$$L^{2}(Y,S(Y)\otimes E|_{Y})\rightarrow L^{2}(Y,S(Y)\otimes E|_{Y})$$
of spinors on $Y$, and
$$D_{Y}:\Gamma(Y,S(Y)\otimes E|_{Y})\rightarrow\Gamma(Y,S(Y)\otimes E|_{Y})$$
is the self-adjoint Dirac operator on $Y$.
Denote the APS eta-invariant for $D_{Y}$ by
$$\eta_{D_{Y}}(s)=\sum_{\lambda\in\mathrm{spec}(D_{Y})\backslash\left\{0\right\}}m_{\lambda}\frac{\mathrm{sign}(\lambda)}{|\lambda|^{s}}$$
where $m_{\lambda}$ is the multiplicity of the eigenvalue $\lambda$.
Let $\widehat{M}$ be the non-compact elongation of $M$ defined as follows:
$$\widehat{M}=(-\infty,0]_{s}\times Y\cup_{\partial M}M$$
One denotes the extension of $D_{M}$ on $\widehat{M}$ by $\widehat{D}$.
Atiyah-Padoti-Singer:
$$\mathrm{ind}(\widehat{D})=\int_{M}\hat{A}(TM)\mathrm{ch}(E)-\frac{1}{2}\left(\eta(D_{Y})+\dim\ker D_{Y}\right)$$
$$=\frac{-1}{8\pi^{2}}\int_{M}\mathrm{Tr}\left(F\wedge F\right)+\frac{\dim E}{192\pi^{2}}\int_{M}\mathrm{Tr}\left(R\wedge R\right)-\frac{1}{2}\left(\eta(D_{Y})+\dim\ker D_{Y}\right)$$
Please tell me how I can derive Witten's formula (2.16) from the above APS index formula. The quadratic Casimir $c_{2}(G)$ is suppposed to come from replacing the trace in the adjoint representation by trace in the fundamental representation in the Chern-Simons action. However, from the APS index formula, I cannot see anything in the adjoint representation.
I've seen some "physical" derivations of the formula (2,16) from Gauge Dependence of the Eta-Function in Chern-Simons Field Theory and the Vilkovisky-DeWitt Correction, and Perturbative Expansion of Chern-Simons Theory with Noncompact Gauge Group, but they made me even more confused.
What is even worse, I found a more genetic formula generalizing Witten's formula (2.16) from Lectures on Quantization of Gauge Systems (equation 60 iin page 53) and Computer Calculation of Witten's 3-Manifold Invariant (equation 1.31 in page 86).
Also, in this physics paper Global Symmetries, Counterterms, and Duality in Chern-Simons Matter Theories with Orthogonal Gauge Groups (equation 4.2 in page 33), the APS index theorem looks very different from the original one, with a factor of the quadratic Casimir.
Please tell me where this second order Casimir is coming from.