DeepAI

# Nearly Optimal Time Bounds for kPath in Hypergraphs

In the kPath problem the input is a graph G and an integer k, and the goal is to decide whether G contains a simple path of length k. The fastest algorithm known for the directed version of this problem runs in time 2^kpoly(n) [Williams, IPL, 2009] and for the undirected version in time 1.66^kpoly(n) [Björklund et al., JCSS, 2014], while the only known lower bound for these problems is 2^Ω(k)poly(n) assuming the Exponential Time Hypothesis (ETH), and finding any conditional lower bound with explicit constant in the exponent has been an important open problem. Motivated by this challenge, we study the kHyperPath problem which is a generalization of kPath to finding tight paths in r-uniform hypergraphs on n nodes and m hyperedges, namely, a sequence of k nodes such that for every r consecutive nodes in the sequence there is an edge in the graph containing them. This problem was investigated in its cycle variant for large values of the uniformity parameter r∈ [ω(k),k) [Lincoln et al., SODA 2018], where a conditional lower bound of Õ(n^k) was presented. Considering smaller values of r, for every integer r≥ 3 we show an algorithm with running time (2+ε)^k m^O(r r/ε) for kHyperPath even for the directed version of this problem, which additionally has a permutation for each edge, and requires the path to comply with those permutations. This running time is nearly optimal as a (2-γ)^kpoly(m)-time algorithm with γ independent of r is probably impossible by our main result, as follows. We present a hierarchy of conditional lower bounds assuming the Set Cover Conjecture, where for even undirected kHyperPath with explicit constants in the exponents, where for growing values of r the problem requires time that approaches 2^kpoly(m).

11/02/2018

### On subexponential running times for approximating directed Steiner tree and related problems

This paper concerns proving almost tight (super-polynomial) running time...
04/07/2018

### Tight Lower Bounds for List Edge Coloring

The fastest algorithms for edge coloring run in time 2^m n^O(1), where m...
06/04/2021

### A Nearly Optimal All-Pairs Min-Cuts Algorithm in Simple Graphs

We give an n^2+o(1)-time algorithm for finding s-t min-cuts for all pair...
05/05/2020

### Many visits TSP revisited

We study the Many Visits TSP problem, where given a number k(v) for each...
08/12/2020

### Tight Bounds on Subexponential Time Approximation of Set Cover and Related Problems

We show that Set Cover on instances with N elements cannot be approximat...
07/25/2022

### On Confidence Sequences for Bounded Random Processes via Universal Gambling Strategies

This paper considers the problem of constructing a confidence sequence f...
02/04/2020

### A Double Exponential Lower Bound for the Distinct Vectors Problem

In the (binary) Distinct Vectors problem we are given a binary matrix A ...

## 1 Introduction

In the -Path problem, given a graph and an integer , the goal is to decide whether contains a simple path of length

. This is a fundamental combinatorial optimization problem, and contains the

Hamiltonian Path as a special case. The fastest algorithm known for directed graphs runs in time [Wil09] and for the undirected version the fastest algorithm runs in time [BHPK17]. The only known lower bound for these problems is assuming the Exponential Time Hypothesis (by a simple reduction from Hamiltonian Path), and finding any conditional lower bound with explicit constant in the exponent is an important open problem.

Motivated by this challenge, we study the -HyperPath problem, which is a natural generalization of -Path. Given an -uniform hypergraph , the goal is to find a tight path in of length . That is, a sequence of nodes such that every consecutive nodes constitute an edge in the graph. The cycle variant of problem was previously studied by Lincoln et al.  [LWW18] for large values of the uniformity parameter , where a conditional lower bound of was presented. Considering smaller values of , we show that for every there is some integer such that solving -HyperPath in time on -uniform hypergraphs is most likely impossible. Formally, we present a hierarchy of conditional lower bounds for -HyperPath in undirected hypergraphs with explicit constants in the exponents, where these lower bounds approach as increases.

We complement our conditional lower bounds with almost matching upper bounds. That is, for every integer we show an algorithm with running time for -HyperPath on -uniform hypergraphs with nodes and edges even for the directed version of this problem, where every hyperedge is a sequence of nodes, and tight paths respect the ordering of the corresponding edges.

### 1.1 Our Results

Our main result shows that -HyperPath cannot be solved faster than by an exponential factor independent of the size of a hyperedge unless Set Cover on elements can be solved significantly faster than . The latter statement is known as the Set Cover conjecture, introduced by Cygan et al.  [CDL16]. Formally, we show the following.

###### Theorem 1.

Let and let be an integer. If -HyperPath in undirected -uniform hypergraphs can be solved in time , then there exists , such that Set Cover on elements can be solved in time .

We prove Theorem 1 by showing a reduction from Set Cover to -HyperPath. The reduction consists of two main parts. We first show that Set Cover can be reduced to Exact Cover, thus implying that Exact Cover is "at least as hard" as Set Cover.

###### Lemma 2.

Let . If Exact Cover on elements can be solved in time , then there exists a constant such that Set Cover on elements can be solved in time .

To the best of our knowledge, this "Set Cover hardness" of Exact Cover was not known before. As Exact Cover seems to be a more robust source of reductions than its optimization variant Set Partitioning, due to lack of budget constraints, this result may be of independent interest.

Secondly, we show that Exact Cover can be reduced to -HyperPath. Combining these two reduction constitutes the proof of Theorem 1.

###### Lemma 3.

Let and let be an integer. If -HyperPath in undirected -uniform hypergraphs can be solved in time , then there exists a constant , such that Exact Cover on can be solved in time .

Lemma 3 as well as its proof demonstrate that Exact Cover may be the right problem to associate with -Path, given the connection it shows between its generalization -HyperPath and Exact Cover. We note that by simple modifications to our proofs, all of our results can also be applied for the problem of finding cycles rather than paths with some small (polynomial in the input size) overhead. In addition, our conditional lower bounds for the undirected case imply the same bounds for the directed one by the following simple reduction. Given an -uniform undirected hypergraph , construct an -uniform directed hypergraph by including for every edge all possible orientations of . Clearly there is a -path in if and only if there is one in . Moreover, the size of is at most times the size of .

We accompany our lower bound by an almost tight upper bound showing that even directed -HyperPath is not too difficult a generalization of -Path. While directed -Path can be solved in time , it seems that there is no trivial way to extend this algorithm to -HyperPath. Our second result shows such an extension. That is, for every fixed integer , directed -uniform -HyperPath admits an algorithm with running time .

###### Theorem 4.

For every integer , directed -uniform -HyperPath (respectively kHyperCycle) can be solved in time for some universal constant (respectively ), where and are the number of nodes and hyperedges respectively.

Our results show that while -HyperPath can essentially be solved as fast as -Path, we know that for the former it is nearly tight, assuming the hardness of Set Cover.

Note that once again by the previously described reduction our algorithm could be applied to the easier undirected case with the same running time (for ). Our algorithm is achieved through a reduction to the -Multilinear Monomial Detection problem (-MLD), where the goal is to detect multilinear monomials of degree in a polynomial presented as a circuit. This problem has been utilized to solve -Path [Kou08, Wil09], and our method can be seen as an extension to -HyperPath. Our method uses as a black box an algorithm for -MLD with running time by Williams [Wil09], where is the size of the circuit.

### 1.2 Previous Work

-Path can be solved naively in time , however a long line of work devoted effort to find faster algorithms, starting with -time algorithms, specifically  [Mon85] and  [Bod93], followed by a series of improvements [KMRR06, CLSZ07] with the color coding method [AYZ95] being a notable one. Finally, the fastest methods that were developed [Kou08, Wil09] utilize -MLD to create -Path algorithms with running times and respectively.

On the hardness front, it is well known that -Path requires time assuming ETH, as Hamiltonian path is a special case of this problem and there is a reduction from -SAT to Hamiltonian Path with the number of nodes in the produced instance linear in the formula size. If we care about the exact exponent in the running time, only a restricted lower bound is known. Koutis and Williams [KW16] used communication complexity to show that a faster algorithm for their intermediate problem -MLD in some settings is not possible, and so among a specific class of algorithms, their algorithms for -Path and -Tree, a generalization of -Path whose goal is finding an isomorphic copy of a given tree of size in a given graph, is optimal. Krauthgamer and Trabelsi [KT17] show that -Tree also requires time assuming Set Cover requires time. In the other direction, they show that if Set Cover on sets of size bounded by can be solved in time significantly faster than , then also -Tree can be solved in time significantly faster than , where -Tree is -Tree but with a pattern tree that has number of nodes equals (thus -Tree generalizes Hamiltonian Path).

#### The Set Cover Conjecture.

The set-cover conjecture formally states that for every fixed there is an integer such that Set Cover with sets of size at most cannot be solved in time . The conjecture clearly implies that for every fixed , Set Cover cannot be solved in time . In spite of extensive effort, the fastest algorithm for Set Cover is still essentially a dynamic programming algorithm that runs in time  [FKW04], with several improvements in special cases [Koi09, BHK09, Ned16, BHPK17]. Several conditional lower bounds were based on this conjecture in the recent decade, including for Set Partitioning, Connected Vertex Cover, Steiner Tree, Subset Sum [CDL16] (though the last problem was later shown hard conditioned on the strong exponential time hypothesis [ABHS19]), Maximum Graph Motif [BKK16], parity of the number of solutions to Set Cover with at most sets [BHH15], Colorful Path and Colorful Cycle [KL16], the dynamic, general and connected versions of Dominating Set [KST17], and -Tree [KT17].

## 2 Preliminaries

#### Paths in Hypergraphs.

As there are several ways to generalize simple paths from ordinary graphs to hypergraphs we define it as follows, extending known definitions from the Hamiltonicity context. Let be an -uniform hypergraph. For every and such that divides , an -overlapping -path is a sequence of distinct nodes and hyperedges such that each hyperedge consists of consecutive nodes, and every pair of consecutive edges satisfies . In the case where , such paths are called tight paths, and throughout we will focus on such paths. This natural generalization of paths to hypergraphs has been extensively studied in the area of Hamiltonian paths and cycles, either in the context of algorithms (e.g., [FKL11, GM16]) or combinatorics (e.g., [DFRS17, HZ15]). In particular, Lincoln et al.  [LWW18] show that finding a tight cycle of size in -uniform hypergraphs for cannot be solved significantly faster than unless MAX--SAT can be solved significantly faster than , and also -uniform -HyperClique can be solved significantly faster than .

#### Set Cover, Exact Cover and Set Partitioning.

For sake of completeness of the text, and to avoid confusion, we give a formal definition for each of the three set covering problems discussed in this paper. The input for all three problems is the same. We are given a ground set and a family of subsets of . A sub-cover of from is a subfamily whose union is . In the Set Cover problem the goal is to find a sub-cover of minimal size. The Exact Cover problem is a decision problem that seeks to find whether there exists some sub-cover composed of pairwise disjoint subsets of , also called a partition. Finally, the Set Partitioning problem is the optimization variant of Exact Cover. That is, the goal is to find a partition of minimal size.

## 3 A Conditional Lower Bound for k-HyperPath

This section is devoted to proving Theorem 1 by presenting a reduction from Set Cover to -HyperPath. The reduction is presented in two steps. The first step, in which we prove Lemma 2, reduces Set Cover to Exact Cover. In the second step, which constitutes the technical crux of the proof, we present a reduction from Exact Cover to -HyperPath, thus proving Lemma 3.

### 3.1 Reduction from Set Cover to Exact Cover

In this section we show that if Exact Cover can be solved in time significantly better than , then so does Set Cover, thus proving Lemma 2. More formally, we assume that there exist such that Exact Cover on elements and sets can be solved in time and construct an algorithm that solves Set Cover on elements and sets in time for some to be determined later.

By the self-reducibility property of Set Cover, it is enough to show that the decision version of Set Cover can be solved in time . That is, given a Set Cover instance and a threshold , the goal is to decide if there is a set cover of size at most . We will show that for large values of , this problem can be solved using an algorithm by Nederlof [Ned16]. For small values of , we use a reduction by Nederlof to the decision version of Set Partitioning, and then reduce this problem to solving many (but not too many) instances of Exact Cover. To this end, and following the notation suggested by Nederlof, we refer to instances of the decision variant of Set Cover and Set Partitioning as -instances to denote that the number of elements in the ground set is , the number of subsets given is and the threshold given is .

Assume therefore that we are given an -instance of Set Cover. We first note that if , then the following result by Nederlof solves the problem in time .

###### Lemma 5 ([Ned16]).

There is a Monte-Carlo algorithm that takes a Set Cover instance on elements and sets, as well as an integer , and determines in time if there is a set cover of size .

Assume therefore that . Applying the following reduction by Nederlof, we construct an -instance of Set Partitioning with .

###### Lemma 6 ([Ned16]).

There is an algorithm that, given a real , takes an -instance of Set Cover as input and outputs an equivalent -instance of Set Partitioning with sets in time .

Given the -instance of Set Partitioning constructed above we then construct instances of Exact Cover by repeating the following color-coding scheme independently at random. Sample a random coloring of the input sets to colors. Add new elements, each one associated with a different color, and add each such element to all subsets of that color. Note that this Exact Cover instance has elements, and sets. The following lemma shows that this reduction reduces Set Partitioning to Exact Cover.

###### Lemma 7.

If the Set Partitioning is a ’yes’ instance, then with high probability at least one of the Exact Cover instances is a ’yes’ instance. Conversely, if one of the Exact Cover instances is a ’yes’ instance, then the Set Partitioning instance is a ’yes’ instance with certainty.

###### Proof.

Assume first that the -instance of Set Partitioning is a ’yes’ instance. Then there exists a partition of size . With probability at least , a uniform coloring of the sets colors each set of the partition with a different color. Therefore for every new element added, there is at most one set in the partition with the same color, and therefore there is an exact cover in the corresponding instance. Since the reduction constructs independent instances, with high probability at least one will be a ’yes’ instance. Conversely, assume that one of the Exact Cover instances is a ’yes’ instance, and consider an exact cover for this instance. Since the sets in the cover are disjoint, for every new element added, there is at most one subset in the cover containing it. We can therefore conclude that no two subsets are colored with the same color. Removing the new elements yields a feasible solution to the Set Partitioning instance in which every subset is colored differently. Therefore the cover consists of at most subsets. ∎

By our original assumption, each of the Exact Cover instances can be solved in time . Therefore the total time required to solve all instances is at most

 n22t⋅O(m′c⋅2(1−γ)n′)≤O(n224√δn⋅mc2cδn⋅2(1−γ)(1+4√δ)n)=O∗(2(24√δ+cδ+(1−γ)(1+4√δ))n).

For small enough choice of (depending only on and ), this is at most . This completes the proof of Lemma 2.

### 3.2 Reduction from Exact Cover to k-HyperPath

In this section we show that if -HyperPath can be solved in time significantly better than , then so does Exact Cover, thus proving Lemma 3. More formally, we show that if there exists a constant and an integer such that -HyperPath on can be solved in time then Exact Cover on elements and sets can be solved in time for some to be determined later.

To this end, let and be an Exact Cover instance, and let be fixed. We will present a procedure that runs in time polynomial in and constructs a -HyperPath instance on an undirected -uniform hypergraph with nodes and . We first present the construction under the following assumption. For sake of fluency we will show how to discard it after presenting the construction.

###### Assumption 1.

, divides , and for every , .

We start by defining the vertex set . For every , the hypergraph has a node labeled (the distinction between the node and the corresponding element will be clear from the context). In addition, for every and we define a node labeled . The former set of nodes will be referred to as element-nodes and the latter one as set-nodes. Finally, we add two more element-nodes labeled and two set-nodes labeled . Next we turn to define the set of hyperedges, also demonstrated in Figure 1. Loosely speaking has four types of edges. Internal hyperedges consist of nodes associated with a single set, transition edges consist of nodes associated with a two disjoint sets, starting hyperedges (resp. ending hyperedges) consist of nodes associated with a single set together with a starting (resp. ending) node.

To define the edges formally, for every and we let denote the th element in 111e.g. if then .. We emphasize that is simply a new notation for an element in . Therefore while for every and , , it might be the case that . Loosely speaking, the element-nodes are a "common resource" shared by all sets, while each set has "its own" set-nodes. Finally, although the edges are undirected, intuitively it might prove useful for the reader to think of the edge as a sequence, rather than a set.

Every internal edge contains a sequence of either or elements-nodes, all belonging to the same set. In the former case, the edge begins and ends with a set-node. In the latter, the edge contains a set-node in the midst of the sequence. Formally, for every we define internal edges as follows.

 {uji}∪{xℓi}j+r−3ℓ=j∪{uj+r−2i} ∀j∈[|Si|−(r−2)] {xℓi}j+hℓ=j∪{uj+h+1i}∪{xℓi}j+r−2ℓ=j+h+1 ∀j∈[|Si|−(r−2)],h∈[0,r−3]

Let be such that are disjoint. A transition edge contains a sequence of either or element-nodes, the first part of which consists of elements of and ends with , and the second is either empty or consists of elements of starting with . In the former case, the edge begins with a set-node associated with and ends with a set-node associated with . In the latter, the edge either contains a set-node associated with in the midst of the subsequence associated with elements or a set-node associated with in the midst of the subsequence associated with elements. Formally, for all such that the transition hyperedges are defined as follows.

 {u|Si|−ji}∪{xℓi}|Si|ℓ=|Si|−j∪{xℓi′}r−3−jℓ=1∪{ur−2−ji′} ∀j∈[0,r−3] {xℓi}|Si|−j+hℓ=|Si|−j∪{u|Si|−j+h+1i}∪{xℓi}|Si|ℓ=|Si|−j+h+1∪{xℓi′}r−j−2ℓ=1 ∀j∈[r−3],h∈[0,j−1] {xℓi}|Si|ℓ=|Si|−j+1∪{xℓi′}hℓ=1∪{uh+1i′}∪{xℓi′}r−j−1ℓ=h+1 ∀j∈[r−3],h∈[r−j−2]

Finally, we define the starting and ending edges. Intuitively, these edges are destined to be the start and ending of the desired path. Formally, for every we define the following.

 {ustart,xstart}∪{xℓi}r−3ℓ=1∪{ur−2i} {xstart}∪{xℓi}r−2ℓ=1∪{ur−2i} {u|Si|−(r−3)i}∪{xℓi}|Si|ℓ=|Si|−(r−4)∪{uend,xend} {u|Si|−(r−3)i}∪{xℓi}|Si|ℓ=|Si|−(r−3)∪{xend}

To complete the -HyperPath instance we set . Note that by Assumption 1, is a positive integer. The following claim is straightforward.

###### Claim 8.

Given the Exact Cover instance , we can construct in polynomial time.

We will now show that contains a path of length if and only if the Exact Cover instance is a ’yes’ instance. We first show that if contains a path of length then the Exact Cover instance is a ’yes’ instance. To this end, assume there is a tight path

 P=v1−v2−…−vk

of length in . Let be the collection of all sets in that have a set-node in . Formally, let then . We will show the following.

###### Lemma 9.

is an exact cover of .

To prove the lemma we start with characterizing the structure of . In what follows, we refer to hyperedges containing exactly two set-nodes as heavy and to hyperedges containing exactly one set-node as light. The following straightforward claim follows directly from the construction.

###### Claim 10.

Let be two hyperedges, and let and .

1. contains at most one set-node.

2. If is light and then . If then .

3. If are both light, and , then contains at least two element-nodes.

4. If are both heavy, and , then .

###### Lemma 11.

Let be such that are consecutive set nodes in . Then .

###### Proof.

We will start by proving . Since is tight, , and since every edge contains at least one set-node, thus . Assume towards contradiction that . Since , either or . Without loss of generality, assume (the other case is analogous). Denote . By Claim 10, since share the set-node , then are all element-nodes. Therefore both contain only one set-node, namely , which they also share, however their intersection contains only one element-node, in contradiction to Claim 10. Therefore .

Next we prove that . Assume first that . Then and are both edges of that share , and by Claim 10 cannot share . Therefore thus . Otherwise, if , then . Since , there exists such that is a set-node. By the first part of the proof, , and since , then by the proof for the case we get that . Therefore are both heavy, and they share . By Claim 10, they do not have any element-node in common, and therefore thus . We conclude that . ∎

We can now give a complete characterization of in terms of set-nodes and element-nodes.

###### Lemma 12.

For every , is a set node if and only if divides .

###### Proof.

Let be such that are the only set-nodes in in consecutive order. From the previous lemma it follows that between every two set-nodes there are exactly element-nodes. It follows in addition by induction that . Therefore the number of element-nodes between and is . In addition, the first nodes, as well as the last are element-nodes. Therefore

 (t−1)(r−2)+(α1−1)+(k−αt)≤n+2 (1)

By the definition of we have that

 (k−αt)+(αt−j1)+(α1−1)=k−1=n+2r−2(r−1),

and therefore

 n+2=(r−2)k−1r−1=(t−1)(r−2)+(r−2)(k−αt)+(α1−1)r−1. (2)

Combining (1) and (2) we get that . It follows that , and therefore and . The lemma now follows by simple induction. ∎

###### Corollary 13.

Every element-node appears exactly once in . Moreover, , , and .

###### Proof.

From Lemma 12 the number of element-nodes in is . Since is simple, every element-node appears exactly once in , and specifically and . Therefore must contain at least one starting edge and one ending edge. For every , if is an element-node, then there is a set node such that there are at least edges on containing both and and no other set-node. Since for every and for every set node , there is exactly one edge in that contains both and and no other set-node, it follows that . Without loss of generality, and . Since every base hyperedge containing (resp. ) must contain (resp. ), it follows that and . ∎

In what follows, we show that all element nodes of a given set appear consecutively along the path, and moreover, every two sets whose nodes are visited by the path are, in fact, disjoint.

###### Lemma 14.

Let and let be such that . Then and if then .

###### Proof.

First note that since then . We prove the claim by induction on . If then the edge is a starting edge, and therefore . By Claim 10 every light edge that contains must also contain and . The only two nodes contained in all light edges in that contain are and , it follows that . Since is a heavy starting edge, . Therefore and .

Assume therefore that the claim holds for all , and let . Then is also a set node, and by the induction hypothesis, the claim holds for . Let and be such that . If then is a heavy internal edge containing . By the induction hypothesis, . Therefore by the construction of internal edges, , and and . By arguments similar to the first part of the proof we get that , and therefore and .

Otherwise, if , then is a heavy transition edge containing . Again, by the induction hypothesis, . By the construction of transition hyperedges we get that and . If then in addition , and by arguments similar to the first part of the proof and . If then is a transition light edge such that . Since we get that . ∎

The following follows from the previous lemma by induction.

###### Proposition 15.

Let and let be such that . Then

1. For every , ; and

2. For every , .

Moreover, if then and if then .

###### Corollary 16.

Let , then for every the only nodes between and on are either element-nodes or set-nodes that are associated with .

We are now ready to prove Lemma 9.

###### Proof of Lemma 9.

We will first show that . Let . Then there is some such that . Let be such that and are the set-nodes preceding and following in respectively. Then . By the construction of , there exist and such that either or is and . Since then and therefore .

Next, let be such that . Then there exist and such that . That is, there exist such that and . Without loss of generality, we may assume , and there are no set-nodes associated with between and (otherwise we take the last set-node associated with before ). Then is a heavy transition hyperedge. If then by definition of transition hyperedges, . Otherwise, none of the element nodes in are associated with , and moreover, . From Corollary 16 it follows that the elements of are visited by in the order and similarly the elements of are visited in the order . Since is visited by after then we get that . ∎

We have therefore proved that if there is a tight path of length in , then the Exact Cover is a ’yes’ instance. Conversely, assume that the Exact Cover instance is a ’yes’ instance and let be an exact cover. Since is an exact cover, for every there exist a unique pair such that . We can therefore order the elements of according to a lexicographic ordering. That is for all and , comes before if and only if or and . Consider the following sequence of element-nodes.

 xstart−x11−…−x|S1|1−x12−…−x|S2|2−x13−…−x|St|t−xend.

Between every element-nodes, insert the corresponding set-node. That is, if the element-node that follows the set-node is , then the set-node is . Add in the beginning and end of the sequence respectively. The following claim is proved similarly to the claims used to prove the previous direction.

###### Claim 17.

The sequence constructed above constitutes a tight path of length in .

We have therefore proved that there exists an exact cover if and only if there is a tight path of length in , thus completing the proof of Theorem 1.

Given an Exact Cover instance , we can augment by new elements for some such that divides . Call the new set . We then create collections of subsets by defining for every . Note that . Next, for every we define a collection as follows. For every pairwise-disjoint sets in , we add their union to . The following is straightforward.

###### Claim 18.

Given and

1. we can construct in time ;

2. for every and every set we get that ; and

3. is a ’yes’ instance for Exact Cover if and only if is a ’yes’ instance for Exact Cover and has an exact cover of size for some positive integer .

Therefore is a ’yes’ instance for Exact Cover if and only if there exists such that is a ’yes’ instance for Exact Cover. Performing the reduction to -HyperPath on every instance separately we get a reduction of a general Exact Cover instance to -HyperPath instances.

## 4 Algorithm for k-HyperPath

In this section we show that -HyperPath can be solved in time , thus proving Theorem 4. We follow the ideas of Koutis [Kou08] and of Williams [Wil09], with additional ideas to take care of our generalization. A short introduction to arithmetic circuits follows.

#### Arithmetic Circuits

An arithmetic circuit over a specified ring is a directed acyclic graph with nodes labeled from , where are the input variables of the circuit. Nodes with zero out-degree are called output nodes, and nodes with labels from are called input nodes. The size of the circuit is the number of nodes in it. Clearly, every output node can be associated with a polynomial on . A polynomial is said to contain a multilinear term if it contains a term of the form for a non-empty in the standard monomial expansion of . See [BCS97] for more details on arithmetic circuits.

#### The Algorithm

Given a hypergraph , we define a polynomial on the set of variables