The crossing number of a graph $G$, $\mathrm{cr}(G)$, is the minimum number of edge crossings arising when drawing a graph on a certain surface. Determining $\mathrm{cr}(G)$ is a problem of great importance in Graph Theory. Its maximum variant, i.e. the maximum crossing number, $\mathrm{max-cr}(G)$, is receiving growing attention. Instead of an optimization problem on the number of crossings, here we consider the variance of the number of edge crossings, when embedding the vertices of an arbitrary graph uniformly at random in some space. In his pioneering research, Moon derived this variance on random linear arrangements of complete unipartite and bipartite graphs. Given the need of efficient algorithms to support this sort of research and given also the growing interest of the number of edge crossings in spatial networks, networks where vertices are embedded in some space, here we derive an algorithm to calculate the variance in arbitrary graphs in time $o(nm^2)$ that we transform into one that runs in time $O(nm)$ by reusing computations. We also derive one for forests that runs in time $O(n)$. These algorithms work on a wide range of random layouts (not only on Moon's) and are based on novel arithmetic expressions for the calculation of the variance that we develop from previous theoretical work. This paves the way for many applications that rely on a fast but exact calculation of the variance.
翻译:暂无翻译