We give a fast algorithm for sampling uniform solutions of general constraint satisfaction problems (CSPs) in a local lemma regime. Suppose that the CSP has $n$ variables with domain size at most q, each constraint contains at most k variables, shares variables with at most $\Delta$ constraints, and is violated with probability at most $p$ by a uniform random assignment. The algorithm returns an almost uniform satisfying assignment in expected $\mathrm{poly}(q,k,\Delta)\cdot\tilde{O}(n)$ time, as long as a local lemma condition is satisfied: \[ k\cdot p\cdot q^2\cdot \Delta^5\le C_0\quad\text{for a suitably small absolute constant }C_0. \] Previously, under similar local lemma conditions, sampling algorithms with running time polynomial in both $n$ and $\Delta$ were only known for the almost atomic case, where each constraint is violated by a small number of forbidden local configurations. The key term $\Delta^5$ in our local lemma condition also improves the previously best known $\Delta^7$ for general CSPs [JPV21b] and $\Delta^{5.714}$ for atomic CSPs, including the special case of $k$-CNF [JPV21a, HSW21]. Our sampling approach departs from previous fast algorithms for sampling LLL, which were based on Markov chains. A crucial step of our algorithm is a recursive marginal sampler that is of independent interests. Within a local lemma regime, this marginal sampler can draw a random value for a variable according to its marginal distribution, at a cost independent of the size of the CSP.
翻译:我们提出了一种快速算法,用于在局部引理条件下对一般约束满足问题(CSPs)的均匀解进行采样。假设CSP包含n个变量,每个变量域大小至多为q,每个约束最多包含k个变量,且与最多Δ个约束共享变量,同时均匀随机赋值违反每个约束的概率至多为p。该算法能够在期望的$\mathrm{poly}(q,k,\Delta)\cdot\tilde{O}(n)$时间内返回几乎均匀的满足赋值,前提是满足以下局部引理条件:
\[ k\cdot p\cdot q^2\cdot \Delta^5\le C_0\quad\text{对于适当小的绝对常数 }C_0. \]
此前,在类似局部引理条件下,仅对于几乎原子情形(即每个约束仅由少量禁止局部配置所违反)存在运行时间为n和Δ多项式的采样算法。我们局部引理条件中的关键项$\Delta^5$也改进了此前一般CSP的最优结果$\Delta^7$ [JPV21b] 以及原子CSP(包括k-CNF特例 [JPV21a, HSW21])的$\Delta^{5.714}$。我们的采样方法不同于以往基于马尔可夫链的快速LLL采样算法。算法中的一个关键步骤是递归边际采样器,该采样器具有独立的研究价值。在局部引理条件下,该边际采样器能够以与CSP规模无关的代价,根据变量的边际分布为其抽取随机值。