Counting homomorphisms of a constant sized pattern graph $H$ in an input graph $G$ is a fundamental computational problem. There is a rich history of studying the complexity of this problem, under various constraints on the input $G$ and the pattern $H$. Given the significance of this problem and the large sizes of modern inputs, we investigate when near-linear time algorithms are possible. We focus on the case when the input graph has bounded degeneracy, a commonly studied and practically relevant class for homomorphism counting. It is known from previous work that for certain classes of $H$, $H$-homomorphisms can be counted exactly in near-linear time in bounded degeneracy graphs. Can we precisely characterize the patterns $H$ for which near-linear time algorithms are possible? We completely resolve this problem, discovering a clean dichotomy using fine-grained complexity. Let $m$ denote the number of edges in $G$. We prove the following: if the largest induced cycle in $H$ has length at most $5$, then there is an $O(m\log m)$ algorithm for counting $H$-homomorphisms in bounded degeneracy graphs. If the largest induced cycle in $H$ has length at least $6$, then (assuming standard fine-grained complexity conjectures) there is a constant $\gamma > 0$, such that there is no $o(m^{1+\gamma})$ time algorithm for counting $H$-homomorphisms.
翻译:在输入图形中计算一个不变大小的图案的同质性($H$)是一个根本性的计算问题。在投入$G$和模式$H$的各种限制下,有丰富的历史研究这一问题的复杂性。鉴于这一问题的重要性和现代投入的庞大规模,我们研究近线时间算法的可能性。当输入图中含有变异性时,我们集中关注这个案例,这是一个通常研究的同质性计算的实际等级。我们从以往工作中知道,对于某些类别($H$,$H$)的变异性可以完全以近线性时间($G$)来计算。鉴于这一问题的重要性以及近线性时间算法的庞大规模,我们能否精确地描述出近线性时间算法的美元模式?我们用精细的复杂度来彻底地解决这个问题,让我们发现一个干净的对等值。让我们用美元表示精度的差值值。我们证明:如果以美元计算的最大引导周期($$$$$$$$)的精度周期,那么以美元计的正值($_H_美元)的正数是最大的周期的。