diff --git "a/data_all_eng_slimpj/shuffled/split2/finalzzhdns" "b/data_all_eng_slimpj/shuffled/split2/finalzzhdns" new file mode 100644--- /dev/null +++ "b/data_all_eng_slimpj/shuffled/split2/finalzzhdns" @@ -0,0 +1,5 @@ +{"text":"\\section{Introduction}\n\nAssume to be given a vector field $X$ in a $m$ dimensional manifold $M$, and an equilibrium $e$ of $X$. Once chosen a local atlas $(x_1,..,x_m): U \\subset M \\to {\\mathbb R}^m$, the linearization of $X$ at $e$ is the linear system\n\\begin{equation}\\label{linear system}\n\\dot x = JX_{e} \\, x, \\qquad \\text{where} \\quad JX_{e} = \\begin{pmatrix}\n \\frac{\\partial X_1}{\\partial x_1} (e) & \\cdots & \\frac{\\partial X_1}{\\partial x_m} (e) \\\\\n \\vdots & \\ddots & \\vdots \\\\\n \\frac{\\partial X_m}{\\partial x_1} (e) & \\cdots & \\frac{\\partial X_m}{\\partial x_m} (e) \\\\\n\\end{pmatrix}.\n\\end{equation}\nAmong equilibria, the \\emph{hyperbolic} equilibria (those for which the spectrum of $JX_{e}$ has no eigenvalues with zero real part) are particularly important, are generic, and the linear system \\eqref{linear system} is topologically conjugate to the original one in a neighbourhood of the equilibrium \\cite{1960.PAMS.Hartman, 1961.D.Grobman}. In these cases the Jordan blocks of the matrix $JX_{e}$ have a very mild effect on the quantitative form of solutions (secular terms), and no effect on the qualitative structure of solutions. It follows that hyperbolic equilibria can be classified using only the spectral decomposition of the matrix $JX_{e}$. In particular every equilibrium can be given an inertia-type decomposition using the names \\emph{stable} and \\emph{unstable} to indicate the sign of the eigenvalues and \\emph{node} and \\emph{focus} to indicate wether the eigenvalues are complex or real. \n\nIn this article we classify hyperbolic equilibria using the symbols\n\\[\nf_\\beta^\\alpha n_\\delta^\\gamma, \\qquad \\text{where} \\quad \\alpha,\\beta,\\gamma,\\delta \\in \\mathbb N.\n\\]\nWith $f^\\alpha_\\beta$ we indicate the direct sum of $\\alpha$ unstable foci and $\\beta$ stable foci, with the symbol $n^\\gamma_\\delta$ we indicate the direct sum of $\\gamma$ unstable nodes and $\\delta$ stable nodes. Of course $2 \\alpha + 2\\beta + \\gamma +\\delta = m$, the dimension of the phase space. For the sake of clarity, in classical treaties the name stable node is typically referred to what we call stable double node $n_2$, the name unstable node to what we call unstable double node $n^2$, and the name saddle to what we call $n^1_1$, the direct product of a 1-dimensional stable and a 1-dimensional unstable node. We give the following definition.\n\\begin{defi}\nGiven a vector field $X$ and a hyperbolic equilibrium $e$, let\n\\begin{itemize}\n\\item $\\alpha$ be the number of couples of complex conjugate eigenvalues of $JX_{e}$ with positive real part; \n\\item $\\beta$ be the number of couples of complex conjugate eigenvalues of $JX_{e}$ with negative real part; \n\\item $\\gamma$ be the number of positive real eigenvalues of $JX_{e}$;\n\\item $\\delta$ be the number of negative real eigenvalues of $JX_{e}$.\n\\end{itemize}\nWe call the numbers $\\alpha, \\beta,\\gamma,\\delta$ \\emph{spectral indices}, and we call the symbol $f_\\beta^\\alpha n_\\delta^\\gamma$ \\emph{spectral type} of $e$.\n\\end{defi}\n\nThe investigation of the spectral type of an equilibrium in dimension 2 is trivial. In fact the linearisation of $X$ at $e$ yields a $2\\times 2$ matrix whose characteristic polynomial is $p(\\lambda) = \\lambda^2 - d_1 \\lambda + d_2$ where $d_1,d_2$ are the principal invariants of $JX_e$, that is $d_1 = \\tr JX_{e}$ and $d_2 = \\det JX_{e}$. The spectral type can be classified in the space of invariants in the well known diagram in Figure~\\ref{Marginal2}.\n\\begin{figure}\n\\begin{center}\n\\includegraphics[width=7cm]{Marginal2.pdf}\n\\end{center}\n\\caption{The decomposition of the space of invariants $d_1$ (the trace) and $d_2$ (the determinant) associated to the equilibrium of a 2 degrees of freedom dynamical system. In each open set the spectral type of the equilibrium is specified.}\\label{Marginal2}\n\\end{figure}\nIn this diagram the red half-line is the semi-algebraic set $\\mathcal{R} = \\{(d_1,d_2) \\,|\\, d_1 = 0, d_2 > 0\\}$, and it corresponds to the case in which $JX_{e}$ has a conjugate couple of non-zero purely imaginary eigenvalues. If we slightly move the principal invariants of $JX_{e}$ from right to left across such line, the sign of the real part of the two complex conjugate eigenvalues changes from positive to negative, meaning that the spectral type of the equilibrium changes from $f^1$ (unstable focus) to $f_1$ (stable focus). This event is called \\emph{Hopf bifurcation}.\n\nThe blue line is the algebraic set $\\mathcal{Z} = \\{(d_1,d_2) \\,|\\, d_2 = 0\\}$, and it corresponds to the event of zero being an eigenvalue of $JX_{e}$. If the principal invariants of $JX_{e}$ slightly move across such line the sign of one real eigenvalue of $JX_{e}$ changes from positive to negative or vice-versa, meaning that the spectral type of the equilibrium changes from $n^2$ (unstable node) or $n_2$ (stable node) to $n_1^1$ (saddle). This event is called \\emph{saddle-node bifurcation}.\n\nThe green curve is the algebraic set $\\mathcal{D} = \\{(d_1,d_2) \\,|\\, d_1^2 -4 d_2 = 0\\}$, where $d_1^2 -4 d_2$ is the discriminant of the polynomial $p$, and it corresponds to the event of $p$ having a double root in the real line. If the principal invariants of $JX_{e}$ slightly move across such curve, two real eigenvalues with same sign become a double real eigenvalue with same sign and then transform into a couple of two complex conjugate eigenvalues with real part having the same sign of the double root (and hence same sign of the two distinct eigenvalues). This means that the spectral type of the equilibrium changes from $f^1$ to $n^2$ or from $f_1$ to $n_2$. This event is called \\emph{focus-node bifurcation}.\n\nThe same type of analysis does not seem to have been carried out for higher dimensional systems, and in the literature it is possible to find only partial results, focussing on stability, which go under the name of Routh-Hurwitz conditions \\cite{1895.MA.Hurwitz, 1877.Routh} (see also \\cite{1971.JIMA.Barnett, 1991.CSSP.Anagnost.Desoer, 1992.CSM.Clark}).\n\nIn this article we set the analytical framework for a spectral analysis (Section~\\ref{formal conditions}) and we perform a throughout investigation of the 3 and 4 dimensional cases, where the expressions are simple enough to be written and the results can be pictorially represented (Sections~\\ref{3-dimensional case} and \\ref{4-dimensional case}). The general expressions in higher dimensional cases become cumbersome (in Section~\\ref{5 and 6 dimensional case} we show their aspect in dimension 5 and 6), and the geometric representation impossible. In Section~\\ref{non-genericity} we discuss typical non-generic situation and their effect on our approach. In Section~\\ref{7} we use Sturm's sequence and residue theorem to analytically compute the spectral indices. The general formulas, or even better the procedure to compute them, can be used in particular systems depending on few significant parameters, and gives a representation of the bifurcations of the system. To illustrate this fact we devote the last section.\n\n\\section{The formal conditions}\\label{formal conditions}\n\nConsider an equilibrium $e$ of a vector field $X$, and consider the characteristic polynomial of $JX_{e}$, which is the polynomial\n\\begin{equation}\\label{car pol}\np(\\lambda) = (-1)^m \\lambda^m + (-1)^{m-1} d_1 \\lambda^{m-1} + \\cdots - d_{m-1} \\lambda + d_m.\n\\end{equation}\nwhere $d_1 = \\tr JX_e,...,d_m = \\det JX_e$ are the principal invariants of the matrix $JX_e$. To every choice of principal invariants $(d_1,....,d_m)$ there corresponds a polynomial $p$ (the characteristic polynomial) and a family of roots of $p$ (the eigenvalues), that is a definite spectrum of $JX_{e}$, that is a definite spectral type of the equilibrium $e$. We will abuse the terminology and refer to \\emph{the spectral type of the point $(d_1,...,d_m)$} in the space of invariants.\n\nA change in spectral type of $e$ can take place only when very specific events take place. These events define algebraic varieties that are stratified varieties. Such algebraic varieties decompose the space of invariants in domains. We call \\emph{marginal} all the points $(d_1,...,d_m)$ of the space of invariants at which a change of spectral type is taking place or, in other words, any point at the boundary of domains whose points have a given spectral type. The generic elementary changes in the spectral type for the equilibrium $e$ are all and only one of the following:\n\\begin{itemize}\n\\item[(z)] a single real root changes sign, which corresponds to the change of spectral type\n\\[\nf^\\alpha_\\beta n^{\\gamma+1}_\\delta \\leftrightarrow f^\\alpha_\\beta n^\\gamma_{\\delta+1};\n\\]\n\\item[(r)] the real part of two complex conjugate roots changes sign, which corresponds to the change of spectral type\n\\[\nf^{\\alpha+1}_\\beta n^\\gamma_\\delta \\leftrightarrow f^\\alpha_{\\beta+1} n^\\gamma_\\delta;\n\\]\n\n\\item[(d)] two complex conjugate roots collide in the real axis on a non-zero real number, and then separate into two real roots or viceversa, which corresponds to one of the two possible changes of spectral type, depending on the sign of the real part of the roots \n\\[\nf^{\\alpha+1}_\\beta n^\\gamma_\\delta \\leftrightarrow f^\\alpha_\\beta n^{\\gamma+2}_\\delta \\qquad \\text{or} \\qquad f^\\alpha_{\\beta+1} n^\\gamma_\\delta \\leftrightarrow f^\\alpha_\\beta n^\\gamma_{\\delta+2}.\n\\]\n\\end{itemize}\n\nCondition (d) should be divided in two conditions: (d$^+$), corresponding to bifurcation $f^{\\alpha+1}_\\beta n^\\gamma_\\delta \\leftrightarrow f^\\alpha_\\beta n^{\\gamma+2}_\\delta$ and (d$^-$), corresponding to bifurcation $f^\\alpha_{\\beta+1} n^\\gamma_\\delta \\leftrightarrow f^\\alpha_\\beta n^\\gamma_{\\delta+2}$. We will briefly address this issue at the end of this section. We prefer to keep this analysis out of the picture for clarity.\n\nIn each of these situation a very specific event must take place. The case (z) is particularly simple to treat. At the marginality corresponding to a bifurcation in which a root changes sign, zero must be a root of the characteristic polynomial $p$, and hence the function $\\zeta(d_1,...,d_m) = d_m$ must vanish. We denote\n\\[\n\\mathcal Z = \\{(d_1,...,d_m) \\in {\\mathbb R}^m \\,|\\, \\zeta(d_1,...,d_m)= 0\\}.\n\\]\nThis condition gives a hyperplane in invariant space which separates domains in which the spectral type of the equilibrium changes according to (z).\n\nCase (d) is more involved. This type of bifurcation takes place when the characteristic polynomial has a double real root, which can happen only if the function $\\delta(d_1,...,d_m) = \\dsc(p)$, the discriminant of the polynomial $p$, vanishes. In this case the relevant algebraic variety $\\mathcal D$ is a subvariety of\n\\[\n\\widetilde{\\mathcal D} = \\{(d_1,...,d_m) \\in \\mathbb R^m \\,|\\, \\delta(d_1,...,d_m) = 0\\}.\n\\]\nThe reason for being a subvariety is due to the fact that multiple roots of $p$ could be outside the real axis. Such spurious solutions are strata of the variety $\\widetilde{\\mathcal D}$ which have higher codimension, and can be easily distinguished from the true marginal points (they can be so easily distinguished that they are often overseen). We will see in the case $n= 4$ that the marginal variety $\\mathcal D$ differs form $\\widetilde{\\mathcal D}$ for a 1 dimensional curve which is the analogous of the thread emanating from the swallowtail singularity. One can formally define the marginal region $\\mathcal D$ as the closure of $\\widetilde{\\mathcal D}^{m-1}$, where $\\widetilde{\\mathcal D}^{m-1}$ is the union of all $m-1$ dimensional strata of $\\widetilde{\\mathcal D}$ (see \\cite{2012.Arnold.Gusein-Zade.Varchenko.1} for a discussion on stratifications).\n\nThe bifurcation of type (r) is the most complicate to treat. If we are at such marginality then the characteristic polynomial $p$ has two conjugate, purely imaginary roots, that we indicate $i \\mu$, $-i \\mu$, with $\\mu$ real and non-zero. Let us denote\n\\begin{equation}\\label{pr pi}\n\\begin{cases}\np^r(\\mu) = d_m - d_{m-2} \\mu^2 + d_{m-4} \\mu^4 + \\cdots = \\sum_{j = 0}^{\\lfloor m\/2 \\rfloor} (-1)^j d_{m-2j } \\mu^{2j} \\\\[5pt]\np^i(\\mu) = d_{m-1} - d_{m-3} \\mu^2 + d_{m-5} \\mu^4 + \\cdots = \\sum_{j = 0}^{\\lfloor m\/2 \\rfloor} (-1)^j d_{m-1-2j} \\mu^{2j}.\n\\end{cases}\n\\end{equation}\nthe two polynomials such that $p(i \\mu) = p^r(\\mu) - i \\mu p^i(\\mu)$ (in these expressions we agree that $d_0 = 1$, and $\\lfloor m\/2 \\rfloor$ indicates the integer part of $m\/2$). These two polynomials have degrees\n\\[\n\\deg (p^r) = \n\\left[\\begin{matrix}\nm &\\text{ if } m \\text{ is even}\\\\\nm-1 &\\text{ if } m \\text{ is odd},\n\\end{matrix}\\right.\n\\qquad \n\\deg(p^i) = \\left[\\begin{matrix}\nm-2 & \\text{ if } m \\text{ is even}\\\\\nm-1 & \\text{ if } m \\text{ is odd}.\n\\end{matrix}\\right.\n\\]\n\nAt marginal points of type (r) the two polynomials $p^r$ and $p^i$ must have two common real roots $\\pm \\mu$. Unfortunately, both polynomials are in the variable $\\mu^2$, and hence a codimension one condition is that these two polynomials have two common real solution or that they have two complex conjugate purely imaginary solutions. The polynomials $p^r$, $p^i$ have common roots precisely when the function $\\widetilde\\rho(d_1,...,d_m) = \\res(p^r,p^i)$, the resultant of the two polynomials, vanishes. The above mentioned fact implies that, generically, it is not the entire variety\n\\[\n\\widetilde{\\mathcal R} = \\{ (d_1,...,d_m) \\in \\mathbb R^m \\,|\\, \\widetilde\\rho(d_1,....,d_m) = 0\\}\n\\]\nwhich corresponds to the marginality at exam, but only the semialgebraic variety that corresponds to a common double \\emph{real} root of the polynomials $p^r$, $p^i$. \n\nWe can rephrase the considerations above using the two polynomials $q^r(\\nu)$ and $q^i(\\nu)$ such that $p^r(\\mu) = q^r(\\mu^2)$ and $p^i(\\mu) = q^i(\\mu^2)$. The two polynomials are\n\\begin{equation}\\label{qr qi}\nq^r(\\nu) = \\sum_{j = 0}^{\\lfloor m\/2 \\rfloor} (-1)^j d_{m-2j} \\nu^j, \\qquad q^i(\\nu) = \\sum_{j = 0}^{\\lfloor m\/2 \\rfloor} (-1)^j d_{m-1-2j} \\nu^j\n\\end{equation}\nand their degrees are\n\\[\n\\deg (q^r) = \n\\left[\\begin{matrix}\n\\frac m2 &\\text{ if } m \\text{ is even}\\\\[5pt]\n\\frac{m-1}2 &\\text{ if } m \\text{ is odd}\n\\end{matrix}\\right.\n\\qquad \n\\deg(q^i) = \\left[\\begin{matrix}\n\\frac m2 - 1 & \\text{ if } m \\text{ is even}\\\\[5pt]\n\\frac{m-1}2 & \\text{ if } m \\text{ is odd.}\n\\end{matrix}\\right.\n\\]\nThe bifurcation of type (r) takes place when these two polynomials have a common \\emph{positive} real root. \n\nOnce again, the two polynomials have common roots when the function $\\rho(d_1,...,d_m) = \\res(q^r,q^i)$ vanishes (observe that $\\widetilde\\rho = \\rho^2$). But the vanishing of $\\rho$ corresponds to the condition that the two polynomials have a common real root, while the marginal locus we are looking for is the subvariety of $\\widetilde{\\mathcal R}$ that corresponds to points $(d_1,...,d_m)$ whose associated polynomials $q^r$, $q^i$ have a \\emph{common positive real root}. We hence need an extra condition to ensure that the common root is positive.\n\nThis condition can be obtained using Euclid's division algorithm. In fact the ultimate remainder of Euclid's division algorithm applied to $q^r$ and $q^i$ is a degree zero polynomial (a real number) that is the resultant $\\rho$. When the resultant is zero, the penultimate remainder of the Euclid's division algorithm applied to $q^r$ and $q^i$ is a degree 1 polynomial whose only root $\\sigma(d_1,...,d_m)$ is the common root that must exist given that the resultant is zero. This fact, which holds under generic assumptions, is what solves our dilemma, and we can state that\n\\[\n\\mathcal R = \\{ (d_1,...,d_m) \\in \\mathbb R^m \\,|\\, \\rho(d_1,...,d_m) = 0, \\sigma(d_1,...,d_m) > 0\\}.\n\\]\n\nThe remainders of Euclid's division of two polynomials have a fundamental role in the investigation of roots of polynomials, and they generate the so called \\emph{Sylvester sequence} \\cite{2013.Gondim.deMoralesMelo.Russo}. We summarise the discussion above in a definition and a main theorem.\n\n\\begin{defi}\nWe call \\emph{determinant locus} the set $\\mathcal Z$, \\emph{discriminant locus} the set $\\mathcal D$ and \\emph{resultant locus} the set $\\mathcal R$. We call \\emph{marginal locus} the union of the three loci. We call \\emph{marginal points} the points of the marginal locus.\n\\end{defi}\n\n\\begin{thm}\\label{main}\nGiven a vector field $X$ and an equilibrium $e$ of $X$. The marginal locus in invariant space is the union of three algebraic varieties: $\\mathcal Z$, $\\mathcal R$, and $\\mathcal D$. These varieties decompose the space of invariants in domains with a specific spectral type. Across the marginal locus the spectral type of $e$ varies according to a precise rule depending on the three possibilities (z), (r), (d) listed above.\n\nThe variety $\\mathcal Z$ is the hyperplane $\\{\\zeta = 0\\}$ with $\\zeta$ the determinant of $JX_e$. With possible lower-dimensional artefacts, the algebraic variety $\\mathcal D$ is the variety $\\{\\delta = 0\\}$ with $\\delta$ the discriminant of $p$, the characteristic polynomial of $JX_e$; the semialgebraic variety $\\mathcal R$ is the semialgebraic variety $\\{\\rho = 0, \\sigma > 0\\}$ with $\\rho$ the resultant and $\\sigma$ the unique root of the penultimate Euclid's remainder of the two polynomials $q^r,q^i$ defined in \\eqref{qr qi}.\n\\end{thm}\n\nWe conclude observing that the argument of the penultimate Euclid's remainder applied to $p$ and $p'$ does give information on what type of bifurcation is taking place between $f^{\\alpha+1}_\\beta n^\\gamma_\\delta \\leftrightarrow f^\\alpha_\\beta n^{\\gamma+2}_\\delta$ and $f^\\alpha_{\\beta+1} n^\\gamma_\\delta \\leftrightarrow f^\\alpha_\\beta n^\\gamma_{\\delta+2}$. In fact the last remainder of Euclid's division algorithm applied to $p$, $p'$ is the discriminant. When the discriminant is zero, the root $\\tau(d_1,...,d_m)$ of the penultimate remainder (a degree one polynomial) is the real double root of $p$, and hence its sign will discriminate between the two possible bifurcations: the unstable focus$\\leftrightarrow$unstable node (d$^+$) or the stable focus$\\leftrightarrow$stable node (d$^-$).\n\n\\section{The 3-dimensional case}\\label{3-dimensional case}\n\nLet us use Theorem~\\ref{main} to classify the spectral type of hyperbolic equilibria of a 3-dimensional system. Consider $p(\\lambda) = - \\lambda^3 + d_1 \\lambda^2 - d_2 \\lambda + d_3$, the characteristic polynomial of a $3\\times 3$ matrix, where $d_i$ are the invariants of the matrix, i.e.\\ $d_3$ is the determinant, $d_1$ is the trace, $d_2$ is the sum of the determinants of the three principal $2\\times 2$ minors.\n\nThe hyperplane $\\mathcal Z = \\{(d_1,d_2,d_3) \\,|\\, d_3 = 0\\}$ is easily drawn. Also the discriminant of the characteristic polynomial is easy to compute, and is\n\\[\n\\delta = -4 d_3 d_1^3+d_2^2 d_1^2+18 d_2 d_3 d_1-4 d_2^3-27 d_3^2.\n\\]\nThe corresponding discriminant locus $\\mathcal D = \\{(d_1,d_2,d_3) \\in \\mathbb R^3 \\,|\\, \\delta(d_1,d_2,d_3) = 0\\}$ is drawn in Figure~\\ref{n=3} center pane. In this low dimensional case the polynomials $p$ cannot have a double complex root, since this event can take place only when the polynomial has degree at least four, hence in this case $\\widetilde{\\mathcal D} = \\mathcal D$. The interesting feature of this algebraic set is that $\\mathcal D$ displays a line of cusp points corresponding to a triple root in the real axis.\n\nFor the variety $\\mathcal R$ we must consider the two polynomials $q^r = -d_1 \\nu + d_3$ and $q^i = - \\nu + d_2$. They have common positive real roots only if $d_3\/d_1 = d_2$ and $d_2 > 0$. The resultant of the two polynomials is in fact $\\rho = d_3 -d_1 d_2$. In this case the penultimate remainder is $q^i$ itself (the system is very low-dimensional). It follows that $\\sigma = d_2$. In Figure~\\ref{n=3} left pane a picture of the resultant locus $\\mathcal R$, (in transparent red is represented $\\widetilde{\\mathcal R} \\setminus \\mathcal R$) in the right pane a cumulative picture of the three loci $\\mathcal Z \\cup \\mathcal D \\cup \\mathcal R$.\n\\begin{figure}[h]\n\\begin{center}\n\\includegraphics[width=5cm]{R3.pdf}\n\\includegraphics[width=5cm]{D3.pdf}\n\\includegraphics[width=5cm]{Marginal3.pdf}\n\\end{center}\n\\caption{In the left pane the resultant locus $\\mathcal R$ (solid red), a semialgebraic subvariety of the hyperbolic paraboloid $\\widetilde{\\mathcal R}$ (union of solid and transparent red). In the center pane the discriminant locus $\\mathcal D$. In the right pane the two varieties together with the determinant locus $\\mathcal Z$. The complement of the marginal varieties correspond to domains in which the spectral type does not change.}\n\\label{n=3}\n\\end{figure}\n\nAlthough complete, the above pictures lacks the indication of spectral type in each of the connected component complement of the marginal loci. For this reason we use a simple consideration to choose a representative slice of Figure~\\ref{n=3}. A positive rescaling of the vector field $X$ amounts to a rescaling of the spectral parameter $\\lambda$ (if the rescaling is non positive, there will be an exchange of the stable indices $\\beta$, $\\delta$ with the unstable ones $\\alpha$, $\\gamma$). Assume therefore that $d_3 \\not = 0$. We can positively rescale the variable $\\lambda$ by posing $\\lambda = k \\widetilde\\lambda$ with $k \\in \\mathbb R^+$ and obtain the polynomial\n\\[\n\\widetilde p(\\widetilde \\lambda) = k^3 \\left(\\widetilde \\lambda^3 - \\frac{d_1}k \\widetilde \\lambda^2 + \\frac{d_2}{k^2} \\widetilde \\lambda - \\frac{d_3}{k^3}\\right)\n\\]\nwhose roots have same spectral type of the roots of $p$. We hence shall choose $k = \\sqrt[3]{|d_3|}$ and investigate two possibilities:\n\\[\n\\left[\n\\begin{matrix}\np^- = \\widetilde \\lambda^3 - b_1 \\widetilde \\lambda^2 + b_2 \\widetilde \\lambda - 1 & \\text{ if } d_3 < 0\\\\[3pt]\np^+ = \\widetilde \\lambda^3 - b_1 \\widetilde \\lambda^2 + b_2 \\widetilde \\lambda + 1 & \\text{ if } d_3 > 0\n\\end{matrix}\n\\right.\n\\]\nwhere $b_1 = d_1 \/\\sqrt[3]{|d_3|}$ and $b_2 = d_2 \/\\sqrt[3]{|d_3|}$. The discriminants of these two polynomials are the already computed discriminant $\\delta$ with the substitutions $d_3 \\to \\pm 1$, $d_2 \\to b_2$, $d_1 \\to b_1$, that is\n\\[\n\\delta^\\pm = b_1^2 b_2^2 - 4 b_1^3 \\mp 4 b_2^3 \\pm 18 b_1 b_2 - 27.\n\\]\nThe vanishing of $\\delta^\\pm$ always corresponds to a double real root of $p$ except at the codimension 2 cusp point, which corresponds to a triple real root (see the green curves of Figure~\\ref{n=3 tomography}). Such variety is the marginal state separating the case of $p$ possessing three real roots to the case of $p$ possessing two complex conjugate roots and one real root.\n\nAfter substitution the resultant is $\\rho^\\pm = \\pm 1 - b_1b_2$, and of course its relevant submanifold is the one in which the polynomials $q^r = - b_1 \\nu \\pm 1 $ and $q^i = - \\nu + b_2$ have a common positive real root. It follows that $b_2 > 0$. In Figure~\\ref{n=3 tomography} we show how the marginal loci separate the space of invariants in regions of homogeneous spectral type, and how across each locus the change in spectral type is determined by the locus being crossed.\n\n\n\\begin{figure}[h]\n\\begin{center}\n\\includegraphics[width=5cm]{Margin2projp.pdf}\n\\includegraphics[width=5cm]{Margin2projm.pdf}\n\\end{center}\n\\caption{Tomographics sections of Figure~\\ref{n=3} with specification of the spectral type of the equilibrium in the complement of the marginal loci.}\n\\label{n=3 tomography}\n\\end{figure}\n\nThe sign of $\\tau(d_1,d_2,d_3) = (d_1 d_2-9 d_3)\/(2 \\left(d_1^2-3 d_2\\right))$ separates $\\mathcal D$ in two marginal loci, $\\mathcal D^+$ across which two positive real roots become a couple of complex conjugate roots with positive real part and $\\mathcal D^-$ across which two negative real roots become a couple of complex conjugate roots with negative real part.\n\n\\section{The 4-dimensional case}\\label{4-dimensional case}\n\nIn the 4-dimensional case the characteristic polynomial of a $4\\times 4$ matrix is $p(\\lambda) = \\lambda^4 - d_1 \\lambda^3 + d_2 \\lambda^2 - d_3 \\lambda + d_4$. Also in this case the coefficients $d_1,d_2,d_3,d_4$ are the principal invariants of the matrix. Also in this case zero is an eigenvalue if and only if $d_4 = 0$. So that the determinant locus $\\mathcal Z$ is a hyperplane whose points separate regions in which one eigenvalue changes sign. The discriminant of $p$ is\n\\begin{multline*}\n\\delta = -27 d_4^2 d_1^4-4 d_3^3 d_1^3+18 d_2 d_3 d_4 d_1^3+d_2^2 d_3^2 d_1^2+144 d_2 d_4^2 d_1^2 - 4 d_2^3 d_4 d_1^2-6 d_3^2 d_4 d_1^2 + \\\\\n+ 18 d_2 d_3^3 d_1 -192 d_3 d_4^2 d_1 - 80 d_2^2 d_3 d_4 d_1-27 d_3^4+256 d_4^3-4 d_2^3 d_3^2-128 d_2^2 d_4^2+16 d_2^4 d_4+144 d_2 d_3^2 d_4,\n\\end{multline*}\nwhile the two polynomials needed to define $\\mathcal R$ are $q^r =\\nu ^2 -d_2 \\nu + d_4 $, $q^i = d_1 \\nu - d_3$, from which it follows that\n\\[\n\\rho = d_4 d_1^2-d_2 d_3 d_1+d_3^2, \\qquad \\sigma = d_1 d_3.\n\\] \n\nThese functions are what is needed to investigate bifurcations of 4-dimensional systems, but in this case the space of invariants is 4-dimensional. \n\nWe proceed as done in the 3-dimensional case and, assuming $d_4 \\not = 0$ we apply a positive rescaling of the vector field, which amounts to a positive rescaling of the variable $\\lambda$, hence reducing the parameters down to three. Pose $\\lambda = k \\widetilde \\lambda$ with $k \\in \\mathbb R^+$, the polynomial $p$ becomes\n\\[\n\\widetilde p(\\widetilde \\lambda) = k^4 \\left(\\widetilde \\lambda^4 - \\frac{d_1}k \\widetilde \\lambda^3 + \\frac{d_2}{k^2} \\widetilde \\lambda^2 - \\frac{d_3}{k^3} \\widetilde \\lambda+ \\frac{d_4}{k^4}\\right),\n\\]\nwhose roots have same spectral type of the roots of $p$. We hence shall choose $k = \\sqrt[4]{|d_4|}$ and investigate two possibilities:\n\\[\n\\left[\n\\begin{matrix}\np^- = \\widetilde \\lambda^4 - b_1 \\widetilde \\lambda^3 + b_2 \\widetilde \\lambda^2 - b_3 \\widetilde \\lambda - 1 & \\text{ if } d_4 < 0\\\\[3pt]\np^+ = \\widetilde \\lambda^4 - b_1 \\widetilde \\lambda^3 + b_2 \\widetilde \\lambda^2 - b_3 \\widetilde \\lambda+ 1& \\text{ if } d_4 > 0.\n\\end{matrix}\n\\right.\n\\]\n(also in this case $b_j = d_j\/\\sqrt[4]{|d_4|}$ for $j = 1,2,3$.) The discriminant of these two polynomials is\n\\begin{multline}\n\\delta^\\pm = -27 b_1^4+18 b_1^3 b_2 b_3 - 4 b_1^3 b_3^3 - 4 b_1^2 b_2^3 + b_1^2 b_2^2 b_3^2 \\pm 144 b_1^2 b_2 \\mp 6 b_1^2 b_3^2 \\mp 80b_1b_2^2 b_3 \\pm 18 b_1 b_2 b_3^3-192 b_1 b_3+ \\\\\n\\pm 16 b_2^4 \\mp 4 b_2^3 b_3^2 - 128 b_2^2 + 144 b_2 b_3^2-27 b_3^4 \\pm 256.\n\\end{multline}\nIn this case the variety $\\delta^+ = 0$ does posses a thread, corresponding to the codimension 2 degeneracy associated to the coincidence of two couples of complex conjugate solutions. These degeneracies do not correspond to marginal points, but they are of fundamental interest, being origin of interesting monodromic effects. The variety $\\mathcal D$ has also codimension 2 strata which are cusp singularities, corresponding to triple real roots, which are edges to regular strata of codimension 1 corresponding to double real roots, and it also has two point singularities that are swallotails, and correspond to a quadruple real root \\cite{2012.Arnold.Gusein-Zade.Varchenko.1}.\n\nWith this reduction from the space of invariants $(d_1,d_2,d_3,d_4)$ to the space $(b_1,b_2,b_3)$, the resultant becomes $\\rho^\\pm = b_1^2 - b_1 b_2 b_3 \\pm b_3^2$ and, when the resultant is zero, the common root of $q^r$ and $q^i$ is $\\sigma^\\pm = b_1\/b_3$. This fact can be deduced from the abstract approach of Section~\\ref{formal conditions}, but it can also be obtained by direct computation from the two polynomials $q^r = \\nu^2 - b_2 \\nu \\pm 1$ and $q^i = b_3 \\nu - b_1$.\n\nRepresentations of the loci when $d_4 > 0$ are given in Figure~\\ref{n=4 d4>0}, while representations of the loci when $d_4 < 0$ are given in Figure~\\ref{n=4 d4<0}.\n\\begin{figure}[ht]\n\\begin{center}\n\\includegraphics[width=5cm]{D4p.pdf}\n\\includegraphics[width=5cm]{R4p.pdf}\n\\includegraphics[width=5cm]{Marginal4p.pdf}\n\\end{center}\n\\caption{Case in which $d_4 >0$. In the left pane the marginal locus $\\widetilde{\\mathcal D}$, which differs from $\\mathcal D$ only for the 1-dimensional thread that connects the two 0-dimensional strata (sligtly visible at the center of the image). In the center pane the locus $\\widetilde{\\mathcal R}$ in red (solid and transparent) and $\\mathcal R$ in solid red. In the right pane $\\mathcal D$ and $\\mathcal R$ together.}\\label{n=4 d4>0}\n\\end{figure}\n\n\\begin{figure}[h]\n\\begin{center}\n\\includegraphics[width=5cm]{D4m.pdf}\n\\includegraphics[width=5cm]{R4m.pdf}\n\\includegraphics[width=5cm]{Marginal4m.pdf}\n\\end{center}\n\\caption{Case in which $d_4 < 0$. In the left pane the marginal locus $\\mathcal D$. In the center pane the locus $\\widetilde{\\mathcal R}$ in red (solid and transparent) and $\\mathcal R$ in solid red. In the right pane $\\mathcal D$ and $\\mathcal R$ together.}\\label{n=4 d4<0}\n\\end{figure}\n\nWe complete this investigation by making a tomography at a few representative level sets and indicating the spectral type of the connected components of the complement of the loci. In Figure~\\ref{tomography n=4} we use the same convention made for the 3-dimensional case, that is red line for the resultant locus (across which a change from stable focus to unstable focus takes place) and green line for the discriminant locus (across which a change focus to node takes place, preserving the type of stability).\n\\begin{figure}[ht]\n\\begin{center}\n\\includegraphics[width=5cm]{case4at1.pdf}\n\\includegraphics[width=5cm]{case4at2.pdf}\n\\includegraphics[width=5cm]{case4at3.pdf}\n\\end{center}\n\\caption{In the left and center panes, tomographic sections of the 3-dimensional Figure~\\ref{n=4 d4>0} at two different $b_2$ levels. The labels of the different domains give an exhaustive description of the spectral types that can be met. In the center pane are visible two isolated points (drawn as infinitesimal circles for technical reasons). These points are the intersection of the tomographic plane with the thread in which a focus-focus degeneracy takes place. In the right pane, a section of the 3-dimensional Figure~\\ref{n=4 d4<0} at a chosen $b_3$ level. The labels in the different domains give an exhaustive description of the spectral types that can be met.}\n\\label{tomography n=4}\n\\end{figure}\n\nWhile in the odd-dimensional case ($m$ odd) the regions with $d_m >0$ are equivariantly symmetric with those having $d_m < 0$, which means that the loci are the same, and the spectral types change switching the upper indices with the lower ones, in the even-dimensional case such equivariance is lost, because the vector field $-X$ has linearisation with the same determinant of the linearisation of $X$. This means that in the even dimensional case the figures with $d_m$ positive or negative have a $\\mathbb Z_2$ symmetry that the figures in the odd dimensional case do not possess. In invariant space such $\\mathbb Z_2$ symmetry can be explicitly written and is \n\\[\n\\left[\n\\begin{matrix}\n(d_1,d_2,d_3,...,d_{n-1}, d_m) \\to (-d_1,d_2,-d_3,...-d_{n-1},d_m) &\\text{ if } m \\text{ is even}\\\\[5pt]\n(d_1,d_2,d_3,...,d_{n-1}, d_m) \\to (-d_1,d_2,-d_3,...d_{n-1},- d_m) &\\text{ if } m \\text{ is odd}.\n\\end{matrix}\n\\right.\n\\]\nThis symmetry becomes an equivariance for the odd-dimensional case between points with positive and negative determinant, clearly visible in Figure~\\ref{n=3} and in Figure~\\ref{n=3 tomography} between left and right pane, while in the even-dimensional case it becomes the invariance $(b_1,b_2,b_3,...,b_{n-1}) \\to (-b_1,b_2,-b_3,...-b_{n-1})$ clearly visible in Figures~\\ref{n=4 d4>0}, \\ref{n=4 d4<0}, and in the first two panes of Figure~\\ref{tomography n=4}, where it corresponds to the transformation $(b_1,b_2,b_3) \\to (-b_1,b_2,-b_3)$.\n\nAnother $\\mathbb Z_2$ symmetry for the reduced case, that is $(b_1,...,b_{n-1})$-space, is visible both in the odd and even dimensional case. It is related to the substitution of the spectral parameter $\\lambda = 1\/\\widetilde\\lambda$. This symmetry corresponds to an alternating sign inversion of the parameters \n\\[\n\\left[\n\\begin{matrix}\n(b_1,...,b_{n-1}) \\to (\\mp b_{n-1}, \\pm b_{n-2}, ..., \\pm b_2, \\mp b_1) &\\text{ in the even case}\\\\[5pt]\n(b_1,...,b_{n-1}) \\to (\\mp b_{n-1}, \\pm b_{n-2}, ..., \\mp b_2, \\pm b_1) &\\text{ in the odd case.}\n\\end{matrix}\n\\right.\n\\]\n\n\\section{The 5 and 6-dimensional cases}\\label{5 and 6 dimensional case}\n\nIn the 5-dimensional case the polynomial $p$ and the two polynomials $q^r,q^i$ are\n\\[\np = -\\lambda ^5 + d_1 \\lambda ^4 - d_2 \\lambda ^3 + d_3 \\lambda ^2 - d_4 \\lambda + d_5, \\qquad q^r = d_1 \\nu ^2-d_3 \\nu +d_5, \\qquad q^i = -\\nu ^2 + d_2 \\nu - d_4.\n\\]\nIt follows that\n\\begin{multline*}\n\\delta = 256 d_5^3 d_1^5-27 d_4^4 d_1^4-128 d_3^2 d_5^2 d_1^4-192 d_2 d_4 d_5^2 d_1^4+144 d_3 d_4^2 d_5 d_1^4+18 d_2 d_3 d_4^3 d_1^3-1600 d_2 d_5^3 d_1^3 +\\\\\n-4 d_3^3 d_4^2 d_1^3+144 d_2^2 d_3 d_5^2 d_1^3+160 d_3 d_4 d_5^2 d_1^3+16 d_3^4 d_5 d_1^3-36 d_4^3 d_5 d_1^3-6 d_2^2 d_4^2 d_5 d_1^3-80 d_2 d_3^2 d_4 d_5 d_1^3+144 d_2 d_4^4 d_1^2 + \\\\\n-4 d_2^3 d_4^3 d_1^2-6 d_3^2 d_4^3 d_1^2+2000 d_3 d_5^3 d_1^2+d_2^2 d_3^2 d_4^2 d_1^2-27 d_2^4 d_5^2 d_1^2+560 d_2 d_3^2 d_5^2 d_1^2-50 d_4^2 d_5^2 d_1^2+1020 d_2^2 d_4 d_5^2 d_1^2-4 d_2^2 d_3^3 d_5 d_1^2+ \\\\\n-746 d_2 d_3 d_4^2 d_5 d_1^2+24 d_3^3 d_4 d_5 d_1^2+18 d_2^3 d_3 d_4 d_5 d_1^2-192 d_3 d_4^4 d_1-80 d_2^2 d_3 d_4^3 d_1+2250 d_2^2 d_5^3 d_1-2500 d_4 d_5^3 d_1+18 d_2 d_3^3 d_4^2 d_1+ \\\\\n -900 d_3^3 d_5^2 d_1-630 d_2^3 d_3 d_5^2 d_1-2050 d_2 d_3 d_4 d_5^2 d_1-72 d_2 d_3^4 d_5 d_1+160 d_2 d_4^3 d_5 d_1+24 d_2^3 d_4^2 d_5 d_1+1020 d_3^2 d_4^2 d_5 d_1+356 d_2^2 d_3^2 d_4 d_5 d_1+\\\\\n + 256 d_4^5-128 d_2^2 d_4^4+3125 d_5^4+16 d_2^4 d_4^3+144 d_2 d_3^2 d_4^3-3750 d_2 d_3 d_5^3-27 d_3^4 d_4^2-4 d_2^3 d_3^2 d_4^2+108 d_2^5 d_5^2+825 d_2^2 d_3^2 d_5^2+\\\\\n + 2000 d_2 d_4^2 d_5^2-900 d_2^3 d_4 d_5^2+2250 d_3^2 d_4 d_5^2+108 d_3^5 d_5+16 d_2^3 d_3^3 d_5-1600 d_3 d_4^3 d_5+560 d_2^2 d_3 d_4^2 d_5-630 d_2 d_3^3 d_4 d_5-72 d_2^4 d_3 d_4 d_5,\n \\end{multline*}\nwhile\n\\[\n\\rho = d_1 d_5 d_2^2-d_1 d_3 d_4 d_2-d_3 d_5 d_2+d_1^2 d_4^2+d_5^2+d_3^2 d_4-2 d_1 d_4 d_5.\n\\]\nThe penultimate remainder of Euclid's division algorithm applied to $q^r$, $q^i$ is $\\left(d_1 d_2-d_3\\right) \\nu -d_1 d_4+d_5$, and hence its root is $\\sigma = (d_1 d_4-d_5)\/(d_1 d_2-d_3)$. The positivity of this function is equivalent to the positivity of the polynomial function\n\\[\n\\sigma = d_2 d_4 d_1^2-d_3 d_4 d_1-d_2 d_5 d_1+d_3 d_5,\n\\]\nwhich is preferable to use being a polynomial expression. In the 6-dimensional case the polynomial $p$ and the two polynomials $q^r,q^i$ are\n\\[\np = \\lambda^6 - d_1 \\lambda ^5 + d_2 \\lambda ^4 - d_3 \\lambda^3 + d_4 \\lambda^2 - d_5 \\lambda + d_6, \\qquad q^r = -\\nu ^3 + d_2 \\nu ^2-d_4 \\nu + d_6, \\qquad q^i = -d_1 \\nu ^2+d_3 \\nu -d_5.\n\\]\nWe spare the reader from seeing the expression of $\\delta$, while \n\\begin{multline*}\n\\rho = -d_6^2 d_1^3-d_4^2 d_5 d_1^2+d_3 d_4 d_6 d_1^2+2 d_2 d_5 d_6 d_1^2-d_2^2 d_5^2 d_1+2 d_4 d_5^2 d_1+\\\\\n+ d_2 d_3 d_4 d_5 d_1-d_2 d_3^2 d_6 d_1-3 d_3 d_5 d_6 d_1-d_5^3+d_2 d_3 d_5^2-d_3^2 d_4 d_5+d_3^3 d_6.\n \\end{multline*}\nIn this case the penultimate remainder of Euclid's division algorithm applied to $q^r$, $q^i$ is the polynomial\n\\[\n\\left(-\\frac{d_3^2}{d_1^2}+\\frac{d_2 d_3}{d_1}-d_4+\\frac{d_5}{d_1}\\right) \\nu -\\frac{d_2 d_5}{d_1}+\\frac{d_3 d_5}{d_1^2}+d_6.\n\\]\nIt follows that $\\sigma$ can be chosen as\n\\[\n\\sigma = \\left(d_4 d_1^2 - d_1 d_2 d_3 - d_1 d_5+d_3^2\\right) \\left(d_6 d_1^2-d_2 d_5 d_1+d_3 d_5\\right).\n\\]\n\n\\section{Non-genericity}\\label{non-genericity}\nSome words must be spent on the hypothesis we made that the bifurcations are generic. In many cases the equilibrium of a parameter-dependent dynamical system undergoes bifurcation at some parameters, but the bifurcation does not evolve with a change of spectral type. The three typical cases that can take place are:\n\\begin{itemize}\n\\item[(z$_{deg}$)] one real eigenvalue becomes zero and then moves back to the same real semi-axis from which it came from;\n\\item[(r$_{deg}$)]\ntwo complex conjugate eigenvalues touch the purely imaginary axis and then move back to the same half-plane from which they came from;\n\\item[(d$_{deg}$)]\ntwo real eigenvalues collide in the real axis but they then separate once again in the real axis instead of separating in a couple of complex-conjugate egenvalues (or the same event with two complex conjugate that separate back to two complex conjugate).\n\\end{itemize}\nThese three events are non-generic. Non generic events such as these (and other more subtle) take often place because the vector field $X$ has some symmetry, and the principal invariants of the matrix $JX_e$ are not free to move in an open domain of invariant space. From the point of view of the present treatment this fact can be fully understood by applying a small generic perturbation to the vector field $X$. In singularity theory this is called \\emph{morsification}. An example of what this would mean is represented in Figure~\\ref{morsification}.\n\\begin{figure}[ht]\n\\begin{center}\n\\includegraphics[width=5cm]{before_morse.pdf} \\qquad \\includegraphics[width=5cm]{after_morse.pdf}\n\\end{center}\n\\caption{These 2 panes represent the effect of morsification on the higher dimensional component of marginal loci ($\\mathcal Z$, $\\mathcal D$, $\\mathcal R$ respectively) when, across them, the sign of their defining function ($\\zeta$, $\\delta$, $\\rho$ respectively) does not change sign.}\\label{morsification}\n\\end{figure}\n\nIt is possible that in a chosen vector field our approach will display some of these degenerate features (and even more dramatic ones). The non-generic events described above can be easily determined: in all such cases the algebraic function ($\\zeta$, $\\delta$, or $\\rho$) whose zeroes are the marginal locus being crossed do not change sign across the marginal variety in parameter space. Observe that a software for numerical representation of level-sets will typically not draw such varieties, since a contour hypersurface is typically detected by tracing the changes in sign of the defining function. We will see this fact in the application of Section~\\ref{application}.\n\nOne last word must be spent on a remarkably interesting family of dynamical systems: the Hamiltonian vector fields. Hamiltonian vector fields are non-generic, and the characteristic polynomial of their linearisation at the equilibria are always polynomials in $\\lambda^2$. This implies that the degree of the characteristic polynomial is always even, and that $p^i$ is always zero. Lots can be said on such vector fields, but this is outside the purpose of this article. For such vector fields our approach can give results only after non-Hamiltonian morsification. We will dedicate to Hamiltonian vector fields an ad-hoc investigation.\n\n\\section{Determination of the indices}\\label{7}\n\nIn the previous section we made clear a fact that was not pointed at explicitely in the first part of the manuscript: at each marginal locus one type of bifurcation must take place, but there is uncertainty on which direction this bifurcations is taking place (from positive to negative or vice-versa, from two real to two complex conjugate or vice-versa). This is never unclear at low dimensions, and the best way to settle the question in applications is by checking at appropriate points of the connected components complement of the marginal loci $\\mathcal Z, \\mathcal D, \\mathcal R$. Nonetheless, a theoretical discussion requires a non-numerical determination of the precise spectral type, meaning that we would like to express the spectral type only as a fuction of the invariants $d_1,...,d_m$. This can be done almost explicitly using Sturm's sequences and residue theorem.\n\nLet us begin by considering the indices $\\gamma$ and $\\delta$. They indicate the number of positive real zeroes and of negative real zeroes of the characteristic polynomial $p$. This information can be easily extracted from Sturm's theorem \\cite{1835.Sturm}. Consider $p_0 = p$ and $p_1 = p'$, and define for $j= 2,..., m$ the polynomial $p_j = - \\rem(p_{j-2},p_{j-1})$ where $\\rem(p_{j-2},p_{j-1})$ is the remainder of the Euclidean division of $p_{j-2}$ by $p_{j-1}$. Let $a_1,a_2,....,a_m$ be the list of constant terms of the polynomials $p_j$ and let $b_1,....,b_m$ be the coefficients of the top power of the polynomials $p_j$. We have that\n\\[\n\\gamma = \\var(a_1,a_2,....,a_m) - \\var(b_1,....,b_m), \\delta = \\var(a_1,a_2,....,a_m) - \\var((-1)^{1-m}b_1,....,(-1)^{j-m}b_j,...,(-1)^{m-m}b_m)\n\\]\nwhere with $\\var$ we mean the number of changes in sign of consecutive elements of the list (we should say \"once the zeroes have been removed\", but such event is not generic). This could appear a mysterious formula, but it can be expressed explicitly in terms of the invariants.\n\nThe integer numbers $2\\alpha+\\gamma$ and $2\\beta+\\delta$ can be computed using the residue theorem. In fact if the polynomial $p$ has simple zeroes, the function $p'\/p$ has simple poles with residue 1 at every zero of $p$ \\cite{1974.Henrici}. It follows that the number of zeros that $p$ possesses in a region $\\Omega$ is $(2\\pi i)^{-1} \\int_{\\partial \\Omega} p'(z)\/p(z) dz$ (with the usual convention on orientation of boundaries). By the lemma of the big circle, one has that\n\\[\n2 \\alpha + \\gamma = \\frac 1{2 \\pi i} \\lim_{R \\to + \\infty} \\left(\\int_R^{-R} \\frac{p'(i s)}{p(i s)} i ds + \\int_{\\Gamma_R} \\frac{p'(z)}{p(z)} dz\\right) \\quad 2 \\beta + \\delta = \\frac 1{2 \\pi i} \\lim_{R \\to + \\infty} \\left(\\int_{-R}^R \\frac{p'(i s)}{p(i s)} i ds + \\int_{\\Delta_R} \\frac{p'(z)}{p(z)} dz\\right),\n\\]\nwhere $\\Gamma_R$ is the big half-circle parametrised by $\\Gamma_R(\\vartheta) = R(\\cos\\vartheta + i \\sin\\vartheta)$, $\\vartheta \\in [-\\pi\/2,\\pi\/2]$ and $\\Delta_R$ is the other big half-circle parametrised by $\\Delta_R(\\vartheta) = R(\\cos\\vartheta + i \\sin\\vartheta)$, $\\vartheta \\in [\\pi\/2,3\\pi\/2]$ . Concentrating on $2\\alpha+\\gamma$ we have that the integral along the big half-circle $\\Gamma_R$ gives $n \\pi i $, from which it follows that\n\\begin{multline*}\n2 \\alpha + \\gamma - \\frac n2 = \\frac 1{2 \\pi} \\lim_{R \\to + \\infty} \\int_R^{-R} \\frac{p'(i s)}{p(i s)} ds = \\frac 1{2 \\pi} \\lim_{R \\to + \\infty} \\int_R^{-R} \\frac{p'_i(s) - i p'_r(s)}{p_r(s) + i p_i(s)} ds = \\\\\n= \\frac 1{2 \\pi} \\lim_{R \\to + \\infty} \\int_R^{-R} \\frac{(p'_i(s)p_r(s) - p'_r(s)p_i(s)) - i (p'_r(s) p_r(s) + p'_i(s) p_i(s))}{p^2_r(s)+ p^2_i(s)} ds = \\\\\n= \\frac 1{2 \\pi} \\lim_{R \\to + \\infty} \\int_R^{-R} \\left[\\arg(p_r(s) + i p_i(s)) - \\frac 12 i\\log(p^2_r(s) + p^2_i(s))\\right]'ds = - \\wind(p_r + i p_i).\n\\end{multline*}\nwhere $p(i s) = p_r(s) + i p_i(s)$, the two polynomials $p_r, p_i$ are related to the $p^r,p^i$ introduced in \\eqref{pr pi} by the relation $p_r = p^r$, $p_i = - s p^i$, and $ \\wind(p_r + i p_i)$ is the winding number around zero of the curve parameterised by\n\\[\np_r+ i p_i : \\mathbb R \\to \\mathbb C, \\qquad s \\mapsto p_r(s) + i p_i(s) = p(i s).\n\\]\nA similar argument can be used in the other half-plane and it gives\n\\[\n2 \\beta + \\delta - \\frac n2 = \\wind(p_r + i p_i).\n\\]\nObserve that, by simple considerations on the asymptotic of the curve $s \\mapsto p_r(s) + i p_i(s)$, the winding number is an integer if $m$ is even and is a semi-integer if $m$ is odd. Moreover, the derivative of $\\arg(p_r + i p_i)$ is a rational function with numerator a polynomial in $s^2$ of degree at most $2m-2$ and denominator a polynomial in $s^2$ of degree $2 m$. The integral can be in turns computed using the residue theorem once again. It follows that\n\\begin{thm}\\label{indices}\nWith the notations of the previous sections $\\gamma$ and $\\delta$ can be computed using Sturm's theorem, and\n\\[\n\\alpha = \\frac12 \\left( \\frac n2 - \\wind(p_r + i p_i) - \\gamma \\right), \\qquad \\beta = \\frac 12 \\left( \\frac n2 + \\wind(p_r + i p_i) - \\delta \\right).\n\\]\n\\end{thm}\n\nLet us explicitly write the formulas of Theorem~\\ref{indices} in the low-degree cases. We only compute $\\gamma$ and $\\alpha$, since the other two indices $\\delta$ and $\\beta$ lead to similar expressions. When $n=2$ we have\n\\[\n\\gamma = \\var\\left(d_2,-d_1, d_1^2-4 d_2\\right) - \\var\\left(1,d_1^2-4 d_2\\right)\n\\]\nand\n\\[\n\\wind = \\frac{1}{2\\pi} \\int_{-\\infty}^{+ \\infty} \\frac{- d_1 \\mu ^2- d_1 d_2}{\\mu ^4 + (d_1^2 -2 d_2) \\mu ^2 + d_2^2} d\\mu.\n\\]\n\nWhen $n=3$ we have\n\\begin{multline*}\n\\gamma = \\var\\left(d_3,-d_2,d_1 d_2- 9 d_3,4 d_3 d_1^3-d_2^2 d_1^2-18 d_2 d_3 d_1+4 d_2^3+27 d_3^2\\right) + \\\\\n- \\var\\left(-1,3 d_2- d_1^2,4 d_3 d_1^3-d_2^2 d_1^2-18 d_2 d_3 d_1+4 d_2^3+27 d_3^2\\right),\n\\end{multline*}\n\\[\n\\wind = \\frac 1{2\\pi} \\int_{-\\infty}^{+ \\infty} \\frac{-d_1 \\mu ^4 + (3 d_3 - d_1 d_2) \\mu ^2 - d_2 d_3}{\\mu ^6 + (d_1^2 -2 d_2) \\mu ^4+ (d_2^2 -2 d_1 d_3)\\mu ^2 + d_3^2} d\\mu.\n\\]\nWhen $n=4$ the expressions for $\\gamma$ become cumbersome, while\n\\[\n\\wind = \\frac 1{2\\pi} \\int_{-\\infty}^{+ \\infty} \\frac{-d_1 \\mu ^6 + (3 d_3 - d_1 d_2) \\mu ^4 + (3 d_1 d_4 - d_2 d_3) \\mu ^2 - d_3 d_4}{\\mu ^8 + (d_1^2 - 2 d_2) \\mu ^6 + (d_2^2 -2 d_1 d_3 + 2 d_4) \\mu ^4 + (d_3^2 - 2 d_2 d_4) \\mu ^2+d_4^2} d\\mu.\n\\]\n\n\n\\section{Application}\\label{application}\n\nTo conclude, we want to show how the algebraic equations that define $\\mathcal Z$, $\\mathcal D$, and $\\mathcal R$ become useful in an application. Let us consider the celebrated Lorenz system, that is the vector field\n\\[\nX = \\begin{pmatrix} a (y - x) \\\\ b x - y - x z \\\\ x y - c z \\end{pmatrix}.\n\\]\nThe equilibria of $X$ are $e = (0,0,0)$ and $e_\\pm = (\\pm \\sqrt{c(b-1)}, \\pm \\sqrt{c(b-1)},b-1)$. Let us consider the equilibrium $e$, which always exists. The linearisation, the characteristic polynomial $p$, and the associated polynomials $q^r,q^i$ at such equilibrium are\n\\[\nJX_e = \\begin{pmatrix} -a & b & 0 \\\\ a & -1 & 0 \\\\ 0 & 0 & -c \\end{pmatrix}, \\qquad \\begin{cases} p = -\\lambda ^3 - \\lambda ^2 (1+a+c) + \\lambda (a b-a c-a-c)+ a c (b -1) \\\\\nq^r = (a+c+1)\\nu + a c (b-1)\\\\\nq^i = \\nu + a b-a c-a-c.\n\\end{cases}\n\\]\n\nIn parameter space $(a,b,c)$ we have that\n\\[\n\\zeta = \\zeta_1 \\, \\zeta_2 \\, \\zeta_3, \\text{ with } \\quad \\zeta_1 = a, \\quad \\zeta_2 = b-1, \\quad \\zeta_3 = c,\n\\]\n\\[\n\\rho = \\rho_1 \\rho_2, \\text{ with } \\quad \\rho_1 = 1+a, \\quad \\rho_2 = a - a b + c + a c + c^2, \\quad \\text{and } \\quad \\sigma = a - a b + c + a c,\n\\]\n\\[\n\\delta = \\delta_1 \\delta_2^2, \\text{ with } \\quad \\delta_1 = (-1 + a)^2 + 4 a b, \\quad \\delta_2 = (-1 + c) c - a (-1 + b + c).\n\\]\nThis allows to draw the marginal loci in Figure~\\ref{Lorentz e0}. The cumulative picture of the marginal locus and a section at $c=2$ with the indication of the spectral types is shown in Figure~\\ref{Lorentz e0 bis}.\n\\begin{figure}\n\\begin{center}\n\\includegraphics[width=4cm]{Lorenz0a.pdf}\\includegraphics[width=4cm]{Lorenz0b.pdf}\n\\includegraphics[width=4cm]{Lorenz0c.pdf}\n\\end{center}\n\\caption{In the first pane the determinant locus $\\mathcal Z$, in the second pane the discriminant locus $\\mathcal D$ which is the union of two varieties, one across which $\\delta$ changes sign (solid green) and another across which $\\delta$ does not change sign (transparent green), in the third pane the resultant locus $\\widetilde{\\mathcal R}$ in solid and transparent red. In solid red its semialgebraic subvariety $\\mathcal R$.}\\label{Lorentz e0}\n\\end{figure}\n\n\\begin{figure}\n\\begin{center}\n\\includegraphics[width=7cm]{Lorenz0d.pdf} \\qquad \\includegraphics[width=7cm]{Lorenz0e.pdf}\n\\end{center}\n\\caption{In the first pane all the relevant marginal loci together, in the second pane is a section at $c = 2$ of the three-dimensional plot with the indication of the spectral types of the equilibrium $e_0$. The transparent green curve is a discriminant locus in which two negative real eigenvalues touch but on both sides of the curve they separate in the real axis.}\\label{Lorentz e0 bis}\n\\end{figure}\n\n\n \\section{Conclusions}\n\nIn this article we used a few fundamentals facts:\n\\begin{itemize}\n\\item the marginal loci are stratified, their regular stratum corresponds to a simple degeneracy. With simple degeneracy we mean that either zero is a simple root of $p$ ($\\mathcal Z$), or $p$ has a double root in the real line ($\\mathcal D$), or $p$ has two roots in the imaginary axis ($\\mathcal R$). The strata with higher codimension correspond to higher degeneracies (e.g. three roots that coincide in the real axis, two couples of complex conjugate roots that coincide);\n\\item generically, across the regular stratum of the marginal loci, the corresponding vanishing function, $\\zeta$, $\\delta$, and $\\rho$ change sign, and respectively one root of $p$ changes sign crossing $\\mathcal Z$, two roots of $p$ change from two real to a couple of conjugate numbers crossing $\\mathcal D$, two complex conjugate roots of $p$ have real part that changes sign crossing $\\mathcal R$;\n\\item if, crossing a marginal locus, the corresponding vanishing function does not change sign, then the transverse generic change of spectral type of the previous point does not take place.\n\\item the penultimate Euclid's remainder of two polynomials $p,q$ is generically a polynomial of degree one whose zero is the unique common zero of the two polynomials when the ultimate Euclid's remainder, which is the resultant of $p,q$, vanishes (if $q = p'$ the same is true with double root of $p$ instead of unique common zero and discriminant instead of resultant);\n\\end{itemize}\n\nThese facts are basic notions of singularity theory and algebraic geometry, and we think that giving formal justifications in this article would obscure the relevant information given here. The applications of these ideas to relevant parametric-dependent systems will prove extremely useful.\n\nWe found enlightening to numerically draw the loci in parameter space, numerically compute the location of zeroes of the characteristic polynomial in the complex plane, numerically compute the indices $\\alpha,\\beta,\\gamma,\\delta$ through the variations of Sturm's sequences and the winding number given in Section~\\ref{7}, and visualise the changes of spectral type with a Mathematica manipulation.\n\n\n\\section*{Acknowledgments}\nThe author acknowledges the financial support of Universit\u00e0 degli Studi di Catania, progetto PIACERI \\emph{Analisi qualitativa e quantitativa per sistemi dinamici finito e infinito dimensionali con applicazioni a biomatematica, meccanica, e termodinamica estesa classica e quantistica}, PRIN 2017YBKNCE \\emph{Multiscale phenomena in Continuum Mechanics: singular limits, off-equilibrium and transitions}, and GNFM (INdAM). I also thank Francesco Russo for fruitful conversations.\n\n\\printbibliography[heading=bibliography]\n\n\\end{document}","meta":{"redpajama_set_name":"RedPajamaArXiv"}} +{"text":"\\section{Properties of the secret $\\pi$-calculus}\n\\label{sec:examples} \nIn this section we discuss some algebraic \nproperties of the secret $\\pi$-calculus, and we \n show how we can implement the name matching operator. Lastly we provide an example\nof deployment of a mandatory access control policy that is inspired by the D-Bus\ntechnology~\\cite{dbus}.\nIn the following, we write $P\\not\\stackrel{\\bullet}{\\cong} Q$ to indicate that $(P,Q)\\not\\in\\;\\stackrel{\\bullet}{\\cong}$.\nWe also write $\\SENDn{x}{}$ and omit to indicate the message in output whenever\nthis is irrelevant, and use the notation $\\SR B P$ to indicate the process\n$\\SR {b_1} \\cdots\\SR {b_n} P$ whenever $B=\\{b_1,\\dots,b_n\\}$.\n\n\\paragraph{\\bf Algebraic equalities and inequalities} \nThe first inequality illustrates the mechanism of blocked names.\n\\begin{align}\nx(y\\forbids B).P \\not\\stackrel{\\bullet}{\\cong} x(y\\forbids B').P &&\nB\\ne B'\\label{eq:forbids}\n\\end{align}\nTo prove (\\ref{eq:forbids}) let $z\\in B'$, $z\\not\\in B$ and consider the context \n $C[-]\\;\\stackrel{\\text{\\scriptsize def}}{=}\\; \\SR {B,B'}[\\SEND xz\\SENDn\\omega{ }\\mid - ]$ with\n$\\omega$ free, $\\omega\\not\\in\\fv(P)$. \nBy applying \\reductionrulename{Com} followed by applications of \\reductionrulename{Hide} we \nhave that $C[x(y\\forbids B).P ]\\osred \\SR {B,B'}[\\SENDn\\omega{ }\\mid P\\subs zy] $, that\nis \n$C[x(y ).P]\\mathrel{\\!\\Downarrow}_{\\bar\\omega}$. In contrast, we have that \n\\mbox{$C[x(y\\forbids B').P]\\!\\not\\Downarrow_{\\bar\\omega}$}, because of $z\\in B'$. \nThe case $B'\\subseteq B$ is analogous.\n\nWe have a similar result for accepted names.\n\\begin{align}\nx[y\\accept A].P \\not\\stackrel{\\bullet}{\\cong} x[y\\accept A'].P &&\nA\\ne A'\\label{eq:forbids}\n\\end{align}\nA distinguishing context is $C[-]\\;\\stackrel{\\text{\\scriptsize def}}{=}\\; \\SEND xa\\SENDn\\omega{ }\\mid - $ \nwhere $\\omega$ is fresh and $a\\in A, a\\not\\in A'$ if $A\\not\\subset A'$, and \n$a\\in A', a\\not\\in A$ otherwise.\n\nThe next inequality illustrates the discriminating power of the\n{\\it spy}. \n\\begin{align} \n\\NR x (\\SENDn xz \\mid x(y) )&\\not\\stackrel{\\bullet}{\\cong} \\INACT\n\\label{eq:weak}\n\\end{align}\nTo prove (\\ref{eq:weak}), consider the context $C[-]=\\keyword{spy} .\n{\\SENDn \\omega{}}\\mid -$.\nBy applying \\sreductionrulename{Com} and \\reductionrulename{New} followed by \\rstruct we infer \n$C[\\NR x (\\SENDn xy \\mid x(y))]\\osred \\SENDn\\omega{}$: that is,\n$C[\\NR x (\\SENDn xy \\mid x(y))]\\mathrel{\\!\\Downarrow}_{\\bar{\\omega}}$\nwhile $C[\\INACT]\\!\\not\\Downarrow_{\\bar \\omega}$. \n\nThe invisibility of communications protected \nby using the \\emph{hide} operator is established by means of the equation below, which is \nproved\nby co-induction.\n\\begin{align} \n\\SR x [\\SENDn xz \\mid x(y).Q] &\\stackrel{\\bullet}{\\cong}\\SR x[Q\\subs zy] \\label{eq:hide-weak}\n\\end{align}\n\n\n\nThe last equation states the impossibility of extrusion of hidden channels. \n\\begin{align}\n\\SR x [ \\SENDn zx ]\\stackrel{\\bullet}{\\cong} \\INACT \\label{eq:strong-fs}\n\\end{align}\n \n\n\\paragraph{\\bf Implementing name matching} \nName matching is not needed as an operator in our calculus\n(cf.~\\cite{CarboneM03}). We show this \nby providing a semantics-preserving translation of the if-then-else\nconstruct~\\cite{Hen07}. \nConsider the process\n$\\IF {x=y}PQ$ which\nreduces to $P$ whenever $x=y$, and reduces to $Q$ otherwise.\nLet $Z\\;\\stackrel{\\text{\\scriptsize def}}{=}\\;\\fv(\\IF\n{x=y}PQ)$; therefore there are names $z_1,\\dots, z_n$, $n\\geq 0$, s.t. \n$Z=\\{x,z_1,\\dots,z_n\\}$. Let $I=\\{1,\\dots,n\\}$ and assume~$k$ fresh. We define:\n\\begin{align*}\n\\encSQA{\\IF {x=y}PQ} &\\;\\stackrel{\\text{\\scriptsize def}}{=}\\;\n \\SR k[y[w\\accept k] \\mid \\SEND xk(P\\uplus k)\\mid_{I}\\SEND {z_i}k(Q\\uplus\nk) ]\n\\end{align*} \nWhenever $x=y$, we have that the only possible reduction arises among\nthe trusted input $y[w\\accept k]$ and $\\SEND xk(P\\uplus k)$, leading to\n$P'\\;\\stackrel{\\text{\\scriptsize def}}{=}\\; \\SR k[P\\uplus k \\mid_I \\SEND\n{z_i}k(Q\\uplus k)]$. Note that $P$ and $P'$ have the same interactions with\nthe context, because $k$ is blocked in all threads of $P'$: therefore $Q$ cannot be\nunblocked. \nThis result can be formalized by relying on the behavioural theory~\\footnote{Note that\nobservational equivalence is not\npreserved by input-prefixing; the outlined translation could be indeed sensitive to\nname aliasing.} of the secret\n$\\pi$-calculus.\n\n\\noindent\nWe infer the following equation\n\\begin{equation}\n\\encSQA{\\IF {x=x}PQ}\\cong P \\label{eq:match}\n\\end{equation}\n \n\\medskip\\noindent\nConsider now the case $x\\ne y$ and let $y=z_1$.\nThe matching process reduces to the rearranged process \n$\\SR k[\\SEND xk(P\\uplus k) \\mid Q\\uplus k \\mid_{ \n\\{2,\\dots,n\\}}\\SENDn{z_i}k(Q\\uplus k)]$, which has the same behaviour\nof~$Q$\n\\begin{equation}\n\\encSQA{\\IF {x=y}PQ}\\cong Q \\qquad x\\ne y \\label{eq:mismatch}\n\\end{equation} \n\n\\paragraph{\\bf Modeling dedicated channels}\nSecurity mechanisms based on dedicated\nchannels can be naturally modeled in the secret $\\pi$-calculus. \nD-Bus~\\cite{dbus} is an IPC system for software applications \nthat is used in many desktop environments. Applications of each user\nshare a private bus for asynchronous message-passing\ncommunication;\na system bus\npermits to broadcast messages among applications of different users. \nVersions smaller than $0.36$ contain an erroneous access policy for\nchannels which allows users to send and listen to messages on another user's channel\nif the address of the socket is known. We model this vulnerability \nby means of an {\\it internal } attacker that leaks the user's\nchannel. In the specification below, two applications of an user~$U_1$ utilize\na private bus to exchange a password; in fact, the password can be intercepted by the\nuser~$U_2$ through the malicious\ncode~$!\\SENDn {\\sys}{c}$ of $U_1$, which publishes~$c$ on the system bus. \n \\begin{align}\n U_1&\\;\\stackrel{\\text{\\scriptsize def}}{=}\\; \\NR{c}(! \\SENDn {\\sys}{c}\\mid \n\\NR{\\pwd}\\SENDn {c}{\\pwd} \\mid \\RECEIVE {c}x{P} ) \n& U_2&\\;\\stackrel{\\text{\\scriptsize def}}{=}\\; \\sys(x).x(y_{pwd}).Q \n\\end{align} \n\nThe patch released by Fedora restricts the access to the\nuser's bus: only applications with the same user-id can\nhave access. We stress that this policy is mandatory: that is, the user cannot\nchange it. By using the secret \\mbox{$\\pi$-calculus} we can easily patch $U_1$ by hiding\nthe\nbus: \n$U' \\;\\stackrel{\\text{\\scriptsize def}}{=}\\; \\SR{c}[! \\SENDn {\\sys}{c}\\mid \n\\NR{\\pwd}(\\SENDn {c}{\\pwd} ) \\mid \\RECEIVE {c}x{P}]$. \nThe following equation, which can be proved co-inductively, states that the\npolicy is fulfilled even in presence\nof internal attacks: \n\\begin{align} \nU' &\\stackrel{\\bullet}{\\cong} \\SR{c}[\\NR{\\pwd}({P}\\subs{\\pwd} x)] \\label{eq:dbus}\n\\end{align}\n \n\n\\shrink{\nWhile we do not have a formal separation result, we believe that enforcing such\nmandatory policies in the (untyped) $\\pi$-calculus is difficult. On contrast, our\ncalculus permits to naturally model security mechanisms based on dedicated channels\nthat cannot be disclosed. \n}\n\n\n\n\\section{Observational equivalence}\n\\label{sec:observational}\n \nIn this section we define a notion of behavioral equivalence based on observables, or\nbarbs. As the reader will notice, a distinctive feature of our observational theory is\nthat trusted inputs are visible only under certain conditions, namely that the context\nknows at least a name that is declared as accepted. Conversely, processes trying to send\na name protected by an hide declaration are not visible at all.\nThe choice to work in a synchronous setting\npermits us to emphasize the differences among our theory and that of\n$\\pi$-calculus. However, the same results would hold for a secret asynchronous\n$\\pi$-calculus, while the contrast would be less explicit as input barbs would not be\nobservable.\n\nWe say that a name $x$ is bound in $P$ if $x\\in\\bv(P)$.\nAn occurrence of $y$ is hidden in $P$ if such occurrence of $y$ appears\nin the scope of a {\\sf hide} operator in~$P$.\n \n\\begin{definition}[Barbs] \nWe define: \n\\begin{itemize}\n \\item $P\\mathrel{\\!\\downarrow}_{x}$ whenever $P\\equiv C[\\RECEIVET x{y\\accept A} Q]$ with $x$ not\nbound in $P$ and $A\\cap\\bv(P)\\ne A$, or whenever \n $P\\equiv C[\\RECEIVE x{y\\forbids B} Q]$ with $x$ not bound in $P$. \n \\item $P\\mathrel{\\!\\downarrow}_{\\overline x}$ whenever \n $P\\equiv C[\\SEND xyQ]$ with $x$ not bound in $P$ and~$y$ not hidden in~$P$.\n\\end{itemize}\n\\end{definition} \n\n\\noindent\nBased on this definition, we have that \n$P_1\\;\\stackrel{\\text{\\scriptsize def}}{=}\\;\\SR x \\RECEIVET z{y\\accept x}Q$, \n$P_2\\;\\stackrel{\\text{\\scriptsize def}}{=}\\;\\NR x \\RECEIVE x{y\\forbids B}Q$, and\n$P_3\\;\\stackrel{\\text{\\scriptsize def}}{=}\\; \\RECEIVET z{y\\accept \\emptyset}Q$ do not exhibit a barb $z$, written\n$P_i \\mathrel{\\!\\not\\downarrow}_z$ for $i=1,2,3$. \nIn contrast, when $x\\ne z$ and $A\\cap \\{x\\}\\ne\\emptyset$ \nwe have that $\\NR x \\RECEIVET\nz{y\\accept\nA}P \\mathrel{\\!\\downarrow}_z$, and when $x\\ne z$ we have $\\SR x \\RECEIVE z{y\\forbids B}P$. \nWhenever $P\\;\\stackrel{\\text{\\scriptsize def}}{=}\\; \\SR y \\SEND xvQ$ with $y\\ne x$, we have $P\\mathrel{\\!\\downarrow}_{\\overline x}$ if\n$y\\ne v$, and $P\\mathrel{\\!\\not\\downarrow}_{\\overline x}$ otherwise.\nWeak barbs are defined by ignoring reductions. \nWe let $P\\mathrel{\\!\\Downarrow}_{x}$\nwhenever $P\\Rightarrow P'$ and $P'\\mathrel{\\!\\downarrow}_{x}$; similarly $ P\\mathrel{\\!\\Downarrow}_{\\overline x}$ whenever $\nP\\Rightarrow P'$ and $P'\\mathrel{\\!\\downarrow}_{\\overline x }$. \n\nFollowing the standard definition of observational equivalence, we are aiming at an \nequivalence relation that is sensitive to the barbs, is closed under reduction, and is\npreserved by certain contexts. \n\n\\begin{definition}[Barb preservation]\nA relation $\\,{\\cal R}\\,$ over processes is barb preserving if \n$P\\,{\\cal R}\\, Q$, $P\\mathrel{\\!\\downarrow}_{x}$ implies $Q\\mathrel{\\!\\Downarrow}_{x}$, and \n $P\\mathrel{\\!\\downarrow}_{\\overline x}$ implies $Q \\mathrel{\\!\\Downarrow}_{\\overline x}$.\n\\end{definition}\n\nThe requirement of reduction closure is to ensure that the processes maintain their\ncorrespondence through the computation. \n\n\\begin{definition}[Reduction closure]\nA relation $\\,{\\cal R}\\,$ over processes is reduction-closed if $P\\,{\\cal R}\\, Q$\nand $P\\rightarrow P'$ implies that $Q\\Rightarrow Q'$ and \n$P'\\,{\\cal R}\\, Q'$.\n\\end{definition}\n\nWe require contextuality with respect to the parallel composition, the new and the\nhide operators (cf. Section~\\ref{sec:pi-calculus}). \n\n\\begin{definition}[Contextuality]\nA relation $\\,{\\cal R}\\,$ over processes is contextual if $P\\,{\\cal R}\\, Q$ implies\n$C[P] \\,{\\cal R}\\, C[Q]$. \n\\end{definition}\n\n\\begin{definition}[Observational equivalence]\\label{def:obs-equivalence}\nObservational equivalence, noted $\\cong$, is the largest symmetric \nrelation over processes which is barb preserving, reduction closed\nand contextual. \n\\end{definition} \n\nObservational equivalence is difficult to establish since it requires\nquantification over contexts. In the next section we will introduce labelled transition\nsemantics for the secret $\\pi$-calculus, and show that the induced bisimulation coincides\nwith observational equivalence. Besides the theoretical interest, this will be also\nof help in proving that two processes are observationally equivalent. \n \n\\subsection{Characterization} \n\\label{sec:bisimulation}\n\\input{fig-lts-rev}\nThe characterization relies on labelled transitions of the form $P\\lts\\alpha P'$, \nwhere $\\alpha$ is one of\nthe following actions:\n\\[\n\\alpha = x(z)\\mid \\SENDn xz \\mid (z)\\SENDn xz\n\\mid \\tau \n\\]\nWe let $\\fv(x(z))=\\{x\\}$, $\\fv(\\SENDn xz)=\\{x,z\\}$, and \n$\\fv{(z)\\SENDn xz}=\\{x\\}$. \nWe define $\\bv(x(z))=\\{z\\}$, $\\bv(\\SENDn xz)=\\emptyset$ and\n$\\bv( (z)\\SENDn xz)=\\{z\\}$. We let $\\fv(\\tau)=\\emptyset=\\bv(\\tau)$.\n\nThe transitions are defined by the rules in Figure~\\ref{fig:lts}. \nAction $ x(z)$ represents the receiving of a name $z$ on a\nchannel $x$. In rule \\ltsrulename{In}, a process\nof the form $x(y\\forbids B).P$ can receive a value $z$ over $x$, provided that $z$ is is\nnot blocked ($z\\not\\in B$). The received name will\nreplace the formal parameter in the body of the continuation. \nRule \\linpt describes a trusted input, that is a process\nof the form $\\RECEIVET x{y\\accept A}P$ that receives a variable $z$ over $x$ whenever \n$z$ is accepted ($z\\in A$); the variable~$z$ will replace all occurrences of~$y$ in $P$.\nThe action $ \\SENDn xy$ represents the output of a name $y$ over\n$x$. This move is performed in \\lout by the process $\\SEND xyP$ and leads to the\ncontinuation $P\\rhd B$. \nCommunication arises in rule \\lcom by means of a $\\tau$ action obtained by a\nsynchronization of an $ x(y)$ action with a $ \\SENDn xy$ action.\nAction $ (y)\\SENDn xy$ is fired when the name $y$ sent over $x$ is bound\nby the {\\sf new } operator and its scope is opened by using rule \\ltsrulename{Open}. \nThe scope of the {\\sf new } is closed by using rule \\lclose.\nIn this rule the scope of a name $y$ sent over $x$ is \nenlarged to include a process which executes a dual action $ x(y)$, \ngiving rise to a synchronization of the two threads depicted by an action $\\tau$. \nRule \\lres is standard for restriction. \nRule \\ltsrulename{Hide} says that process $\\SR x P $ performs an action $\\alpha$ inferred\nfrom $P$, provided that the $\\alpha$ does not contain $x$.\nTherefore extrusion of hidden channels is not possible, as previously discussed; note\nindeed that this the unique rule applicable for \\emph{hide}. \nRule \\ltsrulename{Repl} performs a replication. \n \nWe have a standard notion of bisimilarity; in the following, we let $\\Lts{\\tau}$ be\nthe reflexive and transitive closure of $\\lts{\\tau}$.\n\n\\begin{definition}[Bisimilarity]\\label{def:bisimulation}\nA symmetric relation $\\,{\\cal R}\\,$ over processes is a bisimulation if\nwhenever $P\\,{\\cal R}\\, Q$ and $P\\lts{\\alpha} P'$ then there exists \na process $Q'$ such that \n$Q \\Lts{\\tau}\\lts{\\hat\\alpha}\\Lts{\\tau}Q'$ and \n$P'\\,{\\cal R}\\, Q'$ where $\\hat\\tau$ is the empty string and\n$\\hat\\alpha=\\alpha$ otherwise. \nBisimilarity, noted $\\approx$, is the largest bisimulation.\n\\end{definition}\n\nThe following result establishes that bisimilarity can be used as a proof technique for\nobservational equivalence; the proof is by coinduction and relies on the closure of\nbisimilarity under the {\\sf new}, {\\sf hide} and parallel composition operators. \n \n\\begin{proposition}[Soundness]\\label{prop:soundness}\nIf $P\\approx Q$ then $P\\cong Q$. \n\\end{proposition}\n\n\nTo prove the reverse direction, namely that behaviourally equivalent processes are\nbisimilar, we follow the approach of Hennessy~\\cite{Hen07} and proceed by co-induction\nrelying on contexts $C_\\alpha$ which emit the desired barbs whenever they interact\nwith a process $P$ such that $P\\Lts{\\alpha} P'$, and vice versa. \nPerhaps interestingly, we can program a context to check if\na given name is fresh even if our syntax does not include a matching construct \n(cf.~\\cite{Hen07,BorealeS98}).\nIn Section~\\ref{sec:examples} we will show that in the secret $\\pi$-calculus the process \n$\\IF{x=y}PQ$ can be derived. \n\n\n\\begin{proposition}[Completeness]\n\\label{prop:completeness}\nIf $P\\cong Q$ then $P\\approx Q$. \n\\end{proposition} \n\\begin{proof}\nLet $P\\,{\\cal R}\\, Q$ whenever $P\\cong Q$ and assume that\n$P\\lts\\alpha P'$. We show that there is $Q'$ such that $Q\\Lts{\\hat\\alpha} Q'$\nand $P'\\equiv \\,{\\cal R}\\, \\equiv Q'$; this suffices to prove that $\\,{\\cal R}\\,$ is included in\nobservational equivalence (cf.~\\cite{SangiorgiM92}).\nWhenever $\\alpha=\\tau$, we use reduction-closure of $\\cong$ to find $Q'$ such that\n$Q\\Lts{} Q'$ with $P'\\cong Q'$. By relyng on a lemma that establishes that\nreductions correspond to $\\tau$ actions, we infer that $Q\\Lts{\\tau} Q'$, which is the\ndesired result since $P'\\,{\\cal R}\\, Q'$. Otherwise assume $\\alpha\\ne\\tau$.\nWe exploit contextuality of $\\cong$ and infer that\n$C^A_\\alpha[P]\\cong C^A_\\alpha[Q]$ where we let $A=\\fv(P)\\cup\\fv(Q)$ and $C^A_\\alpha$ be\ndefined below. We let $A=\\{a_1,\\dots,a_n\\}$, $I=1,\\dots,n$, with $n\\geq 1$, and\nassume names $\\omega,\\psi_1,\\dots,\\psi_n$ such that\n$\\{\\omega,\\psi_1,\\dots,\\psi_n\\}\\cap A=\\emptyset$. \n\\begin{align*}\nC^A_{x(y)}[-] &\\;\\stackrel{\\text{\\scriptsize def}}{=}\\; - \\mid \\SEND xy\\SENDn \\omega{} \\\\\nC^A_\\alpha[-] &\\;\\stackrel{\\text{\\scriptsize def}}{=}\\; \n- \\mid \\SR k[x(z).( z[w\\accept k] \\mid \\SENDn \\omega{}) \n\\mid_{i\\in I} \\SEND {a_i}k\\SENDn{\\psi_i}{}]\n&& \\alpha=x\\oput y,(y)x\\oput y\\\\\nC'_y&\\;\\stackrel{\\text{\\scriptsize def}}{=}\\; \\SR k [y[w\\accept k]\\mid \\SENDn \\omega{}\\mid_{i\\in I} \\SEND \n{a_i}k\\SENDn{\\psi_i}{}] &&\\forall i\\in I\\,.\\, y\\ne a_i \n\\\\\nC''_y &\\;\\stackrel{\\text{\\scriptsize def}}{=}\\; \\SR k [\\SENDn \\omega{} \\mid\n\\SENDn{\\psi_l}{}\\mid_{i\\in I\\less l}\\SEND{a_i}k\\SENDn{\\psi_i}{} ]\n&&a_l=y\n\\end{align*} \nAssume $\\alpha=\\SENDn xy$. We have that there is $a_l\\in A, a_l=y$ such that\n$C^A_\\alpha[P]\\Lts{}\\equiv C_P\\;\\stackrel{\\text{\\scriptsize def}}{=}\\; P'\\mid C''_y$. We find\na process $C_Q$ such that\n$C^A_\\alpha[Q]\\Lts{}C_Q\\cong C_P $.\nSince $C_P\\mathrel{\\!\\downarrow}_{\\bar \\omega}, \\mathrel{\\!\\downarrow}_{\\bar \\psi_l}$, this implies that \n$C_Q\\mathrel{\\!\\Downarrow}_{\\bar \\omega}, \\mathrel{\\!\\Downarrow}_{\\bar \\psi_l}$. Therefore the weak barb \n$\\bar \\omega$ of $C_Q$ has been unblocked since $Q$ emits a weak action $\\alpha'$ with\n$x$ as subject. Moreover, the object of $\\alpha'$ is~$y$, that is $\\alpha'=\\alpha$,\nbecause of the weak barb $\\bar \\psi_l$. Indeed the thread $\\SEND {a_l}k\\SENDn\n{\\psi_l}{}$ with $a_l=y$ can be unblocked only by $y[w:k]$, because $k$ is protected by\nthe {\\sf hide} declaration. \nTherefore there is $Q'$ such that $Q\\Lts{\\alpha} Q'$ and $C_Q\\cong Q'\\mid C''_y$.\nWe conclude by showing that this implies $P'\\cong Q'$, and in turn $P'\\,{\\cal R}\\, Q'$, as\nrequested. \nAssume $\\alpha=(y)x\\oput y$. We have that $C^A_\\alpha[P]\\Lts{}\\equiv C_P\\;\\stackrel{\\text{\\scriptsize def}}{=}\\; P'\\mid\nC'_y$. Since $y$ is fresh we have that $a_i\\ne y$ for all $a_i\\in A$. Therefore\n$C_P\\!\\not\\Downarrow_{\\bar \\psi_i}$ for all $i\\in I$, because $k$ is protected by {\\sf hide}.\nWe easily obtain that there is $C_Q$ such that $C^A_\\alpha[Q]\\Lts{} C_Q\\cong C_P$ with\n$C_Q\\mathrel{\\!\\Downarrow}_{\\bar\\omega},\\!\\not\\Downarrow_{\\bar \\psi_i}$, for all $i\\in I$. This let us infer that \nthere is $Q'$ such that $Q\\Lts{\\alpha} Q'$ and $C_Q\\cong Q'\\mid C'_y$, and the result then\nfollows by showing that $P'\\mid C'_y\\cong Q'\\mid C'_y$ implies $P'\\cong Q'$.\n\\end{proof} \n\nFull abstraction is obtained by\nPropositions~\\ref{prop:soundness} and~\\ref{prop:completeness}.\n\n\n\\begin{theorem}[Full Abstraction]\n\\label{theor:character}\n$\\cong\\ =\\ \\approx$. \n\\end{theorem}\n\n\n\n\n\n\n\n\\section{Introduction}\n\\label{sec:intro}\n\nThe restriction operator is present in most process calculi. Its behaviour is crucial for\n\\emph{expressiveness} (e.g., for specifying unbounded linked structures, nonce generation\nand locality). \nIn the $\\pi$-calculus~\\cite{MPW92a,MPW92b}, it plays a prominent role: It provides \nfor the generation and extrusion of unique names. In CCS~\\cite{Milner80}, it is also\nfundamental but it does not provide for name extrusion: It limits the interface of a given\nprocess with its external world. In this paper we shall extend the $\\pi$-calculus with a\nhiding operator, called {\\sf hide}, that behaves similarly to the CCS restriction. The\nmotivation for our work comes from the realm of \\emph{secrecy} and \\emph{confidentiality}: we shall\nargue that {\\sf hide} allows us to express and guarantee secret communications.\n\n\\paragraph{Motivation.} Secrecy and confidentiality are major concerns in most systems of communicating agents. \nEither because some of the agents are untrusted, or because the communication uses insecure channels, there \nmay be the risk of sensitive information being leaked to potentially malicious entities. \nThe price to pay for such security breaches may also be very high. \nIt is not surprising, therefore, that secrecy and confidentiality have become central issues in the \nformal specification and verification of communicating systems. \n\nThe $\\pi$-calculus and especially its variants enriched with mechanisms to\nexpress \ncryptographic operations, the spi calculus~\\cite{AbadiG99} and the applied\n$\\pi$-calculus~\\cite{AbadiF01}, have become \npopular formalisms for security applications. They all feature the operator {\\sf new} (restriction) \nand make crucial use of it in the definition of security protocols. \nThe prominent aspects of {\\sf new} are the capability of creating a new channel name, \nwhose use is restricted within a certain scope, and the possibility of enlarging its scope by communicating it to other processes. \nThe latter property is central to the most interesting feature of the $\\pi$-calculus: the \\emph{mobility} of the communication structure. \n\nAlthough in principle the restriction aspect of {\\sf new} should guarantee that the channel is used for communication \nwithin a secure environment only, the capability of extruding the scope leads to security problems. \nIn particular, it makes it unnatural to implement the communication using dedicated channels, and\nnon-dedicated channels are not secure by default. \nThe spi calculus and the applied $\\pi$-calculus do not assume, indeed, any \nsecurity guarantee on the channel, and implement security by using cryptographic encryption. \n\nLet us illustrate the problem with an example. \nThe following $\\pi$-calculus process describes a\nprotocol for the exchange of a confidential information:\n\\[\nP= \\SENDn s{\\textrm{CreditCard}} \\mid\n\\RECEIVE sx\\IFs {x=\\textrm{OwnerCard}} (\\SENDn p{\\textrm{Ok}} \\mid \\SENDn ps) \n\\qquad p\\ne s\n\\]\nIn this specification, the thread on the left sends a\ncredit card number over the channel~$s$ to the thread on the right which is waiting\nfor an input on the same channel. If the received card number is the expected one,\nthen the latter both sends an ack and forwards the communication channel~$s$ on a public\nchannel~$p$. \nThe problem is that, while the confidentiality of the information would require the context to be\nunable to interfere with the protocol and to steal the credit card number, \nin fact this is not guaranteed in the $\\pi$-calculus where \ninteraction with a parallel process waiting for input on channel~$s$ is allowed. \n \n\nTo amend this problem, the idea is to let the channel for the\nexchange of the secret information available only to the process $P$, \nrestricting its scope to $P$ with the declaration: $\\NR s P$. \nThe $\\pi$-calculus semantics makes the exchange invisible to the context. This is formalized\nby the following observational equation stating that no $\\pi$-calculus context \ncan tell apart $P$ from its continuation:\n\\begin{align}\n\\NR s P\\cong^{\\textrm{obs}}_\\pi \\NR s \\IFs\n{\\,\\textrm{CreditCard}=\\textrm{OwnerCard}}(\\SENDn p{\\textrm{Ok}} \\mid \\SENDn ps) \n\\label{eq:inact} \n\\end{align}\n\nUnfortunately, to preserve such behavioral\nequations when processes are deployed in untrusted\nenvironments is difficult, since, as explained above, we cannot rely on dedicated\nchannels for\ncommunication on names created by the {\\sf new} operator. \nOne natural approach to cope with this problem is to map the private communication \nwithin the scope of the {\\sf new} into open communications protected by cryptography. \n\n\nFor instance, the process $\\NR s P$ could be implemented in the spi calculus protocol\n$\\encSQ {\\NR sP}$ below by using a public-key crypto-scheme.\nIn this implementation the creation of a $\\pi$-calculus channel $s$ is mapped into the \ncreation of a couple\nof spi calculus keys: a public key~$s^+$ and a private key~$s^-$.\nThe receiver performs decryption of the crypto-packet ${\\pack{\\textrm{CC}}{s^+}}$\nwith the private key $s^-$; the operation assigns the card number to the variable\nin the conditional test. \n\\begin{align*}\n\\encSQ {\\NR s P} \\;\\stackrel{\\text{\\scriptsize def}}{=}\\;& \\NR{s^+,s^-}\n(\\SEND {net}{\\pack {\\textrm{CC}}{s^+}}\\INACT \\mid {net}(y).\\DECRYPT y{\\pack\nx{s^-}}Q)\n\\\\\nQ\\;\\stackrel{\\text{\\scriptsize def}}{=}\\;& \\IFs {x=\\textrm{OC}}{ \\SENDn {net}{\\pack{\\textrm{Ok}}{p^+}} \\mid \\SENDn\n{net}{\\pack{s^+,s^-}{p^+} }} \n\\end{align*} \nUnfortunately, the naive protocol above suffers from a number of problems,\namong which the most serious is the lack of forward secrecy~\\cite{abadi98}: this property \nwould guarantee that if keys are corrupted at some time~$t$ then the protocol steps\noccurred before~$t$ do preserve secrecy. \nIn particular, forward secrecy requires that the content of the packet~$\\pack\n{\\textrm{CC}}{s^+}$, which is the credit card number, is not disclosed if at some step of\nthe computation the context gains the decryption key~$s^-$. Stated differently, the\nimplementation $\\encSQ \\cdot$ should preserve the semantics of equation (\\ref{eq:inact}):\nthat is, it should be fully abstract. \nIt is easy to see that this is not the case since \na spi calculus context can first buffer the encrypted packet and subsequently, whenever it\nenters in posses of the decryption key, retrieve the confidential information; this\nbreaks equation (\\ref{eq:inact}).\nWhile a solution to recover the behavioral theory of $\\pi$-calculus is\navailable~\\cite{popl07}, the price to pay is a complex cryptographic\nprotocol that relies on a set of trusted authorities acting as proxies. \n\nBased on these considerations, in this paper we argue that the\nrestriction operator of $\\pi$-calculus does not adequately ensure confidentiality. \nTo tackle this problem, we introduce an operator to\nprogram explicitly secret communications, called {\\sf hide}. \nFrom a programming language point of view, the envisaged use of the\noperator is for declaring secret a medium used for {\\it local} inter-process\ncommunication; examples include pipelines, message queues and IPC\nmechanisms of microkernels. \nThe operator is static: that is, we assume that the scope of hidden\nchannels can not be extruded. The motivation is that all processes using a private channel\nshall be included in the scope of its {\\sf hide} declaration; processes outside\nthe scope represent another location, and must not interfere with the protocol. \nSince the {\\sf hide} cannot extrude the scope of secret channels, we can use it to directly build specifications\nthat preserves forward secrecy.\nIn contrast, we regard the\nrestriction operator of the $\\pi$-calculus, {\\sf new}, as useful to create a new \nchannel for message passing with scope extrusion, and which does not provide secrecy\nguarantees. \n\nTo emphasize the difference between {\\sf hide} and {\\sf new}, we introduce a\n \\emph{spy} context that represents a side-channel attack on the non-dedicated channels.\nIn practice, \n \\emph{spy} is able to detect whether there has been a communication on one of the\nchannels not protected by a {\\sf hide}, but \n is not able to retrieve its content.\n \n\n \n\n \\medskip\\noindent{\\bf {Contributions.}}\n We introduce the {\\it secret} $\\pi$-calculus as an \\ignore{orthogonal} extension of the\n$\\pi$-calculus with an operator representing confidentiality ({\\sf hide}). We \ndevelop its structural operational semantics and its observational theory. In particular,\nwe provide a reduction semantics, a labelled\ntransition semantics and an observational equivalence.\nWe show that the observational equivalence induced by the reduction semantics coincides\nby the labelled transition system semantics. \nTo illustrate the difference between {\\sf hide} and {\\sf new}, we shall also consider a\ndistinguished process context, called \\emph{spy}, representing a side-channel attack.\n \n \\medskip\\noindent{\\bf Plan of the paper}\n In the next section we introduce the syntax and the reduction semantics of\n the secret $\\pi$-calculus. \n In Section~\\ref{sec:observational} we present the observational equivalence, and a\ncharacterization based on labelled transition semantics, that we show sound\n and complete. \n In Section~\\ref{sec:spy} we introduce the {\\it spy} process, and we extend\nthe reduction semantics and bisimulation method accordingly. \n In Section~\\ref{sec:examples} we discuss some algebraic \n equalities and inequalities of the secret $\\pi$-calculus, and we analyze some\ninteresting examples, notably an\nimplementation of name matching, and a deployment of mandatory access control. \n Finally, Section~\\ref{sec:discussion} presents related work and concludes. \n An extended version of the paper containing all proofs is available\nonline~\\cite{tech-report}.\n \n\\section{Secret $\\pi$-calculus}\n\\label{sec:pi-calculus}\n\nThis section introduces the syntax and the semantics of our calculus, \n the {\\it secret $\\pi$-calculus}. \nThe syntax of the processes in Figure~\\ref{fig:syntax} extends \nthat of the $\\pi$-calculus~\\cite{MPW92a,MPW92b} by:\n(1) We consider two binding operators: \n{\\sf new }, which -- as we will argue -- does not offer enough security \nguarantees, and {\\sf hide}, which serves to program secrecy.\n(2) We use two forms of restricted pattern matching in input, so\nthat we can deny a process to receive a (possibly empty) set of channels, or we can\nenforce a process to receive only trusted channels. When in the first form the set of\nchannels is empty we have the standard input of $\\pi$-calculus. \n\\begin{figure}\n \\begin{align*} \n P,Q \\; ::= \\; & & \\text{Processes:} \n \\\\\n & \\RECEIVE x{y\\forbids{ B}}P & \\text{input} && \\NR{x}(P) &&\n\\text{restriction}\n \\\\\n & \\RECEIVET x{y\\accept{ A}}P& \\text{trusted input}\n && \\SR{x}[P] && \\text{secrecy} \n \\\\\n & \\SEND xyP & \\text{output} && \\INACT && \\text{inaction} \n \\\\\n &P\\mid Q & \\text{composition} && !P &&\n\\text{replication} \n \\end{align*}\n \\caption{Syntax of the secret $\\pi$-calculus}\\label{fig:syntax}\n \\end{figure}\nWe use an infinite set of names ${\\cal N}$, ranged over by $a,b,\\dots,x,y,z$, to represent\nchannel names and parameters, i.e. the subjects and the objects of communication, \nrespectively. \nWe let $A,B$ range over subsets of ${\\cal N}$. \n \nA process of the form $\\RECEIVE x{y\\forbids B }P$ represents an input\nwhere the name $x$ is the input channel name, \n$y$ is a formal parameter which can appear in the continuation $P$, \nand~$B$ is the set of {\\it blocked} names that the process cannot receive.\nOn contrast, an input process of the form $\\RECEIVET x{y\\accept A }P$ \ndeclares the object names that the process can {\\it accept}: that is, \nthe process accepts in input a name $z$ only if $z\\in A$. \nThis permits to program security protocols where only trusted names can be received. \nThe free and the bound names of such process are defined as follows: \n$\\fv(x[y\\forbids B].P)=(\\fv(P)\\setminus \\{y\\})\\cup\\{x\\}\\cup B$ and\n$\\bv(x[y\\forbids B].P)=\\{y\\}\\cup \\bv(P)$, \n$\\fv(x(y\\accept A).P)=(\\fv(P)\\setminus \\{y\\})\\cup\\{x\\}\\cup A $ and\n$\\bv(x(y\\accept A).P)=\\{y\\}\\cup \\bv(P)$. \n\n\nProcesses $\\SEND xyP$, $\\NR x(P)$, $P\\mid Q$, $!P$, and $\\INACT$ are the pi calculus\noperators respectively describing an output of a name~$y$ over channel~$x$,\nrestriction of~$x$ in $P$, parallel composition, replication and inaction;\nsee~\\cite{SanWalk01} for more details. \n\nThe process $\\SR x[P]$ represents a process $P$ in which the name $x$ is regarded as\n\\emph{secret}, and should not be accessible to any \nprocess external to $P$. $\\SR x[P]$ binds the occurrence of $x$ in $P$: \n$\\fv(\\SR x[P])=\\fv(P)\\setminus \\{x\\}$, and $\\bv(\\SR\nx[P])=\\{x\\}\\cup \\bv(P)$. \n \n\nContexts are processes containing a hole~$-$. We write $C[P]$ for\nthe process obtained by replacing~$-$ with $P$ in $C[-]$.\n\\begin{align*} \nC[-] &\\; ::= \\; - \\;\\mid\\; C[-]\\mid P \\;\\mid\\; P\\mid C[-] \\;\\mid\\; \\NR x[-]\\;\\mid\\; \\SR\nx[-]\n&& \\text{contexts}\n\\end{align*} \n\nWe write $x(y).P$ as a short of $x(y\\forbids \\emptyset).P$, and omit curly brackets in\n$x(y\\forbids\\{b\\}).P$ and $x[y\\accept\\{a\\}].P$. When no ambiguity is possible, we will\nremove scope parentheses in $\\NR x(P)$ and $\\SR x[P]$.\nWe will often avoid to indicate trailing~$\\INACT$s.\n\nThe combination of the accept and the block construct permits to design\nprocesses which are not \nsubject to interference attacks from the context. \nWe note that their role is dual: the accept operator prevents the reception (intrusion)\nof untrusted names from the environment, and its use is specified by the programmer. \nThe block mechanism prevents another process from sending (extruding) a secret name, \nand it is inserted automatically by the system to ensure the protection of such \nnames. \nOne may wonder whether we could have used just one form of (trusted) input, and declare\nthe names\nto be blocked by accepting all names in $\\cal N$ but the intended ones. The main reason\nthat guided our choice is that we believe that our form of input with blocked names can be\neffectively implemented, for instance by using blacklists. Also, we think that there is a\nnice symmetry among processes $\\RECEIVE x{y\\forbids B}P $ and $\\NR xP$, and among\nprocesses $\\RECEIVET x{y\\accept A}P $ and $\\SR xP$.\n \n\nWe embed the block mechanism in the rules for structural congruence through the \noperation~$\\uplus$ defined in Figure~\\ref{fig:reduction}. {\\it Blocked} names could indeed\nbe introduced both statically and dynamically, i.e. when structural congruence is\nperformed during the computation. We leave the time when the system blocks explicitly the\nname in components as an implementation detail. \nNote that in the second rule of the first line \nthe name $b$ is guaranteed to be different from all the names in $A$, because in the\ncongruence rule for \\emph{hide} (cfr same Figure) the free names of Q are\nrequired to be different from the name we want to hide, so the alpha conversion should be\napplied .\n\n\n\n\n\\input{fig-reduction-rev}\nFollowing standard lines, we define the semantics of our calculus\nvia a reduction\nrelation, also specified in Figure~\\ref{fig:reduction}.\nWe assume a capture-free substitution operation $\\subs zy$: \nthe process $P \\subs zy$ is obtained from $P $ by substituting all the free occurrences of $y$ \n by $z$.\nAs usual, we use a structural congruence $\\equiv$ to rearrange processes.\nSuch congruence includes the equivalence induced by alpha-conversion, and the relations defined in Figure~\\ref{fig:reduction}.\nThe rules for the $\\pi$-calculus operators (first line) are the standard ones.\nThe rules for inaction under a binder follow (second line).\nWe recall that the scope extrusion rule for \\keyword{new} (third line) permits to\nenlarge the scope of a name and let a process receive it. \nIn contrast, the scope extrusion rule for \\keyword{hide} (fourth line) permits to \nenlarge the scope of a name, but at the same time it sets the name to \\emph{blocked} for\nthe process which are being included in the scope, thus preventing them to receive the\nname. The last rule (fifth line) permits to swap the two binders. \n \nThe first rule for reduction, \\reductionrulename{Com}, says that an input process of the form\n $\\RECEIVE x{y\\forbids B}P$ is allowed to synchronize with an output process $\\SEND\nxzQ$ and receive the name~$z$ provided that~$z$ is not \\emph{blocked}\n($z\\not\\in B$). \nThe result of the synchronization is the progression of both the receiver and the sender,\nwhere the formal parameter in the input's continuation is replaced by the name~$z$. Note\nthat whenever $B=\\emptyset$ we have the standard communication rule of the $\\pi$-calculus.\nThe main novelty is represented by the rule for trusted communication \n \\rtcom. This rule says that an output process can send a\nname $z$ over $x$ to a parallel process waiting for input on $x$, provided that $z$ is\nexplicitly declared as accepted ($z\\in A$) by the receiver. If this is the case, the name\nwill replace the occurence of the formal parameter in the input's continuation. \nRules \\reductionrulename{New} and \\reductionrulename{Hide} are for {\\sf new} and for \n{\\sf hide} respectively, and follow the same schema. \nThe rules for parallel composition, replication and incorporating structural congruence\nare standard. \n\nWe let $P \\Rightarrow P'$ whenever either (a) $P \\rightarrow \\cdots \\rightarrow P'$, or \n(b) $P'=P$.\n\n\\begin{example}\\label{example:secrecy}\nWe show how {\\sf hide} can be used to prevent the extrusion of a secret.\nConsider the \nprocess:\\vspace{-.5em}\n\\[ \nP \\;\\stackrel{\\text{\\scriptsize def}}{=}\\; \\SR {z}[ \\SENDn xv ] \\qquad x\\ne z\n\\]\nThe process $\\SENDn xv$ can be interpreted as an internal attacker trying to\nleak the name $v$ to a context $C[-]\\;\\stackrel{\\text{\\scriptsize def}}{=}\\; -\\mid x(y).\\SENDn{leak}y $. \nBy using the structural rule for enlarging the scope of hide in\nFigure~\\ref{fig:reduction} we infer that $C[P] \\equiv \\SR {z}[ \\SENDn xv \\mid\nx(y\\forbids\nz).\\SENDn{leak}y]$.\nWhenever the name $v$ is not declared secret, that is whenever $v\\ne z$, the leak\ncannot be prevented: by applying \\reductionrulename{Com},\\reductionrulename{Hide}, and \\rstruct we have $C[P]\\osred\n\\SENDn{leak}v $.\nConversely, when the name $v$ is protected by {\\sf hide}, that is $v=z$, we do\nnot have any interaction and secrecy is preserved.\n\\end{example} \n \n\n\\begin{example}\\label{example:accepted}\nThe combined use of the accept and block sets permits to avoid\ninterference with the context. \nConsider the process below, where $n>0$:\\vspace{-.6em}\n\\begin{align*}\nP &\\;\\stackrel{\\text{\\scriptsize def}}{=}\\; \\SR {z_1} \\cdots \\SR {z_n}[\\cdots[x[y\\accept Z].P \\mid \\SENDn\nx{z_i} ]\\cdots] \n&&\nZ \\subseteq \\{z_1,\\cdots z_n\\},i\\in \\{1,\\dots,n\\} \n\\end{align*}\nTake a context $C[-] \\;\\stackrel{\\text{\\scriptsize def}}{=}\\; -\\mid \\NR y !\\SENDn xy \\mid \n!x(w)$. Such context is unable to send the fresh name $y$ to $P$,\nbecause the input process in $P$ is programmed to accept only trusted names protected\nby {\\sf hide}. Dually, the context cannot\nreceive the protected name~$z_i$. \nTherefore $C$ and~$P$ cannot interact: $C[P]\\osred Q$ implies that a) \n$Q\\equiv C[\\SR {z_1} \\cdots \\SR\n{z_n}[\\cdots[P\\subs {z_i}y ]\\cdots]]$ or b) $Q\\equiv C[P]$.\n\\end{example}\n\n\n \n\\section{Related work}\n\\label{sec:discussion}\n\n\\ignore{ \nThe idea that the restriction operator of the $\\pi$-calculus ({\\sf new}) and its scope extrusion mechanism\ncan model the possession and communication of a secret goes back to the spi\ncalculus~\\cite{AbadiG99}. In this approach, one can devise specifications of protocols\nthat rely on channel-based communication protected by {\\sf new}, and establish the\ndesired security properties by using equivalences representing indistinguishablity even in the presence of a Dolev-Yao attacker.\nHowever, while the secrecy properties of some protocols can be enforced by relying on\ndedicated channels, this is not obvious when protocols describe\ninter-site communication over the Transport\/Internet layer. \nIt is also not obvious to implement scope extrusion over dedicated channels. \nIn the presence of open, untrusted networks the secrecy of the protocol needs to be\nrecovered by means of other mechanisms, for instance by using asymmetric\ncryptography. However, preserving secrecy in the presence of scope\nextrusion is problematic~\\cite{abadi98}, and eventually leads to complex cryptographic\nprotocols which rely on a set of certified authorities~\\cite{popl07}. \nMoreover, the attacker can detect a communication, even if she cannot retrieve the content\nof the message. \n\nBased on these considerations, in this paper we argue that the\n{\\sf new} operator of the $\\pi$-calculus does not adequately represent confidentiality.\nWe enrich the $\\pi$-calculus with another operator for security, ({\\em hide}), which\ndiffers from {\\sf new} in that it forbids the extrusion of a name and hence has a static\nscope. To emphasize the\ndifference, we introduce a spy process that represents a side-channel attack and\nbreaks some of the standard security equations for {\\sf new}.\n}\n\nMany analysis and programming techniques for security have been developed for process\ncalculi. Among these, \nwe would mention the security analysis enforced by means of static and dynamic\ntype-checking (e.g.~\\cite{CardelliGG05,Hennessy05,tgc05}), \nthe verification of secure implementations and protocols that are \nprotected by cryptographic encryption\n(e.g.~\\cite{BorealeNP01,AbadiFG02,AbadiBF07,popl07}),\nand programming models that consider a notion of location \n(e.g.~\\cite{Hen07,SewellV03,CastagnaVN05})\n\n\nThe paper~\\cite{CardelliGG05} introduces a type system for a $\\pi$-calculus with groups\nthat permits to control the distribution of resources: names can be received only by\nprocesses in the scope of the group. The intent is, as in our paper, to preserve the\naccidental or malicious leakage of secrets, even in the presence of untyped opponents. \nA limitation of~\\cite{CardelliGG05} is that processes\nthat are not statically type-checked are interpreted as opponents trying to leak secrets. \nOn contrast, our aim is to consider systems where processes could dynamically join\nthe system at run-time; this permits us to analyze the secrecy of protocols composed by\ntrusted sub-systems that can grow in size of the number of the participants.\nWhile devising an algorithm for type checking groups can be non-trivial \n(cf.~\\cite{VasconcelosH93}), \nwe note that actual systems do not often rely on types, even for local\ncommunications. For instance D-Bus (cf. Section~\\ref{sec:examples}) relies on a mandatory\naccess control policy enforced at the kernel level through process IDs. Our\nsemantics-based approach appears as adequate to describe such low-level mechanisms. \n\n\nAs discussed in the introduction, concrete implementations of $\\pi$-calculi models\ndo protect communications by means of cryptography. The problem of devising a secure,\nfully abstract implementation has been first introduced\nin~\\cite{abadi98} and subsequently tackled for the join calculus in~\\cite{AbadiFG02}. \nThe paper~\\cite{BorealeNP01} introduces a bisimulation-based technique to prove\nequivalences of processes using cryptographic primitives; this can be used to show that\na protocol does preserve secrecy. We follow a similar\napproach and devise bisimulation semantics for establishing the secrecy of processes\nrunning in an environment where the distribution of channels is controlled. \nThe presence of a spy in our model is reminiscent of the network abstraction\nof~\\cite{mik-mscs10}. In that paper, the network provides the low-level counter part of\nthe model where attacks based on bit-string representations, interception, and\nforward\/reply\ncan be formalized. \n\nFrom the language design point of view, we share some similarity with the ideas\nbehind the boxed $\\pi$-calculus~\\cite{SewellV03}. \nA box in~\\cite{SewellV03} acts as wrapper where we can confine untrusted process;\ncommunication among the box and the context is subject to a fine-grained control that\nprevents the untrusted process to harm the protocol.\nOur {\\sf hide} operator is based on the symmetric principle: processes\nwithin the scope of an {\\sf hide} can run their protocol without be disturbed by the\ncontext outside it. \n \n\nAn interesting approach related to ours in spirit -- but not in conception or details --\nis D-fusion~\\cite{BorealeBM04}. \nThe calculus has two forms of restriction: A\n\"$\\nu$\" operator for name generation, and a \"$\\lambda$\" operator that behaves like an\nexistential quantifier and it can be seen as a generalization of an input binder. Both\noperators allow extrusion of the entities they declare but only the former guarantees\nuniqueness. In contrast our {\\sf hide} operator is not meant as an existential nor as an\ninput-binder and it prevents the extrusion of the name it declares.\n\n\\medskip\\noindent{\\bf Acknowledgements }\n We wholeheartedly thank the extremely competent, anonymous reviewers of EXPRESS 2012. \n They went beyond the call of duty in providing excellent reports which have been very helpful to improve our paper. \n\\section{Distrusting communications protected by restriction}\n\\label{sec:spy} \n\nIn this section we introduce a {\\em spy} process that \nrepresents a side-channel attack against communications that occur on untrusted\nchannels, that is: channels that are not protected by {\\sf hide}. \nWe assume that the spy is not able to retrieve the content of an exchange.\nThe spy abstraction models the ability of the context to detect interactions\nwhen the processes are implemented by means of network protocols which do not rely on \ndedicated channels, and therefore require some mechanism to enforce the secrecy of the\nmessage (e.g. cryptography). \nThis ability leads to break some of the standard security\nequations for \nthe {\\sf new} operator, which can be recovered by re-programming the protocol and making \nuse of the {\\sf hide} operator.\nWe add to the syntax of the secret $\\pi$-calculus the following process where we\nlet \\keyword{spy} be a reserved keyword. We let $P,Q,R$ to range over \\emph{spied\nprocesses}. \n\n \\begin{align*} \n P,Q,R &\\; ::= \\; \\cdots \\;\\mid\\; \\spyb P && \\text{spied processes}\\\\\n S &\\; ::= \\; \\{x\\} \\;\\mid\\; \\emptyset && \\text{spied set}\n \\end{align*} \n \n\n\\input{fig-spy-rev}\nWhen in $\\spyb P$ the spied set $S$ is equal to $\\{x\\}$, noted\n$\\keyword{spy}\\accept x . P$, this permits to make explicit which (free) reduction\nthe spy shall observe. Note that listening on multiple names can be easily programmed by\nputting in parallel several spies. \nThe spy process $\\keyword{spy}\\accept\\emptyset. P$, noted $\\spy P$, will be used to\ndetect reductions protected by restriction. \nWe let the free and bound names of\nthe\n\\emph{spy} be defined as follows:\n$\\fv(\\spyb R)\\;\\stackrel{\\text{\\scriptsize def}}{=}\\; S\\cup\\fv(R)$ and \n$\\bv(\\spyb R)\\;\\stackrel{\\text{\\scriptsize def}}{=}\\; \\bv(R)$. \n\nThe semantics of spied processes is\ndescribed by adding the communication rules in Figure~\\ref{fig:spy} to those in\nFigure~\\ref{fig:reduction}: \nThe rules describe a form of synchronization among three processes: a sender on\nchannel~$x$, a receiver on channel~$x$, and a {\\it spy} on channel~$x$. More in detail,\nrule \\sreductionrulename{Com} depicts a synchronization among an input\nof the form $\\RECEIVE x{y\\forbids B}P$, a sender and a spy, while rule \\rstcom describes\na similar three-synchronization but for a trusted input of the form $\\RECEIVET x{y\\accept \nA}P$. \n\nThe definition of observational equivalence \nfor spied processes is obtained by extending Definition~\\ref{def:obs-equivalence}\nto the semantics in Figure~\\ref{fig:spy}; we indicate the resulting equivalence with\n$\\stackrel{\\bullet}{\\cong}$. This will permit to study the security of processes in presence of the\n\\emph{spy}. \n\n\n \n\\input{fig-lts-spy-rev}\nTo make the picture clear, in Figure~\\ref{fig:lts-spy} we introduce labelled\ntransition semantics for spied processes. \nWe consider two new actions $?x$ and $!x$ corresponding\nrespectively to the presence of a \\emph{spy} and to a signal of communication.\n\\begin{align*}\n\\alpha &\\; ::= \\; \\cdots \\mid\\, ?x \\mid !x \n\\end{align*} \n\nWe assume the existence of variable~$\\nu\\in\\cal N$\nthat cannot occur in the process syntax,\nand we use it to signal restricted communications. \nIt is convenient to define the notion of (free) subject and object of an action.\nWe let $\\operatorname{subj}(\\alpha)\\;\\stackrel{\\text{\\scriptsize def}}{=}\\; \\{x\\}$ whenever $\\alpha=\\SENDn xy,(y)\\SENDn xy, x(y)$, and\nbe empty otherwise. We define $\\operatorname{obj}(\\alpha)\\;\\stackrel{\\text{\\scriptsize def}}{=}\\; \\{ y\\}$ whenever $\\alpha=\\SENDn\nxy,x(y)$, and $\\operatorname{obj}(\\alpha)=\\emptyset$ otherwise.\n\nThe lts in Figure~\\ref{fig:lts-spy} introduces three new rules for the\n\\emph{spy}, \\sltsrulename{Spy}, \\sltsrulename{Spy-Res} and \\sltsrulename{Spy-Com}, and re-defines the rules for restriction, for\n{\\sf hide} and for communication of Figure~\\ref{fig:lts}. \nIn rule \\sltsrulename{Spy} the process $\\keyword{spy}:x. P$ can fire an action $?x$\nand progress to~$P$. %\nThe dual action, $!x$, is fired in rules \\sltsrulename{Com} and \\slclose whenever a communication\noccurred on a free channel~$x$. \nRule \\sltsrulename{Spy-Com} describes the eaves-dropping of a communication. \nA process of the form $\\keyword{spy}.P$ can only fire an action $?\\nu$ through\nrule \\sltsrulename{Spy-Res}.\nIn rule \\lres\t we use a partial function $\\enc{\\cdot}_x$ to relabel the action fired\nunderneath a restriction: we let\n$\\enc{\\alpha}_x\\;\\stackrel{\\text{\\scriptsize def}}{=}\\;\\alpha$ whenever $x\\not\\in\\fv(\\alpha)$, \n$\\enc{!x}_x\\;\\stackrel{\\text{\\scriptsize def}}{=}\\; !\\nu$, $\\enc{?x}_x\\;\\stackrel{\\text{\\scriptsize def}}{=}\\; ?\\nu$. This will be\nused to signal restricted communications, as introduced. \nDifferently, in rule \\ltsrulename{Hide} we use a relabeling partial function $\\encH{\\cdot}_x$ that\nmakes invisible communications that occur under \\emph{hide}. We let\n$\\encH{\\alpha}_x\\;\\stackrel{\\text{\\scriptsize def}}{=}\\;\\alpha$ whenever $x\\not\\in\\fv(\\alpha)$, \n$\\encH{!x}_x\\;\\stackrel{\\text{\\scriptsize def}}{=}\\; \\tau$ and $\\encH{?x}_x\\;\\stackrel{\\text{\\scriptsize def}}{=}\\; \\tau$. \n \n\n\\begin{definition}[Bisimilarity]\nA symmetric relation $\\,{\\cal R}\\,$ over spied processes is a bisimulation if\nwhenever $R_1\\,{\\cal R}\\, R_2$ and $R_1\\lts{\\alpha}R'$ then there exists \na spied process $R''$ such that $R_2 \\Lts{\\tau}\\lts{\\hat\\alpha}\\Lts{\\tau}R''$ and \n$R'\\,{\\cal R}\\, R''$ where \n$\\hat\\tau$ is the empty string, and\n$\\hat\\alpha=\\alpha$ otherwise. \nBisimilarity, noted $\\stackrel{\\bullet}{\\approx}$, is the largest bisimulation.\n\\end{definition} \n\nBy using the same construction of Section~\\ref{sec:bisimulation}, we obtain the\nmain result of this section: observational equivalence for spied processes and \nbisimilarity coincide. As a by-product, we can also use bisimulation as a technique to\nprove that two processes cannot be distinguished by the {\\it spy}. \n\n\\begin{theorem}[Full Abstraction]\n\\label{theor:spy-fa}\n$\\stackrel{\\bullet}{\\cong} \\, =\\,\\stackrel{\\bullet}{\\approx}$. \n\\end{theorem}\n\\begin{proof}[Sketch of the proof]\nTo see that behavioural equivalence is included in bisimilarity, we proceed by\nco-induction as in the proof of Proposition~\\ref{prop:completeness} by \nrelying on contexts $C^A_\\alpha$ that detect whenever a process does emit a weak\naction $\\alpha$. Given a set of names $A$ such that $\\fv(\\alpha)\\subseteq A$\nand $\\omega\\not\\in A$ we define the following contexts to account for the new actions\n$!x$ and $?x$.\n\\begin{align*}\nC^A_{!x}[-]&\\;\\stackrel{\\text{\\scriptsize def}}{=}\\; \\keyword{spy}\\accept x. {\\SENDn\\omega{}} &&x\\ne \\nu\n\\\\\nC^A_{?x}[-]&\\;\\stackrel{\\text{\\scriptsize def}}{=}\\; x(y).\\SENDn\\omega{} \\mid \\SENDn x{} &&x\\ne \\nu\n\\\\\nC^A_{!\\nu}[-]&\\;\\stackrel{\\text{\\scriptsize def}}{=}\\; \\keyword{spy} . {\\SENDn\\omega{}} \n\\\\\nC^A_{?\\nu}[-]&\\;\\stackrel{\\text{\\scriptsize def}}{=}\\; \\NR{x}(x(y).\\SENDn\\omega{} \\mid \\SENDn x{}) \n\\end{align*}\nThe proof then proceeds routinely by following a schema similar to the one of\nProposition~\\ref{prop:completeness}.\nThe reverse direction, namely that bisimilarity is contained in behavioural equivalence,\nis shown by proving that $\\stackrel{\\bullet}{\\approx}$ is closed under the {\\sf new}, {\\sf hide}, and\nparallel composition operators. See~\\cite{tech-report} for all the details.\n\\end{proof}\n\n","meta":{"redpajama_set_name":"RedPajamaArXiv"}} +{"text":"\\section{Introduction}\\label{sec:introduction}}\n\n\\IEEEPARstart{R}ecently, the intelligent spectrum management has received more attention than past few years since it shows the ability to efficiently allocate the scarce frequency resource. It is one of the key techniques for next-generation communication systems to liberate the spectrum\\cite{pahlavan2021understanding}. However, the wireless service provider and the airlines initiated a discussion about whether the 5G can affect the safety of aircrafts\\cite{news2022}. The cornerstone of intelligent spectrum management, interference monitoring and modeling, can be a solution to forecast the interference and dynamically allocate the spectrum without affecting the safety of other systems. \nThe CRN (Cognitive radio network) has been well researched since it plays an essential role in spectrum sharing\\cite{okegbile2021stochastic}. It requires accurate interference modeling to protect the user's communication. Related work in\\cite{yun2021intelligent} proposed an intelligent dynamic spectrum resource management mechanism that can coexist with other CRNs. The stochastic geometry-based models get rid of extensive Monte Carlo simulations and provide methods for random spatial patterns. This kind of model treats the locations of the base stations as points distributed\\cite{wang2016stochastic}, and they are widely used in analyzing the performance of CRN. Using stochastic geometry tools, authors in\\cite{lu2021stochastic} presented a comprehensive spatial-temporal analysis of large-scale communications systems.\n\n\n\\begin{figure*}[t!]\n\\centering\n\\hfill\n\\subfigure[]{\n \\begin{minipage}[b]{0.48\\textwidth}\n \\centering\n \\includegraphics[width=0.75\\textwidth,scale=0.3]{New_Figures\/Picture1b.png}\n \\label{fig:1_1}\n \\end{minipage}\n}\n\\hfill\n\\subfigure[]{\n \\begin{minipage}[b]{0.48\\textwidth}\n \\centering\n \\includegraphics[width=0.75\\textwidth,scale=0.3]{New_Figures\/Picture1a.png}\n \\label{fig:1_2}\n \\end{minipage}\n}\n\n\\caption{Measurement scenarios in our dataset, (a) Outdoor (b) Indoor}\n\\end{figure*}\n\n\\begin{figure*}[t!]\n\\begin{minipage}[b]{\\textwidth}\n \\centering\n \\includegraphics[width=\\textwidth]{New_Figures\/Picture2.png}\n \\end{minipage}\n \\caption{Trajectory and Measurement \\label{fig:2}}\n\\end{figure*}\n\nRelated works successfully establish models for Wi-Fi bands to determine whether the channel is busy. \\cite{hou2021modeling} measured the 2.4 GHz and 5GHz Wi-Fi bands and proves the current channel allocation is not efficient enough. 7 different distributions are evaluated using Kolmogorov-Smirnov (KS) distance, Kullback-Leibler (KL) divergence, and Bhattacharyya distance to compare the predictability. Authors in \\cite{hou2021modeling} monitored the 2.4 GHz and 5 GHz bands in a railway station with fixed location receivers. Spectrogram plays a vital role in the analysis of temporal features. To exploit the spectrogram using Deep Learning algorithms, \\cite{bhatti2021shared} proposes the Q-spectrogram and shows it is better for CNN than the traditional spectrogram using experimental data. The Deep Learning model trained on Q-spectrogram offers 99\\% accuracy in estimating the Wi-Fi traffic load (five density levels). Instead of using the locations of base stations, \\cite{al2018free} monitors 915-928 MHz ISM-band in Melbourne, Australia. The authors stated that the normalized histogram follows a log-normal distribution. The duty cycles are calculated across all the frequency bins as the key parameters for evaluating occupancy. The definition of whether a band is busy varies in the literature, But for Wi-Fi bands, the binarization of data can simplify the modeling. \\cite{al2018free} and \\cite{hou2021modeling} converted the data into binary patterns and counted the length of the continuous busy and idle durations with certain resolutions. The threshold for binarization also varies in the literature since it depends on the design purpose of the application. In this work, we follow a similar approach to analyze the interference behavior in 1.9-2.5 GHz. Most of the related works focus only on the unlicensed bands without considering the licensed band. The problem is if we can use the same method to model the interference in licensed bands and if we can monitor and predict the occupancy in all types of frequency bands. \nTo explore the possibility of allocating both licensed and unlicensed bands, we collected interference measurements in the spectrum in an urban area in Worcester, MA, and in a laboratory building of WPI. We proposed an interference model based on both temporal and spatial information. During the data collection, we added the GPS tag to each measurement to prove interference in the licensed band is highly related to location information. The rest of this paper is organized as follows; We first introduce the importance of spectrum monitoring and interference modeling. In part \\ref{sec:2}, we present the scenario and equipment in the data collection phase and show the result of spectrum monitoring. In part \\ref{sec:3}, we construct the interference model and analyze the interference behavior based on the real data. In part 4, we state the importance of interference modeling in intelligent spectrum management and present the Contribution of this study.\n\n\n\n\\section{The Measurement Scenarios and Data Analysis}\n\\label{sec:2}\nIn this section, we will introduce the measurement scenarios and dataset size and structure. The equipment used in the study is Agilent E4407B ESA-E Spectrum Analyzer, which can measure 9kHz to 26.5 GHz with 0.4 dB overall amplitude accuracy. The frequency of interest is 1.9 GHz to 2.5 GHz, including the LTE band and 2.4 GHz ISM band. Therefore, we are able to compare the interference for different types of bands. Fig.\\ref{fig:1_1} shows the outdoor measurement scenario. We put the spectrum analyzer on the back seat of the car and connected it with a laptop using a GPIB cable. Benefit from PyVISA, we can easily control the equipment and retrieve data from it. The GPS receiver is also connected to the laptop to label the data with GPS coordinates. For the indoor environment shown in Fig.\\ref{fig:1_2}, we put the spectrum analyzer on a cart and move it around the third floor of Atwater Kent laboratory of WPI. We do not use GPS in this scenario since the GPS receiver performs poorly in the indoor environment, which can have an error up to tens of meters.\n\n\nFig.\\ref{fig:2} shows a test drive on the selected route. We select an area near Worcester Common, Worcester, MA, an urban region with a large population. There are at least 5 cellular towers around. Fig. 2 left is the map of the selected area, and the trajectory is marked as a solid red dot. The relative location is calculated by GPS coordinates. Fig. 2 right is the spectrum measurement corresponding to this location. The frequency range is 1.9 GHz to 2.5 GHz, and the amplitude is from -20 dBm to -70 dBm. Each test drive is about 10 - 15 minutes, depending on the traffic situation. We can collect about 700 \u2013 1000 measurements during the drive. Each measurement consists of 401 amplitude readings representing the 600 MHz frequency span and the 2.2 GHz center frequency. The omnidirectional antenna is used in this study. Since the noise level changes over time for different measurements, we normalized the receiver power to make fair comparisons.\n\nWithout processing the collected data, we look into the raw data for an overview of temporal and spatial behavior of the interference. To analyze the difference between licensed and unlicensed bands, we plot the spectrogram of the data. Fig 3 is one set of data, including a complete test drive. Fig.\\ref{fig:3_1} is the spectrogram of the measurement starting at 0 sec and ending at 950 sec, and the power is between -20 dBm and -70 dBm. In this figure, different times also represent other locations. For licensed bands, we observe higher interference at locations closer to the cell tower (around 504 sec) than on the open road (0 \u2013 216 sec). 1.9 GHz \u2013 2.0 GHz has a similar spatial pattern as 2.1 \u2013 2.2 GHz since the variations in power levels are almost the same. For the 2.4 GHz unlicensed band, the interference is discontinuous, and the power level is significantly lower than the licensed bands. Fig.\\ref{fig:3_2} is the congested plot of the data showing the interference between 1.9 GHz and 2.5GHz. 2.0 GHz \u2013 2.1 GHz and 2.2 -2.3 GHz seems to be inactive bands during the experiment, which shows the potential of spectrum sharing applications. \n\n\n\\begin{figure*}[t!]\n\\centering\n\\hfill\n\\subfigure[]{\n \\begin{minipage}[b]{0.48\\textwidth}\n \\centering\n \\includegraphics[width=\\textwidth]{New_Figures\/Picture3.png}\n \\label{fig:3_1}\n \\end{minipage}\n}\n\\hfill\n\\subfigure[]{\n \\begin{minipage}[b]{0.48\\textwidth}\n \\centering\n \\includegraphics[width=\\textwidth]{New_Figures\/Picture3b.png}\n \\label{fig:3_2}\n \\end{minipage}\n}\n\n\\caption{(a) Spectrogram of One Test Drive (b) Congested Plot}\n\\end{figure*}\n\n\\begin{figure*}[t!]\n\\centering\n\\hfill\n\\subfigure[]{\n \\begin{minipage}[b]{0.3\\textwidth}\n \\centering\n \\includegraphics[width=\\textwidth]{New_Figures\/licensed.png}\n \\label{fig:new_1}\n \\end{minipage}\n}\n\\hfill\n\\subfigure[]{\n \\begin{minipage}[b]{0.3\\textwidth}\n \\centering\n \\includegraphics[width=\\textwidth]{New_Figures\/unlicensed.png}\n \\label{fig:new_2}\n \\end{minipage}\n}\n\\hfill\n\\subfigure[]{\n \\begin{minipage}[b]{0.3\\textwidth}\n \\centering\n \\includegraphics[width=\\textwidth]{New_Figures\/inactive.png}\n \\label{fig:new_3}\n \\end{minipage}\n}\n\n\\caption{Histograms of 4 Datasets in Different Bands: (a) Licensed (b) Unlicensed (c) Inactive}\n\\end{figure*}\n\n\\begin{figure}[t!]\n\\centering\n\\hfill\n \\begin{minipage}[b]{0.48\\textwidth}\n \\centering\n \\includegraphics[width=0.75\\textwidth,scale=0.3]{New_Figures\/histo_bands.png}\n \\end{minipage}\n \\label{fig:new2}\n \\caption{Comparison of Different Bands in the Same Scenario}\n\\end{figure}\n\n\n To analyze the difference between licensed and unlicensed bands, we plot the spectrogram of the data. Fig 3 is one set of data, including a complete test drive. Fig 3 (a) is the spectrogram of the measurement starting at 0 sec and ending at 950 sec. In this figure, different times also represent other locations. For licensed bands, we observe higher interference at locations closer to the cell tower (around 504 sec) than on the open road (0 \u2013 216 sec). 1.9 GHz \u2013 2.0 GHz has a similar spatial pattern as 2.1 \u2013 2.2 GHz since the variations in power levels are almost the same. For the 2.4 GHz unlicensed band, the interference is discontinuous, and the power level is significantly lower than the licensed bands. Fig 3 (b) is the congested plot of the data showing the interference between 1.9 GHz and 2.5GHz. 2.0 GHz \u2013 2.1 GHz and 2.2 -2.3 GHz seems to be inactive bands during the experiment, which shows the potential of spectrum sharing applications. \n\n\\begin{figure*}[t!]\n\\centering\n\\hfill\n\\subfigure[]{\n \\begin{minipage}[b]{0.3\\textwidth}\n \\centering\n \\includegraphics[width=\\textwidth]{New_Figures\/Picture4a.png}\n \\label{fig:4_1}\n \\end{minipage}\n}\n\\hfill\n\\subfigure[]{\n \\begin{minipage}[b]{0.3\\textwidth}\n \\centering\n \\includegraphics[width=\\textwidth]{New_Figures\/Picture4b.png}\n \\label{fig:4_2}\n \\end{minipage}\n}\n\\hfill\n\\subfigure[]{\n \\begin{minipage}[b]{0.3\\textwidth}\n \\centering\n \\includegraphics[width=\\textwidth]{New_Figures\/Picture4c.png}\n \\label{fig:4_3}\n \\end{minipage}\n}\n\n\\caption{(a) Data Binarization (b) Empirical CDF (c) Fitted CDF}\n\\end{figure*}\n\n\n\n\\section{Interference Modeling and Comparison}\n\\label{sec:3}\nIn this section, we begin with the comparison using histograms. Fig. 4 reveals the difference in amplitude distribution of 4 datasets when we plot the histogram of the same frequency bin. Fig.\\ref{fig:new_1} is the histogram of the licensed band. The indoor environment tends to have lower interference and is more centered. Fig.\\ref{fig:new_2} and Fig.\\ref{fig:new_3} are the plots for the unlicensed band and one of the unused bands, respectively. The main difference is the average interference level. We also compare the interference in each frequency band type by using only one dataset. Fig.\\ref{fig:new2} shows histograms of 3 frequency bands in the same dataset. The variance of interference in the licensed band seems much more significant than in the other two bands. \nTo have numerical comparisons, we can analyze the short-term variations of the interference in an IoT environment where many stationery and moving wireless devices interfere with each other based on circular scattering principles \\cite{clarke1968statistical} \\cite{pahlavan2005wireless}. This modeling enables a realistic performance evaluation of the RF cloud interference with any wireless device. According to Clarke's Model, the probability density function of the amplitude fluctuations follows a Rayleigh Distribution: \t\n\\[f(r) = \\frac{r}{{{\\sigma ^2}}}{e^{ - \\frac{{{r^2}}}{{2{\\sigma ^2}}}}},r \\ge 0\\]\nAs a device moves along a path with velocity $v_m$, the Doppler shift from each interfering source depends on the spatial angle of the direction of movement with the direction of the source, $\\alpha$,\n\\[{f_d} = \\frac{{{v_m}}}{\\lambda }\\cos \\alpha = {f_m}\\cos \\alpha \\Rightarrow \\alpha {\\cos ^{ - 1}}\\left( {\\frac{{{f_d}}}{{{f_m}}}} \\right)\\]\nFor uniform distribution of interference angle, $\\alpha$, the PDF ${f_A}(\\alpha )$ is given as: \n\\[{f_A}(\\alpha ) = \\frac{1}{{2\\pi }};\\alpha \\in ( - \\pi ,\\pi ]\\]\t \nThe Doppler spectrum of the interference is \\cite{pahlavan2005wireless}: \n \\begin{equation}\n{\\rm{D}}(f) = \\frac{1}{{2\\pi {f_m}}}{\\left[ {1 - (f\/{f_m})} \\right]^{ - \\frac{1}{2}}};\\left| f \\right| < {f_m}\n\\label{eq:doppler}\n\\end{equation}\nEq.\\ref{eq:doppler} allows one to simulate the interference for a mobile user for performance analysis by running a complex Gaussian noise through a filter reflecting Doppler spectrum characteristics \\cite{pahlavan2005wireless}. Then we can design software and hardware interference simulators to examine the effects of IoT interference on a communication link, a GPS device, or a radar. \n\n\\begin{figure*}[t!]\n\\centering\n\\hfill\n\\subfigure[]{\n \\begin{minipage}[b]{0.3\\textwidth}\n \\centering\n \\includegraphics[width=\\textwidth]{New_Figures\/Picture5a.png}\n \\label{fig:5_1}\n \\end{minipage}\n}\n\\hfill\n\\subfigure[]{\n \\begin{minipage}[b]{0.3\\textwidth}\n \\centering\n \\includegraphics[width=\\textwidth]{New_Figures\/Picture5b.png}\n \\label{fig:5_2}\n \\end{minipage}\n}\n\\hfill\n\\subfigure[]{\n \\begin{minipage}[b]{0.3\\textwidth}\n \\centering\n \\includegraphics[width=\\textwidth]{New_Figures\/Picture5c.png}\n \\label{fig:5_3}\n \\end{minipage}\n}\n\\caption{Doppler Spectrum (a) Inactive Band (2.2 GHz) (b) Unlicensed Band (2.4 GHz) (c) Licensed Band (1.95 GHz)}\n\\end{figure*}\n\n\n\nFor obtaining a model from empirical data, we first introduce data processing. The received power is first normalized using Min-Max scaling. The result normalized power is in the range [0, 1]. Then we convert the normalized power to a dummy variable using Eq.\\ref{eq:1}, where $I$ is the interference reading, and $I_{new}$ donates the result dummy variable. The data binarization makes computing the spectrum occupancy much easier. \n\n\\begin{equation}\n{I_{new}} = \\left\\{ \\begin{array}{l}\n0,I \\ge 0.1\\\\\n1,I < 0.1\n\\end{array} \\right.\n\\label{eq:1}\n\\end{equation}\n\nWe define the spectrum occupancy by counting the number of consecutive \"1\"s, which means if the current interference is greater than 10\\% of the maximum interference in this channel, we consider the band as occupied and busy, and it is unavailable to spectrum sharing.\nFig. 4a shows the result of the binarization of one of the licensed frequency bands. We can only observe about ten \"0\"s, so this frequency band is highly occupied. If we count the number of \"1\"s between every two \"0\"s, we can calculate the probability of the occupancy time for a specific frequency band. \nUsing the approach described above, we calculate the Cumulative Distribution Function (CDF) using real data. Fig 4b shows the empirical CDF of 3 different times of the day for the outdoor environment and one indoor dataset. All three outdoor datasets almost reach a probability of 0.9 for occupancy<=200. Since the sample rate is 1 per second, it means we have a 90\\% probability that the frequency occupancy is less than 200 seconds. For the indoor environment, the empirical CDF shows a probability of 0.22 for occupancy$<=$200. The outdoor environment tends to have less interference than the indoor environment because the indoor environment has more interference sources and a severe radio frequency (RF) environment. \nTo numerical compare the effect of interfence on spectrum occupancy, we fit the empirical data to obtain distribution and then evaluate the parameter. Since Rayleigh distribution is widely used for Wi-Fi channel occupancy modeling, we also apply it to the licensed band to have a fair evaluation. Fig 4c is the CDF of fitted Rayleigh distribution for four datasets mentioned before. Outdoor measurements approach 1 much faster than indoor measurements. The detailed parameters are shown in Table 1. \n\n\\begin{table}[]\n\\caption{Rayleigh Distribution Parameters}\n\\label{table:1}\n\\centering\n\\begin{tabular}{|l|l|l|}\n\\hline\n{Dataset} & {Loc} & {Scale} \\\\ \\hline\n8:00 Outdoor & -26.8908 & 65.8010 \\\\ \\hline\n12:00 Outdoor & -3.5453 & 9.0201 \\\\ \\hline\n16:00 Outdoor & -16.3339 & 40.9457 \\\\ \\hline\nAK 320 Indoor & 21.4714 & 182.7133 \\\\ \\hline\n\\end{tabular}\n\\end{table}\n\nWe further investigate the frequency domain of interference measurements for indoor and outdoor scenarios. We first deduct the average value from the data using Eq.\\ref{eq:2} to remove the DC component.\n\n \\begin{equation}\n{I_{new - i}} = {I_i} - \\frac{1}{N}\\sum\\limits_i^N {{I_i}} \n\\label{eq:2}\n\\end{equation}\n\nThen we apply FFT to the processed data. Using one of the outdoor datasets as an example, Fig.\\ref{fig:5_1} shows the frequency domain feature of an inactive band (2.2 GHz). Fig.\\ref{fig:5_2} is the FFT result of the unlicensed band (2.4 GHz). Fig.\\ref{fig:5_3} illustrates one of the licensed bands (1.95 GHz). Compared with the two more occupied bands, the inactive band shows fewer variances and tends to be \"flat\". Both licensed and unlicensed bands have a U-shape spectrum. The only difference is that the unlicensed band has minor variations. Frequency domain patterns can also contribute to estimating whether the spectrum resource is available to be allocated to secondary users. This section analyzes the interference in two environments using statistical approaches and the interference in different frequency bands using frequency-domain approaches. \n\n\n\n\n\\section{CONCLUSION}\nSpectrum monitoring using the spectrum analyzer provides an approach to read and log the interference in real-time. The collected dataset shows its potential for intelligence spectrum management with retrieved temporal and spatial information. In this study, we demonstrate that the interference is highly related to the location, time, and band type. By analyzing the probability distribution of the occupancy time, we can estimate how long we can allocate a currently unused frequency band to secondary users. The result in the frequency domain demonstrates different mechanisms should be considered for each type of frequency band while assigning frequency resources. The information obtained from spectrum monitoring is critical for intelligence spectrum management since it provides parameters for manege the interference. We believe more datasets and Deep Learning algorithms can make accurate dynamic spectrum allocation achievable.\n\n\n\\ifCLASSOPTIONcompsoc\n \n \\section*{Acknowledgments}\nI'm extremely grateful to my friends Jianan Li for driving me to collect the data and Fei Li for his help on pyVisa.\nI'd also like to express my thanks to my classmates in ECE 538 for their patience in peer-reviewing this work.\n\n\\else\n \n \\section*{Acknowledgment}\n\\fi\n\n\n\n\\ifCLASSOPTIONcaptionsoff\n \\newpage\n\\fi\n\n\n\n\n\\nocite{*}\n\\bibliographystyle{IEEEtran}\n","meta":{"redpajama_set_name":"RedPajamaArXiv"}} +{"text":"\\section{Introduction}\n\nIt is by now well established that particles confined to a two\ndimensional space can have fractional statistics. Interest in such\nparticles, which are called anyons, is partially motivated by their\nphysical effects such as their conjectured role in the fractionally\nquantized Hall effect \\cite{girvin} or high temperature\nsuperconductivity \\cite{hfl}, and partially by the fact that the\ndescription of anyons uses interesting mathematical structures.\nAnyons are a generalization of ordinary bosons or fermions where the\nwave functions of many identical particles, instead of being symmetric\nor antisymmetric, carry a representation of the braid group on their\ntwo dimensional configuration space \\cite{fracstat}. The braid group\non a two-dimensional space is an infinite, discrete, non-Abelian group\nand has many potentially interesting representations (see, for example\n\\cite{4}).\n\nAnyons are sometimes described mathematically by coupling the currents\nof particles to the gauge field of a Chern-Simons theory. This\ncoupling has been argued to produce fractional statistics both for the\ncase where particles are excitations of a dynamical quantum field\n\\cite{dynany} and when the matter is non-dynamical classical point particles\n\\cite{nondynany}. The representation of the braid group which arises\n(and therefore also the fractional statistics) can be either Abelian\nor non-Abelian. The former case arises from the quantization of\nAbelian Chern-Simons theory. It is also know that non-Abelian\nstatistics can arise from either non-Abelian Chern-Simons theory or\nelse Abelian Chern-Simons theory on a manifold whose fundamental group\nis non-trivial.\n\nFor an Abelian Chern-Simons theory, the action is\n\\BE \\label{csa}\nS=-{k \\over 4 \\pi}\\int A{\\rm d} A+\\int A_\\mu j^\\mu {\\rm d}^3 x\n\\EE\nwhere\n\\BE\nj^\\mu(x)=\\sum_{i=1}^n q_i \\int d\\tau\n\\frac{dr_i^\\mu}{d\\tau}\\delta^3(x-r_i(\\tau))\n\\label{curr}\n\\EE\nand $r_i^\\mu(\\tau)$ is the trajectory and $q_i$ the charge of the i'th\nparticle. (If particles are identical, then their charges should be\nequal.)\n\nIn this paper we shall examine the question of which representations\nof the braid group on a given Riemann surface are obtained from the\nwave functions of an Abelian Chern-Simons theory in the most general\ncase where the constant $k$ is a rational number, the Riemann surface\nhas arbitrary genus $g$ and the total charge of the particles is\nnon-zero. We shall construct the wave functions of the quantum theory\nwith action (\\ref{csa}) explicitly and find that, depending on the\ncoefficient $k$ and the genus of the configuration space, the wave\nfunction carries certain multi-dimensional, in general non-Abelian\nrepresentations of the braid group.\n\nThe wave function of Abelian Chern-Simons theory coupled to classical\npoint particles on the plane was found by Dunne, Jackiw and\nTrugenberger \\cite{8}. In this case the Chern-Simons theory has no\nphysical degrees of freedom, the Hilbert space is one-dimensional and\nthe only quantum state is given by a single unimodular complex number.\nFor a trajectory of $n$ particles with positions $z_i(t),~\ni=1,\\ldots,n$, $t\\in[0,1]$ which is periodic up to a permutation,\n$z_i(1)=z_{P(i)}(0)$, the phase of the wave function changes by the\nwell-known factor\n\\begin{displaymath}\nq_i q_j\\frac{1}{ k}\\sum_{il;\\ 1\\le l,p\\le g\n\\end{displaymath}\n\\BE \\label{braidrg}\n\\sigma_1^{-1}\\alpha_l\\sigma_1\\beta_l=\n\\beta_l\\sigma_1\\alpha_l\\sigma_1\\qquad\n1\\le l\\le g\n\\EE\nThese relations are necessary so that topologically equivalent braids\nare represented by identical elements of the braid group. There is\none additional relation which follows from the fact that there always\nexists a trajectory of a particle which encircles all other particles\nand traces all homology generators of ${\\cal M}$ and which is\nequivalent to a trivial loop on $Q_n({\\cal M})$. This leads to the\nrelation\n\\BE \\label{braidrt}\n\\sigma_1\\cdots\\sigma_{n-1}^2 \\cdots \\sigma_1\\beta_g\\beta_{g-1} \\cdots\n\\beta_1(\\alpha_1^{-1}\\beta_1^{-1}\\alpha_1) \\cdots\n(\\alpha_g^{-1}\\beta_g^{-1}\\alpha_g)=1\n\\EE\nThe above generators and relations constitute a presentation of the\ngeneral abstract braid group. In most cases, we are interested in\nrepresentations of this group, even finite dimensional ones.\n\nThe representations which follow from Abelian Chern-Simons theory are\nthe so-called pure $\\theta$-statistics representations where the\ngenerator of an interchange of neighboring particles is represented by\na phase, times a unit matrix, as the $\\sigma$ in (\\ref{jp}). In these\nparticular type of representations, the generators for particle\nexchanges $\\sigma_i$ and those for transport around handles satisfy a\nfar less restrictive set of relations due to the Abelian structure of\nthese $\\sigma_i$. They satisfy the relations (\\ref{braidra}) trivially\nwhile the relations (\\ref{braidrb}) tell us that the $\\sigma_i$ are\nequal, which we will called $\\sigma$. The remaining relations\n(\\ref{braidrg}) becomes\n\\begin{displaymath}\n[\\sigma,\\alpha_l]=[\\sigma,\\beta^l]=[\\alpha_l,\\alpha_m]=[\\beta^l,\\beta^m]=0\n\\end{displaymath}\n\\begin{displaymath}\n[\\alpha_l,\\beta^m]=0\\qquad{\\rm for}\\qquad l\\ne m\n\\end{displaymath}\n\\BE \\label{bgrel}\n\\alpha_l\\cdot\\beta^l=\\sigma^2\\beta^l\\cdot\\alpha_l\n\\EE\nand the global constraint (\\ref{braidrt}) for closed manifold is\n\\BE \\label{bggrel}\n\\sigma^{2(n+g-1)}=1\n\\EE\n\nWe will show that the wave functions of a Chern-Simons action coupled to\ncharges gives pure $\\theta$-statistic representations of the braid\ngroup on a Riemann surface, as these charges form braids in space-time.\n\n\\section{The decomposition of the gauge field}\n\nOur space will be an orientable 2-dimensional Riemann surface, ${\\cal\nM}$, of genus g. While our space-time will be a 3-dimensional manifold\nformed as the Riemann surface ${\\cal M}$ times a real line for the\ntime direction. In other words, the space-time metric is $g_{00}=1,\\\ng_{01}=g_{02}=0$ and the remaining components form the metric on\n${\\cal M}$. Since we have to consider the case of a non-zero total\nflux on ${\\cal M}$, the representation of this type of gauge field can\nbe done only on a set of patches covering ${\\cal M}$. Let us consider\nthe set of patches $U^i$ as a good cover of the manifold ${\\cal M}$.\nWe have a field $A^{(i)}$ on each patch $U^i$, with the transition\nfunctions defined on the intersection of any two patches $U^i\\cap U^j$\ngiven by\n\\BE \\label{trans}\nA^{(i)}-A^{(j)}=d\\chi^{(ij)}\n\\EE\nwhere $\\chi^{(ij)}=-\\chi^{(ji)}$ by definition. On triple intersection\n$U^i\\cap U^j\\cap U^k$ we can use (\\ref{trans}) to find the\nrelation \\BE\n\\chi^{(ij)}+\\chi^{(jk)}+\\chi^{(ki)}=c^{(ijk)}=\\ {\\rm constant}\n\\EE\nThe set of constants $c^{(ijk)}$ are related to the total flux by \\cite{9}\n\\BE \\label{F0}\nF_0=\\int_{\\cal M}{\\rm d} A=\\sum_i\\int_{V^i}{\\rm d} A^{(i)}=\\sum_{ij}\\int_{V^{ij}}\n{\\rm d}\\chi^{(ij)}=\\sum_{P^{ijk}}c^{(ijk)}\n\\EE\nwhere $V^i\\subset U^i$ and it is bounded by a line, $V^{ij}$, dividing the\nintersection $U^i\\cap U^j$. On the triple intersection, we\nlet the three lines $V^{ij}$, $V^{jk}$ and $V^{ki}$ meet at one point\n$P^{ijk}$.\n\nBefore quantizing, we will decompose the degrees of freedom of $A$ in\nits various components. To separate the effect of the non-zero total\nflux (\\ref{F0}) we will break it in two parts. First a fixed field\n$A_p$ with a total flux $F_0$ on ${\\cal M}$ localized at a reference\npoint $z_0$. This is an \"imaginary\" field without a direct physical\nmeaning, its purpose is to take care of the total flux. This will be\nthe field that has to be defined on patches, as explained above. The\nsecond field, $A_r$, is the remaining degree of freedom of $A$ on\n${\\cal M}$, a globally well defined 1-form. So we have\n\\BE \\label{decA}\nA=A_p+A_r\n\\EE\n\nWe decompose $A_r$ (without the $A_0{\\rm d} t$ part) into its exact, coexact\nand harmonic parts. More precisely, the Hodge decomposition of $A_r$,\non ${\\cal M}$, is given by (${\\rm d}$ and ${}^*$ act on ${\\cal M}$ in this\npaper)\n\\BE \\label{hda}\nA_r={\\rm d}(\\frac{1}{\\Box'}{}^*{\\rm d}^*A_r)+{}^*{\\rm d}(\\frac{1}{\\Box'}{}^*{\\rm d}\nA_r)+\\frac{2\\pi i}{k}\\sum_{l=1}^g(\\bar\\gamma_l\n\\omega^l-\\gamma_l\\bar\\omega^l)\n\\EE\nwhere $1\/\\Box'$ is the inverse of the laplacian $(\\Box)$ acting on\n0-forms where the prime means that the zero modes are removed. With\nour decomposition (\\ref{decA}), ${\\rm d} A_r$ do not have a zero mode.\nAlso we will set the zero mode of ${}^*{\\rm d}^* A_r=\\vec\\nabla\\cdot\\vec\nA_r$ to zero, using a time independent gauge transformation.\n\nThe first homology and cohomology group of ${\\cal M}$ tell us the number\nof additional degrees of freedom of $A$ there are on ${\\cal M}$ compared to\na plane, and how to take them into account. The zero modes for both ${\\rm d}$\nand\n${}^*{\\rm d}^*$ (or for $\\Box$) acting on a one-form are spanned by the set of\nAbelian differentials, $\\omega^l$, on ${\\cal M}$, called the holomorphic\n(function of $z$) harmonic forms (solution of $\\Box\\omega=0$). We can\nrepresent the homology of ${\\cal\nM}$ in terms of generators $a_l$ and its conjugate generators $b_l$,\n$l=1,\\ldots,g$. The intersection numbers of these generators are\ngiven by\n\\BE \\label{inter}\n\\nu(a_l,a_m)=\\nu(b^l,b^m)=0,\\ \\nu(a_l,b^m)=-\\nu(b^m,a_l)=\\delta_l^m\n\\EE\nwhere $\\nu(C_1,C_2)$ is the signed intersection number (number of\nright-handed minus number of left handed crossings) of the oriented\ncurves $C_1$ and $C_2$. The holomorphic harmonic one-forms $\\omega^l$\nhave the standard normalization\n\\cite{1}\n\\begin{displaymath}\n\\oint_{a_l}\\omega^m=\\delta_l^m,\\ \\oint_{b^l}\\omega^m=\\Omega^{lm}\n\\end{displaymath}\nThe matrix $\\Omega^{lm}$ is symmetric and its imaginary part is\npositive definite. This actually defines a metric in the space of\nholomorphic harmonic forms\n\\BE \\label{hfn}\n i\\int_{\\cal M}\\omega^l\\wedge\\bar\\omega^m=2{\\rm\nIm}(\\Omega^{lm})=G^{lm},\\ G_{lm}G^{mn}=\\delta_l^n\n\\EE\nWe will use $G_{lm}$ and $G^{lm}$ to lower or raise indices when needed and use\nEinstein summation convention over repeated indices.\n\nAny linear relation, with integer coefficients, of $a_l$ and $b_l$\nthat satisfy (\\ref{inter}) is another valid basis for the homology\ngenerators. These transformations form a symmetry of the Chern-Simons\ntheory and comprise the modular group, $Sp(2g,Z)$:\n\\BE \\label{mt}\n\\dc{a}{b}\\rightarrow S\\dc{a}{b}\\qquad{\\rm where}\\qquad S=\\dc{D\\ C}{B\\ A}\n\\EE\nwith $SES^\\top=E$ and $E=\\dc{\\ 0\\ 1}{-1\\ 0}$. The $g\\times g$\nmatrices $A,B,C,D$ have integer entries.\n\nWe can define\n\\begin{displaymath}\n\\xi=-\\frac{k}{2\\pi}\\frac{1}{\\Box'}{}^*{\\rm d}^* A_r~,~~\\ F_r={}^*{\\rm d} A_r\n\\end{displaymath}\nSo we then have the complete decomposition of the gauge field, with the\n$A_0{\\rm d} t$ part,\n\\BE \\label{ta}\nA_r=A_0{\\rm d} t-\\frac{2\\pi}{k}{\\rm d}\\xi+{}^*{\\rm d}(\\frac{1}{\\Box'}F_r)+2\\pi i\n(\\bar\\gamma_l \\omega^l-\\gamma_l\\bar\\omega^l)\n\\EE\nSimilarly we can write the current ${\\bf\nj}=j^\\mu\\frac{\\partial}{\\partial x^\\mu}$ into a one-form $j=j_\\mu{\\rm d}\nx^\\mu=j_0{\\rm d} t+\\tilde j$, using the metric. We can use again the\nHodge decomposition of ${}^*\\tilde j$ on ${\\cal M}$\n\\BE \\label{tj}\n{}^*\\tilde j=-{\\rm d}\\chi+{}^*{\\rm d}\\psi+i(j_l\\bar\\omega^l-\\bar j_l\\omega^l)\n\\EE\nThe continuity equation, using the 3-dimensional star operator ${}^{\\star}$,\n\\begin{displaymath}\n{\\rm d}^{\\star}j= (\\vec\\nabla\\cdot\\vec j){\\rm d}^3x=\\frac{\\partial\nj_0}{\\partial t}{\\rm d}^3x+{\\rm d}^*\\tilde j \\wedge{\\rm d} t=0\n\\end{displaymath}\ncan be used to solve for $\\psi$\n\\begin{displaymath}\n\\psi=-\\frac{1}{\\Box'}\\frac{\\partial j_0}{\\partial t}\n\\end{displaymath}\n\nWe shall consider a set of point charges moving on ${\\cal M}$, with\ntrajectories $z_i(t)$ and charge $q_i$, where $z_i(t)\\ne z_j(t)$ for\n$i\\ne j$. The current is represented by\n\\BE \\label{pcc}\nj_0(z,t)=\\sum_i q_i\\delta(z-z_i(t)),\\ \\tilde j(z,t)=\\sum_i\nq_i\\delta(z-z_i(t))\n\\frac{1}{2}(\\dot z_i(t){\\rm d}\\bar z+\\dot{\\bar z}_i(t){\\rm d} z)\n\\EE\nIntegrating (\\ref{pcc}) with the harmonic forms $\\omega^l$ , we find\nthe topological components of the current in (\\ref{tj})\n\\BE \\label{tc}\nj^l(t)=\\sum_i q_i\\dot z_i(t)\\omega^l(z_i(t))\\ ,\\qquad\\bar j^l(t)=\\sum_i q_i\n\\dot{\\bar z}_i(t)\\bar \\omega^l(\\bar z_i(t))\n\\EE\nThis is just telling us that integrating the topological currents $j^l(t)$\nover time is equivalent to a sum of the integral of the harmonic forms\n$\\omega^l$ over each charge trajectory.\n\nTo solve for $\\chi$, it is best to use complex notation\n\\begin{displaymath}\nR=\\psi+i\\chi=R(z,\\bar z)\n\\end{displaymath}\nwhere we find ${}^*{\\rm d}\\chi+{\\rm d}\\psi=\\partial_z\\bar R{\\rm d} z+\\partial_{\\bar z}\nR{\\rm d}\\bar z$. From (\\ref{tj}), (\\ref{pcc}) and using (\\ref{tc}) we find\n\\begin{displaymath}\n\\partial_z\\bar R+\\bar j_l\\omega^l(z)=\\frac{1}{2}\\sum_i q_i\\dot{\\bar z}_i\n\\delta(z-z_i(t))\n\\end{displaymath}\n\\BE \\label{R}\n\\partial_{\\bar z} R+j_l\\bar\\omega^l(\\bar z)=\\frac{1}{2}\\sum_i q_i\\dot{z}_i\n\\delta(z-z_i(t))\n\\EE\nTo solve (\\ref{R}) for $R$, we will need the prime form\n\\begin{displaymath}\nE(z,w)=(h(z)h(w))^{-{\\frac{1}{2}}}\\cdot\\Theta\\dc{1\/2}{1\/2}(\\int_z^w\\omega|\n\\Omega)\n\\end{displaymath}\nwhere $h(z)=\\frac{\\partial}{\\partial u^l}\\Theta\\dc{1\/2}{1\/2}\n(u|\\Omega)|_{u=0}\\cdot\\omega^l(z)$. The prime form is antisymmetric in\nthe variables $z$ and $w$ and behaves like $z-w$ when $z\\approx w$\n(the $h(z)$ which appear in the denominator are for\nnormalization).\\footnote{This formalism can also be extended to\ninclude the sphere, where there are no harmonic 1-forms at all (the\nspace of cohomology generators has dimension zero) by properly\ndefining the prime form. We use stereographic projection to map the\nsphere into the complex plane and use $E(z,w)=z-w$ as the definition\nof the prime form. }\n\nThe theta functions \\cite{7} are defined by\n\\BE \\label{thetaf}\n\\Theta\\dc{\\alpha}{\\beta}(z|\\Omega)=\\sum_{n_l}e^{i\\pi(n_l+\\alpha_l)\\Omega^{lm}\n(n_m+\\alpha_m)+2\\pi i(n_l+\\alpha_l)(z^l+\\beta^l)}\n\\EE\nwhere $\\alpha,\\ \\beta\\in [0,1]$, and have the following property\n\\begin{displaymath}\n\\Theta\\dc{\\alpha}{\\beta}(z^m+\ns^m+\\Omega^{ml}t_l|\\Omega)=e^{2\\pi i\\alpha_l s^l- i\\pi\nt_m\\Omega^{ml}t_l-2\\pi i t_m(z^m+\\beta^m)}\\Theta\\dc{\\alpha}{\\beta}(z|\n\\Omega)\n\\end{displaymath}\nfor integer--valued vectors $s^m$ and $t_l$. For a non-integer\nconstant $c$\n\\begin{displaymath}\n\\Theta\\dc{\\alpha}{\\beta}(z^m+c\n\\Omega^{ml}t_l|\\Omega)=e^{-i\\pi c^2 t_m\\Omega^{ml}\nt_l-2\\pi i c t_m(z^m+\\beta^m)}\\Theta\\dc{\\alpha-ct}{\\beta}(z|\\Omega)\n\\end{displaymath}\n\nThe solution of (\\ref{R}) is\n\\BE\nR=\\frac{\\partial}{\\partial t}[-\\frac{1}{2\\pi}\\sum_i\nq_i\\log(\\frac{E(z,z_i(t))}\n{E(z_0,z_i(t))})]-j_l(t)\\int_{z_0}^z(\\bar\\omega^l-\\omega^l)\n\\EE\nwhere we have chosen $R$ such that $R(z_0,\\bar z_0)=0$ for an\narbitrary point $z_0$\n, which we choose to be the same as the $z_0$ in the definition of $A_p$\n(We can choose $z_0=\\infty$ for genus zero).\nThe important fact about $R$ is that it is a single-valued function.\nIf we move $z$ around any of the homology cycles, $R$ returns to its\noriginal value. In fact, this is also true for windings of $z_0$, an important\nrelation since it is only a reference point. So\n\\BE \\label{chi}\n\\chi=\\frac{\\partial}{\\partial t}[-\\frac{1}{2\\pi}\\sum_i q_i\n{\\rm Im}\\log(\\frac{E(z,z_i(t))}{E(z_0,z_i(t))})]+\n\\frac{i}{2}[(j_l(t)+\\bar j_l(t))\\int_{z_0}^z(\\bar\\omega^l-\\omega^l)]\n\\EE\n\nThe action (\\ref{csa}) is written for a trivial U(1) bundle over ${\n\\cal M}$, that is for zero total flux. Every integral of the gauge field,\nwhich is invariant under a gauge transformation of $A$, can be extended\nuniquely into an integral using the $A^{(i)}$, defined on the set of\npatches, that is patch independent by adding appropriate terms.\nWe will represent our set of 3-dimensional patches as $V^i$. Then $V^i$\nand $V^j$ will share a common boundary, a\n2-dimensional surfaces $V^{ij}$.\nFinally, three surfaces $V^{ij}$, $V^{jk}$ and $V^{ki}$ will intersect along a\nline $L^{ijk}$, and four of these lines will terminate at a point\n$P^{ijkl}$. This might be best visualized as a triangulation of ${\\cal\nM}\\times[0,1]$ in term of 3-simplexes (or tetrahedrons), the $V^i$, with\n2-simplexes boundaries (or triangles), the $V^{ij}$, which in term has\n1-simplexes boundaries (or lines), the $L^{ijk}$, and finally those have\n0-simplexes (or points) as boundaries, the $P^{ijkl}$.\nFor our case, we will be using the proper extension of (\\ref{csa}), see\n\\cite{9,10}, that is\n\\begin{displaymath}\nS=-\\frac{k}{4\\pi}\\sum_i\\int_{V^i}A^{(i)}{\\rm d} A+\\frac{k}{4\\pi}\\sum_{ij}\\int\n_{V^{ij}}\\chi^{(ij)}{\\rm d} A-\\frac{k}{4\\pi}\\sum_{ijk}\\int_{L^{ijk}}c^{<(ijk)}\nA^{(k)>}+\\frac{k}{4\\pi}\\sum_{P^{ijkl}}c^{<(ijk)}\\chi^{(kl)>}(P)\n\\end{displaymath}\n\\BE \\label{pcsa}\n+\\sum_i\\int_{V^i}A^{(i)}{}^{\\star}j-\\sum_{ij}\\int_{V^{ij}}\\chi^{(ij)}{}^\n{\\star}j+\\sum_{ijk}\\int_{L^{ijk}}c^{<(ijk)}W^{(k)>}-\\sum_{P^{ijkl}}c^{<(ijk)}\n\\tilde\\chi^{(kl)>}(P)\n\\EE\nwhere the one-form $W$ is defined by ${}^{\\star}j={\\rm d} W$ locally, but since\n$\\int_{\\cal M}{}^{\\star}j=Q$,\nthis can be done only on patches\nwhere $W^{(i)}-W^{(j)}={\\rm d}\\tilde\\chi^{(ij)}$, in\nthe same way as we did for the gauge field $A$. The bracket $<...>$ mean put\nthe\nindices in increasing order (with appropriate sign) and set the repeated\nindex according to position, see \\cite{10}.\nIt will be useful to do the same decomposition of\n$j$ as we did for $A$, by having $j=j_p+j_r$, where $j_p$ is a\nterm corresponding to a single particle of charge $Q$ at the reference\npoint $z_0$.\n\nThe complicated expression (\\ref{pcsa}) for the action ensure that the\ntotal expression is independent of the triangulation of the manifold used\nfor the evaluation of each integral. For example, if we change the patches\n$V^i$, the integrand in the first term will change by a total derivative,\nleading to a correction term integrated over the boundaries of the $V^i$,\nthat is the $V^{ij}$. But the second term, in return, will change in such a\nway as to cancel the change generated by this first term, leaving the total\naction invariant. A similar effect can be found for the other terms in\n(\\ref{pcsa}).\n\nUsing (\\ref{decA}), the decomposition of $j$ and performing several\nintegrations by parts gives\n\\begin{displaymath}\nS=-\\frac{k}{4\\pi}\\int_{{\\cal M}\\otimes{\\cal\nR}}A_r{\\rm d} A_r+\\frac{k}{2\\pi}\\int_{{\\cal M}\n\\otimes{\\cal R}}A_r{\\rm d} A_p+\\int_{{\\cal M}\\otimes{\\cal\nR}}A_r({}^\\star j_r+{}^\\star j_p)+\\int_{{\\cal M}\\otimes{\\cal R}}W_r{\\rm d} A_p\n\\end{displaymath}\n\\BE \\label{topcsa}\n+[-\\frac{k}{4\\pi}\\int A_p{\\rm d} A_p+\\int A_p{}^\\star j_p]+{\\rm Surface\\ terms}\n\\EE\nThe terms in brackets, involving $A_p$ and $j_p$, has to be performed using\nthe extended decomposition (\\ref{pcsa}), by replacing $A$ with $A_p$.\nFor our case, we extend the\ntriangulation of ${\\cal M}$ trivially through the time direction.\nThe surface terms, appearing at the time boundaries ($t=0$ and $t=t_f$), are\nnot important for the quantum theory or\nthe braid group representation that we will find later on. They can't be\navoided since the action is not invariant under gauge transformations at\nthe time boundaries. Thus there is no terms to cancel the\ntriangulation dependent terms. This will not be a problem since under a\nperiodic configuration we are\neffectively working on ${\\cal M}\\times S^1$, so there is no surface term,\nor alternatively the surface terms are equal and cancel each other.\nAlso, surface terms do not affect the dynamics or quantization of the system.\nWe also represent $A_p$ such that ${\\rm d} A_p=F_0\\delta(z-z_0){\\rm d}^2 x$, which\nimplies that $z_0$ must stay within one patch at all time. And similarly\nfor $j_p$ since it is equal to $Q\\delta(z-z_0){\\rm d} t$. After a quick\ncalculation, we find that the terms inside the brackets are all zero, except\nfor the integral, $\\oint c^{<(ijk)}W^{k>}$, which is defined\nmodulo $c^{(ijk)}Q$ (for periodic motion). This is because $W$ is defined\non patches also, due to the total charge $Q$. At the quantum level, we are\nleft with a phase $e^{ic^{(ijk)}Q}$, but since the $c^{(ijk)}$ are\narbitrary except for the constraint (\\ref{F0}), the real ambiguity is\n$e^{iQ F_0}$. Actually,\nthe integral $\\int A{}^\\star j$ is equal to $\\sum_i q_i\\int_{C_i}A$,\nthe Wilson line integral for a\nset of charges $q_i$ following the curves $C_i$. In this case for each\nof these Wilson line integrals, corresponding to the charge $q_i$, we find\na phase $e^{i q_i F_0}$ instead. To solve these ambiguities we impose\nthese phases to be equal to unity as constraints on our system.\n\nOn the other hand, if in addition to the gauge field $A$, we had a second\nindependent Abelian gauge field, say $\\Gamma$, then a similar phase\nambiguity, $e^{i h_i \\chi_E}$, would arise. Here $h_i$ will be the charge\nattached to the particle $i$ corresponding to this new field, and\n$\\chi_E=\\int_{\\cal M}{\\rm d}\\Gamma$ is the total flux. The important fact,\nnow, is that the phase ambiguity from both gauge fields would appear at\nthe same time, thus we would have to impose the constraint\n\\BE \\label{fconst}\ne^{iq_i F_0-i h_i \\chi_E}=1\n\\EE\nto obtain a consistent quantum theory\n(the minus sign has been added to simplify the notation later on).\nAt this stage, the new field $\\Gamma$ seems artificial, but it turns out\nthat it is necessary to introduce such a field for Chern-Simons theory. In\nfact, it correspond to a connection on the tangent space of ${\\cal M}$.\nWe will need it because for each charge trajectory we will attach a\nframing (a unit vector on ${\\cal M}$). Such a framing has to be defined\nin relation to the basis of the tangent space, so $\\Gamma$ does not\nhave to be the associated metric connection, but it will enjoy the same\nglobal properties. It is well known that $\\chi_E=4\\pi(1-g)$, known as the\nEuler class of ${\\cal M}$. Note that we will assume that the field\n$\\Gamma$ does not have any flux around the particles (an effect similar\nto cosmic string), this would lead to a gravitational change in the\nstatistic of these particles. The charges $h_i$\nwill be equal to $q_i^2\/2k$, this will appear quit naturally in the next\nsection. Like we did for the filed $A$, we will concentrate all the\nflux, $\\chi_E$, of $\\Gamma$ around the point $z_0$. This will allow us to\nassume a constant framing on ${\\cal M}$, except when we cross the point\n$z_0$, in which case the constraint (\\ref{fconst}) will be used to fix any\nphase ambiguity.\n\nThe term $\\int_{{\\cal M}\\otimes{\\cal R}}W_r{\\rm d} A_p=F_0\\int_{\\cal R}W_{r0}\n(z_0){\\rm d} t$, but a simple calculation shows that $W_{r0}=-\\chi$. Since\n$\\chi(z_0)=0$, we set it up this way by definition, this term vanishes. If\nwe had not used our freedom in the definition of $\\chi$ to set it up this\nway, we would have to take care of its effects on the hamiltonian and\nultimately the wave function.\n\n\\section{Quantization}\n\nNow we are ready to solve for the action. By\nputting (\\ref{ta}) and (\\ref{tj}) back into (\\ref{topcsa}) we find\n\\begin{displaymath}\nS=\\frac{1}{2}\\int(\\xi\\dot F_r-\\dot\\xi F_r){\\rm d}^3x+i\\pi k\\int(\\gamma^l\n\\dot{\\bar\\gamma}_l-\\dot\\gamma^l\\bar\\gamma_l){\\rm d} t+\\int A_0(j_0\n-\\frac{k}{2\\pi}F){\\rm d}^3x\n\\end{displaymath}\n\\BE \\label{tcsa}\n-\\int(\\frac{2\\pi}{k}\\xi\\frac{\\partial j_0}{\\partial t}+F_r\\chi){\\rm d}^3x\n+2\\pi i\\int(j_l\\bar\\gamma^l -\\bar j^l\\gamma_l){\\rm d} t+{\\rm Surface\\ terms}\n\\EE\n\n{}From this we obtain the equal-time commutation relations of the quantum\ntheory\n\\BE \\label{qv}\n[\\xi(z),F_r(w)]=-iP\\delta(z-w)\\qquad {\\rm or}\\qquad\nF_r(z)=iP\\frac{\\delta}{\\delta\n\\xi(z)}\n\\EE\nand\n\\BE \\label{tqv}\n[\\gamma_l,\\bar\\gamma_m]=-\\frac{1}{2\\pi k}G_{lm}\\qquad {\\rm or}\\qquad\n\\bar\\gamma_l=\\frac{1}{2\\pi k}G_{lm}\\frac{\\partial}{\\partial\\gamma_m}=\n\\frac{1}{2\\pi k}\\frac{\\partial}{\\partial\\gamma^l}\n\\EE\nThe projection operator, $P$, in (\\ref{qv}) changes the delta function to\n$\\delta(z-w)-1\/{\\rm Area} ({\\cal M})$, this is needed since $F_r$ does not\nhave a zero mode ($\\int_{\\cal M} F_r{\\rm d}^2 x=0$). The functional derivative\nmust\nalso be defined using this projection operator. With this holomorphic\npolarization \\cite{3} it is convenient to use the following measure in\n$\\gamma$ space\n\\begin{displaymath}\n(\\Psi_1|\\Psi_2)=\\int e^{-2\\pi k\\gamma^m G_{ml}\\bar\\gamma^l}\n\\Psi_1^*(\\bar\\gamma)\\Psi_2(\\gamma)|G|^{-1}\\prod_m {\\rm d}\\gamma^m{\\rm d}\\bar\\gamma^m\n\\end{displaymath}\nwhere $|G|=\\det(G_{mn})$. With this measure, we find that $\\gamma^\\dagger=\\bar\n\\gamma$ as it should be.\n\n$A_0$ is a Lagrange multiplier which enforces the Gauss' law\nconstraint\n\\begin{displaymath}\nF(z)-\\frac{2\\pi}{k}j_0(z)=iP\\frac{\\delta}{\\delta\\xi(z)}+F_0\\delta(z-z_0)-\\frac\n{2\\pi}{k}j_{r0}(z)+\\frac{2\\pi}{k}Q\\delta(z-z_0)\\approx 0\n\\end{displaymath}\nfrom which we extract $F_0=\\frac{2\\pi}{k}Q$. Since $F_0$ and $Q$ are not\nquantum variables, this is a strong equality. Thus leaving\n\\BE \\label{glc}\nF_r(z)-\\frac{2\\pi}{k}j_{r0}(z)=iP\\frac{\\delta}{\\delta\\xi(z)}-\\frac\n{2\\pi}{k}j_{r0}(z)\\approx 0\n\\EE\n\nUnder a modular transformation, the basis $\\gamma^l$, ${\\bar\\gamma}^l$\nwill be transformed accordingly. This will not change the choice of\npolarization, since the modular transformations do not mix $\\gamma$\nand $\\bar\\gamma$.\n\n{}From (\\ref{tcsa}), (\\ref{qv}) and (\\ref{tqv}), we find that the hamiltonian,\nin the $A_0=0$ gauge, can be separated into two commuting parts (where we\nused $\\frac{\\partial j_0}{\\partial t}=\\frac{\\partial j_{r0}}{\\partial t}$)\n\\begin{displaymath}\nH=-\\int_{\\cal M}A\\wedge^*\\tilde j= H_0+H_T\n\\end{displaymath}\nwhere\n\\BE\nH_0=\\int_{\\cal M}(\\frac{2\\pi}{k}\\xi\\frac{\\partial j_{r0}}{\\partial t}+\ni\\chi P\\frac{\\delta}{\\delta\\xi}){\\rm d}^2 x\n\\EE\nwhile the\nadditional part that takes care of the topology is\n\\BE \\label{th}\nH_T=i(2\\pi\\bar j_l\\gamma^l-\\frac{1}{k}j^l\\frac{\\partial}\n{\\partial\\gamma^l})\n\\EE\n\nTo solve the Schr\\\"odinger equation, we will use the fact that the\nhamiltonian separates, thus writing the wave function as\n\\begin{displaymath}\n\\Psi(\\xi,\\gamma,t)=\\Psi_0(\\xi,t)\\Psi_T(\\gamma,t)\n\\end{displaymath}\nwith the Gauss' law constraint (\\ref{glc})\n\\begin{displaymath}\n(iP\\frac{\\delta}{\\delta\\xi}-\\frac{2\\pi}{k}j_{r0})\\Psi_0(\\xi,t)=0\n\\end{displaymath}\nwhich is solved by\n\\BE \\label{gwf}\n\\Psi_0(\\xi,t)=\\exp[-\\frac{2\\pi i}{k}(\\int_{\\cal M}\\xi(z) j_{r0}(z,t)\n{\\rm d}^2 x)]\\Psi_c(t)\n\\EE\nNote that in (\\ref{gwf}) there is a term $-Q\\xi(z_0)$ out of the integral,\nthis shows the presence of an \"imaginary\" charge at $z_0$, wiht a flux\n$F_0$.\n\nThe first Schr\\\"odinger equation is \\begin{displaymath}\ni\\frac{\\partial\\Psi_0(\\xi,t)}{\\partial t}=H_0 \\Psi_0(\\xi,t)=\n\\left[ \\int_{\\cal M} \\left( \\frac{2\\pi}{k}\\xi\\frac{\\partial j_{r0}}{\\partial\nt}+ i\\chi P\\frac{\\delta}{\\delta\\xi} \\right) {\\rm d}^2 x\\right] \\Psi_0(\\xi,t)\n\\end{displaymath}\nwhich has the solution \\cite{2}\n\\BE \\label{psij}\n\\Psi_c(t)=\\exp\\left[ -\\frac{2\\pi i}{k} \\int_0^t \\int_{\\cal M}\n\\chi(z,t^\\prime) j_{r0}(z,t^\\prime) {\\rm d}^2 x {\\rm d} t^\\prime \\right]\n\\EE\nFor a system of point charges, the use of (\\ref{chi}) with\n(\\ref{gwf}) and (\\ref{psij}), allows us to write $\\Psi_0$ as\n\n\\BE \\label{bgp}\n\\Psi_0(\\xi,t)=\\exp\\left[-\\frac{2\\pi i}{k}(\\sum_i\nq_i\\xi(z_i(t))-Q\\xi(z_0))+\\frac\n{i}{2k}\\sum_{ij} q_i q_j \\int_0^t {\\rm d} t\\dot\\theta_{ij}(t)+\\Phi(t) \\right]\n\\EE\nwhere\n\\begin{displaymath}\n\\Phi(t)=\\frac{\\pi}{k}\\left[\\int_0^t j_l(t^\\prime){\\rm d} t^\\prime \\int_0^\n{t^\\prime} \\bar j^l(t^{\\prime\\prime}){\\rm d} t^{\\prime\\prime}-\\int_0^t\\bar\nj_l( t^\\prime){\\rm d} t^\\prime \\int_0^{t^\\prime} j^l(t^{\\prime\\prime}){\\rm d}\nt^{\\prime\n\\prime}\\right]\n\\end{displaymath}\n\\BE \\label{phase}\n+\\frac{\\pi}{2k}\\left[\\int_0^t \\bar j_l(t^\\prime){\\rm d} t^\\prime \\int_0^ t\n\\bar j^l(t^\\prime){\\rm d} t^\\prime-\\int_0^t j_l( t^\\prime){\\rm d} t^\\prime\n\\int_0^t j^l(t^\\prime){\\rm d} t^\\prime\\right]\n\\EE\nand\n\\begin{displaymath}\n\\theta_{ij}(t)={\\rm Im}\\log\\left[\\frac{E(z_i(t),z_j(t))}{E(z_i(t),z_0)E(z_0\n,z_j(t))}\\right]\n\\end{displaymath}\n\\BE \\label{angfunc}\n+{\\rm Im}\\left[\\int_{z_0}^{z_i(0)}\\omega^l\\int_{z_j(0)}^{z_j(t)}\n(\\omega_l+\\bar\\omega_l)+\\int_{z_0}^{z_j(0)}\\omega^l\\int_{z_i(0)}^{z_i(t)}\n(\\omega_l+\\bar\\omega_l)\\right]\n\\EE\nis a multi-valued function defined using the prime form. We will need\nthe phase (\\ref{phase}) for the topological part of the wave function.\nThe function $\\theta_{ij}(t)$ is the angle function for particle $i$\nand $j$.\n\nFor $i=j$, we find a self-linking term of the form ${\\rm\nIm}\\log(z_i-z_i)={\\rm\nIm}\\log(0)$ which is an undetermined expression, although not a\ndivergent one. One way to solve the problem is to choose a framing\n\\BE \\label{frame}\nz_i(t)=z_j(t)+\\epsilon f_i(t)\n\\EE\nwhich leads to the replacement of $E(z_i(t),z_i(t))$ by $f_i(t)$. This\ncorrespond to a small shift in the position of the charges in $j_{r0}$, but\nnot in $\\chi$. In effect, this leads to a small violation of the continuity\nequation. Alternatively, we can view this term as the additional gauge\nfield $\\Gamma$ introduced in the last section. With the framing\n(\\ref{frame}), we find that\n\\begin{displaymath}\n\\int\\frac{q_i^2}{2k}\\dot\\theta_{ii}{\\rm d} t=h_i\\int_{C_i}\\Gamma\n\\end{displaymath}\nwhere $C_i$ is the trajectory of $q_i$ on ${\\cal\nM}$, representing a coupling of the particles, of charges $h_i$, to an\nAbelian gauge field $\\Gamma$, as claimed in the last section. We also recover\nthese charges as $h_i=q_i^2\/2k$, which actually are\nthe conformal weights of the underlying two dimensional conformal field\ntheory \\cite{2}.\n\nThe angle function (\\ref{angfunc}) depends on $z_0$, but it\nshould be invariant if we move $z_0$ either infinitesimally or around\nan homology cycle. For a small displacement there is no change unless\none of the charge trajectories, $z_i(t)$, passing by $z_0$ from one side\nis now going from the other side. Looking at the denominator of\n$\\theta_{ij}$, we see that this will change $\\Psi_0$ by\n$e^{i\\frac{2\\pi}{k}q_iQ}$, while looking at the numerator, we find a phase\n$e^{i\\frac{2\\pi}{k}q_i^2(g-1)}$ due to the flux $\\chi_E$ of $\\Gamma$. Or\nalternatively, the framing of $z_i$ is subject to a rotation of\n$\\chi_E\/2\\pi=2(1-g)$ turns as we go around ${\\cal M}$, an effect that we\nconcentrated around $z_0$ here. The total phase shift is\n\\BE \\label{fconsf}\ne^{i\\frac{2\\pi}{k}q_i(Q+q_i(g-1))}=1\n\\EE\nThis is equal to one by imposing the constraint (\\ref{fconst}),\nwith the use of the Gauss' law constraint $F_0=\\frac{2\\pi}{k}Q$ and our\nchoice of $\\chi_E$. The equation\n(\\ref{fconsf}) will represent a fundamental constraint that has to be\nsatisfied by all charges if we want a consistent solution to Chern-Simons\ntheory.\n\nLooking at (\\ref{angfunc}) shows that we can write\n$\\sum_{ij}q_iq_j{\\rm Im}\\log[E(z_i(t),z_0)E(z_0,z_j(t))]^{-1}$ as\n$\\sum_iq_i(-Q){\\rm Im}\\log[E(z_i(t),z_0)]+\\sum_j(-Q)q_j{\\rm Im}\\log\n[E(z_0,z_j(t))]$, thus representing an additional charge $-Q$ at $z_0$.\nThe constraint (\\ref{fconsf}) is indicating that this is indeed an \"imaginary\"\ncharge and that it should not be seen by any real charge.\nFor the displacement of\n$z_0$ around an homology cycle, we find that the angle function changes only\nby a constant, thanks to the second term in (\\ref{angfunc}), which will\ncancel out when we take the difference in (\\ref{bgp}). This point is\nactually more complicated; we will come back to it later on.\nSo the wave function (\\ref{bgp}), with the angle function (\\ref{angfunc}),\naccurately forms a representation of the braid group on a plane\n\\cite{2,8}, or $\\sigma$ is one of the generator of the full braid group\n(\\ref{bgrel})-(\\ref{bggrel}). We will cover the full braid group in more\ndetail later on.\n\nNow, the topological part of the hamiltonian is used to find the part of the\nwave function affected by the currents going around the non-trivial loops of\n${\\cal M}$. The Schr\\\"odinger equation for (\\ref{th}) is\n\\begin{displaymath}\ni\\frac{\\partial\\Psi_T(\\gamma,t)}{\\partial t}=\nH_T\\Psi_T(\\gamma,t)=\ni\\left(2\\pi\\bar j_l\\gamma^l -\\frac{1}{k} j^l\n\\frac{\\partial}{\\partial\\gamma^l} \\right)\n\\Psi_T(\\gamma,t)\n\\end{displaymath}\nwhich has the solution\n\\BE\n\\Psi_T(\\gamma,t)\n=\\exp \\left[ 2\\pi\\gamma^l \\int_0^t\\bar j_l(t^\\prime)\n{\\rm d} t^\\prime - \\frac{2\\pi}{k} \\int_0^t j_l(t^\\prime)\n{\\rm d} t^\\prime \\int_0^{t^\\prime} \\bar j^l(t^{\\prime\\prime}){\\rm d} t^{\\prime\\prime}\n\\right] \\tilde\\Psi_T(\\gamma,t)\n\\EE\nNote that with the phase (\\ref{phase}), the double integral above will turn\ninto $\\int_0^t j_l(t^\\prime){\\rm d} t^\\prime \\cdot\\int_0^t \\bar j^l(t^{\\prime})\n{\\rm d} t^{\\prime}$, a topological expression.\n\nThe remaining equation for $\\tilde\\Psi_T(\\gamma,t)$\n\\BE\n\\frac{\\partial\\tilde\\Psi_T(\\gamma,t)}{\\partial t}\n=-\\frac{1}{k}\\ j^l \\frac{\\partial\\tilde\\Psi(\\gamma,t)}\n{\\partial\\gamma^l}\n\\EE\nis easily solved in the form\n\\BE \\label{tpsit}\n\\tilde\\Psi_T(\\gamma^l,t)\n=\\tilde\\Psi_T(\\gamma^l -\\frac{1}{k} \\int_0^t j^l(t^\\prime){\\rm d} t^\\prime)\n\\EE\n\n\\section{Large gauge transformations}\n\nThe wave function (\\ref{tpsit}) is not arbitrary, but must satisfy the\ninvariance of the action (\\ref{csa}) under large gauge transformations, when\nthere is no current around. So let us set $j^\\mu=0$ for this section and find\nthe condition on $\\tilde\\Psi_T$.\n\nIn general, the large $U(1)$ gauge transformations are given by the set of\nsingle-valued gauge functions, with $s^m$ and $t_m$ integer-valued vectors,\n\\begin{displaymath}\nU_{s,t}(z)=\\exp\\left(2\\pi i(t_m\\eta^m(z)-s^m\\tilde\\eta_m(z)\\right)\n\\end{displaymath}\nwhere\n\\begin{displaymath}\n\\eta^m(z)=i\\int_{z_0}^z(\\bar\\Omega^{ml}\\omega_l-\\Omega^{ml}\\bar\\omega_l)\\\n,\\qquad \\tilde\\eta_m(z)=-i\\int_{z_0}^z(\\omega_m-\\bar\\omega_m)\n\\end{displaymath}\n\nIf we change the endpoint of integration by $z\\rightarrow z+a_l u^l+b^m v_m$\nwith $u,v$ integer and $a,b$ defined in\n(\\ref{inter}), we find $\\eta^m\\rightarrow\\eta^m+u^m,\\\n\\tilde\\eta_m\\rightarrow\\tilde\\eta_m+v_m$ and $U_{s,t}\\rightarrow U_{s,t}e^\n{2\\pi i(t_m u^m-\ns^m v_m)}=U_{s,t}$. The transformation of the gauge field (\\ref{hda}) under\n$U_{s,t}$ is given by\n\\BE \\label{lgt}\n\\gamma^m\\rightarrow\\gamma^m+s^m+\\Omega^{ml}t_l\\ ,\\qquad\\bar\\gamma^m\\rightarrow\n\\bar\\gamma^m+s^m+\\bar\\Omega^{ml}t_l\n\\EE\nThe classical operator that produces the transformation (\\ref{lgt})\n\\begin{displaymath}\nc_{s,t}(\\gamma,\\bar\\gamma)=\\exp\\left[(s^m+\\Omega^{ml}t_l)\\frac{\\partial}\n{\\partial\\gamma^{m}}+(s^m+\\bar\\Omega^{ml}t_l)\\frac{\\partial}{\\partial\\bar\n\\gamma^{m}}\\right]\n\\end{displaymath}\nmust be transformed into the proper quantum operator acting on the wave\nfunction\n$\\tilde\\Psi_T$. By using the commutation (\\ref{tqv}) to replace $\\frac\n{\\partial}{\\partial\\bar\\gamma^{m}}$ by $-2\\pi k\\gamma_m$ we find the\noperators $C_{s,t}$ which implement the large gauge transformations \\cite{5}\n\\BE \\label{glgt}\nC_{s,t}(\\gamma)=\\exp\\left[-2\\pi k(s^m+\\bar\\Omega^{ml}t_l)\\gamma_m-\\pi\nk(s^m+\\bar\n\\Omega^{ml}t_l)G_{mn}(s^n+\\Omega^{nl}t_l)\\right]e^{(s^m+\\Omega^{ml}t_l)\\frac\n{\\partial}{\\partial\\gamma^{m}}}\n\\EE\n\nThe quantum operators $C_{s,t}$ do not commute among themselves for\nnon-integer $k$. From now on we will set $k=\\frac{k_1}{k_2}$ for integer\n$k_1$ and $k_2$. Now, in contrast with their classical counterparts, the\noperators $C_{s,t}$ satisfy the clock algebra\n\\BE \\label{clka}\nC_{s_1,t_1}C_{s_2,t_2}=e^{-2\\pi ik(s^m_1{t_m}_2-s^m_2{t_m}_1)}C_{s_2,t_2}\nC_{s_1,t_1}\n\\EE\nTheir action on the wave function is\n\\begin{displaymath}\nC_{s,t}(\\gamma)\\tilde\\Psi_T(\\gamma^m)=\\exp\\left[-2\\pi k(s^m+\\bar\\Omega^{ml}t_l)\n\\gamma_m\\right.\n\\end{displaymath}\n\\BE \\label{ca}\n\\left.-\\pi k(s^m+\\bar\\Omega^{ml}t_l)G_{mn}(s^n+\\Omega^{nl}t_l)\\right]\n\\tilde\\Psi_T(\\gamma^m+s^m+\\Omega^{ml}t_l)\n\\EE\nOn the other hand $C_{k_2s,k_2t}$ commutes with everything and must be\nrepresented only by phases $e^{i\\phi_{s,t}}$. This implies, using (\\ref{ca}),\n\\begin{displaymath}\n\\tilde\\Psi_T(\\gamma^m+k_2(s^m+\\Omega^{ml}t_l))=\\exp\\left[-i\\phi_{s,t}+2\\pi\nk_1(s^m+\\bar\\Omega^{ml}t_l)\\gamma_m\\right.\n\\end{displaymath}\n\\BE \\label{algc}\n\\left.+\\pi k_1k_2(s^m+\\bar\\Omega^{ml}t_l)G_{mn}\n(s^n+\\Omega^{nl}t_l)\\right]\\tilde\\Psi_T(\\gamma^m)\n\\EE\nThe only functions that are doubly (semi-)periodic are combinations of the\ntheta functions (\\ref{thetaf}).\nAfter some algebra, we find that the set of functions\n\\BE \\label{tqf}\n\\Psi_{p,r}\\dc{\\alpha}{\\beta}(\\gamma|\\Omega)=e^{\\pi k\\gamma^m\\gamma_m}\\Theta\n\\dc{\\frac{\\alpha+k_1 p+k_2 r}{k_1 k_2}}{\\beta}(k_1\\gamma|k_1 k_2\\Omega)\n\\EE\nwhere $p=1,2,\\dots,k_2$ and $r=1,2,\\dots,k_1$ with $\\alpha,\\ \\beta\\in[0,1]$\nsolve the above algebraic conditions (\\ref{algc}).\nTheir inner product is given by\n\\BE\n(\\Psi_{p_1,r_1}|\\Psi_{p_2,r_2})=\\int_P e^{-2\\pi k\\gamma^mG_{ml}\\bar\\gamma^l}\n\\overline{\\Psi_{p_1,r_1}(\\gamma)}\\Psi_{p_2,r_2}(\\gamma)\n|G|^{-1}\\prod_m {\\rm d}\\gamma^m{\\rm d}\\bar\\gamma^m\n\\EE\n\\begin{displaymath}\n=|G|^{-\\frac{1}{2}}\\delta_{p_1,p_2}\\delta_{r_1,r_2}\n\\end{displaymath}\nThe integrand is completely invariant under the translation (\\ref{lgt}), thus\nwe restrict the integration to one of the\nplaquettes $P$ ($\\gamma^m=u^m+\\Omega^{ml}v_l$ with $u,v\\in[0,1]$), the phase\nspace\nof the $\\gamma$'s.\n\nUnder a large gauge transformation\n\\begin{displaymath}\nC_{s,t}\\Psi_{p,r}\\dc{\\alpha}{\\beta}(\\gamma)=\\exp\\left [2\\pi ikp_m s^m+i\\pi\nks^m t_m+\\frac{2\\pi i}{k_2}(\\alpha_m s^m-\\beta^m\nt_m)\\right ]\\Psi_{p+t,r}\\dc{\\alpha}{\\beta}(\\gamma)\n\\end{displaymath}\n\\BE\n=\\sum_{p^\\prime}[C_{s,t}]_{p,p^\\prime}\\Psi_{p^\\prime,r}\\dc{\\alpha}{\\beta}\n(\\gamma)\n\\EE\nThe matrix $[C_{s,t}]_{p,p^\\prime}$ forms a $(k_2)^g$ dimensional\nrepresentation\nof the algebra (\\ref{clka}) of large gauge transformations.\n\nThe parameters $\\alpha$ and $\\beta$ appear as free parameters, but in fact\nthey may be fixed such that we obtain a modular invariant wave function.\nThe modular transformation (\\ref{mt}) on our set of functions (\\ref{tqf}) is\n\\begin{displaymath}\n\\Psi_{p,r}\\dc{\\alpha}{\\beta}(\\gamma|\\Omega)\\rightarrow|C\\Omega+D|^{-\\frac{1}\n{2}}e^{-i\\pi\\phi}\\Psi_{p,r}\\dc{\\alpha^\\prime}{\\beta^\\prime}(\\gamma\n^\\prime|\\Omega^\\prime)\n\\end{displaymath}\nwhere $\\gamma^\\prime={(C\\Omega+D)^{-1}}^\\top \\gamma,\\ \\Omega^\\prime=(A\\Omega+B)\n(C\\Omega+D)^{-1}$ and $\\phi$ is a phase that will not concern us here (and\n$G^\\prime_{lm}=[(C\\Omega+D)^{-1}]_{lr}G_{rs}[(C\\bar\\Omega+D)^{-1}]_{sm}$).\nMost important are the new variables\n\\begin{displaymath}\n\\alpha^\\prime=D\\alpha-C\\beta-\\frac{k_1 k_2}{2}(CD^\\top)_d\\qquad\\beta^\\prime=\n-B\\alpha+A\\beta-\\frac{k_1 k_2}{2}(AB^\\top)_d\n\\end{displaymath}\nwhere $(M)_d$ mean $[M]_{dd}$, the diagonal elements.\n\nA set of modular invariant wave functions \\cite{4,5,6} can exist only when\n$k_1 k_2$ is even, where we set $\\alpha=\\beta=0$ (and also $\\phi=0$).\nIn the case of odd $k_1 k_2$, we can set $\\alpha,\\ \\beta$ to either $0$ or\n$\\frac{1}{2}$, which amount to the addition of a spin structure on the wave\nfunctions. This will increase the number of functions by $4^g$ which will now\ntransform non trivially under modular transformations.\n\n\\section{The braid group on a Riemann surface and Chern-Simons statistics}\n\nConsidering a set of point charges leads to the set of wave functions\n\\begin{displaymath}\n\\Psi_{p,r}\\dc{\\alpha}{\\beta}(\\xi,\\gamma,t|\\Omega)=\\exp\\left[\\pi k\\gamma^m\n\\gamma_m+2\\pi\\gamma^m\\int_0^t(\\bar j_m-j_m){\\rm d} t^\\prime-\\frac{2\\pi i}{k}(\\sum_i\nq_i\\xi(z_i(t))-Q\\xi(z_0))\\right.\n\\end{displaymath}\n\\begin{displaymath}\n\\left.+\\frac{i}{2k}\\sum_{ij}q_iq_j(\\theta_{ij}(t)-\\theta_{ij}(0))+\n\\frac{\\pi}{2k}\\int_0^t(j_m-\\bar j_m){\\rm d} t^\\prime\\cdot\\int_0^t(j^m-\n\\bar j^m){\\rm d} t^\\prime\\right]\n\\end{displaymath}\n\\BE \\label{wvfn}\n\\cdot\\Theta\\dc{\\frac{\\alpha+k_1 p+k_2 r}{k_1 k_2}}{\\beta}(k_1\\gamma^m-k_2\n\\int_0^tj^m{\\rm d} t^\\prime|k_1 k_2\\Omega)\n\\EE\n\nThe wave function depends on charge\npositions through the integrals over the topological components of the\ncurrent $j^m, \\bar j^m$, and through the function $\\theta_{ij}(t) -\n\\theta_{ij}(0)$. Consider for a moment motions of the particles\nwhich are closed curves, and are homologically trivial. We focus\nfirst on the integrals over $j^m, \\bar j^m$. If, for example a single\nparticle moves in a circle,\nwe find that the integral of these topological currents vanishes, we\nconclude that these currents contribute nothing additional to the phase of\nthe wave function under these kinds of motions. The function $\\theta_{ij}\n(t) - \\theta_{ij}(0)$ must be treated differently here, because it has\nsingularities when particles coincide, and thus, while motions that\nencircle no other particles may be easily integrated to get zero, this\nis not true when other particles are enclosed by one of the particle\npaths, and the result is non-zero in this case, in fact it is $2\\pi$ (with\nappropriate sign depending on the loop orientation). Nevertheless, this\nfunction is still independent of the particular\nshape of the particle path. Actually the definition of $\\theta_{ij}$ in term\nof the prime form $E(z,w)$ is just the generalization to an arbitrary Riemann\nsurface of the well known angle function on the plane, that is as the angle of\nthe line joining the particle $i$ and $j$ compare to a fixed axis of\nreference, determined by $z_0$ here.\nThus, we may conclude that under the permutation of two identical particles of\ncharge $q$, the wave functions defined here acquire the phase\n\\BE \\label{perph}\n\\sigma =e^{i\\frac{\\pi}{k}q^2}\n\\EE\n\nFor homologically non-trivial motions of a single particle on ${\\cal M}$\n, the current integral $\\int_0^t\nj^l(t^\\prime){\\rm d} t^\\prime$ will in general change as $\\int_0^t\nj^l(t^\\prime){\\rm d} t^\\prime \\longrightarrow \\int_0^t\nj^l(t^\\prime){\\rm d} t^\\prime + s^l+\\Omega^{lm}t_m$, where $s^l$ and $t_m$\nare integer-valued vectors whose entries denote the number of windings\nof the particle around each homological cycle.\nHowever, now, for multi-particle non-braiding paths, there is no\ncontribution comming from $\\theta_{ij}$.\nThus, for closed path on ${\\cal M}$, the wave functions become\n\\begin{displaymath}\n\\Psi_{p,r}(t)=\\exp\\left[-\\frac{2\\pi i}{k}r_m s^m\n-\\frac{2\\pi i}{k_1}\\sum_i q_i((\\alpha -k_2\\alpha_0)\n_m s_i^m-(\\beta-k_2\\beta_0)^m t_{im})-iJ\\right]\n\\end{displaymath}\n\\BE \\label{braid}\n\\cdot\\Psi_{p,r+t}(0)\n=\\sum_{r^\\prime}[B_{s,t}]_{r,r^\\prime}\\Psi_{p,r^\\prime}(0)\n\\EE\nwith\n$\\sum_iq_i\\int_{z_0}^{z_i(0)}\\omega^l=\\alpha_0^l+\\Omega^{lm}\\beta_{0m}$\nand where $J=\\sum_i \\frac{q_i^2}{2k}(f_i(t)-f_i(0))$ is the self-linking\nterm. The matrices (\\ref{braid}) satisfy the cocycle relation\n\\BE \\label{bgalg}\nB_{s_1,t_1}B_{s_2,t_2}=e^{-\\frac{2\\pi i}{k}(s_1^m{t_m}_2-s^m_2{t_m}_1)}\nB_{s_2,t_2}B_{s_1,t_1}\n\\EE\nThis cocycle has to be contrasted with the large gauge transformations cocycle\n(\\ref{clka}). They are very similar except that $k$ is now $\\frac{1}{k}$\nand the operator act on the wave function $\\Psi_{p,r}$ on the other index.\nIn this sense, these two cocycles play a dual role on the wave function.\n\nThe self-linking contribution, $J$, in (\\ref{braid}), plays an\nimportant role here. For homologically trivial closed particle\ntrajectories, we find $J=0$ if\nthe path does not enclose $z_0$ in the patch that we are working on, since we\nchoose to put all the flux of $\\Gamma$ around $z_0$. Otherwise, we find a\ncontribution $\\frac{q_i^2}{2k}\\chi_E=2\\pi\\frac{q_i^2}{k}(1-g)$ to $J$, for\nthe particle $i$. This can be illustrated by\nchecking for independence of the braiding (\\ref{braid}) on $z_0$.\nIn the definition of the angle function $\\theta_{ij}$ in (\\ref{angfunc}), we\nargue that by moving $z_0$ along an homology cycle, the angle function\nis changed by a constant that should cancel out in (\\ref{braid}).\nNow the function (\\ref{braid}) changes by $e^{i\\frac\n{2\\pi}{k}Qq_i}e^{i\\frac{2\\pi}{k}q_i^2(g-1)}$ to an integer power. Fortunately\nthis is one, being our\nfundamental consistency condition (\\ref{fconsf}). The first phase come\nfrom the shift in $\\alpha_0$ and $\\beta_0$, while the second phase come\nfrom the fact that each charge trajectory is being crossed by $z_0$, which\nproduces a shift in $J$.\n\nTo study the permuted (identical particles) braid group, we will consider $n$\nparticles of charge $q$, so $Q=nq$. The representation of the braid\ngroup is characterized by its generators, the permutation phase\n$\\sigma$ in (\\ref{perph}), and the braid matrices $B_{s,t}$ in (\\ref{braid}).\nThese generators are the result of the action of elements of the permuted\nbraid group on the particles which form the external sources in our\ntheory.\nIn fact, let the integer vectors $\\hat s^l$, $\\hat t_m$\ndenote vectors that are 0 in all entries except for the $l$th and\n$m$th, respectively, and 1 at the remaining position. Then with the\nidentifications $\\alpha_l = B_{\\hat s^l,0},\\\n\\beta_m = B_{0,\\hat t_m}$, it is easy to check that we recover all of\nthe necessary relations of the braid group on the Riemann surface,\ngiven in (\\ref{bgrel}). In particular, we recover the global constraint\n(\\ref{bggrel}), this is just our fundamental constraint (\\ref{fconsf}),\nusing (\\ref{perph}), applied to this case.\n\n\n\\section{Conclusion}\n\nWe have quantized Abelian Chern-Simons theory coupled to arbitrary\nexternal sources on an arbitrary Riemann surface, and solved the\ntheory. We find that the presence of non-trivial spatial topology\nintroduces extra dimensionality to the Hilbert space separately for\nthe large gauge transformations and the braid group.\nWe find a fundamental constraint (\\ref{fconsf}), relating the\ncharges, $k$, and $g$ such that we recover a consistent topological\nfield theory representing a general (with some identical and\nnon-identical particles) braid group on ${\\cal M}$. In particular, we\nrecover the permuted braid group on ${\\cal M}$.\n\n","meta":{"redpajama_set_name":"RedPajamaArXiv"}} +{"text":"\\section{Introduction}\n\\label{sec.intro}\n\nThere are many profound relations between quantum field theory, string theory\nand knot theory. This paper focuses on two aspects of the polynomial knot invariants -- in particular HOMFLY polynomials, superpolynomials, and their specializations -- colored by symmetric powers of the fundamental \nrepresentation:\n\\begin{itemize}\n\\item\nthe special geometry of algebraic curves of a knot,\n\\item\nthe integrality of the BPS invariants of a knot.\n\\end{itemize}\nBy (affine) algebraic curves we mean curves obtained as classical limits of recursions\nof knot polynomials. Such recursions are known to exist (for colored Jones\npolynomials \\cite{GL,Hikami_AJ}, or colored HOMFLY and superpolynomials of twist or torus knots) and conjectured to exist for all colored HOMFLY or superpolynomials \\cite{AVqdef,FGS,superA,Nawata}. For the colored Jones polynomial, the above algebraic curve agrees with the A-polynomial \\cite{GL,Hikami_AJ,Apol}. For the colored \nHOMFLY polynomial, the above algebraic curve is conjectured \\cite{AVqdef,superA} to agree with the augmentation polynomial of a knot \\cite{NgFramed}. The curve arising as the classical limit of recursions for colored superpolynomials is called the super-A-polynomial \\cite{superA,Fuji:2013rra}.\n\nOn the other hand, by BPS invariants of a knot we mean the Labastida-Mari{\\~n}o-Ooguri-Vafa (LMOV) invariants of a knot \\cite{OoguriV,Labastida:2000zp,Labastida:2000yw,Labastida:2001ts}, or certain combinations thereof. \n\nOur aim is to give exact formulas for a certain class of BPS invariants, as well\nas their asymptotic expansions to all orders, using the corresponding\nalgebraic curve. One motivation of our work is as follows. On one hand, as stated above, various algebraic curves associated to knots arise as classical limits of recursion relations for knot polynomials (Jones, HOMFLY, or superpolynomials) colored by symmetric representations \\cite{GL,Hikami_AJ,AVqdef,FGS,superA,FGSS,Nawata}. \nOn the other hand, as we will show, one can restrict the defining relations between HOMFLY polynomials and LMOV invariants to the case of symmetric representations only. This implies that recursion relations for knots should encode information about LMOV invariants labeled by symmetric representations, and classical limits of these recursions should still capture some of this information. In this paper we make these statements precise. Our main results are the following. \n\n\\begin{proposition}\n\\label{prop.main}\n\\rm{(a)} Fix a knot $K$, a natural number $r$ and an integer $i$. Then the BPS invariants $b_{r,i}$ are given by\n\\begin{equation}\nx\\frac{\\partial_x y(x,a)}{y(x,a)} \n= -\\frac{1}{2} \\sum_{r,i} r^2 b_{r,i} \\frac{x^r a^i}{1-x^r a^i}, \n\\label{xdyy}\n\\end{equation}\nwhere $y=y(x,a) \\in 1 + \\mathbb Q[[x,a]]$ is an algebraic function of $(x,a)$\nthat satisfies a polynomial equation\n\\begin{equation}\n\\mathcal{A}(x,y,a)=0 \\,. \\label{Axya}\n\\end{equation}\n\\rm{(b)} Explicitly, $x \\partial_x y\/y$ is an algebraic function of $(x,a)$,\nand if $x \\partial_x y\/y=\\sum_{n,m \\geq 0} a_{n,m} x^n a^m$, and $\\mu(d)$ denotes the M\\\"obius function, then\n\\begin{equation}\nb_{r,i} = \\frac{2}{r^2} \\sum_{d|r,i} \\mu(d) a_{\\frac{r}{d},\\frac{i}{d}} \n\\,. \n\\label{b-ri}\n\\end{equation}\n\\end{proposition}\nThe BPS invariants $b_{r,i}$ introduced above are certain combinations of LMOV invariants. In the string theory interpretation they are encoded in holomorphic disk amplitudes or superpotentials \\cite{OoguriV,AV-discs,AKV-framing} for D-branes conjecturally associated to knots, and more accurately they could be referred to as classical BPS invariants; however in this paper, unless otherwise stated, we simply call them BPS invariants or degeneracies. The definition of $b_{r,i}$ is given in Section~\\ref{sub-total}. The polynomial $\\mathcal{A}(x,y,a)$, sometimes referred to as the dual A-polynomial, is defined in Section~\\ref{ssec-AJ}. Equation \\eqref{xdyy} gives exact formulas for the BPS invariants $b_{r,i}$ for arbitrary $r,i$, as well as asymptotic expansions to all orders of $r$ when $(r,i)$ are along a ray. In particular, one obtains exact formulas\nand asymptotic expansions for the BPS invariants $b^\\pm_r=b_{r,r \\cdot c_\\pm}$ along the two extreme rays, that we call extremal BPS invariants. The extremal BPS invariants $b^{\\pm}_r$ can also be expressed in terms of coefficients of, respectively, maximal and minimal powers of $a$ in HOMFLY polynomials. The coefficients of these extremal powers are also referred to as top-row and bottom-row HOMFLY polynomials (\\emph{rows} refer to the components of the diagram representing HOMFLY homology, see e.g. \\cite{Gorsky:2013jxa}).\n\nWe call the algebraic curves that encode extremal BPS degeneracies the extremal A-polynomials, and for a knot $K$ we denote them $\\mathcal{A}^{\\pm}_{K}(x,y)$. We also refer to $\\mathcal{A}^{+}_{K}(x,y)$ and $\\mathcal{A}^{-}_{K}(x,y)$ respectively as top and bottom A-polynomials. In this work, among the others, we determine extremal A-polynomials for various knots. We also discuss their properties; we note here that in particular they are tempered, i.e. the roots of their face polynomials are roots of unity, which is also referred to as the quantizability condition \\cite{superA,Fuji:2013rra} and is the manifestation of the so-called $K_2$ condition \\cite{abmodel}. The extremal A-polynomials for twist knots, for a family of $(2,2p+1)$ torus knots, and for various knots with up to 10 crossings are given in Appendix \\ref{sec-extremeA}. The extremal A-polynomials for twist knots are also given below. \n\nFix an integer $p \\neq 0,1$ and consider the family of \nhyperbolic twist knots $K_p$. For $p=-1,-2,-3,\\ldots$ these are $4_1,6_1,8_1,\\ldots$ knots; for $p=2,3,4\\ldots$ these are $5_2,7_2,9_2,\\ldots$ knots. Much more can be said for this family of knots.\n\n\\begin{proposition}\n\\label{prop.twist}\nThe extremal BPS invariants of twist knots are given by\n\\begin{equation}\nb^-_{K_p,r} = -\\frac{1}{r^2}\\sum_{d|r} \\mu\\big(\\frac{r}{d}\\big) {3d-1 \\choose d-1},\\qquad b^+_{K_p,r} = \\frac{1}{r^2}\\sum_{d|r} \\mu\\big(\\frac{r}{d}\\big) {(2|p|+1)d - 1 \\choose d-1} \n\\label{br-neg-intro}\n\\end{equation}\nfor $p \\leq -1$ and \n\\begin{equation}\nb^-_{K_p,r} = \\frac{1}{r^2}\\sum_{d|r} \\mu\\big(\\frac{r}{d}\\big) (-1)^{d+1} {2d-1 \\choose d-1},\\qquad b^+_{K_p,r} = \\frac{1}{r^2}\\sum_{d|r} \\mu\\big(\\frac{r}{d}\\big) (-1)^d {(2p+2)d - 1 \\choose d-1} \\label{br-pos-intro}\n\\end{equation}\nfor $p \\geq 2$. \n\\end{proposition}\nOur formulas and the integrality of the BPS invariants\nlead to nontrivial integrality statements among sequences of rational numbers.\nIn particular, it implies that $b^\\pm_{K_p,r}$ are integers for all natural numbers $r$ and all integers $p \\neq 0,1$.\nNote that this implies a nontrivial statement, that for fixed $r$ the sums in expressions (\\ref{br-neg-intro}) and (\\ref{br-pos-intro}) are divisible by $r^2$. Also note that the above BPS degeneracies are determined explicitly for an infinite range of $r$; this is in contrast to other LMOV invariants in literature, which were determined explicitly only for some finite range of labeling representations (Young diagrams consisting up to several boxes)\n\\cite{Labastida:2000zp,Labastida:2000yw,Labastida:2001ts,Ramadevi_Sarkar,Zodinmawia:2011oya,Zodinmawia:2012kn}.\n\n\nWhat's more, we experimentally discover an Improved Integrality for the BPS invariants, observed by Kontsevich for algebraic curves satisfying the $K_2$ condition \\cite{Kontsevich-K2} (which is the same condition as already mentioned above \\cite{abmodel}). \n\n\\begin{conjecture}(Improved Integrality)\n\\rm{} Given a knot there exist nonzero integers $\\gamma^\\pm$ such that for any $r\n\\in \\mathbb N$\n\\begin{equation}\n \\frac{1}{r} \\gamma^\\pm b^\\pm_r \\in \\mathbb Z .\n\\label{eq.improved}\n\\end{equation}\n\\end{conjecture}\nWe checked the above conjecture for twist knots, torus knots and several knots\nwith up to 10 crossings. The values of $\\gamma^{\\pm}$ for various knots are given in table \\ref{c-minmax-aug}. Note that this integrality conjecture is more general than the integrality\nof LMOV invariants \\cite{OoguriV,Labastida:2000zp,Labastida:2000yw,Labastida:2001ts}, which only implies integrality of $b_r$. It would be interesting to give a physical interpretation of\nthis property and of the conjectured integer knot invariants $\\gamma^\\pm$.\n\nOur next proposition illustrates the special geometry of the extremal \n$A$-polynomials of the twist knots.\n\n\\begin{proposition}\n\\rm{(a)} The extremal A-polynomials of twist knots are are given by\n\\begin{align}\n \\mathcal{A}^-_{K_p}(x,y) &= x-y^4+y^6, & \n\\mathcal{A}^+_{K_p}(x,y) &= 1-y^2+x y^{4|p|+2}, & p \\leq -1, \n\\label{Ap-neg-intro} \\\\\n\\mathcal{A}^-_{K_p}(x,y) &=1-y^2- x y^4, &\n\\mathcal{A}^+_{K_p}(x,y) &= 1-y^2+x y^{4p+4}, & p \\geq 2. \n\\label{Ap-pos-intro}\n\\end{align}\n\\rm{(b)}\nThe algebraic curves $\\mathcal{A}^\\pm_{K_p}(x,y^{1\/2})$ have a distinguished\nsolution $y=y(x) \\in 1 + x \\mathbb Z[[x]]$ such that\n\\begin{equation}\n\\boxed{\\text{$y$ and $x y'\/y$ are algebraic hypergeometric functions}}\n\\label{eq.fortunate}\n\\end{equation}\n\\end{proposition}\nExplicit formulas for those solutions can be found in Section \\ref{sec-results}.\nNote that if $y$ is algebraic, so is $x y'\/y$. The converse nearly holds. \nThe next theorem was communicated to us by Kontsevich in the 2011 \nArbeitstagung talk. A proof, using the solution to the Grothendieck-Katz \nconjecture, was written in Kassel-Reutenauer~\\cite{KS}.\n\n\\begin{theorem}\n\\label{thm.KS}\nIf $f \\in \\mathbb Z[[x]]$ is a formal power series with integer coefficients such\nthat $g=x f'\/f$ is algebraic, then $f$ is algebraic. \n\\end{theorem}\nWith the above notation, the converse holds trivially: if $f$ is algebraic,\nso is $g$, without any integrality assumption on the coefficients of $f$.\nThe integrality hypothesis are required in Theorem~\\ref{thm.KS}: if $f=e^x$\nthen $g=x$. Note finally that the class of algebraic hypergeometric functions \nhas been completely classified in \\cite{beukers:monodromy, beukers:algebraic}. \nUsing this, one can also determine the functions that satisfy \n\\eqref{eq.fortunate}. We will not pursue this here.\n\nThe special geometry property \\eqref{eq.fortunate} does not seem to hold \nfor non-twist hyperbolic knots. \n\nNext, we point out more information encoded in extremal A-polynomials.\n\n\\begin{lemma}\n\\label{prop.disc}\nThe exponential growth rates of $b^{\\pm}_r$ are given by the zeros of $y$-discriminant of the corresponding extremal A-polynomials $\\mathcal{A}^{\\pm}_{K}(x,y)$\n\\begin{align}\nx_0=\\lim_{r\\to\\infty} \\frac{b^{\\pm}_r}{b^{\\pm}_{r+1}}\\quad \\Rightarrow\\quad \n\\mathrm{Disc}_y \\mathcal{A}_K^{\\pm}(x_0,y)=0\n\\end{align}\n\\end{lemma}\n\nFor example, for $K_p$ torus knots with $p\\leq -1$, the $y$-discriminant of $\\mathcal{A}^-_{K_p}(x,y)$ in (\\ref{Ap-neg-intro}) is\ngiven by \n$$\n\\mathrm{Disc}_y \\mathcal{A}^-_{K_p}(x,y)= -64 x^3 (-4 + 27 x)^2\n$$\nand its zero $x_0=\\frac{4}{27}$ matches the exponential growth rate \nof $b^-_{K_p,r}$ in (\\ref{br-neg-intro}), which can be obtained from Stirling formula.\n\nFurthermore, we generalize the above analysis of extremal A-polynomials and extremal BPS states by introducing the dependence on variables $a$ and $t$. As conjectured in \\cite{AVqdef,superA}, the augmentation polynomials \\cite{Ng,NgFramed}, that depend on variable $a$, should agree with Q-deformed polynomials obtained as classical limits of recursions for colored HOMFLY polynomials \\cite{AVqdef}. We verify that this is indeed the case by computing corresponding BPS invariants from augmentation polynomials, and verifying that they are consistent with LMOV invariants determined from known colored HOMFLY polynomials for various knots with up to 10 crossings. While using our method we can determine BPS invariants for arbitrarily large representations $S^r$ from augmentation polynomials, for more complicated knots the colored HOMFLY polynomials are known explicitly only for several values of $r$, see e.g. \\cite{Nawata:2013qpa,Wedrich:2014zua}. Nonetheless this is already quite a non-trivial check.\n\nFinally we introduce the dependence on the parameter $t$, consider refined BPS degeneracies arising from appropriate redefinitions of super-A-polynomials,\nand show their integrality.\n\nWe note that apart from the relation to the LMOV invariants our results have an interpretation also from other physical perspectives. In particular, recently a lot of attention has been devoted to the so-called 3d-3d duality, which relates knot invariants to 3-dimensional $\\mathcal{N}=2$ theories \\cite{DGG,superA,Chung:2014qpa}. In this context the A-polynomial curves, such as (\\ref{Axya}) or extremal A-polynomials, represent the moduli space of vacua of the corresponding $\\mathcal{N}=2$ theories. Furthermore, the equation (\\ref{xdyy}) can be interpreted as imposing (order by order) relations between BPS degeneracies, which should arise from relations in the corresponding chiral rings. We also note that in the corresponding brane system extremal invariants arise from the $\\mathbb{C}^3$ limit of the underlying resolved conifold geometry, and the precise way of taking this limit is encoded in the integers $c_{\\pm}$ mentioned below (\\ref{b-ri}) that specify the extreme rays. We comment on these and other physical interpretations in section \\ref{sec-conclude} and plan to analyze them further in future work.\n\n\n\n\n\\section{BPS invariants of knots from algebraic curves} \\label{sec-BPS}\n\n\n\n\n\n\\subsection{BPS invariants for knots} \\label{sub-total}\n\nIn this section we recall the formulation of Labastida-Mari{\\~n}o-Ooguri-Vafa (LMOV) invariants and discuss its form in case of $S^r$-colored HOMFLY polynomials. The starting point is to consider the Ooguri-Vafa generating function \\cite{OoguriV,Labastida:2000zp,Labastida:2000yw,Labastida:2001ts}\n\\begin{equation}\nZ(U,V) = \\sum_R \\textrm{Tr}_R U \\, \\textrm{Tr}_R V = \\exp\\Big( \\sum_{n=1}^{\\infty} \\frac{1}{n} {\\rm Tr \\,} U^n {\\rm Tr \\,} V^n \\Big),\n\\end{equation}\nwhere $U=P\\,\\exp\\oint_K A$ is the holonomy of $U(N)$ Chern-Simons gauge field along a knot $K$, $V$ can be interpreted as a source, and the sum runs over all representations $R$, i.e. all two-dimensional partitions. The LMOV conjecture states that the expectation value of the above expression takes the following form\n\\begin{equation}\n\\big\\langle Z(U,V) \\big\\rangle = \\sum_R P_{K,R}(a,q) \\textrm{Tr}_R V = \\exp \\Big( \\sum_{n=1}^\\infty \\sum_R \\frac{1}{n} f_{K,R}(a^n,q^n) \\textrm{Tr}_R V^n \\Big), \\label{ZUV}\n\\end{equation}\nwhere the expectation value of the holonomy is identified with the unnormalized HOMFLY polynomial of a knot $K$, $\\langle \\textrm{Tr}_R U \\rangle = P_{K,R}(a,q)$, and the functions $f_{K,R}(a,q)$ take form\n\\begin{equation}\nf_{K,R}(a,q) = \\sum_{i,j} \\frac{N_{R,i,j} a^i q^j}{q-q^{-1}}, \\label{fR}\n\\end{equation}\nwhere $N_{R,i,j}$ are famous BPS degeneracies, or LMOV invariants, a term that we will use interchangably; in particular they are conjectured to be integer. In string theory interpretation they count D2-branes ending on D4-branes that wrap a Lagrangian submanifold associated to a given knot $K$. From two-dimensional space-time perspective D2-branes are interpreted as particles with charge $i$, spin $j$, and magnetic charge $R$. For a fixed $R$ there is a finite range of $i$ and $j$ for which $N_{R,i,j}$ are non-zero. \n\nIn what follows we are interested in the case of one-dimensional source $V=x$. In this case ${\\rm Tr \\,}_R V \\neq 0$ only for symmetric representations $R=S^r$ (labeled by partitions with a single row\nwith $r$ boxes \\cite{AM}), so that $\\textrm{Tr}_{S^r}(x) = x^r$. For a knot $K$, let us denote $P_K(x,a,q)=\\langle Z(U,x) \\rangle$, and let $P_{K,r}(a,q) \\in \\mathbb Q(a,q)$ denote the $S^r$-colored HOMFLY polynomial of $K$. For a detailed \ndefinition of the latter, see for example \\cite{AM}. In this setting (\\ref{ZUV}) reduces to the following expression\n\\begin{equation}\nP_K(x,a,q) = \\sum_{r=0}^\\infty P_{K,r}(a,q) x^r = \n\\exp\\Big( \\sum_{r,n\\geq 1} \\frac{1}{n} f_{K,r}(a^n,q^n)x^{n r}\\Big).\n\\label{Pz2}\n\\end{equation}\nNote that we use the unnormalized (or unreduced) HOMFLY polynomials, so that the unknot is normalized as\n$P_{{\\bf 0_1},1}(a,q)=(a-a^{-1})\/(q-q^{-1})$.\nOften, we will drop the knot $K$ from the notation.\nNote that $f_r(a,q)$ is a universal polynomial (with rational coefficients) of $P_{r\/d}(a^d,q^d)$ for all divisors $d$ or $r$. For instance, we have:\n\\begin{eqnarray}\nf_1(a,q) &=& P_1(a,q), \\nonumber\\\\\nf_2(a,q) &=& P_2(a,q) - \\frac{1}{2}P_1(a,q)^2 -\\frac{1}{2} P_1(a^2,q^2), \\nonumber\\\\\nf_3(a,q) &=& P_3(a,q) - P_1(a,q)P_2(a,q) + \\frac{1}{3}P_1(a,q)^3 - \\frac{1}{3} P_1(a^3,q^3) \\label{f-P} \\\\\nf_4(a,q) &=& P_4(a,q) - P_1(a,q)P_3(a,q) - \\frac{1}{2}P_2(a,q)^2 + P_1(a,q)^2P_2(a,q) + \\nonumber\\\\\n& & -\\frac{1}{4}P_1(a,q)^4 -\\frac{1}{2}P_2(a^2,q^2)+\\frac{1}{4}P_1(a^2,q^2)^2. \\nonumber\n\\end{eqnarray}\nIt follows that $f_r(a,q) \\in \\mathbb Q(a,q)$. The LMOV conjecture asserts that \n$f_r(a,q)$ can be expressed as a finite sum\n$$\nf_{r}(a,q) = \\sum_{i,j} \\frac{N_{r,i,j} a^i q^j}{q-q^{-1}} ,\n\\qquad\nN_{r,i,j} \\in \\mathbb Z \\,.\n$$ \nand in this case the BPS degeneracies $N_{r,i,j}$ are labeled by a natural number $r$.\n\nWe now explain how to extract BPS degeneracies from the \ngenerating function \\eqref{Pz2}. First we write it in product form\n\\begin{eqnarray}\nP(x,a,q) &=& \\sum_r P_r(a,q) x^r \n\\exp\\Big( \\sum_{r,n\\geq 1; i,j} \\frac{1}{n} \n\\frac{N_{r,i,j}(x^r a^i q^j)^n}{q^{n}-q^{-n}}\\Big) \\nonumber\\\\\n&=& \\exp\\Big( \\sum_{r\\geq 1;i,j;k\\geq 0} N_{r,i,j}\n\\log(1-x^r a^i q^{j+2k+1} )\\Big) \\nonumber\\\\\n&=& \\prod_{r\\geq 1;i,j;k\\geq 0} \\Big(1 - x^r a^i q^{j+2k+1} \\Big)^{N_{r,i,j}} \n\\label{Pr-LMOV} \\\\\n&=& \\prod_{r\\geq 1;i,j} \\Big( x^r a^i q^{j+1};q^2 \\Big)_\\infty^{N_{r,i,j}} \n\\nonumber\n\\end{eqnarray}\nwhere the $q$-Pochhammer symbol (or quantum dilogarithm) notation is used\n\\begin{equation}\n(x;q)_\\infty =\\prod_{k=0}^\\infty (1-x q^k) \\,. \\label{qdilog}\n\\end{equation}\nThen, in the limit $q=e^{\\hbar} \\to 1$, using well known asymptotic expansion of the quantum dilogarithm (see e.g. \\cite{abmodel}), we get the following asymptotic \nexpansion\n of $P(x,a,e^{\\hbar})$\n\\begin{eqnarray}\nP(x,a,e^{\\hbar}) &=& \\exp\\Big( \\sum_{r,i,j} N_{r,i,j} \n\\big( \\frac{1}{2\\hbar}\\textrm{Li}_2(x^r a^i) -\\frac{j}{2}\\log(1-x^r a^i) \n+O(\\hbar) \\big) \\Big)= \\nonumber \\\\\n&=&\\exp\\Big(\\frac{1}{2\\hbar}\\sum_{r,i} b_{r,i} \\textrm{Li}_2(x^r a^i) \n-\\sum_{r,i,j} \\frac{j}{2}N_{r,i,j}\\log(1-x^r a^i) +O(\\hbar) \\Big)\n\\label{Px-asympt} \\\\\n&=& \\exp\\Big(\\frac{1}{\\hbar} S_0(x,a)+S_1(x,a) + O(\\hbar)\\Big), \\nonumber\n\\end{eqnarray}\nwhere \n\\begin{align}\nS_0(x,a) &= \\frac{1}{2} \\sum_{r,i} b_{r,i} \\textrm{Li}_2(x^r a^i), \\\\\nS_1(x,a) &= -\\frac{1}{2}j\\sum_{r,i,j} \\log(1-x^r a^i). \n\\label{Px-dilog}\n\\end{align}\nAbove we introduced \n\\begin{equation}\nb_{r,i} = \\sum_j N_{r,i,j} \\,\n\\label{eq.btotal}\n\\end{equation}\nthat appear at the lowest order in $\\hbar$ expansion in the exponent of (\\ref{Px-asympt}) and can be interpreted as the classical BPS degeneracies. These degeneracies are of our main concern. In the string theory interpretation they determine holomorphic disk amplitudes or superpotentials \\cite{OoguriV,AV-discs,AKV-framing} for D-branes conjecturally associated to knots. In what follows, unless otherwise stated, by BPS degeneracies we mean these numbers.\n\nOur next task is to compute $S_0(x,a)$. To do so, we use a linear $q$-difference\nequation for $P(x,a,q)$ reviewed in the next section.\n\n\n\n\\subsection{Difference equations and algebraic curves} \\label{ssec-AJ}\n\nIn this section we introduce various algebraic curves associated to knots.\nFirst, recall that the colored Jones polynomial $J_{K,r}(q) \\in \\mathbb Z[q^{\\pm 1}]$ of a knot $K$ can \nbe defined as a specialization of the colored HOMFLY polynomial:\n$$\nJ_{K,r}(q)=P_{K,r}(q^2,q) \\,.\n$$\nIt is known that the colored Jones polynomial satisfies a linear $q$-difference\nequation of the form\n\\begin{equation}\n\\widehat{A}_K(\\hat M, \\hat L,q) J_{K,r}(q) = 0, \n\\end{equation}\nwhere $\\widehat{A}_K$ is a polynomial in all its arguments, and $\\hat M$ and $\\hat L$ are operators that satisfy the relation $\\hat L \\hat M = q \\hat M \\hat L$ and act on colored Jones polynomials by\n\\begin{equation}\n\\hat M J_{K,r}(q) = q^r J_{K,r}(q),\\qquad \\quad \n\\hat L J_{K,r}(q) = J_{K,r+1}(q). \\label{MhatLhat}\n\\end{equation}\nThe AJ Conjecture states that\n\\begin{equation}\n\\widehat{A}_K(\\hat M, \\hat L,1) = A_K(M,L)\n\\end{equation}\nwhere $A_K(M,L)$ is the A-polynomial of $K$ \\cite{CCGLS}. Likewise, we will\nassume that the colored HOMFLY polynomial of a knot satisfies a linear\n$q$-difference equation of the form\n\\begin{equation}\n\\widehat{A}(\\hat M, \\hat L,a,q) P_r(a,q) = 0 \\,. \\label{Ahat-a}\n\\end{equation}\nThe corresponding 3-variable polynomial $A(M,L,a)=A(M,L,a,1)$ defines a family\nof algebraic curves parametrized by $a$. A further conjecture \\cite{AVqdef,superA} identifies\nthe 3-variable polynomial $A(M,L,a)$ with the augmentation polynomial of\nknot contact homology \\cite{Ng,NgFramed}.\n\nWe further assume the existence of the super-A-polynomial, i.e. the refined colored HOMFLY polynomial $P_r(a,q,t)$ of a knot, that specializes at $t=-1$ to the usual colored HOMFLY\npolynomial, and that also satisfies a linear $q$-difference equation\n\\cite{superA,FGSS}\n\\begin{equation}\n\\widehat{A}^{\\textrm{super}}(\\hat M,\\hat L, a,q,t) P_r(a,q,t) = 0. \n\\end{equation}\nThe specialization $\\widehat{A}^{\\textrm{super}}(M,L, a,1,t)$ can be thought\nof as an $(a,t)$-family of A-polynomials of a knot.\n\nIn the remainder of this section we discuss a dual version $\\mathcal{A}(x,y,a)$\nof the algebraic curve $A(M,L,a)$. \n\n\\begin{lemma}\nFix a sequence $P_r(a,q)$ which is annihilated by an operator \n$\\widehat A (\\hat M,\\hat L,a,q)$ and consider the\ngenerating function $P(x,a,q)=\\sum_{r=0}^{\\infty} P_r(a,q) x^r$. Then, \n\\begin{equation}\n\\widehat{A}(\\hat{y},\\hat{x}^{-1},a,q) P(x,a,q) = const, \\label{AyxP}\n\\end{equation}\nwhere\n\\begin{equation}\n\\hat{x} P(x,a,q) = x P(x,a,q),\\qquad \\quad \\hat{y} P(x,a,q) = P(qx,a,q) \\label{lemma-Px}\n\\end{equation}\nsatisfy $\\hat{x} \\hat{y} = q \\hat{y} \\hat{x}$, and $const$ is a $q$-dependent term that vanishes in the limit $q\\to 1$. \n\\end{lemma}\n\n\\noindent\n\\emph{Proof.} \nWe have\n\\begin{equation}\n\\widehat{A}(\\hat M,\\hat L) P(x,a,q) = \n\\sum_r x^r \\widehat{A}(\\hat M,\\hat L) P_r(a,q) = 0. \\label{AhatMLP}\n\\end{equation}\nOn the other hand, acting with $\\hat M$ and $\\hat L$ on this generating function (and taking care of the boundary terms) we get\n\\begin{eqnarray}\n\\hat M P(x,a,q) &=& \\sum_{r=0}^{\\infty} P_r(a,q) (qx)^r = P(qx,a,q), \\\\\n\\hat L P(x,a,q) &=& \\sum_{r=0}^{\\infty} P_{r+1}(a,q)x^r = \\frac{1}{x} \\Big(P(x,a,q) - P_0(a,q) \\Big)\\nonumber.\n\\end{eqnarray}\nTherefore the action of $\\hat M$ and $\\hat L$ on $P(x)$ can be identified, respectively, with the action of operators $\\hat{y}$ and $\\hat{x}^{-1}$, up to the subtlety in the boundary term arising from $r=0$. From the property of the recursion relations for the HOMFLY polynomial the result follows.\n\\qed\n\nApplying the above lemma to the colored HOMFLY polynomial $P_r(a,q)$, this\nmotivates us to introduce the operator\n\\begin{equation}\n\\widehat{\\mathcal{A}}(\\hat{x},\\hat{y},a,q) = \n\\widehat{A}(\\hat{y},\\hat{x}^{-1},a,q),\n\\end{equation}\nso that (\\ref{AyxP}) can be simply written as\n\\begin{equation}\n\\widehat{\\mathcal{A}}(\\hat{x},\\hat{y},a,q) P(x,a,q) = const. \\label{calAxyP}\n\\end{equation}\nIn the limit $q\\to 1$ the right hand side vanishes and we can consider the algebraic curve\n\\begin{equation}\n\\mathcal{A}(x,y,a)= A(y,x^{-1},a). \\label{calAxy}\n\\end{equation}\n\n\n\\subsection{The Lambert transform}\n\nIn this section we recall the Lambert transform of two sequences $(a_n)$\nand $(b_n)$ which is useful in the proof of Proposition \\ref{prop.main}.\n\n\\begin{lemma}\n\\label{lem.1}\n\\rm{(a)} Consider two sequences $(a_n)$ and $(b_n)$ for $n=1,2,3,\\dots$ that\nsatisfy the relation\n\\begin{equation}\n\\label{eq.ab}\na_n = \\sum_{d | n} b_d\n\\end{equation}\nfor all positive natural numbers $n$. Then we have:\n\\begin{equation}\n\\label{eq.ba}\nb_n = \\sum_{d | n} \\mu\\left(\\frac{n}{d}\\right) a_d\n\\end{equation}\nwhere $\\mu$ is the M\\\"obius function. Moreover, we have the Lambert \ntransformation property\n\\begin{equation}\n\\label{eq.gf}\n\\sum_{n=1}^\\infty a_n q^n = \n\\sum_{n=1}^\\infty b_n \\frac{q^n}{1-q^n} \n\\end{equation} \nand the Dirichlet series property\n\\begin{equation}\n\\label{eq.gf2}\n\\sum_{n=1}^\\infty \\frac{a_n}{n^s} = \\zeta(s)\n\\sum_{n=1}^\\infty \\frac{b_n}{n^s} \\,.\n\\end{equation} \n\\rm{(b)} If $(a_n)$ has an asymptotic expansion\n\\begin{equation}\n\\label{eq.asa}\na_n \\sim \\sum_{(\\lambda,\\alpha)} \\lambda^n n^{\\alpha}\n\\left( c_0 + \\frac{c_1}{n} + \\frac{c_2}{n^2}\n+ \\dots \\right)\n\\end{equation} \nwhere the first sum is a finite sum of pairs $(\\lambda,\\alpha)$ such that\n$|\\lambda|$ is fixed, then so does $(b_n)$ and vice-versa.\n\\end{lemma}\n\n\\noindent\n\\emph{Proof.}\nPart (b) follows from Equation~\\eqref{eq.gf2} easily. For a detailed discussion,\nsee the appendix to \\cite{zeidler} by D. Zagier.\n\\qed\n\n\\begin{lemma}\n\\label{lem.2}\nSuppose $y \\in \\mathbb Z[[x]]$ is algebraic with constant term $y(0)=1$. Write\n$$\ny=1+\\sum_{n=1}^\\infty c_n x^n = \\prod_{n=1}^\\infty (1-x^n)^{b_n}.\n$$\nIf $y$ has a singularity in the interior of the unit circle then $(b_n)$\nhas an asymptotic expansion of the form~\\eqref{eq.asa}. Moreover, the\nsingularities of the multivalued function $y=y(x)$ are the complex roots of the\ndiscriminant of $p(x,y)$ with respect to $y$, where $p(x,y)=0$ is a \npolynomial equation.\n\\end{lemma}\n\n\\noindent\n\\emph{Proof.}\nWe have:\n$$\n\\log y =\\sum_{n=1}^\\infty b_n \\log(1-x^n)\n$$\nthus if $z=x d\\log y=xy'\/y$, then we have\n$$\nz = \\sum_{n=1}^\\infty n b_n \\frac{x^n}{1-x^n} .\n$$\nNow $z$ is algebraic by the easy converse to Theorem~\\ref{thm.KS}. It follows \nthat the coefficients $(a_n)$ of its Taylor series\n$$\nz=\\sum_{n=1}^\\infty a_n x^n\n$$\nis a sequence of Nilsson type~\\cite{Ga:nilsson}. Since $z$ is algebraic, \nthere are no $\\log n$ terms in the asymptotic expansion. \nMoreover, the exponential growth rate is bigger than 1, in absolute value. \nPart (b) of Lemma~\\ref{lem.1} concludes the proof.\n\\qed\n\n\n\n\\subsection{Proof of Proposition 1.1.}\n\nLet us define\n\\begin{equation}\ny(x,a) = \n\\lim_{q\\to 1} \\frac{P(qx,a,q)}{P(x,a,q)} = \n\\lim_{q\\to 1} \\prod_{r\\geq 1;i,j;k\\geq 0} \n\\Big(\\frac{1 - x^r a^i q^{r+j+2k+1} }{1 - x^r a^i q^{j+2k+1}}\\Big)^{N_{r,i,j}} \n= \\prod_{r\\geq 1;i} (1 - x^r a^i)^{-r b_{r,i} \/ 2} .\n\\label{sfx-prod}\n\\end{equation}\nIf $P(x,a,q)$ is annihilated by $\\widehat{\\mathcal{A}}(\\hat{x},\\hat{y},a,q)$,\nit follows that $y=y(a,x)$ is a solution of the polynomial equation\n\\begin{equation}\n\\mathcal{A}(x,y,a) = 0.\n\\end{equation}\nIndeed, divide the recursion \n$$\n\\widehat{\\mathcal{A}}(\\hat{x},\\hat{y},a,q) P(x,a,q)=0\n$$\nby $P(x,a,q)$, and observe that\n$$\n\\lim_{q \\to 1} \\frac{P(q^jx,a,q)}{P(x,a,q)} =\n\\prod_{l=1}^j \\lim_{q \\to 1} \\frac{P(q^l x,a,q)}{P(q^{l-1}x,a,q)} =\ny(x,a)^j.\n$$\nTaking the logarithm and then differentiating \\eqref{sfx-prod} concludes\nEquation \\eqref{xdyy}. Part (b) of Proposition \\ref{prop.main} follows from\nLemma \\ref{lem.1}.\n\\qed\n\n\n\n\n\n\n\\subsection{Refined BPS invariants}\n\nIn this section we discuss refined BPS invariants $N_{r,i,j,k}$. In full generality, we can consider the generating function of superpolynomials $P_r(a,q,t)$; suppose that it has the product structure analogous to (\\ref{Pr-LMOV}), however with an additional $t$-dependence\n\\begin{equation}\nP(x,a,q,t) = \\sum_{r=0}^\\infty P_r(a,q,t) x^r \n= \\prod_{r\\geq 1;i,j,k;n\\geq 0} \n\\Big(1 - x^r a^i t^j q^{k+2n+1} \\Big)^{N_{r,i,j,k}} \n\\label{Pr-LMOVref} \n\\end{equation}\nWe conjecture that the refined BPS numbers $N_{r,i,j,k}$ encoded in this expression are integers. As in this work we are mainly interested in invariants in the $q\\to 1$ limit, encoded in (classical) algebraic curves, let us denote them as\n\\begin{equation}\nb_{r,i,j} = \\sum_k N_{r,i,j,k}.\n\\end{equation} \nIn this case the curves in question are of course the dual versions of super-A-polynomial $A^{\\rm super}(M,L,a,t)$, with arguments transformed as in (\\ref{calAxy}), i.e.\n\\begin{equation}\n\\mathcal{A}(x,y,a,t) = A^{\\rm super}(y,x^{-1},a,t)= 0.\n\\end{equation}\nSolving this equation for $y=y(x,a,t)$ and following steps that led to (\\ref{xdyy}), we find now\n\\begin{equation}\nx\\frac{\\partial_x y(x,a,t)}{y(x,a,t)} = \\frac{1}{2} \\sum_{r,i,j} r^2 b_{r,i,j} \\frac{x^r a^i t^j}{1-x^r a^i t^j}, \\label{xdyy-ref}\n\\end{equation}\nand from such an expansion $b_{r,i,j}$ can be determined. Conjecturally these should be integer numbers; as we will see in several examples this turns out to be true. \n\n\n\n\n\n\\section{Extremal invariants} \\label{sec-extreme}\n\n\\subsection{Extremal BPS invariants}\n\nIn this section we define extremal BPS invariants of knots. If $P_r(a,q)$ is\na $q$-holonomic sequence, it follows that the minimal and maximal exponent with respect to\n$a$ is a quasi-linear function of $r$, for large enough $r$. This follows \neasily from the Lech-Mahler-Skolem theorem as used in \\cite{Ga:degree} and is \nalso discussed in detail in \\cite{vanderveen}. We now restrict our attention to \nknots that satisfy\n\\begin{equation}\nP_r(a,q) = \\sum_{i=r \\cdot c_-}^{r\\cdot c_+} a^i p_{r,i}(q) \n\\label{Pr-minmax}\n\\end{equation}\nfor some integers $c_\\pm$ and for every natural number $r$, where\n$p_{r,r \\cdot c_\\pm}(q) \\neq 0$.\nThis is a large class of knots -- in particular two-bridge knots and torus knots have this property.\nFor such knots, we can consider the extremal parts \nof the colored HOMFLY polynomials (i.e. their top and bottom rows, that is the coefficients of maximal and minimal powers of $a$), defined as one-variable polynomials\n\\begin{equation}\nP^\\pm_r(q) = p_{r,r \\cdot c_\\pm}(q). \\label{Pminmax}\n\\end{equation}\nLikewise, we define the extremal LMOV invariants by \n\\begin{equation}\nf^\\pm_r(q) = \n\\sum_j \\frac{N_{r, r \\cdot c_\\pm,j} q^j}{q - q^{-1}} \\,, \\label{f-minmax}\n\\end{equation}\nand the extremal BPS invariants by\n\\begin{equation}\nb^\\pm_r = b_{r,r \\cdot c_\\pm} = \\sum_j N_{r,r \\cdot c_\\pm,j}. \\label{br-minmax}\n\\end{equation}\nWe also refer to $b^+_r$ and $b^-_r$ as, respectively, top and bottom BPS invariants. \nFinally, we define the extremal part of the generating series $P(x,a,q)$\nby\n\\begin{equation}\nP^\\pm(x,q) = \\sum_{r=0}^\\infty P^\\pm_r(q) x^r \n= \\prod_{r\\geq 1;j;k\\geq 0} \n\\Big(1 - x^r q^{j+2k+1} \\Big)^{N_{r,r \\cdot c_\\pm,j}}.\n\\label{Pr-LMOV-minmax} \n\\end{equation}\nThe analogue of Equation \\eqref{Px-asympt} is\n\\begin{equation}\nP^\\pm(x,e^{\\hbar}) = \n\\exp\\Big(\\frac{1}{2\\hbar}\\sum_{r} b^\\pm_r \\textrm{Li}_2(x^r) \n-\\sum_{r,j} \\frac{j}{2}N_{r,r \\cdot c_\\pm,j}\\log(1-x^r) +O(\\hbar) \\Big). \n\\label{Px-asympt-minmax}\n\\end{equation}\n\nIt follows from the LMOV conjecture that $b^{\\pm}_r$, as combinations of LMOV invariants $N_{r,r\\cdot c_{\\pm},j}$, are integer. Moreover, according to the Improved Integrality conjecutre \\ref{eq.improved}, for each knot one can find integer numbers $\\gamma^{\\pm}$, such that \n\\begin{equation}\n \\frac{1}{r} \\gamma^\\pm b^\\pm_r \\in \\mathbb Z .\n\\end{equation}\nThe numbers $\\gamma^{\\pm}$ can be regarded as new invariants of a knot. We compute these numbers for various knots in section \\ref{sec-results}, with the results summarized in table \\ref{c-minmax-aug}.\n\n\\begin{table}\n\\begin{equation}\n\\begin{array}{|c|c|c||c|c|c||c|c|c|}\n\\hline \n\\textrm{\\bf Knot} & \\ \\gamma^- \\ & \\ \\gamma^+ \\ & \\textrm{\\bf Knot} & \\ \\gamma^- \\ & \\ \\gamma^+ \\ & \\textrm{\\bf Knot} & \\ \\gamma^- \\ & \\ \\gamma^+ \\ \\nonumber \\\\\n\\hline \n\\hline\n\\ K_{-1-6k} \\ & 2 & 2 & \\ K_{2+6k}\\ & 6 & 2 & 6_2 & 3 & 30 \\\\\n\\ K_{-2-6k} \\ & 2 & 3 & \\ K_{3+6k}\\ & 6 & 3 & 6_3 & 6 & 6 \\\\\n\\ K_{-3-6k} \\ & 2 & 2 & \\ K_{4+6k}\\ & 6 & 2 & 7_3 & 1 & 10 \\\\\n\\ K_{-4-6k} \\ & 2 & 1 & \\ K_{5+6k}\\ & 6 & 1 & 7_5 & 3 & 30 \\\\\n\\ K_{-5-6k} \\ & 2 & 6 & \\ K_{6+6k}\\ & 6 & 6 & 8_{19} & 7 & 1 \\\\\n\\ K_{-6-6k} \\ & 2 & 1 & \\ K_{7+6k}\\ & 6 & 1 & 10_{124} & 2 & 8 \\\\\n\\hline \n\\hline\n\\ T_{2,2p+1} \\ & \\ 2p+3 \\ &\\ 2p-1 & \\multicolumn{6}{c|}{ } \\\\\n\\hline \n\\end{array}\n\\end{equation} \n\\caption{Improved Integrality: values of $\\gamma^-$ and $\\gamma^+$ for various knots. For twist knots $K_p$ the range of the subscript is labeled by $k=0,1,2,\\ldots$, and $T_{2,2p+1}$ denotes $(2,2p+1)$ torus knot.} \\label{c-minmax-aug}\n\\end{table}\n\n\n\\subsection{Extremal A-polynomials}\n\nIt is easy to see that if $P_r(a,q)$ is annihilated by\n$\\widehat{A}(\\hat M, \\hat L,a,q)$, then its extremal part $P^\\pm_r(q)$ is\nannihilated by the operator $\\widehat{A}^\\pm(\\hat M, \\hat L,q)$\nobtained by multiplying \n$\\widehat{A}(\\hat M, \\hat L,a^{\\mp 1},q)$ by $a^{\\pm r c_\\pm}$ (to make every \npower of $a$ nonnegative), and then setting $a=0$. This allows us to introduce\nthe extremal analogues of the curve \\eqref{calAxy} defined as distinguished, irreducible factors in \n\\begin{equation}\n\\mathcal{A}(x a^{- c_\\pm},y,a)|_{a^{\\mp 1} \\to 0} \n\\label{Amin} \n\\end{equation}\nthat determine the extremal BPS degeneracies. We call these curves extremal A-polynomials and denote them $\\mathcal{A}^\\pm(x,y)$. We also refer to $\\mathcal{A}^+(x,y)$ and $\\mathcal{A}^-(x,y)$ as top and bottom A-polynomials respectively. The extremal A-polynomials that we determine in this work are listed in Appendix \\ref{sec-extremeA}.\n\nAmong various interesting properties of extremal A-polynomials we note that they are tempered, i.e. the roots of their face polynomials are roots of unity. This is a manifestation of their quantizability and the so-called $K_2$ condition \\cite{abmodel, superA,Kontsevich-K2}, and presumably is related to the Improved Integrality of the corresponding extremal BPS states. \n\n\n\\subsection{Extremal BPS invariants from extremal A-polynomials}\n\nIn this section we give the analogue of Proposition \\ref{prop.main} for\nextremal BPS invariants.\n\n\\begin{proposition}\n\\label{prop.main.extreme}\n\\rm{(a)} Fix a knot $K$ and a natural number $r$. Then the extremal \nBPS invariants $b^\\pm_{r}$ are given by\n\\begin{equation}\nx\\frac{(y^\\pm)'(x)}{y^\\pm(x)} \n= \\frac{1}{2} \\sum_{r\\geq 1} r^2 b^\\pm_{r} \\frac{x^r}{1-x^r}\\,, \n\\label{xdyy-minmax}\n\\end{equation}\nwhere $y^\\pm=y^\\pm(x) \\in 1 + \\mathbb Q[[x]]$ is an algebraic function of $x$\nthat satisfies a polynomial equation\n$$\n\\mathcal{A}^\\pm(x,y^\\pm)=0 \\,.\n$$\n\\rm{(b)} Explicitly, $x \\partial_x y^\\pm\/y^\\pm$ is an algebraic function of \n$x$ and if \n\\begin{equation}\n\\label{xdyy-an}\nx (y^\\pm)'(x)\/y^\\pm(x)=\\sum_{n \\geq 0} a^\\pm_{n} x^n,\n\\end{equation} \nthen\n\\begin{equation}\nb^\\pm_{r} = \\frac{2}{r^2} \\sum_{d|r} \\mu(d) a^\\pm_{\\frac{r}{d}} \n\\,. \n\\label{b-r}\n\\end{equation}\n\\end{proposition}\n\n\\noindent\n\\emph{Proof.}\nWe define\n\\begin{equation}\ny^\\pm(x) = \n\\lim_{q\\to 1} \\frac{P^\\pm(qx,q)}{P^\\pm(x,q)} = \n\\lim_{q\\to 1} \\prod_{r\\geq 1;i,j;k\\geq 0} \n\\Big(\\frac{1 - x^r q^{r+j+2k+1} }{1 - x^r q^{j+2k+1}}\\Big)^{N_{r,r \\cdot\nc_\\pm,j}} \n= \\prod_{r\\geq 1;i} (1 - x^r )^{-r b^\\pm_r \/ 2} .\n\\label{sfx-prod-minmax}\n\\end{equation}\nAs in the proof of Proposition \\ref{prop.main}, it follows that $y^\\pm(x)$\nsatisfies the polynomial equation\n$$\n\\mathcal{A}^\\pm(x,y)=0 \\,.\n$$\nThis concludes the first part. The second part follows just as in \nProposition \\ref{prop.main}.\n\\qed\n\n\n\n\n\\section{Examples and computations} \n\\label{sec-results}\n\nIn this section we illustrate the claims and ideas presented earlier in many examples. First of all, LMOV invariants arise from redefinition of unnormalized knot polynomials. Therefore we recall that the unnormalized superpolynomial for the unknot reads \\cite{superA}\n\\begin{equation}\nP_{{\\bf 0_1},r}(a,q,t) = (-1)^{\\frac{r}{2}}a^{-r}q^{r}t^{-\\frac{3r}{2}} \\frac{(-a^2t^3;q^2)_{r}}{(q^2;q^2)_{r}} \\, ,\n\\label{Punknot} \n\\end{equation}\nand the unnormalized HOMFLY polynomial arises from $t=-1$ specialization of this expression. In what follows we often take advantage of the results for normalized superpolynomials $P^{norm}_r(K,a,q,t)$ for various knots $K$, derived in \\cite{superA,FGSS,Nawata}. Then the unnormalized superpolynomials that we need from the present perspective differ simply by the unknot contribution\n\\begin{equation}\nP_{K,r}(a,q,t) = P_{{\\bf 0_1},r}(a,q,t) P^{norm}_{K,r}(a,q,t). \\label{Punnorm}\n\\end{equation}\nIn general to get colored HOMFLY polynomials one would have to consider the action of a certain differential \\cite{DGR,GS}; however for knots considered in this paper, for which superpolynomials are known, HOMFLY polynomials arise from a simple substitution $t=-1$ in the above formulas. \n\n\n\\begin{wrapfigure}{l}{0.4\\textwidth}\n\\begin{center}\n\\includegraphics[scale=0.3]{draws\/4_1.pdf}\n\\end{center}\n\\caption{The $4_1$ knot.}\n\\label{fig-41}\n\\end{wrapfigure}\n\nLet us stress some subtleties related to various variable redefinitions. Super-A-polynomials for various knots, corresponding to the normalized superpolynomials $P^{norm}_r(K,a,q,t)$, were determined in \\cite{superA,FGSS,Nawata}; in the current notation we would write those polynomials using variables $M$ and $L$, as $A^{\\textrm{super}}(M,L,a,t)$. Super-A-polynomials in the unnormalized case (i.e. encoding asymptotics of unnormalized superpolynomials), which are relevant for our considerations, arise from $A^{\\textrm{super}}(M,L,a,t)$ by the substitution\n\\begin{equation}\nM\\mapsto M, \\qquad L \\mapsto (-a^2t^3)^{-1\/2} \\frac{1+ a^2 t^3 M}{1-M} L. \\label{MLnorm}\n\\end{equation}\nIn what follows we often consider $a$-deformed polynomials, which for knots considered in this paper are again simply obtained by setting $t=-1$ in $A^{\\textrm{super}}(M,L,a,t)$. These $a$-deformed polynomials are not yet identical, however closely related (by a simple change of variables) to augmentation polynomials or Q-deformed polynomials; we will present these relations in detail in some examples.\n\n\n\\subsection{The unknot}\n\nLet us illustrate first how our formalism works for the unknot. From the analysis of asymptotics, or recursion relations satisfied by (\\ref{Punknot}), the following super-A-polynomial is determined\\footnote{More precisely, due to present conventions, one has to substitute $M^2\\mapsto x, L\\mapsto y, a^2\\mapsto a$ to obtain the curve from \\cite{superA} on the nose.} \\cite{superA}\n\\begin{equation}\nA(M,L,a,t) = (-a^{-2}t^{-3})^{1\/2}(1+a^2 t^3 M^2)-(1-M^2)L.\n\\end{equation}\nThe analysis of the refined case essentially is the same as the unrefined, as the dependence on $t$ can be absorbed by a redefinition of $a$. Therefore let us focus on the unrefined case. From (\\ref{calAxy}) we find that, up to an irrelevant overall factor, the dual A-polynomial reads\n\\begin{equation}\n\\mathcal{A}(x,y,a) = x-a^2x y^2 -a+ay^2. \\label{Aconi}\n\\end{equation}\nFrom this expression we can immediately determine\n\\begin{equation}\ny^2=\\frac{1-x a^{-1}}{1-x a},\n\\end{equation}\nand comparing with (\\ref{sfx-prod}) we find only two non-zero BPS invariants $b_{1,\\pm 1}=\\pm 1$ (and from LMOV formulas (\\ref{f-P}) one can check that there are also only two non-zero LMOV invariants $N_{1,\\pm 1,j}$). These invariants represent of course two open M2-branes wrapping $\\mathbb{P}^1$ in the conifold geometry \\cite{OoguriV,AV-discs} (for the refined case we also find just two refined BPS invariants). Furthermore, from (\\ref{Punknot}) we find $c_{\\pm}=\\pm 1$, and therefore from (\\ref{Amin}) we determine the following extremal A-polynomials\n\\begin{equation}\n\\mathcal{A}^-(x,y) = 1-x-y^2,\\qquad \\qquad \\mathcal{A}^+(x,y) = 1+xy^2-y^2,\n\\end{equation}\nwhich represent two $\\mathbb{C}^3$ limits of the resolved conifold geometry (in terms of $Y=y^2$, the curve (\\ref{Aconi}) and the above extremal A-polynomials are the usual B-model curves for the conifold and $\\mathbb{C}^3$ respectively).\n\n\n\\subsection{The $4_1$ knot}\n\nAs the second example we consider the $4_1$ (figure-8) knot, see figure \\ref{fig-41}.\nThe (normalized) superpolynomial for this knots reads \\cite{superA} \n\\begin{equation}\nP^{norm}_{r} (a,q,t) = \\sum_{k=0}^{\\infty} (-1)^k a^{-2k} t^{-2k} q^{-k(k-3)} \\frac{(-a^2 t q^{-2},q^2)_k}{(q^2,q^2)_k} (q^{-2r},q^2)_k (-a^2 t^3 q^{2r}, q^2)_k \\,.\n\\label{Paqt41}\n\\end{equation}\n\nFrom this formula, after setting $t=-1$, it is immediate to determine $N_{r,i,j}$ LMOV invariants using the explicit relations (\\ref{f-P}), up to some particular value of $r$. Instead, using the knowledge of associated algebraic curves, we will explicitly determine the whole family of these invariants, labeled by arbitrary $r$.\n\nFirst of all, by considering recursion relations satisfied by $P^{norm}_r$, or from the analysis of its asymptotic behavior for large $r$, the following (normalized) super-A-polynomial is determined\\footnote{Again, one has to substitute $M^2\\mapsto x, L\\mapsto y, a^2\\mapsto a$ to obtain the curve from \\cite{superA} on the nose.} in \\cite{superA}\n\\begin{eqnarray}\nA^{\\text{super}} (M,L , a,t) \\, &=& \\,\na^4 t^5 (M^2-1)^2 M^4 + a^2 t^2 M^4 (1 + a^2 t^3 M^2)^2 L^3 + \\label{Asuper41} \\\\\n& & \\quad + a^2 t (M^2-1) (1 + t(1-t) M^2 + 2 a^2 t^3(t+1) M^4\n -2 a^2 t^4(t+1) M^6 + \\nonumber\\\\\n & & + a^4 t^6(1-t) M^8 - a^4 t^8 M^{10}) L - (1 + a^2 t^3 M^2) (1 + a^2 t(1-t) M^2 + \\nonumber \\\\\n & & \\quad + 2 a^2 t^2(t+1) M^4 + 2 a^4 t^4(t+1) M^6 + a^4 t^5(t-1) M^8 + a^6 t^7 M^{10}) L^2 . \\nonumber\n\\end{eqnarray}\nWe will use this formula when we consider refined BPS states; however at this moment let us consider its unrefined (i.e. $t=-1$) version. With the notation\nof Section \\ref{ssec-AJ} and Equation \\eqref{calAxy} we find the dual A-polynomial\n\\begin{eqnarray}\n\\mathcal{A}(x,y,a) &=& a^3 \\left(y^6-y^4\\right) +x \\left(-a^6 y^{10}+2 a^4 y^8-2 a^2 y^2+1\\right)+ \\label{calAa-41} \\\\\n& & + a x^2 \\left(a^4 y^{10}-2 a^4 y^8+2 y^2-1\\right) +x^3 \\left(a^2 y^4-a^4 y^6\\right). \\nonumber\n\\end{eqnarray}\nFrom \\eqref{Punnorm} and \\eqref{Paqt41} we find that the HOMFLY polynomial in the fundamental ($r=1$) representation is given by\n\\begin{equation}\nP_{1}(a,q) =a^{-3}\\frac{q}{\\left(1-q^2\\right)} + a^{-1}\\frac{q^4+1}{q \\left(q^2-1\\right)} \n+a \\frac{ \\left(q^4+1\\right)}{q \\left(1-q^2\\right)} + a^3 \\frac{ q}{q^2-1}.\n\\end{equation}\nComparing this with (\\ref{Pr-minmax}) we determine the value of $c_\\pm$\n\\begin{equation}\nc_- = -3, \\qquad \\quad c_+ =3, \\label{minmax-41}\n\\end{equation}\nso the extremal A-polynomials following from the definition \\eqref{Amin} and the result \\eqref{calAa-41} are given by\n\\begin{equation}\n\\mathcal{A}^-(x,y) = x - y^4 + y^6,\\qquad \\quad \n\\mathcal{A}^+(x,y) = 1 - y^2 + x y^6. \\label{Aminmax-41}\n\\end{equation}\nNote that $\\mathcal{A}^+(x,y^{-1}) = y^{-6} \\mathcal{A}^-(x,y)$, i.e. these curves agree up to $y\\mapsto y^{-1}$ (and multiplication by an overall monomial \nfactor) -- this reflects the fact that the $4_1$ knot is amphicheiral.\n\nWe can now extract the extremal BPS invariants from the curves (\\ref{Aminmax-41}). As these curves are cubic in terms of $Y=y^2$ variable, we can determine explicit solutions of the corresponding cubic equations. We will use two fortunate coincidences. \n\nThe first coincidence is that the unique solution $Y(x)=1+O(x)$ to the equation\n$\\mathcal{A}^-(x,Y) = x - Y^2 + Y^3 = 0$ is an algebraic hypergeometric \nfunction. Explicitly, we have \n\\begin{eqnarray}\nY(x) = Y^-(x) &=& \\frac{1}{3}+\\frac{2}{3}\\cos\\left[\\frac{2}{3}\\arcsin\\left(\\sqrt{\\frac{3^{3}x}{2^{2}}}\\right)\\right] \\nonumber\\\\\n&=& \\frac{1}{3}\\left[1-\\sum_{n=0}^{\\infty}\\frac{2}{3n-1}{3n \\choose n}x^{n}\\right] \\label{Y-41} \\\\\n&=& \\frac{1}{3}+\\frac{2}{3}\\ _{2}F_{1}\\left(-\\frac{1}{3},\\frac{1}{3};\\frac{1}{2};\\ \\frac{3^{3}x}{2^{2}}\\right). \\nonumber\n\\end{eqnarray}\nThe second coincidence is that $x \\partial_x Y^-\/Y^-$ is not only algebraic,\nbut also hypergeometric. Explicitly, we have:\n\\begin{eqnarray}\nx\\frac{\\partial_x Y^-(x)}{Y^-(x)} &=& \\frac{1}{3}-\\frac{2}{3}\\frac{\\cos\\left[\\frac{1}{6}\\arccos\\left(1-\\frac{27x}{2}\\right)\\right]}{\\sqrt{4-27x}} \\nonumber \\\\\n&=& - \\sum_{n=1}^{\\infty} {3n-1 \\choose n-1} x^n \\\\\n&=& \\frac{1}{3}-\\frac{1}{3}\\ _{2}F_{1}\\left(\\frac{1}{3},\\frac{2}{3};\\frac{1}{2};\\ \\frac{3^{3}x}{2^{2}}\\right).\n\\end{eqnarray}\nRecalling \\eqref{b-r}, we find that \n\\begin{equation}\nx\\frac{\\partial_x Y^-(x)}{Y^-(x)} =\\sum_{n=1}^\\infty a^-_n x^n, \\qquad\na^-_n = -\\frac{1}{2} {3n-1 \\choose n-1} \\label{an-41}\n\\end{equation}\nso that the extremal bottom BPS degeneracies \\eqref{b-r} are given by\n\\begin{equation}\nb^-_r = -\\frac{1}{r^2}\\sum_{d|r} \\mu\\big(\\frac{r}{d}\\big) {3d-1 \\choose d-1}. \\label{br-41}\n\\end{equation}\nSeveral values of $b^-_r$ are given in table \\ref{br-41-tab}. Note that the integrality of $b^-_r$ implies a nontrivial statement, that for each $r$ the sum in (\\ref{br-41}) must be divisible by $r^2$.\n\n\\begin{table}\n\\begin{equation}\n\\begin{array}{|c|c|c|}\n\\hline \nr & b^-_r = -b^+_r & 2\\frac{b^-_r}{r} \\nonumber \\\\\n\\hline \n1 & -1 & -2\\\\\n2 & -1 & -1 \\\\\n3 & -3 & -2 \\\\\n4 & -10 & -5 \\\\\n5 & -40 & -16 \\\\\n6 & -171 & -57 \\\\\n7 & -791 & -226 \\\\\n8 & -3\\, 828 & - 957 \\\\\n9 & -19\\, 287 & -4286 \\\\\n10 & -100\\, 140 & - 20\\, 028\\\\\n11 & -533\\, 159 & -96\\, 938 \\\\\n12 & -2\\, 897\\, 358 & -482\\, 893 \\\\\n13 & -16\\, 020\\, 563 & -2\\, 464\\, 702 \\\\\n14 & -89\\, 898\\, 151 & -12\\, 842\\, 593 \\\\\n\\ 15 \\ &\\ -510\\, 914\\, 700 \\ &\\ -68\\, 121\\, 960 \\ \\\\\n\\hline \n\\end{array}\n\\end{equation} \n\\caption{Extremal BPS invariants and their Improved Integrality for \nthe $4_1$ knot. \n} \\label{br-41-tab}\n\\end{table}\n\nIn an analogous way we determine top BPS invariants. \nThe above mentioned two coincidences persist. The solution \n$Y^+(x)=1\/Y^-(x)=1+O(x)$ of the equation $\\mathcal{A}^+(x,Y)=1-Y+xY^3=0$ is\ngiven by\n\\begin{equation}\nY^+(x) = \\frac{2}{\\sqrt{3x}}\\sin\\left[\\frac{1}{3}\\arcsin\\left(\\sqrt{\\frac{3^{3}x}{2^{2}}}\\right)\\right] = \\sum_{n=0}^{\\infty} \\frac{x^n}{2n+1} {3n \\choose n} = \\, _{2}F_{1}\\left(\\frac{1}{3},\\frac{2}{3};\\frac{3}{2};\\ \\frac{3^{3}x}{2^{2}}\\right)\n\\end{equation}\nso that\n\\begin{equation}\nx\\frac{\\partial_x Y^+(x)}{Y^+(x)} = - x\\frac{\\partial_x Y^-(x)}{Y^-(x)}.\n\\end{equation}\nTherefore $a_n^+=-a^-_n$ and $b^+_r = -b^-_r$, which is a manifestation of the amphicheirality of the $4_1$ knot. The above results illustrate Proposition \\ref{prop.twist} for the $4_1=K_{-1}$\ntwist knot. \n\nExperimentally, it also appears that the Improved Integrality holds \n\\eqref{eq.improved} with $\\gamma^\\pm =2$; see table \\ref{br-41-tab}.\n\nNext, we discuss the asymptotics of $b^\\pm_r$ for large $r$. Stirling's \nformula gives the asymptotics of $a^-_r$, and part (b) of Lemma \\ref{lem.1}\nconcludes that the asymptotics of $b^-_r$ are given by\n\\begin{align*}\nb^-_r &= -\\frac{1}{28 \\sqrt{3 \\pi}} \n\\left(\\frac{27}{4}\\right)^r r^{-1\/2} \\Big( \n1\n-\\frac{7}{72 r}\n+\\frac{49}{10368 r^2}\n+\\frac{6425}{2239488 r^3}\n-\\frac{187103}{644972544 r^4}\n+O\\left(\\frac{1}{r}\\right)^5 \\Big).\n\\end{align*}\nNote that the $Y$-discriminant of $\\mathcal{A}^-(x,Y)$ is\ngiven by \n$$\n\\mathrm{Disc}_Y \\mathcal{A}^-(x,Y)= -x (-4 + 27 x)\n$$\nand its root $x=\\frac{4}{27}$ matches the exponential growth rate \nof $b^-_r$, as asserted in Lemma \\ref{lem.2}.\n\nFinally, we discuss all BPS invariants $b_{r,i}$, not just the extremal ones, i.e. we turn on the\n$a$-deformation. To this end it is useful to rescale the variable $x$ in \n\\eqref{calAa-41} by $c_-=-3$, so that\n\\begin{eqnarray}\n\\mathcal{A}(a^3 x,y,a) &=& (x-y^4+y^6) -2 a x y^2 +a^2 \\left(2 x^2 y^2-x^2+2 x y^8\\right) + \\\\\n&& -a^3 x y^{10} +a^4 \\left(x^3 y^4+x^2 y^{10}-2 x^2 y^8\\right) -a^5 x^3 y^6 \\nonumber\n\\end{eqnarray}\ncontains $\\mathcal{A}^-(x,y)$ at its lowest order in $a$. Then, from (\\ref{xdyy}) and \\eqref{b-ri} we can determine the invariants $b_{r,i}$ for this curve; we list some of them in table \\ref{aBPS-41-tab}, whose first column of course agrees with the extremal BPS invariants $b^-_r$\ngiven by \\eqref{br-41}.\n\n\\begin{table}\n\\begin{small}\n\\begin{equation}\n\\begin{array}{|c|ccccccccc|} \\hline\nr \\setminus i & 0 & 1 & 2 & 3 & 4 & 5 & 6 & 7 & 8 \\\\ \\hline\n1 & -1 & 1 & 1 & -2 & 1 & 0 & 0 & 0 & 0 \\\\\n2 & -1 & 2 & 1 & -4 & 3 & -6 & 11 & -8 & 2 \\\\\n3 & -3 & 7 & 2 & -18 & 21 & -23 & 34 & -48 & 82 \\\\\n4 & -10 & 30 & -2 & -88 & 134 & -122 & 150 & -234 & 384 \\\\\n5 & -40 & 143 & -55 & -451 & 889 & -797 & 664 & -978 & 1716 \\\\\n6 & -171 & 728 & -525 & -2346 & 5944 & -5822 & 3134 & -2862 & 6196 \\\\\n7 & -791 & 3876 & -4080 & -12172 & 39751 & -44657 & 17210 & 4958 & 4071 \\\\\n8 & -3828 & 21318 & -29562 & -62016 & 264684 & -347256 & 121276 & 191744 & -263282 \\\\\n9 & -19287 & 120175 & -206701 & -303910 & 1751401 & -2692471 & 1053774 & 2299115 & -4105859 \\\\\n10 & -100140 & 690690 & -1418417 & -1381380 & 11503987 & -20672858 & 10012945 & 21567000 & -46462399 \\\\ \\hline\n\\end{array}\n\\nonumber\n\\end{equation}\n\\caption{BPS invariants $b_{r,i}$ for the $4_1$ knot.} \n\\label{aBPS-41-tab}\n\\end{small}\n\\end{table}\n\n\n\n\\subsection{$5_2$ knot and Catalan numbers}\n\nWe can analyze the $K_2=5_2$ knot, see figure \\ref{fig-52}, similarly as we did for the figure-8 knot. Starting from the super-A-polynomial derived in \\cite{FGSS} and performing redefinitions discussed above, we get the following $a$-deformed algebraic curve (dual A-polynomial)\n\\begin{eqnarray}\n\\mathcal{A}(x,y,a) &=& a^{10} x^2 y^{16}-2 a^9 x^3 y^{16}+a^8 x^2 y^{12} \\left(x^2 y^4-3 y^2-4\\right)+a^7 x y^{12} \\left(x^2 \\left(4 y^2+3\\right)-1\\right)+ \\nonumber \\\\\n&& + a^6 x^2 y^8 \\left(-x^2 y^6+5 y^4+3 y^2+6\\right)+a^5 x y^{10} \\left(2-x^2 \\left(3 y^2+2\\right)\\right) + \\label{calAa-52} \\\\\n& & -a^4 x^2 \\left(3 y^6+4 y^4-3 y^2+4\\right) y^4-a^3 x \\left(y^2-1\\right) y^4 \\left(x^2 \\left(y^2-1\\right)+y^2+3\\right)+\\nonumber \\\\\n& & + a^2 x^2 \\left(-3 y^6+5 y^4-3 y^2+1\\right)+a x \\left(-3 y^4+4 y^2-2\\right)-y^2+1. \\nonumber\n\\end{eqnarray}\nThe unnormalized HOMFLY polynomial is given by\n\\begin{equation}\nP_{1}(a,q) = a \\frac{\\left(q^4-q^2+1\\right)}{q \\left(1-q^2\\right) } + a^5\\frac{ \\left(q^4+1\\right)}{q \\left(q^2-1\\right)}+a^7\\frac{q}{1-q^2},\n\\end{equation}\nso that \n\\begin{equation}\nc^- =1,\\qquad\\quad c^+=7.\n\\end{equation}\nIt follows that the extremal A-polynomials of \\eqref{Amin} are given by\n\\begin{equation}\n\\mathcal{A}^-(x,y) =\n1 - y^2 - x y^4 ,\\qquad \\quad \\mathcal{A}^+(x,y) = 1 - y^2 - x y^{12}. \\label{Aminmax-52}\n\\end{equation}\n\nThe two fortunate coincidences of the $4_1$ knot persist for the $5_2$ knot\nas well. It is again convenient to use a rescaled variable $Y=y^2$. \nIn particular note that the curve $\\mathcal{A}^-(x,y)$, \npresented as $1-y^2-xy^4 = 1-Y-x Y^2$, is the curve that encodes \nthe Catalan numbers. The latter are the coefficients in the series expansion\n\\begin{equation}\nY(x)=Y^-(x) = \\frac{-1+\\sqrt{1+4x}}{2x} = \\sum_{n=0}^{\\infty} \\frac{1}{n+1}{2n \\choose n} (-x)^n. \\label{Ymin-52}\n\\end{equation}\nTherefore we have found a new role of Catalan numbers -- they encode BPS numbers for $5_2$ knot (and as we will see, also for other twist knots $K_p$ for $p>1$).\n\nNow we get\n\\begin{equation}\nx\\frac{\\partial_x Y^-(x)}{Y^-(x)} = -\\frac{1}{2}+\\frac{1}{2}\\frac{1}{\\sqrt{1+4x}} = \\sum_{n=1}^{\\infty} {2n-1 \\choose n-1} (-x)^n = -\\frac{1}{2} + \\frac{1}{2}\\, _1 F_0\\left(\\frac{1}{2};\\ -\\frac{2^{2}x}{1^{1}}\\right),\n\\end{equation}\nso that\n\\begin{equation}\nb^-_r = \\frac{1}{r^2}\\sum_{d|r} \\mu\\big(\\frac{r}{d}\\big) (-1)^{d+1} {2d-1 \\choose d-1}. \\label{br-52min}\n\\end{equation}\nSeveral values of $b^-_r$ are given in table \\ref{br-52-tab}.\n\n\\begin{table}\n\\begin{equation}\n\\begin{array}{|c|c|c|c|c|}\n\\hline \nr & b^-_r & b^+_r & 6\\frac{b^-_r}{r} & 2\\frac{b^+_r}{r} \\nonumber \\\\\n\\hline \n1 & -1 & -1 & -6 & -2 \\\\\n2 & 1 & 3& 3 & 3 \\\\\n3 & -1 & -15 & -2 & -10 \\\\\n4 & 2 & 110 & 3 & 55 \\\\\n5 & -5 & -950 & -6 & -380 \\\\\n6 & 13 & 9021 & 13 & 3007 \\\\\n7 & -35 & -91\\, 763 & -30 & -26\\, 218\\\\\n8 & 100 & 982\\, 652 & 75 & 245\\, 663 \\\\\n9 & -300 & -10\\, 942\\, 254 & -200 & -2\\, 431\\, 612\\\\\n10 & 925 & 125\\, 656\\, 950 & 555 &25\\, 131\\, 390\\\\\n11 & -2915 & -1\\, 479\\, 452\\, 887 & -1590 & -268\\, 991\\, 434\\\\\n12 & 9386 & 17\\, 781\\, 576\\, 786 & 4693 &2\\, 963\\, 596\\, 131\\\\\n13 & -30\\, 771& -217\\, 451\\, 355\\, 316 & -14\\, 202 & -33\\, 454\\, 054\\, 664\\\\\n14 & 102\\, 347 & 2\\, 698\\, 753\\, 797\\, 201& 43\\, 863 & 385\\, 536\\, 256\\, 743\\\\\n\\ 15 \\ &\\ -344\\, 705 \\ &\\ -33\\, 922\\, 721\\, 455\\, 050\\ &\\ -137\\, 882 \\ &\\ -4\\, 523\\, 029\\, 527\\,340\\ \\\\\n\\hline \n\\end{array}\n\\end{equation} \n\\caption{Extremal BPS invariants and their Improved Integrality for $5_2$ knot.} \\label{br-52-tab}\n\\end{table}\n\n\nIn an analogous way for $\\mathcal{A}^+(x,Y) = 1 - Y - x Y^{6}$ we get more involved solution\n\\begin{equation}\nY(x)^+ = 1 + \\sum_{n=1}^{\\infty} \\frac{1}{n} {6n \\choose n-1} (-x)^n = \n_{5}F_{4}\\left(\\frac{1}{6},\\frac{2}{6},\\frac{3}{6},\\frac{4}{6},\\frac{5}{6};\\ \\frac{6}{5},\\frac{4}{5},\\frac{3}{5},\\frac{2}{5};\\ -\\frac{6^{6}x}{5^{5}}\\right), \\label{Ymax-52}\n\\end{equation}\nso that\n\\begin{equation}\nx\\frac{\\partial_x Y^+(x)}{Y^+(x)} = \\sum_{n=1}^{\\infty} {6n-1 \\choose n-1} (-x)^n = -\\frac{1}{6}+\\frac{1}{6} \\, _{5}F_{4}\\left(\\frac{1}{6},\\frac{2}{6},\\frac{3}{6},\\frac{4}{6},\\frac{5}{6};\\ \\frac{4}{5},\\frac{3}{5},\\frac{2}{5},\\frac{1}{5};\\ -\\frac{6^{6}x}{5^{5}}\\right),\n\\end{equation}\nand in consequence\n\\begin{equation}\nb_r^+ = \\frac{1}{r^2}\\sum_{d|r} \\mu\\big(\\frac{r}{d}\\big) (-1)^{d} {6d-1 \\choose d-1}. \\label{br-52max}\n\\end{equation}\nSeveral values of $b^+_r$ are also given in table \\ref{br-52-tab}.\n\n\nOur discussion illustrates Proposition \\ref{prop.twist} for the $5_2=K_2$\ntwist knot. Experimentally -- see table \\ref{br-52-tab} -- it appears that the Improved Integrality \\eqref{eq.improved}\nholds with\n\\begin{equation}\n\\gamma^- = 6,\\qquad\\quad \\gamma^+=2.\n\\end{equation}\n\nNext, we consider the asymptotics of the extremal BPS numbers. Using Lemma \\ref{lem.1} and Stirling formula for the binomials in \\eqref{br-52min} and \\eqref{br-52max} we find respectively\n\\begin{wrapfigure}{l}{0.4\\textwidth}\n\\begin{center}\n\\includegraphics[scale=0.3]{draws\/5_2.pdf}\n\\end{center}\n\\caption{The $5_2$ knot.}\n\\label{fig-52}\n\\end{wrapfigure}\n\\begin{equation}\n\\lim_{r\\to\\infty} \\frac{b^-_r}{b^-_{r+1}} = -\\frac{1}{4},\\qquad\\quad \\lim_{r\\to\\infty} \\frac{b^+_r}{b^+_{r+1}} = -\\frac{5^5}{6^6}. \\label{br-asympt-52}\n\\end{equation}\nThis matches with Lemma \\ref{lem.2}, since the $Y$-discriminants of \n$\\mathcal{A}^\\pm(x,Y)$ are given by \n\\begin{eqnarray}\n\\mathrm{Disc}_Y \\mathcal{A}^-(x,Y) &=& 1 + 4 x,\\nonumber \\\\\n\\mathrm{Disc}_Y \\mathcal{A}^+(x,Y) &=& x^4(5^5 + 6^6x).\\nonumber\n\\end{eqnarray}\n\n\nFinally, we also consider the $a$-deformation of the extremal curves.\nRescaling $x\\mapsto a^{-c_-} x$ in \\eqref{calAa-52} with $c_-=1$ we get a curve \nthat contains $\\mathcal{A}^-(x,y)$ at its lowest order in $a$. Then, from \n\\eqref{xdyy} and \\eqref{b-ri}, the find integral invariants $b_{r,i}$ given in \ntable \\ref{aBPS-52-tab}. The first column of table \\ref{aBPS-52-tab} agrees \nwith the values of \\eqref{br-52min}.\n\n\n\n\\begin{table}\n\\begin{small}\n\\begin{equation}\n\\begin{array}{|c|ccccccccc|} \\hline\nr \\setminus i & 0 & 1 & 2 & 3 & 4 & 5 & 6 & 7 & 8 \\\\ \\hline\n1 & -1 & 0 & 2 & -1 & 0 & 0 & 0 & 0 & 0 \\\\\n2 & 1 & -2 & 1 & -4 & 11 & -10 & 3 & 0 & 0 \\\\\n3 & -1 & 4 & 0 & -12 & 23 & -71 & 154 & -162 & 80 \\\\\n4 & 2 & -12 & 14 & 8 & 40 & -226 & 594 & -1542 & 2944 \\\\\n5 & -5 & 36 & -66 & -30 & 132 & -184 & 1550 & -6108 & 16525 \\\\\n6 & 13 & -114 & 302 & -94 & -419 & -660 & 3387 & -12042 & 56209 \\\\\n7 & -35 & 372 & -1296 & 1168 & 1843 & -1400 & -1372 & -27398 & 135350 \\\\\n8 & 100 & -1244 & 5382 & -8014 & -4222 & 12390 & 23462 & -42626 & 163928 \\\\\n9 & -300 & 4240 & -21932 & 45383 & -6044 & -79628 & -31246 & 116368 & 589812 \\\\\n10 & 925 & -14676 & 88457 & -234124 & 160251 & 359514 & -192014 & -1022096 & -86854 \\\\ \\hline\n\\end{array}\n\\nonumber\n\\end{equation}\n\\caption{BPS invariants $b_{r,i}$ for the $5_2$ knot.} \n\\label{aBPS-52-tab}\n\\end{small}\n\\end{table}\n\n\n\n\\subsection{Twist knots}\n\nThe $4_1$ and $5_2$ knots are special cases, corresponding respectively to $p=-1$ and $p=2$, in a series of twist knots $K_p$, labeled by an integer $p$. Apart from a special case $p=0$ which is the unknot and $p=1$ which is the\ntrefoil knot $3_1$, all other twist knots are hyperbolic. In this section we analyze their BPS invariants. The two coincidences of the $4_1$\nknot persist for all twist knots. The formulas for $p>1$ are somewhat\ndifferent from those for $p<0$, so we analyze them separately. \n\nWe start with $p<0$. In this case the bottom A-polynomial turns out to be the same for all $p$, however the top A-polynomial depends on $p$, \n\\begin{equation}\n\\boxed{ \\mathcal{A}^-_{K_p}(x,y)=x-y^4+y^6,\\qquad\\quad \\mathcal{A}^+_{K_p}(x,y) = 1-y^2+x y^{4|p|+2} }\n\\end{equation}\nFor $p=-1$ these curves of course reduce to those for the $4_1$ knot (\\ref{Aminmax-41}). For all $p<0$ the bottom BPS invariants are the same as for the $4_1$ knot \\eqref{br-41}\n\\begin{equation}\nb^-_{K_p,r} = -\\frac{1}{r^2}\\sum_{d|r} \\mu\\big(\\frac{r}{d}\\big) {3d-1 \\choose d-1}, \\qquad p <0. \\label{br-min-Kp<0}\n\\end{equation}\nTo get top invariants it is convenient to introduce $Y=y^2$ and consider the equation $\\mathcal{A}^+_{K_p}(x,Y) = 1-y^2+x Y^{2|p|+1} = 0$, whose solution of interest reads\n\\begin{eqnarray}\nY(x) &=& \\sum_{n=0}^{\\infty} \\frac{1}{2|p|n+1} {(2|p|+1)n \\choose n} x^n = \\\\\n&=& _{2|p|}F_{2|p|-1}\\left(\\frac{1}{2|p|+1},...,\\frac{2|p|}{2|p|+1};\\frac{2|p|+1}{2|p|},\\frac{2|p|-1}{2|p|},\\frac{2|p|-2}{2|p|},...,\\frac{2}{2|p|};\\ \\frac{\\left(2|p|+1\\right)^{2|p|+1}x}{\\left(2|p|\\right)^{2|p|}}\\right) \\nonumber\n\\end{eqnarray}\nwhere $_{2|p|}F_{2|p|-1}$ is the generalized hypergeometric function. Then\n\\begin{eqnarray}\nx\\frac{Y'(x)}{Y(x)} &=& \\sum_{n=1}^{\\infty} {(2|p|+1)n - 1 \\choose n-1} x^n = \\\\\n&=& \\frac{1}{2|p|+1}\\left( _{2|p|}F_{2|p|-1}\\left(\\frac{1}{2|p|+1},...,\\frac{2|p|}{2|p|+1};\\ \\frac{2|p|-1}{2|p|},...,\\frac{1}{2|p|};\\ \\frac{(2|p|+1)^{2|p|+1} x}{\\left(2|p|\\right)^{2|p|}}\\right) -1\\right)\\nonumber\n\\end{eqnarray}\nFrom this expression we find top BPS invariants\n\\begin{equation}\nb^+_{K_p,r}= \\frac{1}{r^2}\\sum_{d|r} \\mu\\big(\\frac{r}{d}\\big) {(2|p|+1)d - 1 \\choose d-1}, \\qquad p<0. \\label{br-max-Kp<0}\n\\end{equation}\n\nNext, we consider the case $p>1$. Their bottom A-polynomials are the same for all $p$, however top A-polynomials depend on $p$, \n\\begin{equation}\n\\boxed{ \\mathcal{A}^-_{K_p}(x,y)=1-y^2- x y^4,\\qquad\\quad \\mathcal{A}^+_{K_p}(x,y) = 1-y^2+x y^{4p+4} }\n\\end{equation}\nFor $p=2$ these curves reduce to the results for $5_2$ knot (\\ref{Aminmax-52}). For all $p>1$ the bottom BPS invariants are the same as for $5_2$ knot (\\ref{br-52min})\n\\begin{equation}\nb^-_{K_p,r} = \\frac{1}{r^2}\\sum_{d|r} \\mu\\big(\\frac{r}{d}\\big) (-1)^{d+1} {2d-1 \\choose d-1}, \\qquad p>1 \\label{br-min-Kp>0}\n\\end{equation}\nwhich means that Catalan numbers encode these BPS invariants for all $K_{p>1}$ twist knots.\n\nTo get top invariants we again introduce $Y=y^2$ and consider the equation $\\mathcal{A}^+_{K_p}(x,Y) = 1-Y-x Y^{2p+2} = 0$, whose solution of interest reads\n\\begin{eqnarray}\nY(x) &=& 1 + \\sum_{n=1}^{\\infty} \\frac{1}{n} {(2p+2)n \\choose n-1} (-x)^n = \\\\\n&=& _{2p+1}F_{2p}\\left(\\frac{1}{2p+2},...,\\frac{2p+1}{2p+2};\\frac{2p+2}{2p+1},\\frac{2p}{2p+1},\\frac{2p-1}{2p+1},...,\\frac{2}{2p+1};-\\frac{\\left(2p+2\\right)^{2p+2}x}{\\left(2p+1\\right)^{2p+1}}\\right) \\nonumber\n\\end{eqnarray}\nThen\n\\begin{eqnarray}\nx\\frac{Y'(x)}{Y(x)} &=& \\sum_{n=1}^{\\infty} {(2p+2)n - 1 \\choose n-1} (-x)^n = \\\\\n&=& \\frac{1}{2p+2}\\left( _{2p+1}F_{2p}\\left(\\frac{1}{2p+2},...,\\frac{2p+1}{2p+2};\\frac{2p}{2p+1},...,\\frac{1}{2p+1};-\\frac{\\left(2p+2\\right)^{2p+2}x}{\\left(2p+1\\right)^{2p+1}}\\right) -1\\right) \\nonumber\n\\end{eqnarray}\nFrom this expression we find top BPS invariants\n\\begin{equation}\nb^+_{K_p,r} = \\frac{1}{r^2}\\sum_{d|r} \\mu\\big(\\frac{r}{d}\\big) (-1)^d {(2p+2)d - 1 \\choose d-1}, \\qquad p>1. \n\\label{br-max-Kp>0}\n\\end{equation}\n\nThe Improved Integrality holds for twist knots $K_p$ and the values of $\\gamma^\\pm$ are given in table \\ref{c-minmax-aug}. Note that these invariants repeat periodically with period 6 for both positive and negative $p$.\n\nFinally, turning on $a$-deformation also leads to integral invariants $b_{r,i}$, as an example see the results for $6_1= K_{-2}$ knot in table \\ref{aBPS-61-tab}.\n\n\\begin{table}\n\\begin{small}\n\\begin{equation}\n\\begin{array}{|c|ccccccccc|} \\hline\nr \\setminus i & 0 & 1 & 2 & 3 & 4 & 5 & 6 & 7 & 8 \\\\ \\hline\n1 & -1 & 1 & 1 & -2 & 1 & 0 & 0 & 0 & 0 \\\\\n2 & -1 & 2 & 1 & -4 & 3 & -6 & 11 & -8 & 2 \\\\\n3 & -3 & 7 & 2 & -18 & 21 & -23 & 34 & -48 & 82 \\\\\n4 & -10 & 30 & -2 & -88 & 134 & -122 & 150 & -234 & 384 \\\\\n5 & -40 & 143 & -55 & -451 & 889 & -797 & 664 & -978 & 1716 \\\\\n6 & -171 & 728 & -525 & -2346 & 5944 & -5822 & 3134 & -2862 & 6196 \\\\\n7 & -791 & 3876 & -4080 & -12172 & 39751 & -44657 & 17210 & 4958 & 4071 \\\\\n8 & -3828 & 21318 & -29562 & -62016 & 264684 & -347256 & 121276 & 191744 & -263282 \\\\\n9 & -19287 & 120175 & -206701 & -303910 & 1751401 & -2692471 & 1053774 & 2299115 & -4105859 \\\\\n10 & -100140 & 690690 & -1418417 & -1381380 & 11503987 & -20672858 & 10012945 & 21567000 & -46462399 \\\\ \\hline\n\\end{array}\n\\nonumber\n\\end{equation}\n\\caption{BPS invariants $b_{r,i}$ for the $6_1$ knot.} \n\\label{aBPS-61-tab}\n\\end{small}\n\\end{table}\n\n\n\n\\subsection{Torus knots}\n\nWe can analyze BPS degeneracies for torus knots in the same way as we did for twist knots. Let us focus on the series of $(2,2p+1)\\equiv (2p+1)_1$ knots and present several examples. For the trefoil, $3_1$, see figure \\ref{fig-31}, the ($a$-deformed) dual A-polynomial is given by\n\\begin{equation}\n\\mathcal{A}(x,y,a) = -1 + y^2 + a^2 x^2 y^6 + a^5 x y^8 + \n a x(1 - y^2 + 2 y^4) - a^3 x y^4(2 + y^2) - a^4 x^2 y^8.\n\\end{equation}\nFrom the form of the HOMFLY polynomial we find $c_-=1$, so after appropriate rescaling of the above result we get\n\\begin{equation}\n\\mathcal{A}(a^{-1}x,y,a) = (-1 + x + y^2 - x y^2 + 2 x y^4 + x^2 y^6) - a^2 x y^4 (2 + y^2 + x y^4) +a^4 x y^8 .\n\\end{equation}\nThe lowest term in $a$ in this expression represents the extremal A-polynomial\n\\begin{equation}\n\\mathcal{A}^-(x,y) = -1 + x + y^2 - x y^2 + 2 x y^4 + x^2 y^6.\n\\end{equation}\nThe corresponding BPS invariants are given in table \\ref{aBPS-31-tab}.\n\nFor the $5_1$ knot we find that $c_-=3$ and the rescaled dual A-polynomial takes form\n\\begin{eqnarray}\n\\mathcal{A}(a^{-3}x,y,a) &=& -1 + x + y^2 + 2 x^2 y^{10} + x^3 y^{20} + \\\\\n&& + x y^2 (-1 + 2 y^2) + x y^6 (-2 + 3 y^2) + x^2 y^{12} (-1 + 3 y^2) \\nonumber \\\\\n&& + a^2 \\left(-x^3 y^{22}-2 x^2 y^{16}-x^2 \\left(4 y^2+1\\right) y^{12}-x y^{10}-2 x y^4+2 x \\left(1-2 y^2\\right) y^6\\right) + \\nonumber\\\\\n&& + a^4 \\left(x^2 y^{14}+2 x^2 \\left(y^2+1\\right) y^{16}+x y^8+x \\left(2 y^2-1\\right) y^{10}\\right) +\\nonumber \\\\\n&& + a^6 (-2 x^2 y^{18} - x^2 y^{20}) + a^8 x^2 y^{22} . \\nonumber\n\\end{eqnarray}\n\\begin{wrapfigure}{l}{0.4\\textwidth}\n\\begin{center}\n\\includegraphics[scale=0.3]{draws\/3_1.pdf}\n\\end{center}\n\\caption{The $3_1$ knot.}\n\\label{fig-31}\n\\end{wrapfigure}\nThe terms in the first two lines above constitute the extremal A-polynomial $\\mathcal{A}^-(x,y)$. Several corresponding BPS invariants are given in table \\ref{aBPS-51-tab}.\n\nFor the $7_1$ knot the $a$-deformed A-polynomial takes form of a quite lengthy expression, so we list just some BPS invariants -- with $a$-deformation taken into account -- in the table \\ref{aBPS-71-tab}.\n\nSimilarly we can determine top A-polynomials. We present the list of extremal A-polynomials for several torus knots in table \\ref{tab-A-torus}. Note that for various knots these polynomials have the same terms of lower degree, and for higher degrees more terms appear for more complicated knots. It would be interesting to understand this pattern and its manifestation on the level of BPS numbers.\n\nFurthermore, we observe that the Improved Integrality also holds for this family of torus knots, with the values of $\\gamma^\\pm$ given in table \\ref{c-minmax-aug}. Note that the values of $\\gamma^\\pm$ grow linearly with $p$.\n\n\n\n\n\n\\begin{table}\n\\begin{small}\n\\begin{equation}\n\\begin{array}{|c|cccccccc|} \\hline\nr \\setminus i & 0 & 1 & 2 & 3 & 4 & 5 & 6 & 7 \\\\ \\hline\n1 & -2 & 3 & -1 & 0 & 0 & 0 & 0 & 0 \\\\\n2 & 2 & -8 & 12 & -8 & 2 & 0 & 0 & 0 \\\\\n3 & -3 & 27 & -84 & 126 & -99 & 39 & -6 & 0 \\\\\n4 & 8 & -102 & 488 & -1214 & 1764 & -1554 & 816 & -234 \\\\\n5 & -26 & 413 & -2682 & 9559 & -20969 & 29871 & -28203 & 17537 \\\\\n6 & 90 & -1752 & 14484 & -67788 & 201810 & -405888 & 569322 & -564192 \\\\\n7 & -329 & 7686 & -77473 & 451308 & -1711497 & 4499696 & -8504476 & 11792571 \\\\\n8 & 1272 & -34584 & 411948 & -2882152 & 13350352 & -43658370 & 104759240 & -188904738 \\\\\n9 & -5130 & 158730 & -2183805 & 17877558 & -98157150 & 385713186 & -1128850632 & 2524827921 \\\\\n10 & 21312 & -740220 & 11560150 & -108550256 & 690760044 & -3179915704 & 11028120884 & -29597042376 \\\\ \\hline\n\\end{array}\n\\nonumber\n\\end{equation}\n\\caption{BPS invariants $b_{r,i}$ for the $3_1$ knot.} \n\\label{aBPS-31-tab}\n\\end{small}\n\\end{table}\n\n\n\n\\begin{table}\n\\begin{small}\n\\begin{equation}\n\\begin{array}{|c|cccc|} \\hline\nr \\setminus i & 0 & 1 & 2 & 3 \\\\ \\hline\n1 & -3 & 5 & -2 & 0 \\\\\n2 & 10 & -40 & 60 & -40 \\\\\n3 & -66 & 451 & -1235 & 1750 \\\\\n4 & 628 & -5890 & 23440 & -51978 \\\\\n5 & -7040 & 83725 & -438045 & 1330465 \\\\\n6 & 87066 & -1257460 & 8165806 & -31571080 \\\\\n7 & -1154696 & 19630040 & -152346325 & 716238720 \\\\\n8 & 16124704 & -315349528 & 2847909900 & -15779484560 \\\\\n9 & -234198693 & 5179144365 & -53361940365 & 340607862518 \\\\\n10 & 3508592570 & -86566211200 & 1002184712130 & -7243117544640 \\\\ \\hline\n\\end{array}\n\\nonumber\n\\end{equation}\n\\caption{BPS invariants $b_{r,i}$ for the $5_1$ knot.} \n\\label{aBPS-51-tab}\n\\end{small}\n\\end{table}\n\n\n\n\\begin{table}\n\\begin{small}\n\\begin{equation}\n\\begin{array}{|c|cccccccc|} \\hline\nr \\setminus i & 0 & 1 & 2 & 3 & 4 & 5 & 6 & 7 \\\\ \\hline\n1 & -4 & 7 & -3 & 0 & 0 & 0 & 0 & 0 \\\\\n2 & 28 & -112 & 168 & -112 & 28 & 0 & 0 & 0 \\\\\n3 & -406 & 2618 & -6916 & 9604 & -7406 & 3010 & -504 & 0 \\\\\n4 & 8168 & -71588 & 270928 & -579124 & 765576 & -641452 & 332864 & -97852 \\\\\n5 & -193170 & 2139333 & -10554173 & 30562838 & -57563814 & 73721676 & -65048368 & 39063778 \\\\ \\hline\n\\end{array}\n\\nonumber\n\\end{equation}\n\\caption{BPS invariants $b_{r,i}$ for the $7_1$ knot.} \n\\label{aBPS-71-tab}\n\\end{small}\n\\end{table}\n\n\n\n\\subsection{BPS invariants from augmentation polynomials: $6_2$, $6_3$, $7_3$, $7_5$, $8_{19}$, $8_{20}$, $8_{21}$, $10_{124}$, $10_{132}$, and $10_{139}$ knots} \\label{ssec-aug}\n\nUsing the methods presented above we can easily compute BPS invariants for knots with known augmentation polynomials. Moreover, in many nontrivial cases we can confirm the conjecture that augmentation polynomials agree with Q-deformed polynomials (defined as the classical limit of recursion relations satisfied by colored HOMFLY polynomials) and $t=-1$ limit of super-A-polynomials. This conjecture has been explicitly verified for several torus and twist knots in \\cite{AVqdef,superA,FGSS}, where it was shown that appropriate change of variables relates the two algebraic curves. For example, starting with the super-A-polynomial for figure-8 knot (\\ref{Asuper41}), setting $t=-1$ and changing variables (note that it is not simply (\\ref{MLnorm})) \\cite{superA}\n\\begin{equation}\nQ = a,\\qquad \\beta = M, \\qquad \\alpha = L\\frac{1 - \\beta Q}{Q(1-\\beta)},\n\\end{equation}\nwe obtain (up to some irrelevant simple factor) the Q-deformed polynomial in the same form as in \\cite{AVqdef}\n\\begin{eqnarray}\nA^{\\textrm{Q-def}}(\\alpha,\\beta,Q) & = & (\\beta^2 - Q \\beta^3) + (2 \\beta - 2 Q^2 \\beta^4 + Q^2 \\beta^5 - 1) \\alpha + \\nonumber \\\\\n& & + (1 - 2 Q \\beta + 2 Q^2 \\beta^4 - Q^3 \\beta^5) \\alpha^2 + Q^2 (\\beta-1) \\beta^2 \\alpha^3 \\,, \\nonumber\n\\end{eqnarray}\nwhere it was shown to match the augmentation polynomial.\n\n\\begin{figure}[ht]\n\\begin{center}\n\\includegraphics[scale=0.25]{draws\/6_2.pdf}$\\qquad$\n\\includegraphics[scale=0.25]{draws\/6_3.pdf}$\\qquad$\n\\includegraphics[scale=0.25]{draws\/7_3.pdf}$\\qquad$\n\\includegraphics[scale=0.25]{draws\/7_5.pdf}\n\\end{center}\n\\caption{The $6_2$, $6_3$, $7_3$ and $7_5$ knots.}\n\\label{fig-6-7-knots}\n\\end{figure}\n\nNow we show that this conjecture can be verified for many non-trivial knots, even if an explicit form of Q-deformed polynomials or super-A-polynomial is not known. Let us consider the following knots: $6_2$, $6_3$, $7_3$, $7_5$, $8_{19}$, $8_{20}$, $8_{21}$, $10_{124}$, $10_{132}$, and $10_{139}$, for which augmentation polynomials are determined in \\cite{Ng,NgFramed}. Changing the variables into $M$ and $L$ relevant for A-polynomials, and further into $x$ and $y$ relevant for our considerations, and from appropriate rescalings (\\ref{Amin}) we obtain extremal A-polynomials. They are presented in table \\ref{Aminmax-aug}, and constitute one of our main results.\n\nFrom extremal polynomials in table \\ref{Aminmax-aug} we can determine the extremal BPS invariants $b^{\\pm}_r$ for arbitrary $r$; some results are presented in tables in appendix \\ref{app-bps}. We also experimentally confirm the Improved Integrality -- the constants $\\gamma^\\pm$ for some knots are shown in table \\ref{c-minmax-aug}. However, unfortunately, the corresponding functions $Y^\\pm(x)$ no longer satisfy the \nfortunate condition \\eqref{eq.fortunate}.\n\n\\begin{figure}[ht]\n\\centering\n\\includegraphics[scale=0.3]{draws\/8_19.pdf}$\\qquad$\n\\includegraphics[scale=0.3]{draws\/8_20.pdf}$\\qquad$\n\\includegraphics[scale=0.3]{draws\/8_21.pdf}\n\\caption{The $8_{19}$, $8_{20}$ and $8_{21}$ knots.}\n\\label{fig-8-knots}\n\\end{figure}\n\nEven though the Q-deformed or super-A-polynomials are not known for knots listed in table \\ref{Aminmax-aug}, colored HOMFLY polynomials for those knots for several values of $r$ have been explicitly determined in \\cite{Nawata:2013qpa,Wedrich:2014zua}. We can therefore determine the corresponding invariants $N_{r,i,j}$ using LMOV formulas (\\ref{f-P}) -- we list some of these invariants in tables in appendix \\ref{app-lmov}. On the other hand, from the known augmentation polynomials we can compute some BPS invariants $b_{r,i}$ using our techniques. In all cases we find the agreement between these two computations, as the reader can also verify by comparing tables in appendices \\ref{app-bps} and \\ref{app-lmov}. This is quite a nontrivial test of the (still conjectural) relation between augmentation polynomials and colored HOMFLY polynomials.\n\n\nFor example, consider the LMOV invariants $N_{r,i,j}$ of the $6_2$ knot for $r=1,2,3$, given in tables \\ref{62-N1ij}, \\ref{62-N2ij}, \\ref{62-N3ij}. We determined these invariants from the knowledge of HOMFLY polynomials, determined up to $r=4$ in \\cite{Nawata:2013qpa}, and applying formulas (\\ref{f-P}). To obtain $b^-_r$ and $b^+_r$ we need to resum, respectively, the first and the last row in those tables (corresponding to minimal and maximal power of $a$). For the minimal case (first rows in the tables) from the resummation we obtain the number $-1,-2,-10$, and for the maximal case (last rows in the tables) we find the numbers $2,2,7$. These results indeed agree with values of $b^\\pm_r$ for $6_2$ knot given in table \\ref{6-7-br-aug}, which are determined from its augmentation polynomial (more precisely, the corresponding extremal A-polynomials given in table \\ref{Aminmax-aug}). We verified such an agreement for other knots discussed in this section. \n\n\n\\begin{figure}[ht]\n\\centering\n\\includegraphics[scale=0.3]{draws\/10_124.pdf}$\\qquad$\n\\includegraphics[scale=0.3]{draws\/10_132.pdf}$\\qquad$\n\\includegraphics[scale=0.3]{draws\/10_139.pdf}\n\\caption{The $10_{124}$, $10_{132}$ and $10_{139}$ knots.}\n\\label{fig-10-knots}\n\\end{figure}\n\n\n\n\n\n\n\n\\subsection{Refined BPS invariants from super-A-polynomials}\n\nBeyond the $a$-dependence we can consider further deformation of A-polynomials, in parameter $t$, that leads to super-A-polynomials. It is natural to ask if super-A-polynomials encode refined BPS degeneracies $b_{r,i,j}$. Such degeneracies should be identified with generalized LMOV invariants, defined by relations (\\ref{Pr-LMOVref}), and could be determined from the knowledge of super-A-polynomials, using the relation (\\ref{xdyy-ref}). This conjecture would be confirmed if $b_{r,i,j}$ would turn out to be integer. In this section we extract such invariants from the known super-A-polynomials. To this end it is convenient to consider super-A-polynomials as $T$-deformation and $a$-deformation of bottom A-polynomials (that arise for $a=0$ and $T=1$), where $t=-T^2$. This results in slightly redefined degeneracies $\\tilde{b}_{r,i,j}$, which can be combined into the generating functions\n\\begin{equation}\n\\sum_{r,i,j} \\tilde{b}_{r,i,j} x^r a^i T^j.\n\\end{equation}\nWe present such generating functions in table \\ref{tab-refBPS}. Clearly all coefficients in these generating functions are integer, and therefore capture putative refined BPS degeneracies. We plan to analyze these refined BPS invariants for knots in more detail in future work. \n\n\n\\begin{table}\n\\begin{small}\n\\begin{equation}\n\\begin{array}{|c|l|}\n\\hline \n\\textrm{\\bf Knot} & \\qquad \\qquad\\qquad \\sum_{r,i,j} \\tilde{b}_{r,i,j} x^r a^i T^j \\nonumber \\\\\n\\hline \n\\hline\n{\\bf 4_1} & (-1 + a T - a T^2 + 2 a T^3 - 2 a^2 T^4 + a^2 T^5) x + (-1 + 2 a T + (-a - a^2) T^2 + (3 a + a^2) T^3 + \\\\\n & - 4 a^2 T^4 + (a^2 + a^3) T^5) x^2 + (-3 + 7 a T + (-3 a - 5 a^2) T^2 + (10 a + 5 a^2 + a^3) T^3 + \\\\\n & + (-21 a^2 - 2 a^3) T^4 + (6 a^2 + 13 a^3) T^5) x^3 + (-10 + 30 a T + (-12 a - 32 a^2) T^2 + \\\\\n & + (42 a + 28 a^2 + 14 a^3) T^3 + (-117 a^2 - 21 a^3 - 2 a^4) T^4 + (35 a^2 + 114 a^3 + 5 a^4) T^5) x^4 +\\\\\n & + (-40 + 143 a T + (-55 a - 198 a^2) T^2 + (198 a + 165 a^2 + 132 a^3) T^3 + \\\\\n & + (-690 a^2 - 180 a^3 - 42 a^4) T^4 + (210 a^2 + 912 a^3 + 84 a^4 + 5 a^5) T^5) x^5 +\\dots \\\\\n\\hline\n{\\bf 6_1} & (-1 + a T - 2 a T^2) x + (-1 + 2 a T + (-3 a - a^2) T^2) x^2 + (-3 + 7 a T + (-10 a - 5 a^2) T^2) x^3 +\\\\ \n & + (-10 + 30 a T + (-42 a - 32 a^2) T^2) x^4 + (-40 + 143 a T + (-198 a - 198 a^2) T^2) x^5 + \\dots \\\\\n\\hline\n{\\bf 5_2} & (-1 + T + (-1 - a) T^2 + 2 a T^3 - 2 a T^4 + (a + 2 a^2) T^5) x + (T^2 + (-1 - 2 a) T^3 + \\\\\n & + (1 + 5 a + a^2) T^4 + (-8 a - 4 a^2) T^5) x^2 + (T^3 + (-3 - 4 a) T^4 + (2 + 16 a + 4 a^2) T^5) x^3 + \\\\\n & + (2 T^4 + (-6 - 10 a) T^5) x^4 + 4 T^5 x^5 + \\dots \\\\\n\\hline\n{\\bf 3_1} & (-1 - T^2 + 2 a T^3 + a T^5) x + (T^2 - a T^3 + T^4 - 5 a T^5) x^2 +\\\\\n & + (-2 T^4 + 7 a T^5) x^3 + (T^4 - 3 a T^5) x^4 + \\dots \\\\\n\\hline\n{\\bf 5_1} & (-1 - T^2 + 2 a T^3 - T^4) x + (T^2 - a T^3 + 4 T^4) x^2 - 5 T^4 x^3 + 2 T^4 x^4 +\\dots \\\\\n\\hline \n\\end{array}\n\\end{equation} \n\\end{small}\n\\caption{Generating functions of refined degeneracies $\\tilde{b}_{r,i,j}$ for several knots. Integrality of coefficients confirms the refined version of the LMOV conjecture.} \\label{tab-refBPS}\n\\end{table}\n\n\n\n\n\\section{Conclusions and discussion} \\label{sec-conclude}\n\nThe results of this work deserve further studies that we plan to undertake. On one hand they should inspire mathematical research. We have formulated and tested various conjectures, in particular divisibility by $r^2$ following from the conjectured LMOV integrality, and Improved Integrality of extremal BPS degeneracies. These statements should hold for all knots and proving them is an important task (even proofs of divisibility by $r^2$ in various specific cases, in particular (\\ref{br-neg-intro}) and (\\ref{br-pos-intro}), are challenging); note that proofs of integrality of Gopakumar-Vafa in certain cases were given in \\cite{Kontsevich:2006an,Vologodsky:2007ef,Schwarz:2008ti}, and presumably these techniques could be generalized to the case of knots. We also associated new integer invariants $\\gamma^{\\pm}$, related to Improved Integrality, to all knots -- it is important to understand deeper their mathematical meaning and, possibly, relation to other characteristics of knots. Furthermore, for some knots we observed that the solutions of extremal A-polynomial equations are given by hypergeometric functions. It is important to understand for which knots such algebraic hypergeometric functions arise and if they have any further meaning. Understanding which knots have this property could lead to a new method to determine many other algebraic hypergeometric functions (associated to various knots). \n\nIt would also be interesting to understand our results from the perspective of knot homologies. Currently the most powerful method to determine -- at least conjecturally -- colored HOMFLY homologies is the formalism of (colored) differentials \\cite{DGR,GS}. These differentials reveal intricate structure not only of colored homologies, but also of ordinary HOMFLY invariants. Therefore they should capture some essential information about unrefined and refined BPS degeneracies that we consider. Note that the ``bottom row'' structure of HOMFLY homologies (i.e. corresponding to the minimal power of $a$) was analyzed e.g. in \\cite{Gorsky:2013jxa}; it would be interesting to relate it to BPS degeneracies determined here.\n\nOur results also raise further interesting questions on the physics side. First, in the introduction we already mentioned their intimate connection to 3d-3d duality, which relates knot invariants to 3-dimensional $\\mathcal{N}=2$ theories \\cite{DGG,superA,Chung:2014qpa}. Various objects in our analysis, such as colored knot polynomials, super-A-polynomials, etc., play an important role in this duality. Therefore all the new objects and statements that we consider should also find its interpretation on the $\\mathcal{N}=2$ side of this duality. \n\nSecond, the results such as Improved Integrality or formulation of refined BPS invariants for knots generalize the statements of the original LMOV conjectures \\cite{OoguriV,Labastida:2000zp,Labastida:2000yw}. It is desirable to understand in more detail M-theory interpretation of these results. In particular we obtain the BPS degeneracies in an analogous way as has been done for D-branes in \\cite{AV-discs,AKV-framing}. Furthermore, it has been conjectured in \\cite{OoguriV,AVqdef} that all knots should be mirror to Lagrangian branes in the conifold geometry, and for some knots such Lagrangian branes have been constructed \\cite{Diaconescu:2011xr,Jockers:2012pz}. It would be amusing to construct such Lagrangian branes for other knots that we consider, and compare the degeneracies they encode with our computations.\n\nThird, our results concern primarily the classical algebraic curves, i.e. the $q\\to 1$ limit of recursion relations for knot polynomials. It is desirable to introduce the dependence on the parameter $q$ and determine corresponding BPS degeneracies directly from the knowledge of those recursion relations. Our results can also be further generalized to higher-dimensional varieties generalizing algebraic curves, and correspondingly to links or knots labeled by more general (multi-row) representations.\n\nFourth, an important challenge is to understand refined open BPS states that we compute for several knots, based on the known super-A-polynomials. Recently various formulations of closed refined BPS states have been considered, see e.g. \\cite{Choi:2012jz,Huang:2013yta}. It would be nice to make contact between these various approaches involving open and closed BPS states.\n\nYet another intriguing direction of research relating algebraic curves and knot invariants has to do with the topological recursion. It has been conjectured in \\cite{DijkgraafFuji-1} and further analyzed in \\cite{DijkgraafFuji-2,Borot:2012cw,abmodel,BEM,Gu:2014yba} that the asymptotic expansion of colored Jones or HOMFLY polynomials can be reconstructed from the topological recursion for the A-polynomial curve. This conjecture have been tested in a very limited number of cases and it still seems poorly understood. The new algebraic curves that we consider in this paper, in particular extremal A-polynomials, should provide a simpler setup in which this conjecture can be analyzed. \n\n\n\n\n\\acknowledgments{We thank Estelle Basor, Brian Conrey, Sergei Gukov, Maxim Kontsevich, Satoshi Nawata, and Marko Sto$\\check{\\text{s}}$i$\\acute{\\text{c}}$ for insightful discussions. We greatly appreciate hospitality of American Institute of Mathematics, Banff International Research Station, International Institute of Physics in Natal, and Simons Center for Geometry and Physics, where parts of this work were done. This work is supported by the ERC Starting Grant no. 335739 \\emph{``Quantum fields and knot homologies''} funded by the European Research Council under the European Union's Seventh Framework Programme, and the Foundation for Polish Science.}\n\n\n\n\n\n\\newpage\n\n","meta":{"redpajama_set_name":"RedPajamaArXiv"}}