arXiv++ Combinatorics

Browse math.CO papers from arXiv

Papers by Kai Wang

6 paper(s) by this author · All BibTeX
2026-01-22
An Efficient Algorithm to Generate all Labeled Triangle-free Graphs with a given Graphical Degree Sequence
We extend our previous algorithm that generates all labeled graphs with a given graphical degree sequence to generate all labeled triangle-free graphs with a given graphical degree sequence. The algorithm uses various pruning techniques to avoid having to first generate all labeled realizations of the input sequence and then testing whether each labeled realization is triangle-free. It can be further extended to generate all labeled bipartite graphs with a given graphical degree sequence by adding a simple test whether each generated triangle-free realization is a bipartite graph. All output graphs are generated in the lexicographical ordering as in the original algorithm. The algorithms can also be easily parallelized.
2019-08-19
An Efficient Algorithm to Test Potentially Bipartiteness of Graphical Degree Sequences
Published • View PublicationBIB
As a partial answer to a question of Rao, a deterministic and customizable efficient algorithm is presented to test whether an arbitrary graphical degree sequence has a bipartite realization. The algorithm can be configured to run in polynomial time, at the expense of possibly producing an erroneous output on some "yes" instances but with very low error rate.
2018-06-26
An Improved Algorithm for Counting Graphical Degree Sequences
Published • View PublicationBIB
We present an improved version of a previous efficient algorithm that computes the number $D(n)$ of zero-free graphical degree sequences of length $n$. A main ingredient of the improvement lies in a more efficient way to compute the function $P(N,k,l,s)$ of Barnes and Savage. We further show that the algorithm can be easily adapted to compute the $D(i)$ values for all $i\le n$ in a single run. Theoretical analysis shows that the new algorithm to compute all $D(i)$ values for $i\le n$ is a constant times faster than the previous algorithm to compute a single $D(n)$. Experimental evaluations show that the constant of improvement is about 10. We also perform simulations to estimate the asymptotic order of $D(n)$ by generating uniform random samples from the set of $E(n)$ integer partitions of fixed length $n$ with even sum and largest part less than $n$ and computing the proportion of them that are graphical degree sequences. The known numerical results of $D(n)$ for $n\le 290$ together with the known bounds of $D(n)$ and simulation results allow us to make an informed guess about its unknown asymptotic order. The techniques for the improved algorithm can be applied to compute other similar functions that count the number of graphical degree sequences of various classes of graphs of order $n$ and that all involve the function $P(N,k,l,s)$.
2018-05-03
An efficient algorithm to test forcibly-biconnectedness of graphical degree sequences
We present an algorithm to test whether a given graphical degree sequence is forcibly biconnected or not and prove its correctness. The worst case run time complexity of the algorithm is shown to be exponential but still much better than the previous basic algorithm presented in \cite{Wang2018}. We show through experimental evaluations that the algorithm is efficient on average. We also adapt Ruskey et al's classic algorithm to enumerate zero-free graphical degree sequences of length $n$ and Barnes and Savage's classic algorithm to enumerate graphical partitions of an even integer $n$ by incorporating our testing algorithm into theirs and then obtain some enumerative results about forcibly biconnected graphical degree sequences of given length $n$ and forcibly biconnected graphical partitions of given even integer $n$. Based on these enumerative results we make some conjectures such as: when $n$ is large, (1) the proportion of forcibly biconnected graphical degree sequences of length $n$ among all zero-free graphical degree sequences of length $n$ is asymptotically a constant between 0 and 1; (2) the proportion of forcibly biconnected graphical partitions of even $n$ among all forcibly connected graphical partitions of $n$ is asymptotically 0.
2018-03-02
An efficient algorithm to test forcibly-connectedness of graphical degree sequences
Published • View PublicationBIB
We present an algorithm to test whether a given graphical degree sequence is forcibly connected or not and prove its correctness. We also outline the extensions of the algorithm to test whether a given graphical degree sequence is forcibly $k$-connected or not for every fixed $k\ge 2$. We show through experimental evaluations that the algorithm is efficient on average, though its worst case run time is probably exponential. We also adapt Ruskey et al's classic algorithm to enumerate zero-free graphical degree sequences of length $n$ and Barnes and Savage's classic algorithm to enumerate graphical partitions of even integer $n$ by incorporating our testing algorithm into theirs and then obtain some enumerative results about forcibly connected graphical degree sequences of given length $n$ and forcibly connected graphical partitions of given even integer $n$. Based on these enumerative results we make some conjectures such as: when $n$ is large, (1) almost all zero-free graphical degree sequences of length $n$ are forcibly connected; (2) almost none of the graphical partitions of even $n$ are forcibly connected.
2016-04-14 v3
Efficient Counting of Degree Sequences
Published • View PublicationBIB
Novel dynamic programming algorithms to count the set $D(n)$ of zero-free degree sequences of length $n$, the set $D_c(n)$ of degree sequences of connected graphs on $n$ vertices and the set $D_b(n)$ of degree sequences of biconnected graphs on $n$ vertices exactly are presented. They are all based on a recurrence of Barnes and Savage and shown to run in polynomial time and are asymptotically much faster than the previous best known algorithms for these problems. These appear to be the first polynomial time algorithms to compute $|D(n)|$, $|D_c(n)|$ and $|D_b(n)|$ to the author's knowledge and have enabled us to tabulate them up to $n=118$, the majority of which were unknown. The available numerical results of $|D(n)|$ tend to give more supporting evidence of a conjecture of Gordon F. Royle about the limit of $|D(n)|/|D(n-1)|$. The OEIS entries that can be computed by algorithms in this paper are A004251, A007721, A007722 and A095268.