-
Random Generation of Git Graphs
Authors:
Julien Courtiel,
Martin Pépin
Abstract:
Version Control Systems, such as Git and Mercurial, manage the history of a project as a Directed Acyclic Graph encoding the various divergences and synchronizations happening in its life cycle. A popular workflow in the industry, called the feature branch workflow, constrains these graphs to be of a particular shape: a unique main branch, and non-interfering feature branches. Here we focus on the…
▽ More
Version Control Systems, such as Git and Mercurial, manage the history of a project as a Directed Acyclic Graph encoding the various divergences and synchronizations happening in its life cycle. A popular workflow in the industry, called the feature branch workflow, constrains these graphs to be of a particular shape: a unique main branch, and non-interfering feature branches. Here we focus on the uniform random generation of those graphs with n vertices, including k on the main branch, for which we provide three algorithms, for three different use-cases. The first, based on rejection, is efficient when aiming for small values of k (more precisely whenever k = O($\sqrt$ n)). The second takes as input any number k of commits in the main branch, but requires costly precalculation. The last one is a Boltzmann generator and enables us to generate very large graphs while targeting a constant k/n ratio. All these algorithms are linear in the size of their outputs.
△ Less
Submitted 25 June, 2024; v1 submitted 4 March, 2024;
originally announced March 2024.
-
Theoretical analysis of git bisect
Authors:
Paul Dorbec,
Julien Courtiel,
Romain Lecoq
Abstract:
In this paper, we consider the problem of finding a regression in a version control system (VCS), such as \texttt{git}. The set of versions is modelled by a Directed Acyclic Graph (DAG) where vertices represent versions of the software, and arcs are the changes between different versions. We assume that somewhere in the DAG, a bug was introduced, which persists in all of its subsequent versions. I…
▽ More
In this paper, we consider the problem of finding a regression in a version control system (VCS), such as \texttt{git}. The set of versions is modelled by a Directed Acyclic Graph (DAG) where vertices represent versions of the software, and arcs are the changes between different versions. We assume that somewhere in the DAG, a bug was introduced, which persists in all of its subsequent versions. It is possible to query a vertex to check whether the corresponding version carries the bug. Given a DAG and a bugged vertex, the Regression Search Problem consists in finding the first vertex containing the bug in a minimum number of queries in the worst-case scenario. This problem is known to be NP-complete. We study the algorithm used in \texttt{git} to address this problem, known as \texttt{git bisect}. We prove that in a general setting, \texttt{git bisect} can use an exponentially larger number of queries than an optimal algorithm. We also consider the restriction where all vertices have indegree at most 2 (i.e. where merges are made between at most two branches at a time in the VCS), and prove that in this case, \texttt{git bisect} is a $\frac{1}{\log_2(3/2)}$-approximation algorithm, and that this bound is tight. We also provide a better approximation algorithm for this case. Finally, we give an alternative proof of the NP-completeness of the Regression Search Problem, via a variation with bounded indegree.
△ Less
Submitted 21 December, 2023;
originally announced December 2023.
-
Orientable Burning Number of Graphs
Authors:
Julien Courtiel,
Paul Dorbec,
Tatsuya Gima,
Romain Lecoq,
Yota Otachi
Abstract:
In this paper, we introduce the problem of finding an orientation of a given undirected graph that maximizes the burning number of the resulting directed graph. We show that the problem is polynomial-time solvable on Kőnig-Egerváry graphs (and thus on bipartite graphs) and that an almost optimal solution can be computed in polynomial time for perfect graphs. On the other hand, we show that the pro…
▽ More
In this paper, we introduce the problem of finding an orientation of a given undirected graph that maximizes the burning number of the resulting directed graph. We show that the problem is polynomial-time solvable on Kőnig-Egerváry graphs (and thus on bipartite graphs) and that an almost optimal solution can be computed in polynomial time for perfect graphs. On the other hand, we show that the problem is NP-hard in general and W[1]-hard parameterized by the target burning number. The hardness results are complemented by several fixed-parameter tractable results parameterized by structural parameters. Our main result in this direction shows that the problem is fixed-parameter tractable parameterized by cluster vertex deletion number plus clique number (and thus also by vertex cover number).
△ Less
Submitted 21 November, 2023;
originally announced November 2023.
-
Bijections for Weyl Chamber walks ending on an axis, using arc diagrams and Schnyder woods
Authors:
Julien Courtiel,
Éric Fusy,
Mathias Lepoutre,
Marni Mishna
Abstract:
In the study of lattice walks there are several examples of enumerative equivalences which amount to a trade-off between domain and endpoint constraints. We present a family of such bijections for simple walks in Weyl chambers which use arc diagrams in a natural way. One consequence is a set of new bijections for standard Young tableaux of bounded height. A modification of the argument in two dime…
▽ More
In the study of lattice walks there are several examples of enumerative equivalences which amount to a trade-off between domain and endpoint constraints. We present a family of such bijections for simple walks in Weyl chambers which use arc diagrams in a natural way. One consequence is a set of new bijections for standard Young tableaux of bounded height. A modification of the argument in two dimensions yields a bijection between Baxter permutations and walks ending on an axis, answering a recent question of Burrill et al. (2016). Some of our arguments (and related results) are proved using Schnyder woods. Our strategy for simple walks extends to any dimension and yields a new bijective connection between standard Young tableaux of height at most $2k$ and certain walks with prescribed endpoints in the $k$-dimensional Weyl chamber of type D.
△ Less
Submitted 17 November, 2017; v1 submitted 14 November, 2016;
originally announced November 2016.
-
Counting, generating and sampling tree alignments
Authors:
Cedric Chauve,
Julien Courtiel,
Yann Ponty
Abstract:
Pairwise ordered tree alignment are combinatorial objects that appear in RNA secondary structure comparison. However, the usual representation of tree alignments as supertrees is ambiguous, i.e. two distinct supertrees may induce identical sets of matches between identical pairs of trees. This ambiguity is uninformative, and detrimental to any probabilistic analysis.In this work, we consider tree…
▽ More
Pairwise ordered tree alignment are combinatorial objects that appear in RNA secondary structure comparison. However, the usual representation of tree alignments as supertrees is ambiguous, i.e. two distinct supertrees may induce identical sets of matches between identical pairs of trees. This ambiguity is uninformative, and detrimental to any probabilistic analysis.In this work, we consider tree alignments up to equivalence. Our first result is a precise asymptotic enumeration of tree alignments, obtained from a context-free grammar by mean of basic analytic combinatorics. Our second result focuses on alignments between two given ordered trees $S$ and $T$. By refining our grammar to align specific trees, we obtain a decomposition scheme for the space of alignments, and use it to design an efficient dynamic programming algorithm for sampling alignments under the Gibbs-Boltzmann probability distribution. This generalizes existing tree alignment algorithms, and opens the door for a probabilistic analysis of the space of suboptimal RNA secondary structures alignments.
△ Less
Submitted 7 March, 2016; v1 submitted 22 May, 2015;
originally announced May 2015.