25,844 research outputs found
A General Purpose Algorithm for Counting Simple Cycles and Simple Paths of Any Length
International audienceWe describe a general purpose algorithm for counting simple cycles and simple paths of any length on a (weighted di)graph on N vertices and M edges, achieving a time complexity of O N + M + ω + ∆ |S |. In this expression, |S | is the number of (weakly) connected induced subgraphs of G on at most vertices, ∆ is the maximum degree of any vertex and ω is the exponent of matrix multiplication. We compare the algorithm complexity both theoretically and experimentally with most of the existing algorithms for the same task. These comparisons show that the algorithm described here is the best general purpose algorithm for the class of graphs where (ω−1 ∆ −1 +1)|S | ≤ |Cycle |, with |Cycle | the total number of simple cycles of length at most , including backtracks and self-loops. On Erdős-Rényi random graphs, we find empirically that this happens when the edge probability is larger than circa 4/N. In addition, we show that some real-world networks also belong to this class. Finally, the algorithm permits the enumeration of simple cycles and simple paths on networks where vertices are labeled from an alphabet on n letters with a time complexity of O N + M + n ω + ∆ |S |. A Matlab implementation of the algorithm proposed here is available for download
Balanced Families of Perfect Hash Functions and Their Applications
The construction of perfect hash functions is a well-studied topic. In this
paper, this concept is generalized with the following definition. We say that a
family of functions from to is a -balanced -family
of perfect hash functions if for every , , the number
of functions that are 1-1 on is between and for some
constant . The standard definition of a family of perfect hash functions
requires that there will be at least one function that is 1-1 on , for each
of size . In the new notion of balanced families, we require the number
of 1-1 functions to be almost the same (taking to be close to 1) for
every such . Our main result is that for any constant , a
-balanced -family of perfect hash functions of size can be constructed in time .
Using the technique of color-coding we can apply our explicit constructions to
devise approximation algorithms for various counting problems in graphs. In
particular, we exhibit a deterministic polynomial time algorithm for
approximating both the number of simple paths of length and the number of
simple cycles of size for any
in a graph with vertices. The approximation is up to any fixed desirable
relative error
Approximately Counting Embeddings into Random Graphs
Let H be a graph, and let C_H(G) be the number of (subgraph isomorphic)
copies of H contained in a graph G. We investigate the fundamental problem of
estimating C_H(G). Previous results cover only a few specific instances of this
general problem, for example, the case when H has degree at most one
(monomer-dimer problem). In this paper, we present the first general subcase of
the subgraph isomorphism counting problem which is almost always efficiently
approximable. The results rely on a new graph decomposition technique.
Informally, the decomposition is a labeling of the vertices such that every
edge is between vertices with different labels and for every vertex all
neighbors with a higher label have identical labels. The labeling implicitly
generates a sequence of bipartite graphs which permits us to break the problem
of counting embeddings of large subgraphs into that of counting embeddings of
small subgraphs. Using this method, we present a simple randomized algorithm
for the counting problem. For all decomposable graphs H and all graphs G, the
algorithm is an unbiased estimator. Furthermore, for all graphs H having a
decomposition where each of the bipartite graphs generated is small and almost
all graphs G, the algorithm is a fully polynomial randomized approximation
scheme.
We show that the graph classes of H for which we obtain a fully polynomial
randomized approximation scheme for almost all G includes graphs of degree at
most two, bounded-degree forests, bounded-length grid graphs, subdivision of
bounded-degree graphs, and major subclasses of outerplanar graphs,
series-parallel graphs and planar graphs, whereas unbounded-length grid graphs
are excluded.Comment: Earlier version appeared in Random 2008. Fixed an typo in Definition
3.
Flat Foldings of Plane Graphs with Prescribed Angles and Edge Lengths
When can a plane graph with prescribed edge lengths and prescribed angles
(from among \}) be folded flat to lie in an
infinitesimally thin line, without crossings? This problem generalizes the
classic theory of single-vertex flat origami with prescribed mountain-valley
assignment, which corresponds to the case of a cycle graph. We characterize
such flat-foldable plane graphs by two obviously necessary but also sufficient
conditions, proving a conjecture made in 2001: the angles at each vertex should
sum to , and every face of the graph must itself be flat foldable.
This characterization leads to a linear-time algorithm for testing flat
foldability of plane graphs with prescribed edge lengths and angles, and a
polynomial-time algorithm for counting the number of distinct folded states.Comment: 21 pages, 10 figure
Matching Is as Easy as the Decision Problem, in the NC Model
Is matching in NC, i.e., is there a deterministic fast parallel algorithm for
it? This has been an outstanding open question in TCS for over three decades,
ever since the discovery of randomized NC matching algorithms [KUW85, MVV87].
Over the last five years, the theoretical computer science community has
launched a relentless attack on this question, leading to the discovery of
several powerful ideas. We give what appears to be the culmination of this line
of work: An NC algorithm for finding a minimum-weight perfect matching in a
general graph with polynomially bounded edge weights, provided it is given an
oracle for the decision problem. Consequently, for settling the main open
problem, it suffices to obtain an NC algorithm for the decision problem. We
believe this new fact has qualitatively changed the nature of this open
problem.
All known efficient matching algorithms for general graphs follow one of two
approaches: given by Edmonds [Edm65] and Lov\'asz [Lov79]. Our oracle-based
algorithm follows a new approach and uses many of the ideas discovered in the
last five years.
The difficulty of obtaining an NC perfect matching algorithm led researchers
to study matching vis-a-vis clever relaxations of the class NC. In this vein,
recently Goldwasser and Grossman [GG15] gave a pseudo-deterministic RNC
algorithm for finding a perfect matching in a bipartite graph, i.e., an RNC
algorithm with the additional requirement that on the same graph, it should
return the same (i.e., unique) perfect matching for almost all choices of
random bits. A corollary of our reduction is an analogous algorithm for general
graphs.Comment: Appeared in ITCS 202
- …